aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcvs2svn2005-01-24 15:46:33 +0000
committercvs2svn2005-01-24 15:46:33 +0000
commite6a05dbef707dc10e546ef8fef8fc2a8b7d805bf (patch)
tree7061a2d781348fa7d5965b7d7dd5d7ef6b27a7b0
parente1ed2c6d78bb616e24166c13126adba1b95ea4ea (diff)
downloadtkzinc-POSTSCRIPT.zip
tkzinc-POSTSCRIPT.tar.gz
tkzinc-POSTSCRIPT.tar.bz2
tkzinc-POSTSCRIPT.tar.xz
This commit was manufactured by cvs2svn to create branch 'POSTSCRIPT'.POSTSCRIPT
-rw-r--r--.cvsignore17
-rw-r--r--BUGS16
-rw-r--r--Copyright17
-rw-r--r--Makefile.in520
-rw-r--r--Perl/.cvsignore5
-rw-r--r--Perl/Makefile.PL.in140
-rw-r--r--Perl/README81
-rw-r--r--Perl/Zinc.pm.in157
-rw-r--r--Perl/Zinc.xs59
-rw-r--r--Perl/Zinc/Debug.pm3023
-rw-r--r--Perl/Zinc/Graphics.pm3067
-rw-r--r--Perl/Zinc/Graphics.pod1749
-rw-r--r--Perl/Zinc/Logo.pm238
-rw-r--r--Perl/Zinc/Text.pm262
-rw-r--r--Perl/Zinc/Trace.pm227
-rw-r--r--Perl/Zinc/TraceErrors.pm149
-rw-r--r--Perl/Zinc/TraceUtils.pm111
-rw-r--r--Perl/debug/.cvsignore4
-rw-r--r--Perl/demos/.cvsignore2
-rw-r--r--Perl/demos/Makefile.PL7
-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
-rw-r--r--Perl/demos/t/no-test.t8
-rw-r--r--Perl/demos/zinc-demos502
-rwxr-xr-xPerl/export2cpan173
-rw-r--r--Perl/t/.cvsignore2
-rw-r--r--Perl/t/AnimatedGradient.t175
-rw-r--r--Perl/t/Bbox.t242
-rw-r--r--Perl/t/Coords.t151
-rw-r--r--Perl/t/Images.t212
-rw-r--r--Perl/t/Import.t31
-rw-r--r--Perl/t/PreviousKnownBugs.t61
-rw-r--r--Perl/t/Test/Builder.pm1408
-rw-r--r--Perl/t/Test/Harness.pm1168
-rw-r--r--Perl/t/Test/Harness/Assert.pm68
-rw-r--r--Perl/t/Test/Harness/Iterator.pm61
-rw-r--r--Perl/t/Test/Harness/Straps.pm667
-rw-r--r--Perl/t/Test/More.pm1248
-rw-r--r--Perl/t/TestLog.pm306
-rw-r--r--Perl/t/Text.t58
-rw-r--r--Perl/t/Transformations.t304
-rw-r--r--Perl/t/find.t200
-rw-r--r--Perl/t/test-methods.pl689
-rw-r--r--Perl/t/test-no-crash.pl880
-rw-r--r--Perl/t/testdoc.pl274
-rw-r--r--Perl/t/text.t161
-rw-r--r--Perl/t/traceutils.t89
-rw-r--r--Python/library/Zinc.py.in452
-rw-r--r--README294
-rw-r--r--aclocal.m4171
-rw-r--r--bootstrap3
-rw-r--r--buildperl.tcl40
-rwxr-xr-xconfigure4656
-rw-r--r--configure.in236
-rw-r--r--debian/.cvsignore8
-rw-r--r--debian/README.debian6
-rw-r--r--debian/changelog1374
-rw-r--r--debian/control39
-rw-r--r--debian/copyright22
-rwxr-xr-xdebian/rules125
-rw-r--r--debian/zinc-python.postinst23
-rw-r--r--debian/zinc-python.prerm11
-rw-r--r--demos/allOptions.tcl121
-rw-r--r--demos/atomicGroups.tcl184
-rw-r--r--demos/clipping.tcl123
-rw-r--r--demos/colorCircular.tcl63
-rw-r--r--demos/colorX.tcl48
-rw-r--r--demos/colorY.tcl48
-rw-r--r--demos/contours.tcl202
-rw-r--r--demos/curveBezier.tcl265
-rw-r--r--demos/data/hegias_parouest_TE.vidbin9216 -> 0 bytes
-rw-r--r--demos/data/videomap_orlybin67584 -> 0 bytes
-rw-r--r--demos/data/videomap_paris-w_90_2bin8192 -> 0 bytes
-rw-r--r--demos/fillRule.tcl105
-rw-r--r--demos/groupsInAtcStrips.tcl902
-rw-r--r--demos/groupsPriority.tcl250
-rw-r--r--demos/iconTransform.tcl157
-rw-r--r--demos/images/background_texture.gifbin19979 -> 0 bytes
-rw-r--r--demos/images/paper-grey.gifbin1540 -> 0 bytes
-rw-r--r--demos/images/paper-grey1.gifbin1540 -> 0 bytes
-rw-r--r--demos/images/paper.gifbin1529 -> 0 bytes
-rw-r--r--demos/images/photoAlpha.pngbin77053 -> 0 bytes
-rw-r--r--demos/images/stripped_texture.gifbin123 -> 0 bytes
-rw-r--r--demos/images/zinc.gifbin1461 -> 0 bytes
-rw-r--r--demos/items.tcl144
-rw-r--r--demos/labelformat.tcl86
-rw-r--r--demos/lines.tcl58
-rw-r--r--demos/magicLens.tcl306
-rw-r--r--demos/pathTags.tcl319
-rw-r--r--demos/photoAlpha.tcl162
-rw-r--r--demos/reliefs.tcl278
-rw-r--r--demos/simpleInteractionTrack.tcl232
-rw-r--r--demos/simpleRadar.tcl403
-rw-r--r--demos/testGraphics.tcl2130
-rw-r--r--demos/textInput.tcl80
-rw-r--r--demos/tiger.tcl605
-rw-r--r--demos/tkZincLogo.tcl168
-rw-r--r--demos/transforms.tcl506
-rw-r--r--demos/triangles.tcl48
-rw-r--r--demos/windowContours.tcl92
-rw-r--r--demos/zinc-widget331
-rw-r--r--doc/.cvsignore19
-rw-r--r--doc/alledges.pngbin1684 -> 0 bytes
-rw-r--r--doc/allgradients.pngbin11103 -> 0 bytes
-rw-r--r--doc/alllineshapes.pngbin2672 -> 0 bytes
-rw-r--r--doc/allreliefs.pngbin4878 -> 0 bytes
-rw-r--r--doc/alphastip.pngbin4154 -> 0 bytes
-rw-r--r--doc/atcsymb.pngbin2206 -> 0 bytes
-rw-r--r--doc/fillrule.pngbin7404 -> 0 bytes
-rw-r--r--doc/refman.tex4914
-rw-r--r--doc/tabularexample.pngbin456 -> 0 bytes
-rw-r--r--doc/textthroughholes.pngbin6309 -> 0 bytes
-rw-r--r--doc/tkzinclogo.pngbin13451 -> 0 bytes
-rw-r--r--doc/trackexample.pngbin2626 -> 0 bytes
-rw-r--r--doc/waypointexample.pngbin987 -> 0 bytes
-rw-r--r--library/pkgIndex.tcl13
-rw-r--r--library/zincGraphics.tcl1322
-rw-r--r--library/zincLogo.tcl107
-rw-r--r--library/zincText.tcl191
-rw-r--r--libtess/GL/gl.h2585
-rw-r--r--libtess/GL/glext.h5024
-rw-r--r--libtess/Imakefile60
-rw-r--r--libtess/README447
-rw-r--r--libtess/alg-outline229
-rw-r--r--libtess/dict-list.h107
-rw-r--r--libtess/dict.c117
-rw-r--r--libtess/dict.h107
-rw-r--r--libtess/geom.c271
-rw-r--r--libtess/geom.h90
-rw-r--r--libtess/glu.h325
-rw-r--r--libtess/gluos.h50
-rw-r--r--libtess/libtess_la_SOURCES27
-rw-r--r--libtess/memalloc.c62
-rw-r--r--libtess/memalloc.h65
-rw-r--r--libtess/mesh.c796
-rw-r--r--libtess/mesh.h273
-rw-r--r--libtess/normal.c259
-rw-r--r--libtess/normal.h52
-rw-r--r--libtess/priorityq-heap.c259
-rw-r--r--libtess/priorityq-heap.h114
-rw-r--r--libtess/priorityq-sort.h124
-rw-r--r--libtess/priorityq.c267
-rw-r--r--libtess/priorityq.h124
-rw-r--r--libtess/render.c505
-rw-r--r--libtess/render.h59
-rw-r--r--libtess/sweep.c1362
-rw-r--r--libtess/sweep.h84
-rw-r--r--libtess/tess.c634
-rw-r--r--libtess/tess.h180
-rw-r--r--libtess/tessmono.c208
-rw-r--r--libtess/tessmono.h78
-rw-r--r--redhat/changelog108
-rw-r--r--redhat/perl-Tk-Zinc.spec148
-rw-r--r--redhat/rules31
-rw-r--r--sandbox/Controls.pm224
-rw-r--r--sandbox/alledges.pl47
-rw-r--r--sandbox/allgradients.pl64
-rw-r--r--sandbox/allgradients.tcl48
-rw-r--r--sandbox/alllineshapes.pl47
-rw-r--r--sandbox/allreliefs.pl54
-rw-r--r--sandbox/allreliefs.tcl30
-rw-r--r--sandbox/bouton-down.xpm342
-rw-r--r--sandbox/bouton.xpm329
-rw-r--r--sandbox/conical.tcl18
-rw-r--r--sandbox/contours.tcl45
-rw-r--r--sandbox/controls.tcl158
-rw-r--r--sandbox/defs.tcl1097
-rw-r--r--sandbox/fvwm.xbm21
-rw-r--r--sandbox/lines.pl35
-rw-r--r--sandbox/logo.gifbin402 -> 0 bytes
-rw-r--r--sandbox/smooth.tcl34
-rw-r--r--sandbox/testarc.tcl44
-rw-r--r--sandbox/testbezier.pl190
-rw-r--r--sandbox/testbezier.tcl131
-rw-r--r--sandbox/testbitmaps.tcl86
-rw-r--r--sandbox/testicon.tcl102
-rw-r--r--sandbox/testplug.pl51
-rw-r--r--sandbox/testpoly.tcl157
-rw-r--r--sandbox/testrect.pl99
-rw-r--r--sandbox/testrelief.pl73
-rw-r--r--sandbox/testrelief.tcl45
-rw-r--r--sandbox/testshape.pl132
-rw-r--r--sandbox/testshape.tcl18
-rw-r--r--sandbox/testtext.tcl138
-rw-r--r--sandbox/testwind.tcl19
-rw-r--r--sandbox/testzinc.pl503
-rw-r--r--sandbox/textexpand.tcl6
-rw-r--r--sandbox/texture-bois1.xpm320
-rw-r--r--sandbox/texture-paper.xpm87
-rw-r--r--sandbox/trash.xbm6
-rw-r--r--sandbox/triangles.pl69
-rw-r--r--sandbox/xpenguin.pngbin10148 -> 0 bytes
-rw-r--r--sandbox/zinc.tcl284
-rw-r--r--sandbox/zinc.test154
-rw-r--r--starkit.tcl.in203
-rw-r--r--starkit/demo.tcl4
-rw-r--r--starkit/main.tcl35
-rw-r--r--tclconfig/README.txt26
-rw-r--r--tclconfig/install-sh119
-rw-r--r--tclconfig/tcl.m43179
-rw-r--r--tests/all.tcl8
-rw-r--r--tests/rectangle.test48
-rw-r--r--tkzinc.m4170
-rw-r--r--win/Tkzinc.aip.in118
-rw-r--r--win/Tkzincperl.aip.in151
-rw-r--r--win/WinPort.c1042
-rw-r--r--win/makefile.vc.in130
-rw-r--r--win/package.tcl76
253 files changed, 0 insertions, 78272 deletions
diff --git a/.cvsignore b/.cvsignore
deleted file mode 100644
index a489df5..0000000
--- a/.cvsignore
+++ /dev/null
@@ -1,17 +0,0 @@
-Makefile
-depends
-config.h
-config.cache
-config.log
-config.status
-build
-tk
-bugs
-om
-ptk
-*.prj
-*.pws
-*.cache
-export2cpan
-build-stamp
-pkgIndex.tcl
diff --git a/BUGS b/BUGS
deleted file mode 100644
index 521e0e6..0000000
--- a/BUGS
+++ /dev/null
@@ -1,16 +0,0 @@
-Text stippling is not available under openGL.
-
-Line ends and line joins are not fully implemented under openGL.
-The default behavior if to draw round ends and joins.
-
-Line dashes are not really usable in openGL. Some cases work ok,
-like aligned rectangles and other not, like curves and arcs.
-
-Tiling/stippling begin on the item or item bounding box edge
-rather than on the border edge so that the tile/stipple is
-partially masked by the border.
-
-Item tiling is not available for Windows GDI.
-
-Maps are not rendered filled in openGL. The code of maps still
-lags behind.
diff --git a/Copyright b/Copyright
deleted file mode 100644
index df4bdb2..0000000
--- a/Copyright
+++ /dev/null
@@ -1,17 +0,0 @@
- Copyright (c) 1993 - 2003 CENA, Patrick Lecoanet --
-
- This code is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This code is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public
- License along with this code; if not, write to the Free
- Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
- MA 02111-1307, USA.
-
diff --git a/Makefile.in b/Makefile.in
deleted file mode 100644
index 761fcf7..0000000
--- a/Makefile.in
+++ /dev/null
@@ -1,520 +0,0 @@
-# Copyright (c) 1993 - 2003 CENA, Patrick Lecoanet --
-#
-# This code is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Library General Public
-# License as published by the Free Software Foundation; either
-# version 2 of the License, or (at your option) any later version.
-#
-# This code is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Library General Public License for more details.
-#
-# You should have received a copy of the GNU Library General Public
-# License along with this code; if not, write to the Free
-# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#
-# $Revision$
-#
-#
-# This Makefile.in is derived from the Sample TEA template which is:
-#
-# Copyright (c) 1999 Scriptics Corporation.
-# Copyright (c) 2002 ActiveState SRL.
-#
-
-#========================================================================
-# Enumerate the names of the source files included in this package.
-# EXTRA_SOURCES will be replaced by WIN_SOURCES or UNIX_SOURCES, as is
-# appropriate for your platform. It is not important to specify the
-# directory, as long as it is the $(srcdir) or in the generic, win or
-# unix subdirectory.
-#========================================================================
-
-Atc_SOURCES = @Atc_SOURCES@
-Tkzinc_SOURCES = Tabular.c Rectangle.c Arc.c Curve.c Item.c \
- PostScript.c Attrs.c Draw.c Geo.c List.c \
- perfos.c Transfo.c Group.c Icon.c Text.c \
- Image.c Color.c Field.c Triangles.c Window.c \
- tkZinc.c @EXTRA_SOURCES@ $(Atc_SOURCES)
-Tess_SOURCES = dict.c geom.c memalloc.c mesh.c normal.c priorityq.c \
- render.c sweep.c tess.c tessmono.c
-
-WIN_SOURCES = WinPort.c
-UNIX_SOURCES =
-
-#========================================================================
-# Identify the object files. This replaces .c with .$(OBJEXT) for all
-# the named source files. These objects are created and linked into the
-# final library.
-# Normally we would use $(OBJEXT), but certain make executables won't do
-# the extra macro in a macro conversion properly.
-#
-# "Tkzinc_LIB_FILE" refers to the library (dynamic or static as per
-# configuration options) composed of the named objects.
-#========================================================================
-
-Tkzinc_OBJECTS = $(Tkzinc_SOURCES:.c=.@OBJEXT@)
-Tess_OBJECTS = $(Tess_SOURCES:.c=.@OBJEXT@)
-Tkzinc_LIB_FILE = @Tkzinc_LIB_FILE@
-Tess_LIB_FILE = @Tess_LIB_FILE@
-
-#========================================================================
-# RUNTIME_SOURCES identifies Tcl runtime files that are associated with
-# this package that need to be installed, if any.
-#========================================================================
-
-RUNTIME_SOURCES = zincLogo.tcl zincText.tcl zincGraphics.tcl
-
-#========================================================================
-# This is a list of header files to be installed
-#========================================================================
-
-GENERIC_HDRS =
-
-#========================================================================
-# Nothing of the variables below this line need to be changed.
-#========================================================================
-
-lib_BINARIES = $($(PACKAGE)_LIB_FILE)
-aux_BINARIES = @aux_BINARIES@
-bin_BINARIES = @bin_BINARIES@
-BINARIES = $(Tess_LIB_FILE) $(lib_BINARIES)
-
-SHELL = @SHELL@
-
-srcdir = @srcdir@
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-
-bindir = @bindir@
-libdir = @libdir@
-datadir = @datadir@
-mandir = @mandir@
-includedir = @includedir@
-
-DESTDIR =
-
-PKG_DIR = $(PACKAGE)$(VERSION)
-pkgdatadir = $(datadir)/$(PKG_DIR)
-pkglibdir = $(libdir)/$(PKG_DIR)
-pkgincludedir = $(includedir)/$(PKG_DIR)
-
-top_builddir = .
-
-tess_dir = $(srcdir)/libtess
-generic_dir = $(srcdir)/generic
-unix_dir = $(srcdir)/unix
-windows_dir = $(srcdir)/win
-
-INSTALL = @INSTALL@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-
-PACKAGE = @PACKAGE@
-VERSION = @VERSION@
-CC = @CC@
-CFLAGS_DEBUG = @CFLAGS_DEBUG@
-CFLAGS_DEFAULT = @CFLAGS_DEFAULT@
-CFLAGS_OPTIMIZE = @CFLAGS_OPTIMIZE@
-CFLAGS_WARNING = @CFLAGS_WARNING@
-CLEANFILES = @CLEANFILES@
-EXEEXT = @EXEEXT@
-LDFLAGS_DEBUG = @LDFLAGS_DEBUG@
-LDFLAGS_DEFAULT = @LDFLAGS_DEFAULT@
-LDFLAGS_OPTIMIZE = @LDFLAGS_OPTIMIZE@
-MAKE_LIB = @MAKE_LIB@
-MAKE_SHARED_LIB = @MAKE_SHARED_LIB@
-MAKE_STATIC_LIB = @MAKE_STATIC_LIB@
-OBJEXT = @OBJEXT@
-RANLIB = @RANLIB@
-SHLIB_CFLAGS = @SHLIB_CFLAGS@
-SHLIB_LD = @SHLIB_LD@
-SHLIB_LDFLAGS = @SHLIB_LDFLAGS@
-SHLIB_LD_LIBS = @SHLIB_LD_LIBS@
-STLIB_LD = @STLIB_LD@
-TCL_DEFS = @TCL_DEFS@
-TCL_BIN_DIR = @TCL_BIN_DIR@
-TCL_SRC_DIR = @TCL_SRC_DIR@
-TK_BIN_DIR = @TK_BIN_DIR@
-TK_SRC_DIR = @TK_SRC_DIR@
-#
-# This is necessary for packages that use private Tcl headers
-TCL_TOP_DIR_NATIVE = @TCL_TOP_DIR_NATIVE@
-TK_TOP_DIR_NATIVE = @TK_TOP_DIR_NATIVE@
-# Not used, but retained for reference of what libs Tcl required
-TCL_LIBS = @TCL_LIBS@
-
-
-#========================================================================
-# TCLLIBPATH seeds the auto_path in Tcl's init.tcl so we can test our
-# package without installing. The other environment variables allow us
-# to test against an uninstalled Tcl. Add special env vars that you
-# require for testing here (like TCLX_LIBRARY).
-#========================================================================
-
-EXTRA_PATH = $(top_builddir):$(TCL_BIN_DIR)
-TCLSH_ENV = TCL_LIBRARY=`@CYGPATH@ $(TCL_SRC_DIR)/library` \
- LD_LIBRARY_PATH="$(EXTRA_PATH):$(LD_LIBRARY_PATH)" \
- LIBPATH="$(EXTRA_PATH):${LIBPATH}" \
- SHLIB_PATH="$(EXTRA_PATH):${SHLIB_PATH}" \
- PATH="$(EXTRA_PATH):$(PATH)" \
- TCLLIBPATH="$(top_builddir)"
-TCLSH_PROG = @TCLSH_PROG@
-WISH_PROG = @WISH_PROG@
-TCLSH = $(TCLSH_ENV) $(TCLSH_PROG)
-WISH = $(TCLSH_ENV) $(WISH_PROG)
-SHARED_BUILD = @SHARED_BUILD@
-
-# The local includes must come first, because the TK_XINCLUDES can be
-# just a comment
-INCLUDES = -I$(srcdir)/generic \
- @TCL_INCLUDES@ @TK_INCLUDES@ @TK_XINCLUDES@ @GL_INCLUDES@ -I$(tess_dir)
-
-EXTRA_CFLAGS = $(MEM_DEBUG_FLAGS) @EXTRA_CFLAGS@
-
-DEFS = $(TCL_DEFS) @DEFS@ $(EXTRA_CFLAGS)
-
-CONFIG_CLEAN_FILES = Makefile
-
-CPPFLAGS = @CPPFLAGS@
-LIBS = @LIBS@
-AR = ar
-CFLAGS = @CFLAGS@
-COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-
-#========================================================================
-# Start of user-definable TARGETS section
-#========================================================================
-
-#========================================================================
-# TEA TARGETS. Please note that the "libraries:" target refers to platform
-# independent files, and the "binaries:" target inclues executable programs and
-# platform-dependent libraries. Modify these targets so that they install
-# the various pieces of your package. The make and install rules
-# for the BINARIES that you specified above have already been done.
-#========================================================================
-
-all: binaries libraries doc
-
-#========================================================================
-# The binaries target builds executable programs, Windows .dll's, unix
-# shared/static libraries, and any other platform-dependent files.
-# The list of targets to build for "binaries:" is specified at the top
-# of the Makefile, in the "BINARIES" variable.
-#========================================================================
-
-binaries: $(BINARIES) pkgIndex.tcl
-
-libraries:
-
-#========================================================================
-# The doc target is for building man pages. Currently the zinc doc is
-# only available in html and pdf formats. These formats require tools
-# (LaTeX, pdfTeX, LaTeX2html) that are not readily available on all
-# platforms. To ease automatic construction of the package the target
-# doc does not involve the construction of pdf and html.
-#========================================================================
-
-doc:
-
-pdf: doc/refman.tex
- (cd doc; \
- rm -f refman.aux refman.ilg refman.ind refman.out refman.tpt; \
- rm -f refman.idx refman.lof refman.log refman.lot refman.toc; \
- pdflatex refman.tex; \
- pdflatex refman.tex; \
- makeindex refman.idx; \
- pdflatex refman.tex; \
- thumbpdf refman.pdf; \
- pdflatex refman.tex;)
-
-html: doc/refman.tex
- (cd doc; \
- rm -f refman.ilg refman.ind refman.out; \
- rm -f refman.idx refman.lof refman.log refman.lot refman.toc; \
- mkdir -p refman; cp -f *.png refman; \
- latex2html -split 4 -show_section_numbers -local_icons refman.tex)
-
-install: all install-binaries install-libraries install-demos install-doc
-
-install-binaries: binaries install-lib-binaries install-bin-binaries
-
-
-#========================================================================
-# This rule installs platform-independent files, such as header files.
-#========================================================================
-
-install-libraries: libraries
- @if test "x$(GENERIC_HDRS)" != "x"; then \
- mkdir -p $(DESTDIR)$(includedir); \
- echo "Installing header files in $(DESTDIR)$(includedir)"; \
- for i in "$(GENERIC_HDRS)" ; do \
- echo "Installing $$i" ; \
- $(INSTALL_DATA) $$i $(DESTDIR)$(includedir) ; \
- done; \
- fi
-
-#========================================================================
-# This rule installs the demos files and associated images.
-#========================================================================
-
-install-demos:
- @mkdir -p $(DESTDIR)$(pkglibdir)/demos
- @echo "Installing demo files in $(DESTDIR)$(pkglibdir)/demos"
- @for p in $(srcdir)/demos/*; do \
- if test -f $$p; then \
- p=`basename $$p`; \
- echo " Install $$p $(DESTDIR)$(pkglibdir)/demos/$$p"; \
- $(INSTALL_DATA) $(srcdir)/demos/$$p $(DESTDIR)$(pkglibdir)/demos/$$p; \
- fi; \
- done
- @mkdir -p $(DESTDIR)$(pkglibdir)/demos/images
- @mkdir -p $(DESTDIR)$(pkglibdir)/demos/data
- @for p in $(srcdir)/demos/images/*; do \
- if test -f $$p; then \
- p=`basename $$p`; \
- echo " Install $$p $(DESTDIR)$(pkglibdir)/demos/images/$$p"; \
- $(INSTALL_DATA) $(srcdir)/demos/images/$$p $(DESTDIR)$(pkglibdir)/demos/images/$$p; \
- fi; \
- done
- @for p in $(srcdir)/demos/data/*; do \
- if test -f $$p; then \
- p=`basename $$p`; \
- echo " Install $$p $(DESTDIR)$(pkglibdir)/demos/data/$$p"; \
- $(INSTALL_DATA) $(srcdir)/demos/data/$$p $(DESTDIR)$(pkglibdir)/demos/data/$$p; \
- fi; \
- done
-
-#========================================================================
-# Install documentation. Unix manpages should go in the $(mandir)
-# directory.
-#========================================================================
-
-install-doc: doc
- @mkdir -p $(DESTDIR)$(mandir)/mann
- @echo "Installing documentation in $(DESTDIR)$(mandir)"
- @for i in $(srcdir)/doc/*.n; do \
- if test -f $$i; then \
- i=`basename $$i`; \
- echo "Installing $$i"; \
- rm -f $(DESTDIR)$(mandir)/mann/$$i; \
- $(INSTALL_DATA) $(srcdir)/doc/$$i $(DESTDIR)$(mandir)/mann/$$i ; \
- fi \
- done
-
-test: binaries libraries
- $(TCLSH) `@CYGPATH@ $(srcdir)/tests/all.tcl` $(TESTFLAGS) ; \
-
-shell: binaries libraries
- @$(TCLSH) $(SCRIPT)
-
-gdb:
- $(TCLSH_ENV) gdb $(TCLSH_PROG) $(SCRIPT)
-
-depend:
-
-
-#========================================================================
-# $($(PACKAGE)_LIB_FILE) should be listed as part of the BINARIES variable
-# mentioned above. That will ensure that this target is built when you
-# run "make binaries".
-#
-# The $($(PACKAGE)_OBJECTS) objects are created and linked into the final
-# library. In most cases these object files will correspond to the
-# source files above.
-#========================================================================
-
-$($(PACKAGE)_LIB_FILE): $($(PACKAGE)_OBJECTS)
- -rm -f $($(PACKAGE)_LIB_FILE)
- ${MAKE_LIB}
- #$(RANLIB) $($(PACKAGE)_LIB_FILE)
-
-$(Tess_LIB_FILE): $(Tess_OBJECTS)
- -rm -f $(Tess_LIB_FILE)
- ${STLIB_LD} $@ $(Tess_OBJECTS)
- $(RANLIB) $(Tess_LIB_FILE)
-
-#========================================================================
-# We need to enumerate the list of .c to .o lines here.
-#
-# In the following lines, $(srcdir) refers to the toplevel directory
-# containing your extension. If your sources are in a subdirectory,
-# you will have to modify the paths to reflect this:
-#
-# sample.$(OBJEXT): $(srcdir)/generic/sample.c
-# $(COMPILE) -c `@CYGPATH@ $(srcdir)/generic/sample.c` -o $@
-#
-# Setting the VPATH variable to a list of paths will cause the makefile
-# to look into these paths when resolving .c to .obj dependencies.
-# As necessary, add $(srcdir):$(srcdir)/compat:....
-#========================================================================
-
-VPATH = $(srcdir):$(srcdir)/libtess:$(srcdir)/generic:$(srcdir)/unix:$(srcdir)/win
-
-.SUFFIXES: .c .$(OBJEXT)
-
-.c.$(OBJEXT):
- $(COMPILE) -c `@CYGPATH@ $<` -o $@
-
-#========================================================================
-# Create the pkgIndex.tcl file.
-# It is usually easiest to let Tcl do this for you with pkg_mkIndex, but
-# you may find that you need to customize the package. If so, either
-# modify the -hand version, or create a pkgIndex.tcl.in file and have
-# the configure script output the pkgIndex.tcl by editing configure.in.
-#========================================================================
-
-pkgIndex.tcl:
- ( echo package require Tk \; pkg_mkIndex -verbose -load Tk . $($(PACKAGE)_LIB_FILE) \; exit ) | $(TCLSH)
-
-pkgIndex.tcl-hand:
- (echo 'package ifneeded $(PACKAGE) $(VERSION) \
- [list load [file join $$dir $($(PACKAGE)_LIB_FILE)]]'\
- ) > pkgIndex.tcl
-
-#========================================================================
-# Distribution creation
-# You may need to tweak this target to make it work correctly.
-#========================================================================
-
-COMPRESS = tar zcvf $(PKG_DIR).tar.gz $(PKG_DIR)
-DIST_ROOT = /tmp/dist
-DIST_DIR = $(DIST_ROOT)/$(PKG_DIR)
-
-dist-clean:
- rm -rf $(DIST_DIR) $(DIST_ROOT)/$(PKG_DIR).tar.*
-
-dist: dist-clean
- mkdir -p $(DIST_DIR)
- cp -p $(srcdir)/BUGS $(srcdir)/README* $(srcdir)/Copyright* \
- $(srcdir)/aclocal.m4 $(srcdir)/configure $(srcdir)/*.in \
- $(DIST_DIR)/
- chmod 664 $(DIST_DIR)/Makefile.in $(DIST_DIR)/aclocal.m4
- chmod 775 $(DIST_DIR)/configure $(DIST_DIR)/configure.in
-
- -cp -p $(srcdir)/*.[ch] $(DIST_DIR)/
-
- mkdir $(DIST_DIR)/tclconfig
- cp $(srcdir)/tclconfig/install-sh $(srcdir)/tclconfig/tcl.m4 \
- $(DIST_DIR)/tclconfig/
- chmod 664 $(DIST_DIR)/tclconfig/tcl.m4
- chmod +x $(DIST_DIR)/tclconfig/install-sh
-
- -list='demos doc generic libtess debian redhat library mac tests unix win Perl Python'; \
- for p in $$list; do \
- if test -d $(srcdir)/$$p ; then \
- tar cf - --exclude=CVS --exclude=.cvsignore $$p | \
- (cd $(DIST_DIR); tar xf -) \
- fi; \
- done
-
- (cd $(DIST_ROOT); $(COMPRESS);)
-
-#========================================================================
-# End of user-definable section
-#========================================================================
-
-#========================================================================
-# Don't modify the file to clean here. Instead, set the "CLEANFILES"
-# variable in configure.in
-#========================================================================
-
-clean:
- -test -z "$(BINARIES)" || rm -f $(BINARIES)
- -rm -f *.$(OBJEXT) core *.core
- -test -z "$(CLEANFILES)" || rm -Rf $(CLEANFILES)
-
-distclean: clean
- -rm -f *.tab.c *~
- -rm -f $(CONFIG_CLEAN_FILES)
- -rm -f config.cache config.log config.status
-
-#========================================================================
-# Install binary object libraries. On Windows this includes both .dll and
-# .lib files. Because the .lib files are not explicitly listed anywhere,
-# we need to deduce their existence from the .dll file of the same name.
-# Library files go into the lib directory.
-# In addition, this will generate the pkgIndex.tcl
-# file in the install location (assuming it can find a usable tclsh shell)
-#
-# You should not have to modify this target.
-#========================================================================
-
-install-lib-binaries:
- @mkdir -p $(DESTDIR)$(pkglibdir)
- @list='$(lib_BINARIES)'; for p in $$list; do \
- if test -f $$p; then \
- echo " $(INSTALL_PROGRAM) $$p $(DESTDIR)$(pkglibdir)/$$p"; \
- $(INSTALL_PROGRAM) $$p $(DESTDIR)$(pkglibdir)/$$p; \
- echo " $(RANLIB) $(DESTDIR)$(pkglibdir)/$$p"; \
- $(RANLIB) $(DESTDIR)$(pkglibdir)/$$p; \
- ext=`echo $$p|sed -e "s/.*\.//"`; \
- if test "x$$ext" = "xdll"; then \
- lib=`basename $$p|sed -e 's/.[^.]*$$//'`.lib; \
- if test -f $$lib; then \
- echo " $(INSTALL_DATA) $$lib $(DESTDIR)$(pkglibdir)/$$lib"; \
- $(INSTALL_DATA) $$lib $(DESTDIR)$(pkglibdir)/$$lib; \
- fi; \
- fi; \
- fi; \
- done
- @list='$(aux_BINARIES)'; for p in $$list; do \
- if test -f $$p; then \
- echo " Install $$p $(DESTDIR)$(libdir)/$$p"; \
- $(INSTALL_PROGRAM) $$p $(DESTDIR)$(libdir)/$$p; \
- fi; \
- done
- @list='$(RUNTIME_SOURCES)'; for p in $$list; do \
- if test -f $(srcdir)/library/$$p; then \
- echo " Install $$p $(DESTDIR)$(pkglibdir)/$$p"; \
- $(INSTALL_DATA) $(srcdir)/library/$$p $(DESTDIR)$(pkglibdir)/$$p; \
- fi; \
- done
-#
-# Construct a full pkgIndex in the installation directory
- (cd $(DESTDIR)$(pkglibdir); \
- (echo package require Tk \; pkg_mkIndex -load Tk . \
- $(RUNTIME_SOURCES) $($(PACKAGE)_LIB_FILE) \; exit;) | $(TCLSH))
-
-#========================================================================
-# Install binary executables (e.g. .exe files and dependent .dll files)
-# This is for files that must go in the bin directory (located next to
-# wish and tclsh), like dependent .dll files on Windows.
-#
-# You should not have to modify this target, except to define bin_BINARIES
-# above if necessary.
-#========================================================================
-
-install-bin-binaries:
- @mkdir -p $(DESTDIR)$(bindir)
- @list='$(bin_BINARIES)'; for p in $$list; do \
- if test -f $$p; then \
- echo " $(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/$$p"; \
- $(INSTALL_PROGRAM) $$p $(DESTDIR)$(bindir)/$$p; \
- fi; \
- done
-
-.SUFFIXES: .c .$(OBJEXT)
-
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
- cd $(top_builddir) \
- && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-uninstall-binaries:
- list='$(lib_BINARIES)'; for p in $$list; do \
- rm -f $(DESTDIR)$(pkglibdir)/$$p; \
- done
- list='$(RUNTIME_SOURCES)'; for p in $$list; do \
- rm -f $(DESTDIR)$(pkglibdir)/$$p; \
- done
- list='$(bin_BINARIES)'; for p in $$list; do \
- rm -f $(DESTDIR)$(bindir)/$$p; \
- done
-
-.PHONY: all binaries clean depend distclean doc install libraries test
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/Perl/.cvsignore b/Perl/.cvsignore
deleted file mode 100644
index 16b7eff..0000000
--- a/Perl/.cvsignore
+++ /dev/null
@@ -1,5 +0,0 @@
-Makefile
-Zinc.bs
-Zinc.c
-pm_to_blib
-blib
diff --git a/Perl/Makefile.PL.in b/Perl/Makefile.PL.in
deleted file mode 100644
index 611dddb..0000000
--- a/Perl/Makefile.PL.in
+++ /dev/null
@@ -1,140 +0,0 @@
-use 5.006;
-use Tk;
-use Config;
-use Tk::Config;
-use ExtUtils::MakeMaker;
-use strict;
-
-my $TkLibDir = $Tk::library;
-my $platform = $Tk::platform;
-
-my $VERSION = '@MAJOR_VERSION@.@MINOR_VERSION@@PATCHLEVEL@';
-
-
-if (!$TkLibDir)
-{
- print stderr "==================================================================\n";
- print stderr "Could not find the Perl/Tk (pTk) library.\n";
- print stderr "Please, install first Perl/Tk interface before installing Tk::Zinc\n";
- print stderr "==================================================================\n";
- die;
-}
-
-
-print "Configuring version $VERSION for $platform platform...\n";
-print "Using $TkLibDir as Tk library...\n";
-
-my @GENERIC_C = ('Tabular.c', 'Rectangle.c', 'Arc.c', 'Curve.c',
- 'Item.c', 'PostScript.c', 'Attrs.c', 'Draw.c', 'Geo.c', 'List.c',
- 'perfos.c', 'Transfo.c', 'Group.c', 'Icon.c', 'Text.c', 'Image.c', 'Color.c',
- 'Field.c', 'Triangles.c', 'Window.c', 'tkZinc.c');
-
-my @LIBTESS_C = ('dict.c', 'geom.c', 'memalloc.c', 'mesh.c', 'normal.c', 'priorityq.c',
- 'render.c', 'sweep.c', 'tess.c', 'tessmono.c');
-
-my @ATC_C = ('OverlapMan.c', 'Track.c', 'Reticle.c', 'Map.c', 'MapInfo.c');
-
-my @WIN_C = ('WinPort.c');
-
-my @C;
-
-my $WIN = ($platform =~ /win/i);
-
-push @C, @LIBTESS_C, @GENERIC_C ;
-
-my $NeededLibs = ['-L/usr/X11R6/lib -lXext -lX11 -lGL -L.'];
-
-if ($WIN) {
- push @C, @WIN_C;
- $NeededLibs = ['-lopengl32']
-}
-my $ZincObj = "Zinc" . $Config{"_o"};
-
-my $INC = "-I. -I$TkLibDir -I$TkLibDir/pTk -I$TkLibDir/X11";
-
-unless ($WIN) {
- $INC .= " -I/usr/X11R6/include";
-}
-
-# See lib/ExtUtils/MakeMaker.pm for details of how to influence
-# the contents of the Makefile that is written.
-WriteMakefile(
- 'ABSTRACT' => 'a canvas offering groups, tranformations, transparency, color gradient...',
- 'AUTHOR' => 'Patrick Lecoanet <lecoanet@cena.fr>',
- 'NAME' => 'Tk::Zinc',
- 'VERSION' => $VERSION,
- 'PREREQ_PM' => $WIN ? {Tk => 8.004} : {Tk => 8.0},
- 'LIBS' => $NeededLibs,
- 'DEFINE' => &get_flags,
- 'INC' => $INC,
- 'C' => [@C],
- 'XS_VERSION' => $Tk::Config::VERSION,
- 'XS' => {'Zinc.xs' => 'Zinc.c'},
- 'linkext' => {LINKTYPE => 'dynamic'},
- 'depend' => {$ZincObj => '$(O_FILES) Zinc.c'},
- 'LDFROM' => "\$(O_FILES) $ZincObj",
- );
-
-sub get_flags {
- my %DEF_FLAGS = ('GL' => 1,
- 'SHAPE' => 1,
- 'GL_DAMAGE' => 1,
- 'ATC' => 1
- );
-
- foreach my $arg (@ARGV) {
- print "$arg ....\n";
- my ($name, $value) = split(/[=]+/, $arg);
- if ($name =~ /(with-gl)/i) {
- if ($value =~ /no/i) {
- $DEF_FLAGS{'GL'} = 0;
- $DEF_FLAGS{'GL_DAMAGE'} = 0;
- }
- }
- elsif ($name =~ /(with-atc)/i) {
- if ($value =~ /no/i) {
- $DEF_FLAGS{'ATC'} = 0;
- }
- }
- elsif ($name =~ /(with-shape)/i) {
- if ($value =~ /no/i) {
- $DEF_FLAGS{'SHAPE'} = 0;
- }
- }
- }
-
- my $defines = '-DPTK';
-
- if ($WIN) {
- #
- # No shape extension on Windows (planned later).
- $DEF_FLAGS{'SHAPE'} = 0;
- #
- # Visual C++ does not define __STDC__ by default
- $defines .= ' -D__STDC__';
- }
-
- print "Configuring with:\n ";
- foreach my $flag (keys %DEF_FLAGS) {
- print "$flag=", $DEF_FLAGS{$flag} ? 'ok' : 'no', " ";
- if ($DEF_FLAGS{$flag}) {
- $defines = $defines . " " . "-D$flag";
- if ($flag eq 'ATC') {
- push @C, @ATC_C
- }
- }
- }
- if ($Tk::VERSION =~ /^800/) {
- $defines .= " -DPTK_800";
- print "PTK=800";
- } else {
- print "PTK=804";
- }
- print "\n";
- return $defines;
-}
-
-#
-# For the demo
-#
-# perl -Mblib demos/zinc-demos
diff --git a/Perl/README b/Perl/README
deleted file mode 100644
index e090549..0000000
--- a/Perl/README
+++ /dev/null
@@ -1,81 +0,0 @@
-Tk::Zinc - another Canvas which proposes many new functions, some based on openGL
-
-Tk::Zinc for Perl/Tk is available for Linux, Windows and MacOSX.
-the easiest way could be to use he CPAN. However new releases are usually
-first available on www.tkzinc.org/
-
-
-* On a Linux system, you need Perl (>= 5.6) and perl-tk (800 or 804) packages.
-
-* On MacOSX you need:
- - fink with tk-pm package and its dependencies (http://fink.sf.net)
- tk-pm is available in unstable. You can add this binary unstable tree to you /sw/etc/apt/sources.list:
- deb http://fink.opendarwin.org/bbraun 10.3/unstable main crypto
- deb http://fink.opendarwin.org/bbraun 10.3/stable main crypto
- - X11 et X11 sdk from Apple (http://www.apple.com/macosx/x11/)
-
-* On WinXP you need:
- - perl and perl-tk 804,
- - Visual C++ or the Free Visual C++ Command Line Tools
-
-
-
-Install:
-
- perl Makefile.PL
- # you can use the following options: --with-gl=yes|no --with-om=yes|no --with-shape=yes|no
- # current defaults are --with-gl=yes --with-om=yes --with-shape=yes
-
- make
- make test
-
- # to run demos before installing:
- perl -Iblib/arch -Iblib/lib demos/zinc-demos
-
- make install
-
-
-
-WATCH OUT! On Linux it is quite frequent to have both Mesa and proprietary
- openGL libraries installed. This may lead to big problems at
- runtime if the linker picks the wrong library. It is often the
- the case between the static (libGL.a) Mesa library and the dynamic
- (libGL.so) NVidia library. It is very important to assert that
- the link is done with the library matching the openGL driver
- loaded in the X server.
-
-
-up-to-date documentation is also available at http://www.tkzinc.org/index.php/Main/Documentation
-You will find there the reference manual, a FAQ, a mailing list, its archive
-etc...
-The source of the reference manual is available in the full source package,
-which also includes TkZinc for Tcl/Tk, for Perl/Tk, and for Python (Python binding
-are now obsoletes).
-
-
-After installation, we recommend you to launch the zinc-demos script,
-a frontend to more than 30 small demos.
-
-For more information on building Tk::Zinc, a README is available in
-the tkzinc-*tgz tar file (on Tkzinc web site) used for building all
-flavor of TkZinc (ie tcl, perl and python)
-
-This software is delivered under LGPL licence.
-For the copyright, please, read the COPYRIGHT file.
-
-For any question on Tk::Zinc usage, build or installation pb,
-please send email to zinc@tls.cena.fr
-This mailing list can be subscribed from
-http://www.tkzinc.org/index.php/Main/MailingList. You can
-also send a question without subscribing, but you will be asked
-for a confirmation to avoid spam on the list!
-
-
-Authors and Contributors:
-
-Tk::Zinc main author is Patrick Lecoanet
-Sub-Modules, demos and documentation have been developped by
-Daniel Etienne, Christophe Mertz, Jean-Luc Vinot, with contributions
-from Stéphane Chatty, Céline Schlienger, Alexandre Lemort
-Stéphane Conversy contributed to the MacOSX port.
-Many others contributed with their bug reports!
diff --git a/Perl/Zinc.pm.in b/Perl/Zinc.pm.in
deleted file mode 100644
index 0863458..0000000
--- a/Perl/Zinc.pm.in
+++ /dev/null
@@ -1,157 +0,0 @@
-# $Id$
-# $Name$
-
-package Tk::Zinc;
-
-use Tk;
-use Tk::Photo;
-use Carp;
-
-use base qw(Tk::Widget);
-Construct Tk::Widget 'Zinc';
-
-
-use vars qw($VERSION $REVISION);
-
-$REVISION = q$Revision$ ; # this line is automagically modified by CVS
-$VERSION = '@MAJOR_VERSION@.@MINOR_VERSION@@PATCHLEVEL@';
-
-
-bootstrap Tk::Zinc $Tk::VERSION;
-
-sub Tk_cmd { \&Tk::zinc }
-
-sub CreateOptions
-{
- return (shift->SUPER::CreateOptions,'-render')
-}
-
-Tk::Methods("add", "addtag", "anchorxy", "bbox", "becomes", "bind", "cget",
- "chggroup", "clone", "configure", "contour", "coords", "currentpart",
- "cursor", "dchars", "dtag", "find", "fit", "focus", "gdelete", "gettags",
- "gname", "group", "hasanchors", "hasfields", "hastag", "index",
- "insert", "itemcget", "itemconfigure", "lower", "monitor",
- "numparts", "postscript", "raise", "remove", "rotate", "scale",
- "select", "skew", "smooth", "tapply", "tcompose", "tdelete", "tget",
- "transform", "translate", "treset", "trestore", "tsave", "tset",
- "type", "vertexat", "xview", "yview");
-
-## coord0 is a compatibility function usefull for porting old application
-## previously running with Tk::Zinc V <= 3.2.6a
-## The Zinc methode coords0 can/should replace coords as long as no control points are
-## used in curve or rectangle or an arc...
-## This can dramaticaly simplify the port of an old application from Zinc V<3.2.6a to
-## a newer version of Zinc. HOWEVER YOU STILL MUST CHANGE THE CODE OF THIS OLD APPICATION
-##
-## Remember: the incompatible change in Zinc is due to the introduction of
-## control points in curves (and a future release, in arc or rectangle items...)
-sub coords0 {
- if (wantarray) {
- ## we are in list context, so we should convert the returned value
- ## to match the specification of Zinc Version <= 3.2.6a
- my @res = &Tk::Zinc::coords(@_);
- if ( !ref $res[0] ) {
- ## The first item of the list is not a reference, so the
- ## list is guarranted to be a flat list (x, y, x, y, ... x, y)
- return @res;
- }
- else {
- ## The list is a list of references like : [x y] or [x y symbol]
- ## In the latter case, coord0 should warn that there is a control point!
- ## coord0 will return a flatten list of (x, y, ... x , y)
- my @res0;
- foreach my $ref (@res) {
- my @array = @{$ref};
- if ($#array > 1) {
- my $item = $_[1];
- my $zinc = $_[0];
- my $type = $zinc->type($item);
- carp "Using Zinc coord0 compatibility method with item $item (type=$type) which contains a control point: @array";
- }
- push @res0, $array[0];
- push @res0, $array[1];
- }
- return @res0;
- }
- }
- else {
- ## contexte scalaire
- ## le résultat n'était pas utilisé jusqu'à présent, vu le bug...
- ## donc inutile de le convertir!
- return &Tk::Zinc::coords(@_);
- }
-}
-
-1;
-
-__END__
-
-=head1 NAME
-
-Tk::Zinc - TkZinc is another Canvas which proposes many new functions, some based on openGL
-
-=for category Tk Widget Classes
-
-=head1 SYNOPSIS
-
-I<$zinc> = I<$parent>-E<gt>B<Zinc>(?I<options>?);
-
-=head1 DESCRIPTION
-
-I<Zinc> widget is very similar to Tk Canvase in that it supports
-structured graphics. Like the Canvas, TkZinc implements items used to
-display graphical entities. Those items can be manipulated and bindings can be
-associated with them to implement interaction behaviors. But unlike the
-Canvas, TkZinc can structure the items in a hierarchy (with the use of
-group items), has support for affine 2D transforms (i.e. translation, scaling, and
-rotation), 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.
-
-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.
-
-TkZinc full documentation is available as part of the Zinc software as a
-pdf file, B<refman.pdf> and html pages B<refman/index.html>.
-
-As a complement to the reference manual, small Perl/Tk demos of TkZinc are
-also available through a small application named zinc-demos, highly inspired
-from the widget application included in Tk. The aim of these demos are both
-to demonstrates the power of TkZinc and to help newcomers start using
-TkZinc with small examples.
-
-=head1 WHERE CAN I FIND TkZinc?
-
-TkZinc is available as source in tar.gz format or as Debian or RedHat/Mandrake
-packages at http://www.tkzinc.org/ or http://freshmeat.net/projects/zincisnotcanvas/
-
-TkZinc is also available on CPAN since v3.294 (a kind of 3.2.94)
-
-=head1 AUTHOR
-
-Patrick Lecoanet <lecoanet@cena.fr>
-
-=head1 COPYRIGHT
-
-Zinc has been developed by the CENA (Centres d'Etudes de la Navigation
-Aérienne) for its own needs in advanced HMI (Human Machine Interfaces or Interactions).
-Because we are confident in the benefit of free software, the CENA delivered this
-toolkit under the GNU Library General Public License.
-
-This code is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-Library General Public License for more details.
-
-Parts of this software are derived from the Tk toolkit which is copyrighted
-under another open source license by The Regents of the University of California
-and Sun Microsystems, Inc. The GL
-font rendering is derived from Mark Kilgard code described in `A Simple OpenGL-based
-API for Texture Mapped Text' and is copyrighted by Mark Kilgard under an open source license.
-
-=head1 SEE ALSO
-
-L<Tk(1)>, L<zinc-demos(1)>.
-
-=cut
diff --git a/Perl/Zinc.xs b/Perl/Zinc.xs
deleted file mode 100644
index 26cd0c7..0000000
--- a/Perl/Zinc.xs
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- Copyright (c) 1995-1997 Nick Ing-Simmons. All rights reserved.
- This program is free software; you can redistribute it and/or
- modify it under the same terms as Perl itself.
-*/
-
-#include <EXTERN.h>
-#include <perl.h>
-#include <XSUB.h>
-
-#include <tkGlue.def>
-
-#include <pTk/tkPort.h>
-#include <pTk/tkInt.h>
-#ifdef _WIN32
-#include <pTk/tkWinInt.h>
-#endif
-#include <pTk/tkImgPhoto.h>
-#include <pTk/tkVMacro.h>
-#include <tkGlue.h>
-#include <tkGlue.m>
-
-extern int
-ZincObjCmd(
- ClientData client_data,
- Tcl_Interp* interp,
- int argc,
- Tcl_Obj* CONST args[]);
-
-extern int
-ZnVideomapObjCmd(
- ClientData client_data,
- Tcl_Interp* interp,
- int argc,
- Tcl_Obj* CONST args[]);
-
-extern int
-ZnMapInfoObjCmd(
- ClientData client_data,
- Tcl_Interp* interp,
- int argc,
- Tcl_Obj* CONST args[]);
-
-DECLARE_VTABLES;
-TkimgphotoVtab *TkimgphotoVptr;
-
-MODULE = Tk::Zinc PACKAGE = Tk::Zinc
-
-PROTOTYPES: DISABLE
-
-BOOT:
- {
- IMPORT_VTABLES;
- TkimgphotoVptr = (TkimgphotoVtab *) SvIV(perl_get_sv("Tk::TkimgphotoVtab",GV_ADDWARN|GV_ADD));
-
- Lang_TkCommand("zinc", ZincObjCmd);
- Lang_TkCommand("videomap", ZnVideomapObjCmd);
- Lang_TkCommand("mapinfo", ZnMapInfoObjCmd);
- }
diff --git a/Perl/Zinc/Debug.pm b/Perl/Zinc/Debug.pm
deleted file mode 100644
index 6d4758c..0000000
--- a/Perl/Zinc/Debug.pm
+++ /dev/null
@@ -1,3023 +0,0 @@
-# Tk::Zinc::Debug Perl Module :
-#
-# For debugging/analysing a Zinc application.
-#
-# Author : Daniel Etienne <etienne@cena.fr>
-#
-# $Id$
-#---------------------------------------------------------------------------
-package Tk::Zinc::Debug;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use strict 'vars';
-use vars qw(@ISA @EXPORT @EXPORT_OK $WARNING $endoptions);
-use Carp;
-use English;
-require Exporter;
-use File::Basename;
-use Tk::Dialog;
-use Tk::Tree;
-use Tk::ItemStyle;
-use Tk::Pane;
-use Tk::FBox;
-use Tk::Balloon;
-
-@ISA = qw(Exporter);
-@EXPORT = qw(finditems snapshot tree init);
-@EXPORT_OK = qw(finditems snapshot tree init);
-
-my ($itemstyle, $groupstyle, $step);
-my (%result_tl, $result_fm, $search_tl, $helptree_tl, %coords_tl, %transfo_tl,
- $helpcoords_tl, $searchtree_tl, $tree_tl, %alloptions_tl, $tree,
- $cursorxy_tl, $cursorxy);
-my $showitemflag;
-my ($x0, $y0);
-my ($help_print, $imagecounter, $saving) = (0, 0, 0);
-my %searchEntryValue;
-my $searchTreeEntryValue;
-my %wwidth;
-my %wheight;
-my $preload;
-my %defaultoptions;
-my %instances;
-my @instances;
-my %cmdoptions;
-my $initobjectfunction;
-my %userbindings;
-my $selectedzinc;
-my $control_tl;
-my %button;
-my %on_command;
-my %off_command;
-my @znpackinfo;
-my $screenwidth;
-my $balloonhelp;
-#---------------------------------------------------------------------------
-#
-# Initialisation functions for plugin usage
-#
-#---------------------------------------------------------------------------
-
-# Hack to overload the Tk::Zinc::InitObject method
-#
-BEGIN {
-
- # test if Tk::Zinc::Debug is loaded using the -M perl option
- $preload = 1 if (caller(2))[2] == 0;
- return unless $preload;
- # parse Tk::Zinc::Debug options
- require Getopt::Long;
- Getopt::Long::Configure('pass_through');
- Getopt::Long::GetOptions(\%cmdoptions, 'optionsToDisplay=s', 'optionsFormat=s',
- 'snapshotBasename=s', 'expandTagsField=i');
- # save current Tk::Zinc::InitObject function; it will be invoked in
- # overloaded one (see below)
- use Tk;
- use Tk::Zinc;
- $initobjectfunction = Tk::Zinc->can('InitObject');
-
-} # end BEGIN
-
-
-# Hack to capture the instance(s) of zinc. Tk::Zinc::Debug init function
-# is invoked here.
-#
-sub Tk::Zinc::InitObject {
-
- # invoke function possibly overloaded in other modules
- &$initobjectfunction(@_) if $initobjectfunction;
- return unless $preload;
- my $zinc = $_[0];
- &init($zinc);
-
-} # end Tk::Zinc::InitObject
-
-
-#---------------------------------------------------------------------------
-#
-# Initialisation function
-#
-#---------------------------------------------------------------------------
-
-sub init {
-
- my $zinc = shift;
- $screenwidth = $zinc->screenwidth;
- my %options = @_;
- for my $opt (keys(%options)) {
- carp "in Tk::Zinc::Debug initialisation function, unknown option $opt\n"
- unless $opt eq '-optionsToDisplay' or $opt eq '-optionsFormat'
- or $opt eq '-snapshotBasename' or $opt eq '-expandTagsField' ;
- }
- $cmdoptions{optionsToDisplay} = $options{-optionsToDisplay} if
- not defined $cmdoptions{optionsToDisplay} and
- defined $options{-optionsToDisplay};
- $cmdoptions{optionsFormat} = $options{-optionsFormat} if
- not defined $cmdoptions{optionsFormat} and
- defined $options{-optionsFormat};
- $cmdoptions{snapshotBasename} = $options{-snapshotBasename} if
- not defined $cmdoptions{snapshotBasename} and
- defined $options{-snapshotBasename};
- $cmdoptions{expandTagsField} = $options{-expandTagsField} if
- not defined $cmdoptions{expandTagsField} and
- defined $options{-expandTagsField};
-
- &newinstance($zinc);
- return if Tk::Exists($control_tl);
- print "Tk::Zinc::Debug is ON\n";
- my $bitmaps = &createBitmaps($zinc);
- $control_tl = $zinc->Toplevel;
- $control_tl->title("Tk::Zinc::Debug (V $VERSION)");
- my $fm1 = $control_tl->Frame()->pack(-side => 'left', -padx => 0);
- my $fm2 = $control_tl->Frame()->pack(-side => 'left', -padx => 20);
- my $fm3 = $control_tl->Frame()->pack(-side => 'left', -padx => 0);
-
- for (qw(zn findenclosed findoverlap tree item id snapshot cursorxy)) {
- $button{$_} = $fm1->Checkbutton(-image => $bitmaps->{$_},
- -indicatoron => 0,
- -foreground => 'gray20')->pack(-side => 'left');
- }
- for (qw(zoomminus zoomplus move)) {
- $button{$_} = $fm2->Checkbutton(-image => $bitmaps->{$_},
- -indicatoron => 0,
- -foreground => 'gray20')->pack(-side => 'left');
- }
- for (qw(balloon close)) {
- $button{$_} = $fm3->Checkbutton(-image => $bitmaps->{$_},
- -indicatoron => 0,
- -foreground => 'gray20')->pack(-side => 'left');
- }
- my $bg = $button{zn}->cget(-background);
- for (values(%button)) {
- $_->configure(-selectcolor => $bg);
- }
- $balloonhelp = &balloonhelp();
- $button{balloon}->toggle;
- $control_tl->withdraw();
- $button{zn}->configure(-command => \&focuscommand);
- $button{balloon}->configure(-command => sub {
- if ($button{balloon}->{Value} == 0) {
- $balloonhelp->configure(-state => 'none');
- } else {
- $balloonhelp->configure(-state => 'balloon');
- }
- });
- #--------------------------------------------------
- # on/off commands for exclusive modes :
- #--------------------------------------------------
-
- # findenclosed mode
- $on_command{findenclosed} = sub {
- &saveDragAndDropBindings($selectedzinc);
- $button{findenclosed}->{Value} = 1;
- $selectedzinc->Tk::bind("<ButtonPress-1>",
- [\&startrectangle, 'simple', 'Enclosed',
- 'sienna']);
- $selectedzinc->Tk::bind("<B1-Motion>", \&resizerectangle);
- $selectedzinc->Tk::bind("<ButtonRelease-1>",
- [\&stoprectangle, 'enclosed',
- 'Items enclosed in rectangle']);
- };
- $off_command{findenclosed} = sub {
- $button{findenclosed}->{Value} = 0;
- &restoreDragAndDropBindings($selectedzinc);
- $selectedzinc->remove("zincdebugrectangle", "zincdebuglabel");
- };
- # findoverlap mode
- $on_command{findoverlap} = sub {
- &saveDragAndDropBindings($selectedzinc);
- $button{findoverlap}->{Value} = 1;
- $selectedzinc->Tk::bind("<ButtonPress-1>", [\&startrectangle, 'mixed',
- 'Overlap', 'sienna']);
- $selectedzinc->Tk::bind("<B1-Motion>", \&resizerectangle);
- $selectedzinc->Tk::bind("<ButtonRelease-1>",
- [\&stoprectangle, 'overlapping',
- 'Items which overlap rectangle']);
- };
- $off_command{findoverlap} = sub {
- $button{findoverlap}->{Value} = 0;
- &restoreDragAndDropBindings($selectedzinc);
- $selectedzinc->remove("zincdebugrectangle", "zincdebuglabel");
- };
- # item mode
- $on_command{item} = sub {
- &saveDragAndDropBindings($selectedzinc);
- $button{item}->{Value} = 1;
- $selectedzinc->Tk::bind("<ButtonPress-1>", [\&findintree]);
- };
- $off_command{item} = sub {
- $button{item}->{Value} = 0;
- &restoreDragAndDropBindings($selectedzinc);
- };
- # cursor device position mode
- $on_command{cursorxy} = sub {
- &saveMotionBinding($selectedzinc);
- $button{cursorxy}->{Value} = 1;
- &cursorxyOpen;
- $selectedzinc->Tk::bind("<Motion>", [\&cursorxy]);
- };
- $off_command{cursorxy} = sub {
- $button{cursorxy}->{Value} = 0;
- &cursorxyClose;
- &restoreMotionBinding($selectedzinc);
- };
-
- # move mode
- $on_command{move} = sub {
- &saveDragAndDropBindings($selectedzinc);
- $button{move}->{Value} = 1;
- my ($x0, $y0);
- $selectedzinc->Tk::bind('<ButtonPress-1>', sub {
- my $ev = $selectedzinc->XEvent;
- ($x0, $y0) = ($ev->x, $ev->y);
- });
- $selectedzinc->Tk::bind('<B1-Motion>', sub {
- my $ev = $selectedzinc->XEvent;
- my ($x, $y) = ($ev->x, $ev->y);
- $selectedzinc->translate(1, $x-$x0, $y-$y0) if defined $x0;
- ($x0, $y0) = ($x, $y);
- });
- };
- $off_command{move} = sub {
- $button{move}->{Value} = 0;
- &restoreDragAndDropBindings($selectedzinc);
- };
- # zn mode
- $on_command{zn} = sub {
- $button{zn}->{Value} = 1;
- for my $zinc (&instances) {
- $zinc->remove("zincdebugrectangle", "zincdebuglabel");
- &saveDragAndDropBindings($zinc);
- my $r;
- $zinc->Tk::bind("<ButtonPress-1>", sub {
- $zinc->update;
- my ($w, $h) = ($zinc->cget(-width), $zinc->cget(-height));
- $zinc->tsave(1, 'transfoTopgroup', 1);
- $r = $zinc->add('rectangle', 1, [30, 30, $w-30, $h-30],
- -linecolor => 'red',
- -linewidth => 10);
- $zinc->trestore($r, 'transfoTopgroup');
- $zinc->raise($r);
- $selectedzinc = $zinc;
- });
- $zinc->Tk::bind("<ButtonRelease-1>", sub {
- $zinc->remove($r);
- });
- }
- };
- $off_command{zn} = sub {
- $button{zn}->{Value} = 0;
- for my $zinc (&instances) {
- &restoreDragAndDropBindings($zinc);
- }
- };
-
- my @but = qw(findenclosed findoverlap item move zn cursorxy);
- for my $name (@but) {
- $button{$name}->configure(-command => sub {
- if ($button{$name}->{Value} == 1) {
- for my $other (@but) {
- &{$off_command{$other}} unless $other eq $name;
- }
- &{$on_command{$name}};
- } else {
- &{$off_command{$name}};
- }});
- }
-
- $button{id}->configure(-command => sub {
- $button{id}->update;
- &searchentry($zinc);
- $button{id}->toggle;
- });
-
- $button{snapshot}->configure(-command => sub {
- $button{snapshot}->update;
- &printWindow($zinc);
- $button{snapshot}->toggle;
- });
-
- $button{zoomminus}->configure(-command => sub {
- $button{zoomminus}->update;
- my $w = $selectedzinc->cget(-width);
- my $h = $selectedzinc->cget(-height);
- $selectedzinc->translate(1, -$w/2, -$h/2);
- $selectedzinc->scale(1, 1/1.1, 1/1.1);
- $selectedzinc->translate(1, $w/2, $h/2);
- $button{zoomminus}->toggle;
- });
-
- $button{zoomplus}->configure(-command => sub {
- $button{zoomplus}->update;
- my $w = $selectedzinc->cget(-width);
- my $h = $selectedzinc->cget(-height);
- $selectedzinc->translate(1, -$w/2, -$h/2);
- $selectedzinc->scale(1, 1.1, 1.1);
- $selectedzinc->translate(1, $w/2, $h/2);
- $button{zoomplus}->toggle;
- });
-
- $button{tree}->configure(-command => sub {
- $button{tree}->update;
- &showtree($selectedzinc);
- $button{tree}->toggle;
- });
-
- $button{close}->configure(-command => sub {
- $button{close}->update;
- &Tk::Zinc::Debug::iconify;
- &restoreDragAndDropBindings($selectedzinc);
- for my $name (@but) {
- &{$off_command{$name}};
- }
- $button{close}->toggle;
- });
-
-} # end init
-
-
-#---------------------------------------------------------------------------
-#
-# Deprecated functions
-#
-#---------------------------------------------------------------------------
-
-sub tree {
-
- carp "in Tk::Zinc::Debug module, tree() function is deprecated.\n";
- &init($_[0]);
-
-} # end tree
-
-
-sub finditems {
-
- carp "in Tk::Zinc::Debug module, finditems() function is deprecated.\n";
- &init($_[0]);
-
-} # end finditems
-
-
-
-sub snapshot {
-
- carp "in Tk::Zinc::Debug module, snapshot() function is deprecated.\n";
- &init($_[0]);
-
-} # end snapshot
-
-
-#---------------------------------------------------------------------------
-#
-# Functions related to cursor position
-#
-#---------------------------------------------------------------------------
-sub cursorxy {
-
- my $ev = shift->XEvent;
- $cursorxy = $ev->x.", ".$ev->y;
-
-} # end cursorxy
-
-
-sub cursorxyOpen {
-
- if (Tk::Exists($cursorxy_tl)) {
- $cursorxy_tl->raise;
- return;
- }
- $cursorxy_tl = $control_tl->Toplevel;
- $cursorxy_tl->Label(-text => "Cursor device position")->pack;
- $cursorxy_tl->Label(-textvariable => \$cursorxy)->pack;
- $cursorxy_tl->minsize(150, 40);
- $cursorxy_tl->raise;
-
-} # end cursorxyOpen
-
-
-sub cursorxyClose {
-
- $cursorxy_tl->destroy if Tk::Exists($cursorxy_tl);
-
-} # end cursorxyClose
-
-
-#---------------------------------------------------------------------------
-#
-# Functions related to items tree
-#
-#---------------------------------------------------------------------------
-
-# build or rebuild the items tree
-sub showtree {
-
- my $zinc = shift;
- my $optionstodisplay = $cmdoptions{optionsToDisplay};
- my $optionsFormat = $cmdoptions{optionsFormat};
- # styles definition
- $itemstyle =
- $zinc->ItemStyle('text', -stylename => "item", -foreground => 'black')
- unless $itemstyle;
- $groupstyle =
- $zinc->ItemStyle('text', -stylename => "group", -foreground => 'black')
- unless $groupstyle;
-
- $WARNING = 0;
- my @optionstodisplay = split(/,/, $optionstodisplay);
- $WARNING = 1;
- &hidetree();
- $tree_tl = $control_tl->Toplevel;
- $tree_tl->minsize(280, 200);
- $tree_tl->title("Zinc Items Tree");
- $tree = $tree_tl->Scrolled('Tree',
- -scrollbars => 'se',
- -height => 40,
- -width => 50,
- -itemtype => 'text',
- -selectmode => 'single',
- -separator => '.',
- -drawbranch => 1,
- -indent => 30,
- -command => sub {
- my $path = shift;
- my $item = (split(/\./, $path))[-1];
- &showresult("Attributes of item $item", $zinc, $item);
- $zinc->after(100, sub {
- &undohighlightitem(undef, $zinc)});
- },
- );
- &wheelmousebindings($tree);
- $tree->bind('<1>', [sub {
- my $path = $tree->nearest($_[1]);
- my $item = (split(/\./, $path))[-1];
- &highlightitem($tree, $zinc, $item, 0);
-
- }, Ev('y')]);
-
- $tree->bind('<2>', [sub {
- my $path = $tree->nearest($_[1]);
- return if $path eq 1;
- $tree->selectionClear;
- $tree->selectionSet($path);
- $tree->anchorSet($path);
- my $item = (split(/\./, $path))[-1];
- &highlightitem($tree, $zinc, $item, 1);
-
- }, Ev('y')]);
-
- $tree->bind('<3>', [sub {
- my $path = $tree->nearest($_[1]);
- return if $path eq 1;
- $tree->selectionClear;
- $tree->selectionSet($path);
- $tree->anchorSet($path);
- my $item = (split(/\./, $path))[-1];
- &highlightitem($tree, $zinc, $item, 2);
-
- }, Ev('y')]);
-
- $tree->add("1", -text => "Group(1)", -state => 'disabled');
- &scangroup($zinc, $tree, 1, "1", $optionsFormat, @optionstodisplay);
- $tree->autosetmode;
- # control buttons frame
- my $tree_butt_fm = $tree_tl->Frame(-height => 40)->pack(-side => 'bottom',
- -fill => 'y');
- $tree_butt_fm->Button(-text => 'Help',
- -command => [\&showHelpAboutTree, $zinc],
- )->pack(-side => 'left', -pady => 10,
- -padx => 10, -fill => 'both');
-
- $tree_butt_fm->Button(-text => 'Search',
- -command => [\&searchInTree, $zinc],
- )->pack(-side => 'left', -pady => 10,
- -padx => 10, -fill => 'both');
- $tree_butt_fm->Button(-text => "Build\ncode",
- -command => [\&buildCode, $zinc, $tree],
- )->pack(-side => 'left', -pady => 10,
- -padx => 10, -fill => 'both');
-
- $tree_butt_fm->Button(-text => "Attributes",
- -command => sub {
- my $path = $tree->selectionGet;
- $path = 1 unless $path;
- my $item = (split(/\./, $path))[-1];
- &showresult("Attributes of item $item", $zinc, $item);
- },
- )->pack(-side => 'left', -pady => 10,
- -padx => 10, -fill => 'both');
-
-
- $tree_butt_fm->Button(-text => 'Close',
- -command => sub {$zinc->remove("zincdebug");
- $tree_tl->destroy},
- )->pack(-side => 'left', -pady => 10,
- -padx => 20, -fill => 'both');
- # pack tree
- $tree->pack(-padx => 10, -pady => 10,
- -ipadx => 10,
- -side => 'top',
- -fill => 'both',
- -expand => 1,
- );
-
-
-} # end showtree
-
-
-# destroy the items tree
-sub hidetree {
-
- $tree_tl->destroy if $tree_tl and Tk::Exists($tree_tl);
-
-} # end hidetree
-
-
-# find a pointed item in the items tree
-sub findintree {
-
- my $zinc = shift;
- if (not Tk::Exists($tree_tl)) {
- &showtree($zinc);
- }
- my $ev = $zinc->XEvent;
- ($x0, $y0) = ($ev->x, $ev->y);
- my @atomicgroups = &unsetAtomicity($zinc);
- my $item = $zinc->find('closest', $x0, $y0);
- &restoreAtomicity($zinc, @atomicgroups);
- return unless $item > 1;
- my @ancestors = reverse($zinc->find('ancestors', $item));
- my $path = join('.', @ancestors).".".$item;
- # tree is rebuilded unless path exists
- unless ($tree->info('exists', $path)) {
- $tree_tl->destroy;
- #print "path=$path rebuild tree\n";
- &showtree($zinc);
- }
- $tree->see($path);
- $tree->selectionClear;
- $tree->anchorSet($path);
- $tree->selectionSet($path);
- &surrounditem($zinc, $item);
- $tree->focus;
-
-} # end findintree
-
-
-sub searchInTree {
-
- my $zinc = shift;
- $searchtree_tl->destroy if $searchtree_tl and Tk::Exists($searchtree_tl);
- $searchtree_tl = $tree_tl->Toplevel;
- $searchtree_tl->transient($tree_tl);
- $searchtree_tl->title("Find string in tree");
- my $fm = $searchtree_tl->Frame->pack(-side => 'top');
- $fm->Label(-text => "Find : ",
- )->pack(-side => 'left', -padx => 10, -pady => 10);
- my $entry = $fm->Entry(-width => 20)->pack(-side => 'left',
- -padx => 10, -pady => 10);
- my $status = $searchtree_tl->Label(-foreground => 'sienna',
- )->pack(-side => 'top');
- my $ep = 1;
- my $searchfunc = sub {
- my $side = shift;
- my $found = 0;
- #print "ep=$ep side=$side\n";
- $status->configure(-text => "");
- $status->update;
- $searchTreeEntryValue = $entry->get();
- $searchTreeEntryValue = quotemeta($searchTreeEntryValue);
- my $text;
- while ($ep) {
- $ep = $tree->info($side, $ep);
- unless ($ep) {
- $ep = 1;
- $found = 0;
- last;
- }
- $text = $tree->entrycget($ep, -text);
- if ($text =~ /$searchTreeEntryValue/) {
- $tree->see($ep);
- $tree->selectionClear;
- $tree->anchorSet($ep);
- $tree->selectionSet($ep);
- $found = 1;
- last;
- }
- }
- #print "searchTreeEntryValue=$searchTreeEntryValue found=$found\n";
- $status->configure(-text => "Search string not found") unless $found > 0;
- };
-
- my $fm2 = $searchtree_tl->Frame->pack(-side => 'top');
- $fm2->Button(-text => 'Prev',
- -command => sub {&$searchfunc('prev');},
- )->pack(-side => 'left', -pady => 10);
- $fm2->Button(-text => 'Next',
- -command => sub {&$searchfunc('next');},
- )->pack(-side => 'left', -pady => 10);
- $fm2->Button(-text => 'Close',
- -command => sub {$searchtree_tl->destroy},
- )->pack(-side => 'right', -pady => 10);
- $entry->focus;
- $entry->delete(0, 'end');
- $entry->insert(0, $searchTreeEntryValue) if $searchTreeEntryValue;
- $entry->bind('<Key-Return>', sub {&$searchfunc('next');});
-
-} # end searchInTree
-
-
-sub extractinfo {
- my $zinc = shift;
- my $item = shift;
- my $format = shift;
- my $option = shift;
- my $titleflag = shift;
- $option =~ s/^\s+//;
- $option =~ s/\s+$//;
- #print "option=[$option]\n";
- my @info;
- $WARNING = 0;
- eval {@info = $zinc->itemcget($item, $option)};
- #print "eval $option = (@info) $@\n";
- return if $@;
- return if @info == 0;
- my $info;
- my $sep = ($format eq 'column') ? "\n " : ", ";
- if ($titleflag) {
- $info = $sep."[$option] ".$info[0];
- } else {
- $info = $sep.$info[0];
- }
- if (@info > 1) {
- shift(@info);
- for (@info) {
- if ($format eq 'column') {
- if (length($info." ".$_) > 40) {
- if ($titleflag) {
- $info .= $sep."[$option] ".$_;
- } else {
- $info .= $sep.$_;
- }
- } else {
- $info .= ", $_";
- }
- } else {
- $info .= $sep.$_;
- }
- }
- }
- $WARNING = 1;
- return $info;
-
-} # end extractinfo
-
-
-sub scangroup {
-
- my ($zinc, $tree, $group, $path, $format, @optionstodisplay) = @_;
- my @items = $zinc->find('withtag', "$group.");
- for my $item (@items) {
- my $Type = ucfirst($zinc->type($item));
- my $info = " ";
- if (@optionstodisplay == 1) {
- $info .= &extractinfo($zinc, $item, $format, $optionstodisplay[0]);
- } elsif (@optionstodisplay > 1) {
- for my $opt (@optionstodisplay) {
- $info .= &extractinfo($zinc, $item, $format, $opt, 1);
- }
- }
- if ($Type eq "Group") {
- $tree->add($path.".".$item,
- -text => "$Type($item)$info",
- -style => 'group',
- );
- &scangroup($zinc, $tree, $item, $path.".".$item, $format, @optionstodisplay);
- } else {
- $tree->add($path.".".$item,
- -text => "$Type($item)$info",
- -style => 'item',
- );
- }
- }
-
-} # end scangroup
-
-#---------------------------------------------------------------------------
-#
-# Functions used to build code
-#
-#---------------------------------------------------------------------------
-
-# build perl code corresponding to a branch of the items tree
-sub buildCode {
-
- my $zinc = shift;
- my $tree = shift;
- my @code;
- push(@code, 'use Tk;');
- push(@code, 'use Tk::Zinc;');
- push(@code, 'my $mw = MainWindow->new();');
- push(@code, 'my $zinc = $mw->Zinc(-render => '.$zinc->cget(-render).
- ')->pack(-expand => 1, -fill => "both");');
- push(@code, '# hash %items : keys are original items ID, values are built items ID');
- push(@code, 'my %items;');
- push(@code, '');
- my $path = $tree->selectionGet;
- $path = 1 unless $path;
- my $item = (split(/\./, $path))[-1];
- $endoptions = [];
- if ($zinc->type($item) eq 'group') {
- push(@code, &buildGroup($zinc, $item, 1));
- for(@$endoptions) {
- my ($item, $option, $value) = @$_;
- push(@code,
- '$zinc->itemconfigure('.$item.', '.$option.' => '.$value.');');
- }
- } else {
- push(@code, &buildItem($zinc, $item, 1));
- }
- push(@code, &buildEnd);
-
- my $file = $zinc->getSaveFile(-filetypes => [['Perl Files', '.pl'],
- ['All Files', '*']],
- -initialfile => 'zincdebug.pl',
- -title => 'Save code',
- );
- return unless defined $file;
- $zinc->Busy;
- open (OUT, ">$file");
- for (@code) {
- print OUT $_."\n";
- }
- close(OUT);
- $zinc->Unbusy;
-
-} # end buildCode
-
-
-sub buildEnd {
-
- my @code;
- push(@code, 'for (keys(%items)) {');
- push(@code, ' $zinc->addtag(\'orig\'.$_, "withtag", $items{$_});');
- push(@code, '}');
- push(@code, 'MainLoop;');
- return @code
-
-} # end buildEnd
-
-
-# build a node of tree (corresponding to a TkZinc group item)
-sub buildGroup {
-
- my $zinc = shift;
- my $item = shift;
- my $group = shift;
- my @code;
- # creation
- push(@code, '$items{'.$item.'}=$zinc->add("group", '.$group.', ');
- # options
- push(@code, &buildOptions($zinc, $item));
- push(@code, ');');
- push(@code, '');
- # coords
- push(@code, '$zinc->coords($items{'.$item.'}, ['.
- join(',', $zinc->coords($item)).']);');
- # transformations
- push(@code, &buildTransformations($zinc, $item));
-
- my @items = $zinc->find('withtag', "$item.");
- for my $it (reverse(@items)) {
- if ($zinc->type($it) eq 'group') {
- push(@code, &buildGroup($zinc, $it, '$items{'.$item.'}'));
- } else {
- push(@code, &buildItem($zinc, $it, '$items{'.$item.'}'));
- }
- }
- return @code;
-
-} # end buildGroup
-
-
-# build a leaf of tree (corresponding to a TkZinc non-group item)
-sub buildItem {
-
- my $zinc = shift;
- my $item = shift;
- my $group = shift;
- my $type = $zinc->type($item);
- my @code;
- my $numfields = 0;
- my $numcontours = 0;
- # creation
- my $initstring = '$items{'.$item.'}=$zinc->add("'.$type.'", '.$group.', ';
- if ($type eq 'tabular' or $type eq 'track' or $type eq 'waypoint') {
- $numfields = $zinc->itemcget($item, -numfields);
- $initstring .= $numfields.' ,';
- } elsif ($type eq 'curve' or $type eq 'triangles' or
- $type eq 'arc' or $type eq 'rectangle') {
- $initstring .= "[ ";
- my (@coords) = $zinc->coords($item);
- if (ref($coords[0]) eq 'ARRAY') {
- my @coords2;
- for my $c (@coords) {
- if (@$c > 2) {
- push(@coords2, '['.$c->[0].', '.$c->[1].', "'.$c->[2].'"]');
- } else {
- push(@coords2, '['.$c->[0].', '.$c->[1].']');
-
- }
- }
- $initstring .= join(', ', @coords2);
- } else {
- $initstring .= join(', ', @coords);
- }
- $initstring .= " ], ";
- $numcontours = $zinc->contour($item);
- }
- push(@code, $initstring);
- # options
- push(@code, &buildOptions($zinc, $item));
- push(@code, ');');
- push(@code, '');
- # fields
- if ($numfields > 0) {
- for (my $i=0; $i < $numfields; $i++) {
- push(@code, &buildField($zinc, $item, $i));
- }
- }
- # contours
- if ($numcontours > 1) {
- for (my $i=1; $i < $numcontours; $i++) {
- my (@coords) = $zinc->coords($item);
- my @coords2;
- for my $c (@coords) {
- if (@$c > 2) {
- push(@coords2, '['.$c->[0].', '.$c->[1].', "'.$c->[2].'"]');
- } else {
- push(@coords2, '['.$c->[0].', '.$c->[1].']');
- }
- }
- my $coordstr = '[ '.join(', ', @coords2).' ]';
- push(@code, '$zinc->contour($items{'.$item.'}, "add", 0, ');
- push(@code, ' '.$coordstr.');');
- }
- }
- # transformations
- push(@code, &buildTransformations($zinc, $item));
-
- return @code;
-
-} # end buildItem
-
-
-# add an information field to an item of the tree
-sub buildField {
-
- my $zinc = shift;
- my $item = shift;
- my $field = shift;
- my @code;
- # type group and initargs
- push(@code, '$zinc->itemconfigure($items{'.$item.'}, '.$field.', ');
- # options
- push(@code, &buildOptions($zinc, $item, $field));
- push(@code, ');');
- push(@code, '');
- return @code;
-
-} # end buildField
-
-
-sub buildTransformations {
-
- my $zinc = shift;
- my $item = shift;
- my @tr = $zinc->tget($item);
- my @code;
- return ('$zinc->tset($items{'.$item.'}, '.join(", ", @tr).');');
-
-} # end buildTransformations
-
-
-sub buildOptions {
-
- my $zinc = shift;
- my $item = shift;
- my $field = shift;
- my @code;
- my @args = defined($field) ? ($item, $field) : ($item);
- my @options = $zinc->itemconfigure(@args);
- for my $elem (@options) {
- my ($option, $type, $readonly, $value) = (@$elem)[0, 1, 2, 4];
- next if $value eq '';
- next if $readonly;
- if ($type eq 'point') {
- push(@code, " ".$option." => [".join(',', @$value)."], ");
-
- } elsif (($type eq 'bitmap' or $type eq 'image') and $value !~ /^AtcSymbol/
- and $value !~ /^AlphaStipple/) {
- push(@code, "# ".$option." => '".$value."', ");
-
- } elsif ($type eq 'item') {
- $endoptions->[@$endoptions] =
- ['$items{'.$item.'}', $option, '$items{'.$value.'}'];
-
- } elsif ($option eq '-text') {
- $value =~ s/\"/\\"/; # comment for emacs legibility => "
- push(@code, " ".$option.' => "'.$value.'", ');
-
- } elsif (ref($value) eq 'ARRAY') {
- push(@code, " ".$option." => [qw(".join(' ', @$value).")], ");
-
- } else {
- push(@code, " ".$option." => '".$value."', ");
- }
- }
- return @code;
-
-} # end buildOptions
-
-#---------------------------------------------------------------------------
-#
-# Functions related to search in a rectangular area
-#
-#---------------------------------------------------------------------------
-
-# begin to draw rectangular area for search
-sub startrectangle {
-
- my ($zinc, $style, $text, $color) = @_;
- $zinc->remove("zincdebugrectangle", "zincdebuglabel");
- my $ev = $zinc->XEvent;
- ($x0, $y0) = ($ev->x, $ev->y);
- # store and name the inverted transformation of top group
- $zinc->tsave(1, 'zoom+move', 1);
- $zinc->add('rectangle', 1, [$x0, $y0, $x0, $y0],
- -linecolor => $color,
- -linewidth => 2,
- -linestyle => $style,
- -tags => ["zincdebugrectangle"],
- );
- $zinc->add('text', 1,
- -color => $color,
- -font => '7x13',
- -position => [$x0+5, $y0-15],
- -text => $text,
- -tags => ["zincdebuglabel"],
- );
- # apply to new rectangle the (inverted) transformation stored below
- $zinc->trestore("zincdebugrectangle", 'zoom+move');
- $zinc->trestore("zincdebuglabel", 'zoom+move');
-
-} # end startrectangle
-
-
-# resize the rectangular area for search
-sub resizerectangle {
-
- my $zinc = shift;
- my $ev = $zinc->XEvent;
- my ($x, $y) = ($ev->x, $ev->y);
- return unless ($zinc->find('withtag', "zincdebugrectangle"));
-
- $zinc->coords("zincdebugrectangle", 1, 1, [$x, $y]);
- if ($x < $x0) {
- if ($y < $y0) {
- $zinc->coords("zincdebuglabel", [$x+5, $y-15]);
- } else {
- $zinc->coords("zincdebuglabel", [$x+5, $y0-15]);
- }
- } else {
- if ($y < $y0) {
- $zinc->coords("zincdebuglabel", [$x0+5, $y-15]);
- } else {
- $zinc->coords("zincdebuglabel", [$x0+5, $y0-15]);
- }
- }
- $zinc->raise("zincdebugrectangle");
- $zinc->raise("zincdebuglabel");
-
-} # end resizerectangle
-
-
-# stop drawing rectangular area for search
-sub stoprectangle {
-
- my ($zinc, $searchtype, $text) = @_;
- return unless ($zinc->find('withtag', "zincdebugrectangle"));
-
- my @atomicgroups = &unsetAtomicity($zinc);
- $zinc->update;
- my ($c0, $c1) = $zinc->coords("zincdebugrectangle");
- my @coords = (@$c0, @$c1);
- my @items;
- for my $item ($zinc->find($searchtype, @coords, 1, 1)) {
- push (@items, $item) unless $zinc->hastag($item, "zincdebugrectangle") or
- $zinc->hastag($item, "zincdebuglabel");
- }
- &restoreAtomicity($zinc, @atomicgroups);
- if (@items) {
- &showresult($text, $zinc, @items);
- } else {
- $zinc->remove("zincdebugrectangle", "zincdebuglabel");
- }
-
-} # end stoprectangle
-
-
-# in order to avoid find problems with group atomicity, we set all -atomic
-# attributes to 0
-sub unsetAtomicity {
-
- my $zinc = shift;
- my @groups = $zinc->find('withtype', 'group');
- my @atomicgroups;
- for my $group (@groups) {
- if ($zinc->itemcget($group, -atomic)) {
- push(@atomicgroups, $group);
- $zinc->itemconfigure($group, -atomic => 0);
- }
- }
- return @atomicgroups;
-
-} # end unsetAtomicity
-
-
-sub restoreAtomicity {
-
- my $zinc = shift;
- my @atomicgroups = @_;
- for my $group (@atomicgroups) {
- $zinc->itemconfigure($group, -atomic => 1);
- }
-
-} # end restoreAtomicity
-
-
-#---------------------------------------------------------------------------
-#
-# Function related to item's id search
-#
-#---------------------------------------------------------------------------
-
-sub searchentry {
-
- my $zinc = shift;
- $search_tl->destroy if $search_tl and Tk::Exists($search_tl);
- $search_tl = $control_tl->Toplevel;
- $search_tl->title("Specific search");
- my $fm = $search_tl->Frame->pack(-side => 'top');
- $fm->Label(-text => "Item TagOrId : ",
- )->pack(-side => 'left', -padx => 10, -pady => 10);
- my $entry = $fm->Entry(-width => 20)->pack(-side => 'left',
- -padx => 10, -pady => 10);
- my $status = $search_tl->Label(-foreground => 'sienna',
- )->pack(-side => 'top');
- $search_tl->Button(-text => 'Close',
- -command => sub {$search_tl->destroy},
- )->pack(-side => 'top', -pady => 10);
- $entry->focus;
- $entry->delete(0, 'end');
- $entry->insert(0, $searchEntryValue{$zinc}) if $searchEntryValue{$zinc};
- $entry->bind('<Key-Return>', [sub {
- $status->configure(-text => "");
- $status->update;
- $searchEntryValue{$zinc} = $entry->get();
- my @items = $zinc->find('withtag', $searchEntryValue{$zinc});
- if (@items) {
- my $label;
- if ($searchEntryValue{$zinc} =~ /^\d/) {
- $label = "Attributes of item $searchEntryValue{$zinc}";
- } else {
- $label = "Attributes of item(s) with tag $searchEntryValue{$zinc}"
- }
- &showresult($label, $zinc, @items);
- } else {
- $status->configure(-text => "No such tagOrId ($searchEntryValue{$zinc})");
- }
- }]);
-
-} # end searchentry
-
-
-#---------------------------------------------------------------------------
-#
-# Functions related to transformations parameters
-#
-#---------------------------------------------------------------------------
-
-sub showtransfoparams {
-
- my ($label, $zinc, $item) = @_;
- my @m = $zinc->tget($item);
- my ($m00, $m01, $m10, $m11, $m20, $m21) = @m;
- my ($xt, $yt, $xsc, $ysc, $a, $xsk, $ysk) = $zinc->tget($item, 'all');
- # bug zinc
- $ysk = 0 unless defined $ysk;
- for ($m00, $m01, $m10, $m11, $m20, $m21, $xt, $yt, $xsc, $ysc, $a, $xsk, $ysk) {
- $_ = sprintf("%.2f", $_) if /^-?\d+\.\d/;
- }
- $transfo_tl{$item}->destroy if Tk::Exists($transfo_tl{$item});
- $transfo_tl{$item} = $control_tl->Toplevel();
- $transfo_tl{$item}->transient($result_tl{$label})
- if Tk::Exists($result_tl{$label});
- my $title = "Transformations of item $item";
- $transfo_tl{$item}->title($title);
- my $bgcolor = 'ivory';
- my $fm1 = $transfo_tl{$item}->Frame()->pack(-side => 'top',
- -padx => 20,
- -pady => 10,
- -expand => 1,
- -fill => 'x',
- );
- # set transformation to ident
- my $btn = $fm1->Button(-text => "Show item with transformation\nset to identity",
- -bg => $bgcolor,
- )->pack(-side => 'top', -padx => 5, -pady => 10);
- $balloonhelp->attach($btn,-balloonmsg =>
- "Click and maintain to show the transformation \n".
- "animation. Use btn1, btn2 or btn3 to select the\n".
- "best background color for a good visibility. ");
- $btn->bind('<1>', [\&showtransfo, $zinc, $item, 0]);
- $btn->bind('<2>', [\&showtransfo, $zinc, $item, 1]);
- $btn->bind('<3>', [\&showtransfo, $zinc, $item, 2]);
-
- my $fm11 = $fm1->Frame()->pack(-side => 'left',
- -padx => 20,
- );
-
- my ($set_cb, $reset_cb, $upd_cb);
-
- # matrix
- my $r = 0;
- my $c = 0;
- $fm11->Label(-text => 'matrix', -relief => 'ridge', -bg => $bgcolor)
- ->grid(-row => $r++, -columnspan => 2,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm11->Label(-textvariable => \$m00, -relief => 'ridge')
- ->grid(-row => $r, -column => $c,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm11->Label(-textvariable => \$m01, -relief => 'ridge')
- ->grid(-row => $r++, -column => $c+1,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm11->Label(-textvariable => \$m10, -relief => 'ridge')
- ->grid(-row => $r, -column => $c,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm11->Label(-textvariable => \$m11, -relief => 'ridge')
- ->grid(-row => $r++, -column => $c+1,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm11->Label(-textvariable => \$m20, -relief => 'ridge')
- ->grid(-row => $r, -column => $c,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm11->Label(-textvariable => \$m21, -relief => 'ridge')
- ->grid(-row => $r++, -column => $c+1,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
-
-
- my $fm12 = $fm1->Frame()->pack(-side => 'left',
- -padx => 20,
- );
- my ($e_xt, $e_yt, $e_xsc, $e_ysc, $e_a, $e_xsk, $e_ysk);
-
- $set_cb = sub {
- $zinc->treset($item);
- $zinc->translate($item, $e_xt, $e_yt);
- $zinc->rotate($item, $e_a);
- $zinc->scale($item, $e_xsc, $e_ysc);
- $zinc->skew($item, $e_xsk, $e_ysk);
- ($m00, $m01, $m10, $m11, $m20, $m21) = $zinc->tget($item);
- for ($m00, $m01, $m10, $m11, $m20, $m21) {
- $_ = sprintf("%.2f", $_) if /^-?\d+\.\d/;
- }
- };
-
- # translate params
- $r = 0;
- $c = 0;
- $fm12->Label(-text => 'translate', -relief => 'ridge', -bg => $bgcolor)
- ->grid(-row => $r, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
- &entrytransfo($fm12, $item, $zinc, 'xt', $xt, \$e_xt, 4, $set_cb)
- ->grid(-row => $r, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
- &entrytransfo($fm12, $item, $zinc, 'yt', $yt, \$e_yt, 4, $set_cb)
- ->grid(-row => $r++, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
- # rotate params
- $c = 0;
- $fm12->Label(-text => 'rotate', -relief => 'ridge', -bg => $bgcolor)
- ->grid(-row => $r, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
- &entrytransfo($fm12, $item, $zinc, 'a', $a, \$e_a, 4, $set_cb)
- ->grid(-row => $r++, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
- # scale params
- $c = 0;
- $fm12->Label(-text => 'scale', -relief => 'ridge', -bg => $bgcolor)
- ->grid(-row => $r, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
- &entrytransfo($fm12, $item, $zinc, 'xsc', $xsc, \$e_xsc, 4, $set_cb)
- ->grid(-row => $r, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- &entrytransfo($fm12, $item, $zinc, 'ysc', $ysc, \$e_ysc, 4, $set_cb)
- ->grid(-row => $r++, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
- # skew params
- $c = 0;
- $fm12->Label(-text => 'skew', -relief => 'ridge', -bg => $bgcolor)
- ->grid(-row => $r, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
- &entrytransfo($fm12, $item, $zinc, 'xsk', $xsk, \$e_xsk, 4, $set_cb)
- ->grid(-row => $r, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- &entrytransfo($fm12, $item, $zinc, 'ysk', $ysk, \$e_ysk, 4, $set_cb)
- ->grid(-row => $r++, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
-
-
- my $fm2 = $transfo_tl{$item}->Frame()->pack(-side => 'top',
- -padx => 20,
- -pady => 0,
- );
- $fm2->Button(-text => 'Close',
- -command => sub {
- $transfo_tl{$item}->destroy;
- delete $transfo_tl{$item};
- })->pack(-side => 'top', -padx => 40, -pady => 20);
-
-
-
-} # end showtransfoparams
-
-
-#---------------------------------------------------------------------------
-#
-# Functions related to results tables display
-#
-#---------------------------------------------------------------------------
-
-# display in a toplevel the result of search ; a new toplevel destroyes the
-# previous one
-sub showresult {
-
- my ($label, $zinc, @items) = @_;
- # toplevel (re-)creation
- $result_tl{$label}->destroy if Tk::Exists($result_tl{$label});
- $result_tl{$label} = $control_tl->Toplevel();
- my $title = "TK::Zinc Debug";
- $title .= " - $label" if $label;
- $result_tl{$label}->title($title);
- $result_tl{$label}->geometry('+10+20');
- $control_tl->raise;
- my $fm = $result_tl{$label}->Frame()->pack(-side => 'bottom',
- );
- $fm->Button(-text => 'Close',
- -command => sub {
- $result_tl{$label}->destroy;
- delete $result_tl{$label};
- $zinc->remove("zincdebugrectangle", "zincdebuglabel");
- })->pack(-side => 'left', -padx => 40, -pady => 10);
-
- # scrolled pane creation
- $result_fm = $result_tl{$label}->Scrolled('Pane',
- -scrollbars => 'osoe',
- -height => 200,
- -width => 1024,
- );
- &wheelmousebindings($result_fm);
- my $fm2 = $result_fm->Frame->pack;
- # attributes display
- &showattributes($zinc, $fm2, $label, \@items);
- $result_fm->update;
- $fm2->update;
- my $width = $fm2->width + 10;
- $width = $screenwidth if $width > $screenwidth;
- $result_fm->configure(-width => $width);
- $result_fm->pack(-padx => 10, -pady => 10,
- -ipadx => 10,
- -fill => 'both',
- -expand => 1,
- );
-
-} # end showresult
-
-# display table containing additionnal options/values
-sub showalloptions {
-
- my ($label, $zinc, $item, $fmp) = @_;
- $alloptions_tl{$item}->destroy if Tk::Exists($alloptions_tl{$item});
- $alloptions_tl{$item} = $control_tl->Toplevel();
- $alloptions_tl{$item}->transient($result_tl{$label})
- if Tk::Exists($result_tl{$label});
- my $tl = $alloptions_tl{$item};
- my $title = "All options of item $item";
- $tl->title($title);
- $tl->geometry('-10+0');
-
-
- # footer
- #----------------
- $tl->Button(-text => 'Close',
- -command => sub {
- $alloptions_tl{$item}->destroy;
- delete $alloptions_tl{$item};
- })->pack(-side => 'bottom');
- # option scrolled frame
- #-----------------------
- my $fm = $tl->Scrolled('Pane',
- -scrollbars => 'oe',
- -height => 500,
- )->pack(-padx => 10, -pady => 10,
- -ipadx => 10,
- -expand => 1,
- -fill => 'both');
-
- my $bgcolor = 'ivory';
- my $i = 1;
- $fm->Label(-text => $title, -background => $bgcolor,
- -fg => 'sienna', -relief => 'ridge')
- ->grid(-row => $i++, -column => 1, -ipady => 5, -ipadx => 5,
- -columnspan => 2, -sticky => 'nswe') if $label;
- $fm->Label(-text => 'Option', -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => 1, -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => 'Value', -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i++, -column => 2, -ipady => 10, -ipadx => 5, -sticky => 'nswe');
-
- my @options = $zinc->itemconfigure($item);
- for my $elem (@options) {
- my ($option, $type, $value) = (@$elem)[0,1,4];
- $fm->Label(-text => $option, -relief => 'ridge')
- ->grid(-row => $i, -column => 1,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- if ($option eq '-tags') {
- &entryoption($fm, $item, $zinc, $option,
- join("\n", @$value), 30, 30, scalar @$value)
- ->grid(-row => $i, -column => 2, -ipady => 5,
- -ipadx => 5, -sticky => 'nswe');
- } else {
- &entryoption($fm, $item, $zinc, $option, undef, 50, 25)
- ->grid(-row => $i, -column => 2, -ipady => 5,
- -ipadx => 5, -sticky => 'nswe');
- }
- $i++;
- }
-
-} # end showalloptions
-
-
-# display device coords table
-sub showdevicecoords {
-
- my ($label, $zinc, $item) = @_;
- &showcoords($label, $zinc, $item, 1);
-
-} # end showdevicecoords
-
-
-# display coords table
-sub showcoords {
-
- my ($label, $zinc, $item, $deviceflag) = @_;
- my $bgcolor = 'ivory';
- my $bgcolor2 = 'gray75';
- $coords_tl{$item}->destroy if Tk::Exists($coords_tl{$item}) and not $deviceflag;
- $coords_tl{$item} = $control_tl->Toplevel();
- $coords_tl{$item}->transient($result_tl{$label}) if Tk::Exists($result_tl{$label});
- my $title = "Zinc Debug";
- if ($deviceflag) {
- $title .= " - Coords of item $item";
- } else {
- $title .= " - Device coords of item $item";
- }
- $coords_tl{$item}->title($title);
- $coords_tl{$item}->geometry('+10+20');
- my $coords_fm0 = $coords_tl{$item}->Frame()->pack(-side => 'bottom');
- $coords_fm0->Button(-text => 'Help',
- -command => [\&showHelpAboutCoords, $zinc]
- )->pack(-side => 'left', -padx => 40, -pady => 10);
- $coords_fm0->Button(-text => 'Close',
- -command => sub {
- &hidecontour($zinc);
- $coords_tl{$item}->destroy;
- delete $coords_tl{$item};
- })->pack(-side => 'left', -padx => 40, -pady => 10);
- # scrolled pane creation
- my $coords_fm = $coords_tl{$item}->Scrolled('Pane',
- -scrollbars => 'oe',
- -height => 200,
- )->pack(-padx => 10, -pady => 10,
- -ipadx => 10,
- -expand => 1,
- -fill => 'both');
- my @contour;
- my $contournum = $zinc->contour($item);
- for (my $i=0; $i < $contournum; $i++) {
- my @coords = $zinc->coords($item, $i);
- if (!ref $coords[0]) {
- ## The first item of the list is not a reference, so the
- ## list is guarranted to be a flat list (x, y, ...)
- ## normaly of only one pair of (x y)
- @coords = $zinc->transform($item, 'device', [@coords])
- if $deviceflag;
- for (my $j=0; $j < @coords; $j += 2) {
- push(@{$contour[$i]}, [$coords[$j], $coords[$j+1]]);
- }
- }
- else {
- ## the first element is an array reference, as every
- ## other elements of the list
- for (my $j=0; $j < @coords; $j ++) {
- my @c = @{$coords[$j]};
- @c = $zinc->transform($item, 'device', [@c])
- if $deviceflag;
- push(@{$contour[$i]}, [@c]);
- }
- }
- }
- my $row = 1;
- my $col = 1;
- for (my $i=0; $i < @contour; $i++) {
- $col = 1;
- my $lab = $coords_fm->Label(-text => "Contour $i",
- -background => $bgcolor,
- -relief => 'ridge')->grid(-row => $row,
- -column => $col,
- -ipadx => 5,
- -ipady => 5,
- -sticky => 'nswe');
- $lab->bind('<1>', [\&showcontour, $zinc, 'black', $item, $contour[$i],
- $deviceflag]);
- $lab->bind('<2>', [\&showcontour, $zinc, 'white', $item, $contour[$i],
- $deviceflag]);
- $lab->bind('<3>', [\&showcontour, $zinc, 'red', $item, $contour[$i],
- $deviceflag]);
- $lab->bind('<ButtonRelease-1>', sub { &hidecontour($zinc); });
- $lab->bind('<ButtonRelease-2>', sub { &hidecontour($zinc); });
- $lab->bind('<ButtonRelease-3>', sub { &hidecontour($zinc); });
- my $lab1 = $coords_fm->Label(-text => scalar(@{$contour[$i]})." points",
- -background => $bgcolor,
- -relief => 'ridge')->grid(-row => $row+1,
- -column => $col,
- -ipadx => 5,
- -ipady => 5,
- -sticky => 'nswe');
- $lab1->bind('<1>', [\&showcontourpts, $zinc, 'black', $item, $contour[$i],
- $deviceflag]);
- $lab1->bind('<2>', [\&showcontourpts, $zinc, 'white', $item, $contour[$i],
- $deviceflag]);
- $lab1->bind('<3>', [\&showcontourpts, $zinc, 'red', $item, $contour[$i],
- $deviceflag]);
- $lab1->bind('<ButtonRelease-1>', sub { &hidecontour($zinc); });
- $lab1->bind('<ButtonRelease-2>', sub { &hidecontour($zinc); });
- $lab1->bind('<ButtonRelease-3>', sub { &hidecontour($zinc); });
- $col++;
- my @lab;
- for my $coords (@{$contour[$i]}) {
- if ($col > 10) {
- $col = 2;
- $row++;
- }
- $coords->[0] =~ s/\.(\d\d).*/\.$1/;
- $coords->[1] =~ s/\.(\d\d).*/\.$1/;
- my @opt;
- if (defined $coords->[2]) {
- @opt = (-text => sprintf('%s, %s, %s', @$coords),
- -underline => length(join(',', @$coords)) + 1,
- );
- } else {
- @opt = (-text => sprintf('%s, %s', @{$coords}[0,1]));
- }
- push (@lab, $coords_fm->Label(@opt,
- -width => 15,
- -relief => 'ridge')->grid(-row => $row,
- -ipadx => 5,
- -ipady => 5,
- -column => $col++,
- -sticky => 'nswe'));
- }
- $row++ if (@{$contour[$i]} < 10);
- $row++;
- my $j = 0;
- for (@lab) {
- $_->bind('<1>', [\&showcontourpt, $zinc, 'black',
- $item, $j, $deviceflag, \@lab, @{$contour[$i]}]);
- $_->bind('<2>', [\&showcontourpt, $zinc, 'white',
- $item, $j, $deviceflag, \@lab, @{$contour[$i]}]);
- $_->bind('<3>', [\&showcontourpt, $zinc, 'red',
- $item, $j, $deviceflag, \@lab, @{$contour[$i]}]);
- $j++;
- }
-
- }
-
-} # end showcoords
-
-
-
-# display in a grid the values of most important attributes
-sub showattributes {
-
- my ($zinc, $fm, $label, $items, $expandTagsFlag) = @_;
- $expandTagsFlag = 1;
- &getsize($zinc);
- my $bgcolor = 'ivory';
- my $i = 1;
- $fm->Label(-text => $label, -background => $bgcolor,
- -fg => 'sienna', -relief => 'ridge')
- ->grid(-row => $i++, -column => 0, -ipady => 0, -ipadx => 5,
- -columnspan => 7, -sticky => 'nswe') if $label;
-
- &showbanner($fm, $i++);
- $i++;
- for my $item (@$items) {
- my $c = 0;
- my $type = $zinc->type($item);
- # id
- my $idbtn =
- $fm->Button(-text => $item,
- -foreground => 'sienna'
- )->grid(-row => $i, -column => $c++, -sticky => 'nswe',
- -ipadx => 5);
- $idbtn->bind('<1>', [\&highlightitem, $zinc, $item, 0]);
- $idbtn->bind('<2>', [\&highlightitem, $zinc, $item, 1]);
- $idbtn->bind('<3>', [\&highlightitem, $zinc, $item, 2]);
- $balloonhelp->attach($idbtn,-balloonmsg =>
- "Click and maintain to show the item. \n".
- "Use btn1, btn2 or btn3 to select the best\n".
- "background color for a good visibility. ");
- # type
- if ($type eq 'group') {
- my $gbtn =
- $fm->Button(-text => $type,
- -command => sub {
- my @items = $zinc->find('withtag', $item.".");
- &showresult("Content of group $item", $zinc, @items);
- });
- $gbtn->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
- $balloonhelp->attach($gbtn,-balloonmsg =>
- "Click to display the group's content.");
- } else {
- $fm->Label(-text => $type, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
- }
- # parent group
- my $group = $zinc->group($item);
- my $pgbtn =
- $fm->Button(-text => $group,
- -command => [\&showresult,
- "Attributes of group $group (parent of $item)",
- $zinc, $group]);
- $pgbtn->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
- $balloonhelp->attach($pgbtn,-balloonmsg =>
- "Click to display the parent group's attributes.");
- # priority
- &entryoption($fm, $item, $zinc, -priority)
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 2);
- # sensitiveness
- &entryoption($fm, $item, $zinc, -sensitive)
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 2);
- # visibility
- &entryoption($fm, $item, $zinc, -visible)
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 2);
- # other options
- $fm->Button(-text => 'show',
- -command => [\&showalloptions, $label, $zinc, $item, $fm])
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
- # transformations
- my $tlabel = 'yes';
- my ($xt, $yt, $xsc, $ysc, $a, $xsk) = $zinc->tget($item, 'all');
- $tlabel = 'no' if ($xt == 0 and $yt == 0 and $xsc == 1 and $ysc == 1 and
- $a == 0 and $xsk == 0);
- my $tbtn =
- $fm->Button(-text => $tlabel,
- -command => [\&showtransfoparams, $label, $zinc, $item],
- );
- $tbtn->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
- $balloonhelp->attach($tbtn,-balloonmsg =>
- "Click to display transformation parameters.\n".
- "Some of them can be updated. ");
-
- # coords
- my @coords = $zinc->coords($item);
- my $coords;
- if (!ref $coords[0]) {
- my $x0 = int($coords[0]);
- my $y0 = int($coords[1]);
- $coords = "($x0, $y0)";
- } else {
- my @points0 = @{$coords[0]};
- my $n = $#coords;
- my @pointsN = @{$coords[$n]};
- my $x0 = int($points0[0]);
- my $y0 = int($points0[1]);
- my $xn = int($pointsN[0]);
- my $yn = int($pointsN[1]);
- if ($n == 1) { ## a couple of points
- $coords = "($x0, $y0, $xn, $yn)";
- } else {
- $coords = "P0=($x0, $y0), ..., P".$n."=($xn, $yn)";
- }
- }
- if (@coords > 2) {
- my $cbtn = $fm->Button(-text => $coords,
- -command => [\&showcoords, $label, $zinc, $item]);
- $cbtn->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 2);
- $balloonhelp->attach($cbtn,-balloonmsg =>
- "Click to show all coordinates.");
- } else {
- $fm->Label(-text => $coords, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
- }
- # device coords
- @coords = $zinc->transform($item, 'device', [@coords]);
- if (!ref $coords[0]) {
- my $x0 = int($coords[0]);
- my $y0 = int($coords[1]);
- $coords = "($x0, $y0)";
- } else {
- my @points0 = @{$coords[0]};
- my $n = $#coords;
- my @pointsN = @{$coords[$n]};
- my $x0 = int($points0[0]);
- my $y0 = int($points0[1]);
- my $xn = int($pointsN[0]);
- my $yn = int($pointsN[1]);
- if ($n == 1) { ## a couple of points
- $coords = "($x0, $y0, $xn, $yn)";
- } else {
- $coords = "P0=($x0, $y0), ..., P".$n."=($xn, $yn)";
- }
- }
- if (@coords > 2) {
- my $dcbtn =
- $fm->Button(-text => $coords,
- -command => [\&showdevicecoords, $label, $zinc, $item]);
- $dcbtn->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 2);
- $balloonhelp->attach($dcbtn,-balloonmsg =>
- "Click to show all device coordinates.");
- } else {
- $fm->Label(-text => $coords, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
- }
- # bounding box
- my @bbox = $zinc->bbox($item);
- if (@bbox == 4) {
- my ($b0, $b1, $b2, $b3) = @bbox;
- $b0 = sprintf("%.2f", $b0) if int($b0) ne $b0;
- $b1 = sprintf("%.2f", $b1) if int($b1) ne $b1;
- $b2 = sprintf("%.2f", $b2) if int($b2) ne $b2;
- $b3 = sprintf("%.2f", $b3) if int($b3) ne $b3;
- my $btn = $fm->Button(-text => "($b0, $b1), ($b2, $b3)")
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
- $btn->bind('<1>', [\&showbbox, $zinc, $item]);
- $btn->bind('<ButtonRelease-1>', [\&hidebbox, $zinc]) ;
- $balloonhelp->attach($btn,-balloonmsg =>
- "Click to show the bounding box.");
- } else {
- $fm->Label(-text => "--", , -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
- }
- # tags
- my @tags = $zinc->gettags($item);
- my $height = 2;
- $height = scalar @tags if $cmdoptions{expandTagsField};
- &entryoption($fm, $item, $zinc, -tags, join("\n", @tags), 30, 30, $height)
- ->grid(-row => $i, -column => $c++, -sticky => 'nswe', -ipadx => 5);
-
- $i++;
- &showbanner($fm, $i++) if ($i % 15 == 0);
- }
-
-} # end showattributes
-
-
-sub showbanner {
-
- my $fm = shift;
- my $i = shift;
- my $bgcolor = 'ivory';
- my $c = 0;
- $fm->Label(-text => "Item\nId", -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => "Item\nType", -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => "Parent\ngroup", -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => "P\nr\ni\no", -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -ipady => 2, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => "S\ne\nn\ns", -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -ipady => 2, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => "V\ni\ns\ni", -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++, -ipady => 2, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => "All\noptions", -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++,
- -ipady => 5, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => "Transfo", -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++,
- -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => 'Coords', -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++,
- -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => 'Device coords', -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++,
- -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => 'Bounding box', -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++,
- -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- $fm->Label(-text => 'Tags', -background => $bgcolor, -relief => 'ridge')
- ->grid(-row => $i, -column => $c++,
- -ipady => 10, -ipadx => 5, -sticky => 'nswe');
- $fm->Label()->grid(-row => 1, -column => $c++, -pady => 10);
-
-} # end showbanner
-
-
-#---------------------------------------------------------------------------
-#
-# Functions related to contours display
-#
-#---------------------------------------------------------------------------
-
-# display contour (as simple curve)
-sub showcontour {
- my ($widget, $zinc, $color, $item, $contourcoords, $deviceflag) = @_;
- if ($deviceflag) {
- $zinc->add('curve', 1, $contourcoords,
- -filled => 0,
- -linecolor => $color,
- -tags => ['zincdebugcontour']);
-
- } else {
- $zinc->add('curve', 1, [$zinc->transform($item, 1, $contourcoords)],
- -filled => 0,
- -linecolor => $color,
- -tags => ['zincdebugcontour']);
- }
- $zinc->raise('zincdebugcontour');
-
-} # end showcontour
-
-
-sub hidecontour {
-
- my ($zinc) = @_;
- $zinc->remove('zincdebugcontour');
-
-} # end hidecontour
-
-
-# display contours points (one rectangle per point)
-sub showcontourpts {
- my ($widget, $zinc, $color, $item, $contourcoords, $deviceflag) = @_;
- my $i = 0;
- for my $coords (@$contourcoords) {
- my ($x, $y);
- if ($deviceflag) {
- ($x, $y) = @$coords;
- } else {
- ($x, $y) = $zinc->transform($item, 1, $coords);
- }
- if ($i == 0) {
- $zinc->add('arc', 1, [$x-10, $y-10, $x+10, $y+10],
- -filled => 0,
- -linewidth => 1,
- -linecolor => $color,
- -tags => ['zincdebugcontour']);
- } elsif ($i == @$contourcoords -1) {
- $zinc->add('arc', 1, [$x-10, $y-10, $x+10, $y+10],
- -filled => 0,
- -linewidth => 1,
- -linecolor => $color,
- -tags => ['zincdebugcontour']);
- $zinc->add('arc', 1, [$x-13, $y-13, $x+13, $y+13],
- -filled => 0,
- -linewidth => 1,
- -linecolor => $color,
- -tags => ['zincdebugcontour']);
- }
- my $dx = 3;
- if (@$coords > 2) {
- $zinc->add('rectangle', 1, [$x-$dx, $y-$dx, $x+$dx, $y+$dx],
- -filled => 0,
- -linewidth => 1,
- -linecolor => $color,
- -tags => ['zincdebugcontour']);
- } else {
- $zinc->add('rectangle', 1, [$x-$dx, $y-$dx, $x+$dx, $y+$dx],
- -filled => 1,
- -linewidth => 1,
- -fillcolor => $color,
- -linecolor => $color,
- -tags => ['zincdebugcontour']);
- }
- $i++;
- }
- $zinc->raise('zincdebugcontour');
-
-} # end showcontourpts
-
-
-# display one point of a contour (as a rectangle)
-sub showcontourpt {
-
- my ($widget, $zinc, $color, $item, $index, $deviceflag, $labels, @contour) = @_;
- $widget->focus;
- if ($index < 0 or $index >= @contour) {
- $widget->bell;
- return;
- }
- &hidecontour($zinc);
- my $bgcolor = ($labels->[0]->configure(-background))[3];
- for (@$labels) {
- $_->configure(-background => $bgcolor);
- }
- $labels->[$index]->configure(-background => 'bisque');
- my @coords = @{$contour[$index]};
- my ($x, $y);
- if ($deviceflag) {
- ($x, $y) = @coords;
- } else {
- ($x, $y) = $zinc->transform($item, 1, [@coords]);
- }
- my $dx = 3;
- if (@coords > 2) {
- $zinc->add('rectangle', 1, [$x-$dx, $y-$dx, $x+$dx, $y+$dx],
- -filled => 0,
- -linewidth => 1,
- -linecolor => $color,
- -tags => ['zincdebugcontour']);
- } else {
- $zinc->add('rectangle', 1, [$x-$dx, $y-$dx, $x+$dx, $y+$dx],
- -filled => 1,
- -linewidth => 1,
- -fillcolor => $color,
- -linecolor => $color,
- -tags => ['zincdebugcontour']);
- }
- $widget->bind('<Key-Down>', [\&showcontourpt, $zinc, $color,
- $item, $index+1, $deviceflag, $labels, @contour]);
- $widget->bind('<Key-Right>', [\&showcontourpt, $zinc, $color,
- $item, $index+1, $deviceflag, $labels, @contour]);
- $widget->bind('<Key-Up>', [\&showcontourpt, $zinc, $color,
- $item, $index-1, $deviceflag, $labels, @contour]);
- $widget->bind('<Key-Left>', [\&showcontourpt, $zinc, $color,
- $item, $index-1, $deviceflag, $labels, @contour]);
- $zinc->raise('zincdebugcontour');
-
-} # end showcontourpt
-
-
-#---------------------------------------------------------------------------
-#
-# Functions related to items graphical presentation
-#
-#---------------------------------------------------------------------------
-
-# display the bbox of a group item
-sub showbbox {
-
- my ($btn, $zinc, $item) = @_;
- $zinc->tsave(1, 'zoom+move', 1);
- my @bbox = $zinc->bbox($item);
- if (scalar @bbox == 4) {
- # If item is visible, rectangle is drawm surround it.
- # Else, a warning is displayed.
- unless (&itemisoutside($zinc, @bbox)) {
- my $i = -2;
- for ('white', 'blue', 'white') {
- $zinc->add('rectangle', 1,
- [$bbox[0] + $i, $bbox[1] + $i,
- $bbox[2] - $i, $bbox[3] - $i],
- -linecolor => $_,
- -linewidth => 1,
- -tags => ['zincdebugbbox']);
- $i += 2;
- }
- }
- }
- $zinc->trestore('zincdebugbbox', 'zoom+move');
- $zinc->raise('zincdebugbbox');
-
-} # end showbbox
-
-
-sub hidebbox {
-
- my ($btn, $zinc) = @_;
- $zinc->remove("zincdebugbbox");
-
-} # end hidebbox
-
-
-# display a message box when an item is not visible because outside window
-sub itemisoutside {
-
- my $zinc = shift;
- my @bbox = @_;
- return unless @bbox == 4;
- &getsize($zinc);
- #print "bbox=(@bbox) wheight=$wheight{$zinc} wwidth=$wwidth{$zinc}\n";
- my $outflag;
- $WARNING = 0;
- if ($bbox[2] < 0) {
- if ($bbox[1] > $wheight{$zinc}) {
- $outflag = 'left+bottom';
- } elsif ($bbox[3] < 0) {
- $outflag = 'left+top';
- } else {
- $outflag = 'left';
- }
- } elsif ($bbox[0] > $wwidth{$zinc}) {
- if ($bbox[1] > $wheight{$zinc}) {
- $outflag = 'right+bottom';
- } elsif ($bbox[3] < 0) {
- $outflag = 'right+top';
- } else {
- $outflag = 'right';
- }
- } elsif ($bbox[3] < 0) {
- $outflag = 'top';
- } elsif ($bbox[1] > $wheight{$zinc}) {
- $outflag = 'bottom';
- }
- #print "outflag=$outflag bbox=@bbox\n";
- return 0 unless $outflag;
- # create first group which will be translated. We will apply to this group
- # the reverse transformation of topgroup.
- my $g = $zinc->add('group', 1, -tags => ['zincdebug']);
- # create child group which won't be affected by ancestor's scale.
- my $g1 = $zinc->add('group', $g, -composescale => 0);
- my $hw = 110;
- my $hh = 80;
- my $r = 5;
- $zinc->add('rectangle', $g1, [-$hw, -$hh, $hw, $hh],
- -filled => 1,
- -linecolor => 'sienna',
- -linewidth => 3,
- -fillcolor => 'bisque',
- -priority => 1,
- );
- $zinc->add('text', $g1,
- -position => [0, 0],
- -color => 'sienna',
- -font => '-b&h-lucida-bold-i-normal-sans-34-240-*-*-p-*-iso8859-1',
- -anchor => 'center',
- -priority => 2,
- -text => "Item is\noutside\nwindow\n");
- my ($x, $y);
- if ($outflag eq 'bottom') {
- $x = $bbox[0] + ($bbox[2]-$bbox[0])/2;
- $x = $hw + 10 if $x < $hw + 10;
- $x = $wwidth{$zinc} - $hw - 10 if $x > $wwidth{$zinc} - $hw - 10;
- $y = $wheight{$zinc} - $hh - 10;
- } elsif ($outflag eq 'top') {
- $x = $bbox[0] + ($bbox[2]-$bbox[0])/2;
- $x = $hw + 10 if $x < $hw + 10;
- $x = $wwidth{$zinc} - $hw - 10if $x > $wwidth{$zinc} - $hw - 10;
- $y = $hh + 10;
- } elsif ($outflag eq 'left') {
- $x = $hw + 10;
- $y = $bbox[1] + ($bbox[3]-$bbox[1])/2;
- $y = $hh + 10 if $y < $hh + 10;
- $y = $wheight{$zinc} - $hh - 10 if $y > $wheight{$zinc} - $hh - 10;
- } elsif ($outflag eq 'right') {
- $x = $wwidth{$zinc} - $hw - 10;
- $y = $bbox[1] + ($bbox[3]-$bbox[1])/2;
- $y = $hh + 10 if $y < $hh + 10;
- $y = $wheight{$zinc} - $hh - 10 if $y > $wheight{$zinc} - $hh - 10;
- } elsif ($outflag eq 'left+top') {
- $x = $hw + 10;
- $y = $hh + 10;
- } elsif ($outflag eq 'left+bottom') {
- $x = $hw + 10;
- $y = $wheight{$zinc} - $hh - 10;
- } elsif ($outflag eq 'right+top') {
- $x = $wwidth{$zinc} - $hw - 10;
- $y = $hh + 10;
- } elsif ($outflag eq 'right+bottom') {
- $x = $wwidth{$zinc} - $hw - 10;
- $y = $wheight{$zinc} - $hh - 10;
- }
- # apply the reverse transformation of topgroup to group $g
- $zinc->tsave(1, 'transfo', 1);
- $zinc->trestore($g, 'transfo');
- # then translate group $g1
- $zinc->coords($g1, [$x, $y]);
- $zinc->raise('zincdebug');
-
-} # end itemisoutside
-
-
-
-# highlight an item (by cloning it and hiding other found items)
-# why cloning? because we can't simply make visible an item which
-# belongs to an invisible group.
-sub highlightitem {
-
- my ($btn, $zinc, $item, $level) = @_;
- return if $showitemflag or $item == 1;
- $showitemflag = 1;
- &surrounditem($zinc, $item, $level);
-
- $btn->bind('<ButtonRelease>', [\&undohighlightitem, $zinc]) if $btn;
-
-} # end highlightitem
-
-
-sub undohighlightitem {
-
- my ($btn, $zinc) = @_;
- #print "undohighlightitem\n";
- $btn->bind('ReleaseButton', '') if $btn;
- $zinc->remove('zincdebug');
- $showitemflag = 0;
-
-} # end undohighlightitem
-
-
-sub surrounditem {
-
- my ($zinc, $item, $level) = @_;
- $zinc->remove("zincdebug");
- # cloning
- my $clone = $zinc->clone($item, -visible => 1, -tags => ['zincdebug']);
- $zinc->tsave(1, 'zoom+move', 1);
- $zinc->chggroup($clone, 1, 1);
- my @bbox = $zinc->bbox($clone);
- # create a rectangle around
- if (scalar @bbox == 4) {
- # If item is visible, rectangle is drawm surround it.
- # Else, a warning is displayed.
- unless (&itemisoutside($zinc, @bbox)) {
- if (defined($level) and $level > 0) {
- my $r = $zinc->add('rectangle', 1,
- [$bbox[0] - 10, $bbox[1] - 10,
- $bbox[2] + 10, $bbox[3] + 10],
- -linewidth => 0,
- -filled => 1,
- -tags => ['zincdebug', 'zincdebugdecorator'],
- -fillcolor => "gray20");
- $zinc->itemconfigure($r, -fillcolor => "gray80") if $level == 1;
- }
- my $i = 0;
- for ('white', 'red', 'white') {
- $zinc->add('rectangle', 1,
- [$bbox[0] - 5 - 2*$i, $bbox[1] - 5 - 2*$i,
- $bbox[2] + 5 + 2*$i, $bbox[3] + 5 + 2*$i],
- -linecolor => $_,
- -linewidth => 1,
- -tags => ['zincdebug', 'zincdebugdecorator']);
- $i++;
- }
- }
- }
- # raise
- $zinc->trestore('zincdebugdecorator', 'zoom+move');
- $zinc->raise('zincdebug');
- $zinc->raise($clone);
-
-} # end surrounditem
-
-
-# functions related to transformation animations
-sub showtransfo {
-
- my ($btn, $zinc, $item, $level) = @_;
- my $anim = &highlighttransfo($zinc, $item, $level);
- $btn->bind('<ButtonRelease>', [\&undohighlighttransfo, $zinc, $anim]) if $btn;
-
-} # end showtransfo
-
-
-sub highlighttransfo {
-
- my ($zinc, $item, $level) = @_;
- $zinc->remove("zincdebug");
- my $g = $zinc->add('group', 1);
- my $g0 = $zinc->add('group', $g, -alpha => 0);
- my $g1 = $zinc->add('group', $g);
- # clone item and reset its transformation
- my $clone0 = $zinc->clone($item, -visible => 1, -tags =>['zincdebug']);
- $zinc->treset($clone0);
- # clone item and preserve its transformation
- my $clone1 = $zinc->clone($item, -visible => 1, -tags => ['zincdebug']);
- # move clones is dedicated group
- $zinc->chggroup($clone0, $g0, 1);
- $zinc->chggroup($clone1, $g1, 1);
- # create a rectangle around
- my @bbox0 = $zinc->bbox($g);
- if (scalar @bbox0 == 4) {
- $zinc->tsave(1, 'transfo', 1);
- my @bbox = $zinc->transform(1, $g, [@bbox0]);
- # If item is visible, rectangle is drawm surround it.
- # Else, a warning is displayed.
- unless (&itemisoutside($zinc, @bbox0)) {
- my $r = $zinc->add('rectangle', $g,
- [$bbox[0] - 10, $bbox[1] - 10,
- $bbox[2] + 10, $bbox[3] + 10],
- -filled => 1,
- -linewidth => 0,
- -tags => ['zincdebug'],
- -fillcolor => "gray90");
- $zinc->itemconfigure($r, -fillcolor => "gray50") if $level == 1;
- $zinc->itemconfigure($r, -fillcolor => "gray20") if $level == 2;
- $zinc->trestore($r, 'transfo');
- }
- }
- # raise
- $zinc->raise($g);
- $zinc->raise($g0);
- $zinc->raise($g1);
- # animation
- my $anim;
- if ($zinc->cget(-render) == 0) {
- $anim = $zinc->after(150, [sub {
- $zinc->itemconfigure($g1, -visible => 0);
- $zinc->itemconfigure($g0, -visible => 1);
- $zinc->update;
- }]);
- } else {
- my $maxsteps = 5;
- $step = $maxsteps;
- $anim = $zinc->repeat(100, [sub {
- return if $step < 0;
- $zinc->itemconfigure($g1, -alpha => ($step)*100/$maxsteps);
- $zinc->itemconfigure($g0, -alpha => ($maxsteps-$step)*100/$maxsteps);
- $zinc->update;
- $step--;
- }]);
-
-
- }
- return $anim;
-
-} # end highlighttransfo
-
-
-sub undohighlighttransfo {
-
- my ($btn, $zinc, $anim) = @_;
- $btn->bind('ReleaseButton', '') if $btn;
- $zinc->remove('zincdebug');
- $zinc->afterCancel($anim);
-
-} # end undohighlighttransfo
-
-
-#---------------------------------------------------------------------------
-#
-# Snapshot functions
-#
-#---------------------------------------------------------------------------
-
-# print a zinc window in png format
-sub printWindow {
-
- exit if $saving;
- $saving = 1;
- my ($zinc) = @_;
- my $basename = $cmdoptions{snapshotBasename};
- my $id = $zinc->id;
- my $filename = $basename . $imagecounter . ".png";
- $imagecounter++;
- my $original_cursor = ($zinc->configure(-cursor))[3];
- $zinc->configure(-cursor => 'watch');
- $zinc->update;
- my $res = system("import", -window, $id, $filename);
- $zinc->configure(-cursor => $original_cursor);
-
- $saving = 0;
- if ($res) {
- &showErrorWhilePrinting($zinc, $res)
- }
- else {
- my $dir = `pwd`; chomp ($dir);
- print "Tk::Zinc::Debug: Zinc window snapshot saved in $dir". "/$filename\n";
- }
-
-} # end printWindow
-
-
-# display complete help screen
-sub showErrorWhilePrinting {
-
- my ($zinc, $res) = @_;
- my $dir = `pwd`; chomp ($dir);
- $help_print->destroy if $help_print and Tk::Exists($help_print);
- $help_print = $zinc->Dialog(-title => 'Zinc Print info',
- -text =>
- "To acquire a TkZinc window snapshot, you must " .
- "have access to the import command, which is ".
- "part of imageMagic package\n\n".
- "You must also have the rights to write ".
- "in the current dir : $dir",
- -bitmap => 'warning',
- );
- $help_print->after(300, sub {$help_print->grabRelease});
- $help_print->Show();
-
-} # end showErrorWhilePrinting
-
-#---------------------------------------------------------------------------
-#
-# Help functions
-#
-#---------------------------------------------------------------------------
-
-# display help about tree
-sub showHelpAboutTree {
-
- my $zinc = shift;
- $helptree_tl->destroy if $helptree_tl and Tk::Exists($helptree_tl);
- $helptree_tl = $tree_tl->Toplevel;
- $helptree_tl->title("Help about Tree");
-
- my $text = $helptree_tl->Scrolled('Text',
- -font => scalar $zinc->cget(-font),
- -wrap => 'word',
- -foreground => 'gray10',
- -scrollbars => 'osoe',
- );
- &wheelmousebindings($text);
- $text->tagConfigure('keyword', -foreground => 'darkblue');
- $text->insert('end', "\nNAVIGATION IN TREE\n\n");
- $text->insert('end', "<Up>", "keyword");
- $text->insert('end', " arrow key moves the anchor point to the item right on ".
- "top of the current anchor item. ");
- $text->insert('end', "<Down>", "keyword");
- $text->insert('end', " arrow key moves the anchor point to the item right below ".
- "the current anchor item. ");
- $text->insert('end', "<Left>", "keyword");
- $text->insert('end', " arrow key moves the anchor to the parent item of the ".
- "current anchor item. ");
- $text->insert('end', "<Right>", "keyword");
- $text->insert('end', " moves the anchor to the first child of the current anchor ".
- "item. If the current anchor item does not have any children, moves ".
- "the anchor to the item right below the current anchor item.\n\n");
- $text->insert('end', "\nHIGHLIGHTING ITEMS\n\n");
- $text->insert('end', "To display item's features, ");
- $text->insert('end', "double-click", "keyword");
- $text->insert('end', " on it, press ");
- $text->insert('end', "<Return>", "keyword");
- $text->insert('end', " key or click on the ");
- $text->insert('end', "Attributes", "keyword");
- $text->insert('end', " button.\n\n");
- $text->insert('end', "To highlight item in the application, simply ");
- $text->insert('end', "click", "keyword");
- $text->insert('end', " on it.");
- &infoAboutHighlighting($text);
- $text->insert('end', "\n\n\nBUILDING CODE\n\n");
- $text->insert('end', "To build perl code, select a branch or a leaf ".
- "and click on the ");
- $text->insert('end', "Build code", "keyword");
- $text->insert('end', " button. Then select an output file with the ".
- "file selector.\n\n");
- $text->configure(-state => 'disabled');
-
- $helptree_tl->Button(-command => sub {$helptree_tl->destroy},
- -text => 'Close')->pack(-side => 'bottom',
- -pady => 10);
- $text->pack->pack(-side => 'top', -pady => 10, -padx => 10);
-
-} # end showHelpAboutTree
-
-
-sub showHelpAboutCoords {
-
- my $zinc = shift;
- $helpcoords_tl->destroy if $helpcoords_tl and Tk::Exists($helpcoords_tl);
- $helpcoords_tl = $zinc->Toplevel;
- $helpcoords_tl->title("Help about coordinates");
-
- my $text = $helpcoords_tl->Scrolled('Text',
- -font => scalar $zinc->cget(-font),
- -wrap => 'word',
- -height => 30,
- -foreground => 'gray10',
- -scrollbars => 'oe',
- );
- &wheelmousebindings($text);
- $text->tagConfigure('keyword', -foreground => 'darkblue');
- $text->tagConfigure('title', -foreground => 'ivory',
- -background => 'gray60',
- -spacing1 => 3,
- -spacing3 => 3);
-
-
- $text->insert('end', " To display a contour\n", 'title');
- $text->insert('end', "Press button labeled ");
- $text->insert('end', 'Contour i', 'keyword');
- $text->insert('end', " (*). Release it to hide contour.");
- $text->insert('end', "\n\n");
- $text->insert('end', " To display all the points of a contour\n", 'title');
- $text->insert('end', "Press button labeled ");
- $text->insert('end', 'n points', 'keyword');
- $text->insert('end', " (*). Release it to hide points. First plot is ".
- "particularized by a circle, last one by a double circle. ".
- "Non-filled plots represent control points of a Bezier curve.");
- $text->insert('end', "\n\n");
- $text->insert('end', " To navigate in the contour\n", 'title');
- $text->insert('end', "Select first a point by clicking in the coordinates table ");
- $text->insert('end', "(*). Th corresponding plot is displayed. Then use the ");
- $text->insert('end', "Up/Down", 'keyword');
- $text->insert('end', " (or ");
- $text->insert('end', "Left/Right", 'keyword');
- $text->insert('end', ") arrows keys to navigate in the contour");
- $text->insert('end', "\n\n");
- $text->insert('end', "\n\n");
- $text->insert('end', "(*) The color of displayed elements depends on the mouse ".
- "button you press.");
- $text->insert('end', "\n\n");
- $text->configure(-state => 'disabled');
-
- $helpcoords_tl->Button(-command => sub {$helpcoords_tl->destroy},
- -text => 'Close')->pack(-side => 'bottom',
- -pady => 10);
- $text->pack->pack(-side => 'top', -pady => 10, -padx => 10);
-
-} # end showHelpAboutCoords
-
-
-
-sub infoAboutHighlighting {
-
- my $text = shift;
- $text->insert('end', "By default, using ");
- $text->insert('end', "left mouse button", "keyword");
- $text->insert('end', ", highlighting is done by raising selected item and drawing ".
- "a rectangle arround. ");
- $text->insert('end', "In order to improve visibility, ");
- $text->insert('end', "item will be light backgrounded if you use ");
- $text->insert('end', "center mouse button", "keyword");
- $text->insert('end', " and dark backgrounded if you use ");
- $text->insert('end', "right mouse button", "keyword");
- $text->insert('end', ". ");
-
-} # end infoAboutHighlighting
-
-
-sub entryballoonhelp {
-
- my $e = shift;
- my $msg = shift;
- $msg .= "Editable field. To restore the inital value\n".
- "after edition, enter <Control-z> sequence. ";
- $balloonhelp->attach($e, -balloonposition => 'mouse',
- -balloonmsg => $msg);
-
-} # end entryballoonhelp
-
-
-sub balloonhelp {
-
- my $b = $control_tl->Balloon(-balloonposition => 'widget',
- -font => '6x13');
- $b->attach($button{zn},-balloonmsg =>
- "Widget instance selector. Use it when \n".
- "your application takes more than one \n".
- "TkZinc instance. When this mode is on,\n".
- "select the TkZinc instance you want \n".
- "inspect just by clicking on it. ");
- $b->attach($button{findenclosed}, -balloonmsg =>
- "Inspect all items *enclosed* in a \n".
- "rectangular area. When this mode is\n".
- "selected, draw rectangle using left\n".
- "mouse button. ");
- $b->attach($button{findoverlap}, -balloonmsg =>
- "Inspect all items which *overlap* \n".
- "a rectangular area. When this mode\n".
- "is selected, draw rectangle using \n".
- "left mouse button. ");
- $b->attach($button{tree}, -balloonmsg =>
- #"Display the items hierarchy. Can\n".
- #"build perl code corresponding to\n".
- #"a specific branch. ");
- "Display the items hierarchy. Provide\n".
- "some related functions, like building\n".
- "perl code corresponding to a branch.");
- $b->attach($button{item}, -balloonmsg =>
- "Locate an item in the items tree. \n".
- "When this mode is on, select in \n".
- "your application the item you want\n".
- "to inspect just by clicking on it.");
- $b->attach($button{id}, -balloonmsg =>
- "Open an entry field in which you will \n".
- "enter an item's id you want to inspect.");
- $b->attach($button{snapshot}, -balloonmsg =>
- "Snapshot the application window.");
- $b->attach($button{cursorxy}, -balloonmsg =>
- "Display the device coordinates\n".
- "of the X cursor. ");
- $b->attach($button{zoomminus}, -balloonmsg =>
- "Shrink the top group.");
- $b->attach($button{zoomplus}, -balloonmsg =>
- "Expand the top group.");
- $b->attach($button{move}, -balloonmsg =>
- "Translate the top group. When this\n".
- "mode is selected, move the top \n".
- "group using left mouse button. ");
- $b->attach($button{balloon},-balloonmsg =>
- "Balloon help toggle.");
- $b->attach($button{close},-balloonmsg =>
- "Close this buttons bar.");
- return $b;
-
-} # end balloonhelp
-
-
-
-#---------------------------------------------------------------------------
-#
-# Bitmaps creation for the buttons of the control bar
-#
-#---------------------------------------------------------------------------
-
-sub createBitmaps {
-
- my $zinc = shift;
- my $bitmaps;
-
- $bitmaps->{close} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define close_width 29
-#define close_height 29
-static unsigned char close_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x08, 0x00,
- 0x00, 0x07, 0x1c, 0x00, 0x00, 0x0e, 0x0e, 0x00, 0x00, 0x1c, 0x07, 0x00,
- 0x00, 0xb8, 0x03, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0xe0, 0x00, 0x00,
- 0x00, 0xf0, 0x01, 0x00, 0x00, 0xb8, 0x03, 0x00, 0x00, 0x1c, 0x07, 0x00,
- 0x00, 0x0e, 0x0e, 0x00, 0x00, 0x07, 0x1c, 0x00, 0x00, 0x02, 0x08, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-EOF
- $bitmaps->{zn} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define focus_width 29
-#define focus_height 29
-static unsigned char focus_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x60, 0x38, 0x00, 0x00,
- 0x20, 0x18, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x8e, 0x33, 0x00,
- 0x00, 0x06, 0x7b, 0x00, 0x00, 0x07, 0x67, 0x00, 0x80, 0x03, 0x63, 0x00,
- 0xc0, 0x01, 0x63, 0x00, 0xc0, 0x00, 0x63, 0x00, 0xe0, 0x20, 0x63, 0x00,
- 0x70, 0x30, 0x63, 0x00, 0xf0, 0xbf, 0xe7, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, };
-EOF
- $bitmaps->{findenclosed} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define findenclosed_width 29
-#define findenclosed_height 29
-static unsigned char findenclosed_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00,
- 0xfc, 0xff, 0xff, 0x03, 0xfc, 0xff, 0xff, 0x03, 0x3c, 0x00, 0x00, 0x03,
- 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03,
- 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03,
- 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03,
- 0x18, 0x80, 0x00, 0x03, 0x18, 0x00, 0x01, 0x03, 0x18, 0x00, 0x22, 0x03,
- 0x18, 0x00, 0x24, 0x03, 0x18, 0x00, 0x28, 0x03, 0x18, 0x00, 0x20, 0x03,
- 0x18, 0x00, 0x3e, 0x03, 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03,
- 0xf8, 0xff, 0xff, 0x03, 0xf8, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-EOF
- $bitmaps->{findoverlap} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define findoverlap_width 29
-#define findoverlap_height 29
-static unsigned char findoverlap_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00,
- 0xfc, 0xb6, 0x6d, 0x03, 0xfc, 0xb6, 0x6d, 0x03, 0x3c, 0x00, 0x00, 0x00,
- 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
- 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
- 0x18, 0x00, 0x00, 0x03, 0x18, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
- 0x18, 0x80, 0x00, 0x03, 0x18, 0x00, 0x01, 0x03, 0x00, 0x00, 0x22, 0x00,
- 0x18, 0x00, 0x24, 0x03, 0x18, 0x00, 0x28, 0x03, 0x00, 0x00, 0x20, 0x00,
- 0x18, 0x00, 0x3e, 0x03, 0x18, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
- 0xd8, 0xb6, 0x6d, 0x03, 0xd8, 0xb6, 0x6d, 0x03, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-EOF
- $bitmaps->{tree} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define tree_width 29
-#define tree_height 29
-static unsigned char tree_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0xf0, 0x07, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x10, 0x04, 0x00,
- 0xc0, 0x1f, 0x04, 0x00, 0x40, 0x10, 0x04, 0x00, 0x40, 0x10, 0x04, 0x00,
- 0x40, 0xf0, 0x07, 0x00, 0x40, 0x00, 0x00, 0x00, 0x40, 0x00, 0xe0, 0x0f,
- 0x40, 0x00, 0x20, 0x08, 0x7c, 0x00, 0x20, 0x08, 0x40, 0x00, 0x3f, 0x08,
- 0x40, 0x00, 0x21, 0x08, 0x40, 0x00, 0x21, 0x08, 0x40, 0x00, 0xe1, 0x0f,
- 0x40, 0x00, 0x01, 0x00, 0x40, 0x00, 0x01, 0x00, 0xc0, 0xff, 0x01, 0x00,
- 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00,
- 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x5f, 0x01, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-EOF
- $bitmaps->{item} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define item_width 29
-#define item_height 29
-static unsigned char item_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x08, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0xf0, 0x00, 0x00, 0x00,
- 0xe0, 0x03, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0xc0, 0x1f, 0x00, 0x00,
- 0xc0, 0x7f, 0x00, 0x00, 0x80, 0xff, 0x01, 0x00, 0x00, 0xff, 0x03, 0x00,
- 0x00, 0xff, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0xfe, 0x00, 0x00,
- 0x00, 0xdc, 0x01, 0x00, 0x00, 0x8c, 0x03, 0x00, 0x00, 0x08, 0x07, 0x00,
- 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x38, 0x00,
- 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x40, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-EOF
- $bitmaps->{id} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define id_width 29
-#define id_height 29
-static unsigned char id_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x0e, 0x00, 0x00, 0x06, 0x0c, 0x00,
- 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x87, 0x0f, 0x00,
- 0x00, 0xc6, 0x0c, 0x00, 0x00, 0x66, 0x0c, 0x00, 0x00, 0x66, 0x0c, 0x00,
- 0x00, 0x66, 0x0c, 0x00, 0x00, 0x66, 0x0c, 0x00, 0x00, 0x66, 0x0c, 0x00,
- 0x00, 0xc6, 0x0c, 0x00, 0x00, 0x8f, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, };
-EOF
- $bitmaps->{snapshot} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define snapshot_width 29
-#define snapshot_height 29
-static unsigned char snapshot_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x1f, 0x00,
- 0x80, 0x03, 0x11, 0x00, 0xe0, 0xff, 0xf1, 0x00, 0xf0, 0xff, 0xff, 0x01,
- 0xf0, 0xff, 0xff, 0x01, 0xf0, 0xff, 0xff, 0x01, 0xf0, 0x0f, 0xfe, 0x01,
- 0xf0, 0xe7, 0xfc, 0x01, 0xf0, 0x13, 0xf9, 0x01, 0xf0, 0x09, 0xf2, 0x01,
- 0xf0, 0x05, 0xf4, 0x01, 0xf0, 0x05, 0xf4, 0x01, 0xf0, 0x05, 0xf4, 0x01,
- 0xf0, 0x09, 0xf2, 0x01, 0xf0, 0x13, 0xf9, 0x01, 0xf0, 0xe7, 0xfc, 0x01,
- 0xf0, 0x0f, 0xfe, 0x01, 0xf0, 0xff, 0xff, 0x01, 0xe0, 0xff, 0xff, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-EOF
- $bitmaps->{zoomminus} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define zoomminus_width 29
-#define zoomminus_height 29
-static unsigned char zoomminus_bits[] = {
- 0x00, 0x0e, 0x00, 0x00, 0xc0, 0x71, 0x00, 0x00, 0x30, 0x80, 0x01, 0x00,
- 0x08, 0x00, 0x02, 0x00, 0x04, 0x00, 0x04, 0x00, 0x04, 0x00, 0x04, 0x00,
- 0x02, 0x00, 0x08, 0x00, 0x02, 0x00, 0x08, 0x00, 0x02, 0x00, 0x08, 0x00,
- 0xe1, 0xff, 0x10, 0x00, 0xe1, 0xff, 0x10, 0x00, 0xe1, 0xff, 0x10, 0x00,
- 0x02, 0x00, 0x08, 0x00, 0x02, 0x00, 0x08, 0x00, 0x02, 0x00, 0x08, 0x00,
- 0x04, 0x00, 0x04, 0x00, 0x04, 0x00, 0x04, 0x00, 0x08, 0x00, 0x02, 0x00,
- 0x30, 0x80, 0x05, 0x00, 0xc0, 0x71, 0x28, 0x00, 0x00, 0x0e, 0x70, 0x00,
- 0x00, 0x00, 0xf8, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0xe0, 0x03,
- 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x80, 0x0f, 0x00, 0x00, 0x00, 0x1f,
- 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x04};
-EOF
-
- $bitmaps->{zoomplus} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define zoomplus_width 29
-#define zoomplus_height 29
-static unsigned char zoomplus_bits[] = {
- 0x00, 0x0e, 0x00, 0x00, 0xc0, 0x71, 0x00, 0x00, 0x30, 0x80, 0x01, 0x00,
- 0x08, 0x00, 0x02, 0x00, 0x04, 0x00, 0x04, 0x00, 0x04, 0x0e, 0x04, 0x00,
- 0x02, 0x0e, 0x08, 0x00, 0x02, 0x0e, 0x08, 0x00, 0x02, 0x0e, 0x08, 0x00,
- 0xe1, 0xff, 0x10, 0x00, 0xe1, 0xff, 0x10, 0x00, 0xe1, 0xff, 0x10, 0x00,
- 0x02, 0x0e, 0x08, 0x00, 0x02, 0x0e, 0x08, 0x00, 0x02, 0x0e, 0x08, 0x00,
- 0x04, 0x0e, 0x04, 0x00, 0x04, 0x00, 0x04, 0x00, 0x08, 0x00, 0x02, 0x00,
- 0x30, 0x80, 0x05, 0x00, 0xc0, 0x71, 0x28, 0x00, 0x00, 0x0e, 0x70, 0x00,
- 0x00, 0x00, 0xf8, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x00, 0x00, 0xe0, 0x03,
- 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x80, 0x0f, 0x00, 0x00, 0x00, 0x1f,
- 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x04};
-EOF
-
- $bitmaps->{move} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define hand_width 29
-#define hand_height 29
-static unsigned char hand_bits[] = {
- 0x00, 0xe0, 0x00, 0x00, 0x00, 0x10, 0x01, 0x00, 0x80, 0x13, 0x0f, 0x00,
- 0x40, 0x12, 0x11, 0x00, 0x40, 0x14, 0x11, 0x00, 0x40, 0x14, 0xd1, 0x01,
- 0x80, 0x14, 0x31, 0x02, 0x80, 0x14, 0x31, 0x02, 0x80, 0x18, 0x31, 0x02,
- 0x80, 0x18, 0x31, 0x02, 0x00, 0x11, 0x31, 0x02, 0x00, 0x11, 0x11, 0x01,
- 0x1c, 0x11, 0x11, 0x01, 0x22, 0x01, 0x11, 0x01, 0x42, 0x01, 0x10, 0x01,
- 0x84, 0x01, 0x00, 0x01, 0x88, 0x01, 0x00, 0x01, 0x08, 0x01, 0x00, 0x02,
- 0x08, 0x02, 0x00, 0x02, 0x10, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02,
- 0x20, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x01,
- 0x80, 0x00, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x06, 0x40, 0x00,
- 0x00, 0x08, 0x40, 0x00, 0x00, 0x08, 0x40, 0x00};
-EOF
-
- $bitmaps->{balloon} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define balloon_width 29
-#define balloon_height 29
-static unsigned char balloon_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x00,
- 0x10, 0x00, 0x00, 0x01, 0x08, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x02,
- 0x08, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x02,
- 0x08, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x02,
- 0x08, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x02,
- 0x10, 0x00, 0x00, 0x01, 0xe0, 0xe0, 0xff, 0x00, 0x00, 0x11, 0x00, 0x00,
- 0x00, 0x09, 0x00, 0x00, 0x80, 0x04, 0x00, 0x00, 0x80, 0x02, 0x00, 0x00,
- 0x40, 0x01, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
-EOF
-
- $bitmaps->{cursorxy} = $zinc->toplevel->Bitmap(-data => <<EOF);
-#define balloon_width 29
-#define balloon_height 29
-static unsigned char balloon_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00,
- 0x00, 0x06, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00,
- 0x00, 0x1c, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, 0x48, 0x00, 0x00,
- 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00,
- 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x30, 0x06, 0x8c, 0x01, 0x70, 0x07, 0x8c, 0x01, 0x60, 0x03, 0x8c, 0x01,
- 0xc0, 0x01, 0xd8, 0x00, 0xc0, 0x01, 0xd8, 0x00, 0x60, 0xe3, 0xd8, 0x00,
- 0x70, 0x66, 0x70, 0x00, 0x30, 0x66, 0x70, 0x00, 0x00, 0x30, 0x60, 0x00,
- 0x00, 0x30, 0x30, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, };
-EOF
-
- return $bitmaps;
-
-} # end createBitmaps
-
-
-#---------------------------------------------------------------------------
-#
-# Miscellaneous
-#
-#---------------------------------------------------------------------------
-
-sub getsize {
-
- my $zinc = shift;
- $wwidth{$zinc} = $zinc->cget(-width);
- $wheight{$zinc} = $zinc->cget(-height);
-
-} # end getsize
-
-
-sub entryoption {
-
- my ($fm, $item, $zinc, $option, $def, $widthmax, $widthmin, $height) = @_;
- my $arrayflag;
- unless (defined $def) {
- my @def = $zinc->itemcget($item, $option);
- if (@def > 1) {
- $arrayflag = 1;
- $def = join(', ', @def);
- } else {
- $def = $def[0];
- }
- }
- $def = "" unless defined $def;
- my $i0;
- my $e;
- if ($def =~ /\n/) {
- $height = 1 unless defined($height);
- $e = $fm->Text(-height => $height, -width => 1, -wrap => 'none');
- $i0 = '0.0';
- } else {
- $e = $fm->Entry();
- $i0 = 0;
- }
- &entryballoonhelp($e);
- my $width = length($def);
- $width = $widthmax if defined($widthmax) and $width > $widthmax;
- $width = $widthmin if defined($widthmin) and $width < $widthmin;
- $e->configure(-width => $width);
- if ($defaultoptions{$item}->{$option} and
- $def ne $defaultoptions{$item}->{$option}) {
- $e->configure(-foreground => 'blue');
- }
-
- $e->insert($i0, $def);
- $e->bind('<Control-z>', sub {
- return unless defined $defaultoptions{$item}->{$option};
- my $bg = $e->cget(-background);
- $zinc->itemconfigure($item, $option => $defaultoptions{$item}->{$option});
- $e->delete($i0, 'end');
- $e->insert($i0, $defaultoptions{$item}->{$option});
- $e->configure(-background => 'ivory');
- $e->after(80, sub {$e->configure(-background => $bg, -foreground => 'black')});
- });
- $e->bind('<Key-Return>',
- sub {my $val = $e->get;
- my $bg = $e->cget(-background);
- $e->configure(-background => 'ivory');
- if ($def ne $val) {
- $defaultoptions{$item}->{$option} = $def
- unless $defaultoptions{$item}->{$option};
- }
- my $fg = ($val ne $defaultoptions{$item}->{$option}) ?
- 'blue' : 'black';
- $e->after(80, sub {
- $e->configure(-background => $bg, -foreground => $fg);
- });
- if ($arrayflag) {
- $zinc->itemconfigure($item, $option => [split(/,/, $val)]);
- } else {
- $zinc->itemconfigure($item, $option => $val);
- }
- });
-
- return $e;
-
-} # end entryoption
-
-
-sub entrytransfo {
-
- my ($fm, $item, $zinc, $attr, $def, $var, $width, $set_cb) = @_;
- my $i0;
- my $e;
- $e = $fm->Entry(-textvariable => $var);
- &entryballoonhelp($e);
- $i0 = 0;
- my $width = length($def);
- $e->configure(-width => $width);
- $e->insert($i0, $def);
- $e->bind('<Control-z>', sub {
- my $bg = $e->cget(-background);
- $e->delete($i0, 'end');
- $e->insert($i0, $def);
- $e->configure(-background => 'ivory');
- $e->after(80, sub {$e->configure(-background => $bg, -foreground => 'black')});
- &$set_cb;
- });
- $e->bind('<Key-Return>',
- sub {my $val = $e->get;
- my $bg = $e->cget(-background);
- $e->configure(-background => 'ivory');
- my $fg = ($val ne $def) ? 'blue' : 'black';
- $e->after(80, sub {
- $e->configure(-background => $bg, -foreground => $fg);
- });
- &$set_cb;
- });
-
- return $e;
-
-} # end entrytransfo
-
-
-sub instances {
-
- return @instances;
-
-} # end instances
-
-
-sub saveMotionBinding {
-
- my ($zinc) = @_;
- for my $seq ('Motion') {
- $userbindings{$zinc}->{$seq} = $zinc->Tk::bind('<'.$seq.'>')
- unless defined $userbindings{$zinc}->{$seq};
- $userbindings{$zinc}->{$seq} = "" unless defined $userbindings{$zinc}->{$seq};
- $zinc->Tk::bind('<'.$seq.'>', "");
- }
-
-} # end saveMotionBinding
-
-
-sub restoreMotionBinding {
-
- my ($zinc) = @_;
- for my $seq ('Motion') {
- next unless defined $userbindings{$zinc}->{$seq};
- $zinc->Tk::bind('<'.$seq.'>', $userbindings{$zinc}->{$seq});
- delete $userbindings{$zinc}->{$seq};
- }
-
-} # end restoreMotionBinding
-
-
-sub saveDragAndDropBindings {
-
- my ($zinc) = @_;
- for my $seq ('ButtonPress-1', 'B1-Motion', 'ButtonRelease-1') {
- $userbindings{$zinc}->{$seq} = $zinc->Tk::bind('<'.$seq.'>')
- unless defined $userbindings{$zinc}->{$seq};
- $userbindings{$zinc}->{$seq} = "" unless defined $userbindings{$zinc}->{$seq};
- #print "saveDragAndDropBindings seq=$seq cb=$userbindings{$zinc}->{$seq}\n";
- $zinc->Tk::bind('<'.$seq.'>', "");
- }
-
-} # end saveDragAndDropBindings
-
-
-sub restoreDragAndDropBindings {
-
- my ($zinc) = @_;
- for my $seq ('ButtonPress-1', 'B1-Motion', 'ButtonRelease-1') {
- next unless defined $userbindings{$zinc}->{$seq};
- $zinc->Tk::bind('<'.$seq.'>', $userbindings{$zinc}->{$seq});
- #print "restoreDragAndDropBindings seq=$seq cb=$userbindings{$zinc}->{$seq}\n";
- delete $userbindings{$zinc}->{$seq};
- }
-
-} # end restoreDragAndDropBindings
-
-
-sub newinstance {
-
- my $zinc = shift;
- return if $instances{$zinc};
- $zinc->toplevel->Tk::bind('<Key-Escape>', \&Tk::Zinc::Debug::deiconify);
- $instances{$zinc} = 1;
- push(@instances, $zinc);
- $zinc->Tk::focus;
- $selectedzinc = $zinc;
-
-} # end newinstance
-
-
-sub deiconify {
-
- $button{zn}->destroy() if @instances == 1 and Tk::Exists($button{zn});
- $control_tl->deiconify();
- for (values %result_tl) {
- $_->deiconify if Tk::Exists($_);
- }
- for (values %coords_tl) {
- $_->deiconify if Tk::Exists($_);
- }
- for (values %alloptions_tl) {
- $_->deiconify if Tk::Exists($_);
- }
- $tree_tl->deiconify if Tk::Exists($tree_tl);
- $search_tl->deiconify if Tk::Exists($search_tl);
- $searchtree_tl->deiconify if Tk::Exists($searchtree_tl);
- $cursorxy_tl->deiconify if Tk::Exists($cursorxy_tl);
- $control_tl->raise();
-
-} # end deiconify
-
-
-sub iconify {
-
- for (values %result_tl) {
- $_->withdraw if Tk::Exists($_);
- }
- for (values %coords_tl) {
- $_->withdraw if Tk::Exists($_);
- }
- for (values %alloptions_tl) {
- $_->withdraw if Tk::Exists($_);
- }
- $tree_tl->withdraw if Tk::Exists($tree_tl);
- $search_tl->withdraw if Tk::Exists($search_tl);
- $searchtree_tl->withdraw if Tk::Exists($searchtree_tl);
- $cursorxy_tl->withdraw if Tk::Exists($cursorxy_tl);
- $control_tl->withdraw();
-
-} # end iconify
-
-# wheelmousebindings doesn't work for Tk::Pane widgets...
-sub wheelmousebindings {
- my $w = shift;
- my $count = shift;
- $count = 3 unless $count > 0;
-
- $w->bind('<Control-ButtonPress-4>', sub {$w->yview('scroll', -1, 'page')});
- $w->bind('<Shift-ButtonPress-4>', sub {$w->yview('scroll', -1, 'unit')});
- $w->bind('<ButtonPress-4>', sub {$w->yview('scroll', -$count, 'unit')});
-
- $w->bind('<Control-ButtonPress-5>', sub {$w->yview('scroll', 1, 'page')});
- $w->bind('<Shift-ButtonPress-5>', sub {$w->yview('scroll', 1, 'unit')});
- $w->bind('<ButtonPress-5>', sub {$w->yview('scroll', $count, 'unit')});
-
-} # end wheelmousebindings
-
-1;
-
-__END__
-
-
-=head1 NAME
-
-Tk::Zinc::Debug - a perl module for analysing a Zinc application.
-
-
-=head1 SYNOPSIS
-
- perl -MTk::Zinc::Debug zincscript [zincscript-opts] [Debug-initopts]
-
- or
-
- use Tk::Zinc::Debug;
- my $zinc = MainWindow->new()->Zinc()->pack;
- Tk::Zinc::Debug::init($zinc, [options]);
-
-
-=head1 DESCRIPTION
-
-Tk::Zinc::Debug provides an interface to help developers to inspect Zinc applications.
-
-Press the B<Escape> key in the toplevel of your application to display the Tk::Zinc::Debug buttons bar.
-
-
-Features :
-
-=over
-
-=item B<o> scan a rectangular area
-
-Scan all items which are enclosed in a rectangular area you have first drawn by drag & drop, or all items which overlap it. Result is a Tk table which presents details (options, coordinates, ...) about found items; you can also highlight a particular item, even if it's not visible, by clicking on its corresponding button in the table. You can also display particular item's features by entering this id in dedicated entry field
-
-=item B<o> display items hierarchy
-
-You can find a particular item's position in the tree and you can highlight items and see their features as described above. You can also generate the perl code corresponding to a selected branch (but images can't be reproduced).
-
-=item B<o> snapshot the application window
-
-In order to illustrate a graphical bug for example.
-
-=item B<o> display coordinates of the X cursor.
-
-=item B<o> zoom/translate the top group
-
-=back
-
-
-=head2 Loading Tk::Zinc::Debug as a plugin
-
-If you load Tk::Zinc::Debug using the -M perl option, B<nothing needs to be added to your code>. In this case, the B<init()> function is automatically invoked with its default attributes for each instance of Zinc widget. You can overload these by passing the same options to the command.
-
-=head1 FUNCTION
-
-
-=over
-
-=item B<init>($zinc, ?option => value, ...?)
-
-This function creates required Tk bindings to permit items search. You can specify the following options :
-
-=over
-
-=item E<32>E<32>E<32>B<-optionsToDisplay> => opt1[,..,optN]
-
-Used to display some option's values associated to items of the tree. Expected argument is a string of commas separated options.
-
-=item E<32>E<32>E<32>B<-optionsFormat> => row | column
-
-Defines the display format of option's values. Default is 'row'.
-
-=item E<32>E<32>E<32>B<-snapshotBasename> => string
-
-Defines the basename used for the file containing the snaphshot. The filename will be <current­dir>/basename<n>.png Defaulted to 'zincsnapshot'.
-
-=item E<32>E<32>E<32>B<-expandTagsField> => 0 | 1
-
-Specifies if the tags field in the attributes window will be expanded to show all the items tags (it should take up a lot of space). In the default case (value is set to 0), only the head of the list is displayed.
-
-
-=back
-
-
-=back
-
-
-=head1 AUTHOR
-
-Daniel Etienne <etienne@cena.fr>
-
-
-=head1 HISTORY
-
-Oct 5 2004 : transformations are correctly managed in built code. Transfo parameters can be displayed and set. new mode to display coordinateds of X cursor.
-
-Oct 14 2003 : add a control bar, and zoom/translate new functionalities. finditems(), tree(), snapshot() functions become deprecated, initialisation is done using the new init() function.
-
-Oct 07 2003 : contours of curves can be displayed and explored.
-
-Sep 15 2003 : due to CPAN-isation, the ZincDebug module has been renamed Tk::Zinc::Debug
-
-May 20 2003 : perl code can be generated from the items tree, with some limitations concerning transformations and images.
-
-Mar 11 2003 : ZincDebug can manage several instances of Zinc widget. Options of ZincDebug functions can be set on the command line.
-
-Jan 20 2003 : item's attributes can be edited.
-
-Jan 14 2003 : ZincDebug can be loaded at runtime using the -M perl option without any change in the application's code.
-
-Nov 6 2002 : some additional informations (like tags or other attributes values) can be displayed in the items tree. Add feedback when selected item is not visible because outside window.
-
-Sep 2 2002 : add the tree() function
-
-May 27 2002 : add the snapshot() function contributed by Ch. Mertz.
-
-Jan 28 2002 : Zincdebug provides the finditems() function and can manage only one instance of Zinc widget.
diff --git a/Perl/Zinc/Graphics.pm b/Perl/Zinc/Graphics.pm
deleted file mode 100644
index 8305c81..0000000
--- a/Perl/Zinc/Graphics.pm
+++ /dev/null
@@ -1,3067 +0,0 @@
-#-----------------------------------------------------------------------------------
-#
-# Graphics.pm
-# some graphic design functions
-#
-#-----------------------------------------------------------------------------------
-# Functions to create complexe graphic component :
-# ------------------------------------------------
-# buildZincItem (realize a zinc item from description hash table
-# management of enhanced graphics functions)
-#
-# repeatZincItem (duplication of given zinc item)
-#
-# Function to compute complexe geometrical forms :
-# (text header of functions explain options for each form,
-# function return curve coords using control points of cubic curve)
-# -----------------------------------------------------------------
-# roundedRectangleCoords (return curve coords of rounded rectangle)
-# hippodromeCoords (return curve coords of circus form)
-# ellipseCoords (return curve coords of ellipse form)
-# polygonCoords (return curve coords of regular polygon)
-# roundedCurveCoords (return curve coords of rounded curve)
-# polylineCoords (return curve coords of polyline)
-# shiftPathCoords (return curve coords of shifting path)
-# tabBoxCoords (return curve coords of tabBox's pages)
-# pathLineCoords (return triangles coords of pathline)
-#
-# Function to compute 2D 1/2 relief and shadow :
-# function build zinc items (triangles and curve) to simulate this
-# -----------------------------------------------------------------
-# graphicItemRelief (return triangle items simulate relief of given item)
-# polylineReliefParams (return triangle coords and lighting triangles color list)
-# graphicItemShadow (return triangles and curve items simulate shadow of given item))
-# polylineShadowParams (return triangle and curve coords and shadow triangles color list))
-#
-# Geometrical basic Functions :
-# -----------------------------
-# perpendicularPoint
-# lineAngle
-# lineNormal
-# vertexAngle
-# arc_pts
-# rad_point
-# bezierCompute
-# bezierSegment
-# bezierPoint
-#
-# Pictorial Functions :
-# ----------------------
-# setGradients
-# getPattern
-# getTexture
-# getImage
-# init_pixmaps
-# zincItemPredominantColor
-# ZnColorToRGB
-# hexaRGBcolor
-# createGraduate
-# pathGraduate
-# MedianColor
-# LightingColor
-# RGBtoLCH
-# LCHtoRGB
-# RGBtoHLS
-# HLStoRGB
-#
-#-----------------------------------------------------------------------------------
-# Authors: Jean-Luc Vinot <vinot@cena.fr>
-#
-# $Id$
-#-----------------------------------------------------------------------------------
-package Tk::Zinc::Graphics;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-require Exporter;
-@ISA = qw(Exporter);
-@EXPORT = qw(&buildZincItem &repeatZincItem &buidTabBoxItem
-
- &roundedRectangleCoords &hippodromeCoords &polygonCoords &ellipseCoords
- &roundedCurveCoords &polylineCoords &tabBoxCoords &pathLineCoords &shiftPathCoords
-
- &perpendicularPoint &lineAngle &vertexAngle &rad_point &arc_pts &lineNormal
- &curve2polylineCoords &curveItem2polylineCoords &bezierSegment &bezierCompute
-
- &graphicItemRelief &graphicItemShadow
-
- &setGradients &getPattern &getTexture &getImage &init_pixmaps
-
- &hexaRGBcolor &createGraduate &lightingColor &zincItemPredominantColor
- &MedianColor &RGBtoLCH &LCHtoRGB &RGBtoHLS &HLStoRGB
- );
-
-use strict;
-use Carp;
-use Tk;
-use Tk::PNG;
-use Tk::JPEG;
-use Math::Trig;
-
-# constante facteur point directeur (conique -> quadratique)
-my $const_ptd_factor = .5523;
-
-# constante white point (conversion couleur espace CIE XYZ)
-my ($Xw, $Yw, $Zw) = (95.047, 100.0, 108.883);
-
-# limite globale d'approximation courbe bezier
-my $bezierClosenessThreshold = .2;
-
-# initialisation et partage de ressources couleurs et images
-my @Gradients;
-my %textures;
-my %images;
-my %bitmaps;
-
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::buildZincItem
-# Création d'un objet Zinc de représentation
-#-----------------------------------------------------------------------------------
-# types d'items valides :
-# les items natifs zinc : group, rectangle, arc, curve, text, icon
-# les items ci-après permettent de spécifier des curves 'particulières' :
-# -roundedrectangle : rectangle à coin arrondi
-# -hippodrome : hippodrome
-# -ellipse : ellipse un centre 2 rayons
-# -polygone : polygone régulier à n cotés (convexe ou en étoile)
-# -roundedcurve : curve multicontours à coins arrondis (rayon unique)
-# -polyline : curve multicontours à coins arrondis (le rayon pouvant être défini
-# spécifiquement pour chaque sommet)
-# -pathline : création d'une ligne 'épaisse' avec l'item Zinc triangles
-# décalage par rapport à un chemin donné (largeur et sens de décalage)
-# dégradé de couleurs de la ligne (linéaire, transversal ou double)
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget Zinc
-# parentgroup : <tagOrId> identifiant du group parent
-#
-# options :
-# -itemtype : type de l'item à construire (type zinc ou metatype)
-# -coords : <coords|coordsList> coordonnées de l'item
-# -metacoords : <hastable> calcul de coordonnées par type d'item différent de -itemtype
-# -contours : <contourList> paramètres multi-contours
-# -params : <hastable> arguments spécifiques de l'item à passer au widget
-# -addtags : [list of specific tags] to add to params -tags
-# -texture : <imagefile> ajout d'une texture à l'item
-# -pattern : <imagefile> ajout d'un pattern à l'item
-# -relief : <hastable> création d'un relief à l'item invoque la fonction &graphicItemRelief()
-# -shadow : <hastable> création d'une ombre portée à l'item invoque la fonction &graphicItemShadow()
-# -scale : <scale_factor|[xscale_factor,yscale_factor]> application d'une transformation zinc->scale à l'item
-# -translate : <[dx,dy]> application d'un transformation zinc->translate à l'item.
-# -rotate : <angle> application d'une transformation zinc->rotate (en degré) à l'item
-# -name : <str> nom de l'item
-# spécifiques item group :
-# -clip : <coordList|hashtable> paramètres de clipping d'un item group (coords ou item)
-# -items : <hashtable> appel récursif de la fonction permettant d'inclure des items au groupe
-#-----------------------------------------------------------------------------------
-#
-#-----------------------------------------------------------------------------------
-sub buildZincItem {
- my ($widget, $parentgroup, %options) = @_;
- $parentgroup = 1 if !$parentgroup;
-
- my $itemtype = $options{'-itemtype'};
- my $coords = $options{'-coords'};
- my $params = $options{'-params'};
-
- return unless ($widget and $itemtype and ($coords or $options{'-metacoords'}));
-
- my $name = ($options{'-name'}) ? $options{'-name'} : 'none';
-
- my $item;
- my $metatype;
- my (@items, @reliefs, @shadows);
- my @tags;
-
-
- #--------------------
- # GEOMETRIE DES ITEMS
-
- # gestion des types d'items particuliers et à raccords circulaires
- if ($itemtype eq 'roundedrectangle'
- or $itemtype eq 'hippodrome'
- or $itemtype eq 'polygone'
- or $itemtype eq 'ellipse'
- or $itemtype eq 'roundedcurve'
- or $itemtype eq 'polyline'
- or $itemtype eq 'curveline') {
-
- # par défaut la curve sera fermée -closed = 1
- $params->{'-closed'} = 1 if (!defined $params->{'-closed'});
- $metatype = $itemtype;
- $itemtype = 'curve';
-
- # possibilité de définir les coordonnées initiales par metatype
- if ($options{'-metacoords'}) {
- $options{'-coords'} = &metaCoords(%{$options{'-metacoords'}});
-
- }
-
- # création d'une pathline à partir d'item zinc triangles
- } elsif ($itemtype eq 'pathline') {
-
- $itemtype = 'triangles';
- if ($options{'-metacoords'}) {
- $coords = &metaCoords(%{$options{'-metacoords'}});
-
- }
-
- if ($options{'-graduate'}) {
- my $numcolors = scalar(@{$coords});
- $params->{'-colors'} = &pathGraduate($widget, $numcolors, $options{'-graduate'});
- }
-
- $coords = &pathLineCoords($coords, %options);
-
-
- # création d'une boite à onglet
- } elsif ($itemtype eq 'tabbox') {
- return &buildTabBoxItem($widget, $parentgroup, %options);
-
- }
-
- # calcul des coordonnées finales de la curve
- $coords = &metaCoords(-type => $metatype, %options) if ($metatype);
-
-
- # gestion du multi-contours (accessible pour tous les types d'items géometriques)
- if ($options{'-contours'} and $metatype) {
- my @contours = @{$options{'-contours'}};
- my $numcontours = scalar(@contours);
- for (my $i = 0; $i < $numcontours; $i++) {
- # radius et corners peuvent être défini spécifiquement pour chaque contour
- my ($type, $way, $addcoords, $radius, $corners, $corners_radius) = @{$contours[$i]};
- $radius = $options{'-radius'} if (!defined $radius);
-
- my $newcoords = &metaCoords(-type => $metatype,
- -coords => $addcoords,
- -radius => $radius,
- -corners => $corners,
- -corners_radius => $corners_radius
- );
-
- $options{'-contours'}->[$i] = [$type, $way, $newcoords];
- }
- }
-
-
- #----------------------
- # REALISATION DES ITEMS
-
- # ITEM GROUP
- # gestion des coordonnées et du clipping
- if ($itemtype eq 'group') {
- $item = $widget->add($itemtype,
- $parentgroup,
- %{$params});
-
- $widget->coords($item, $coords) if $coords;
-
- # clipping du groupe par item ou par géometrie
- if ($options{'-clip'}) {
- my $clipbuilder = $options{'-clip'};
- my $clip;
-
- # création d'un item de clipping
- if ($clipbuilder->{'-itemtype'}) {
- $clip = &buildZincItem($widget, $item, %{$clipbuilder});
-
- } elsif (ref($clipbuilder) eq 'ARRAY' or $widget->type($clipbuilder)) {
- $clip = $clipbuilder;
- }
-
- $widget->itemconfigure($item, -clip => $clip) if ($clip);
- }
-
- # créations si besoin des items contenus dans le groupe
- if ($options{'-items'} and ref($options{'-items'}) eq 'HASH') {
- while (my ($itemname, $itemstyle) = each(%{$options{'-items'}})) {
- $itemstyle->{'-name'} = $itemname if (!$itemstyle->{'-name'});
- &buildZincItem($widget, $item, %{$itemstyle});
- }
- }
-
-
- # ITEM TEXT ou ICON
- } elsif ($itemtype eq 'text' or $itemtype eq 'icon') {
- my $imagefile;
- if ($itemtype eq 'icon') {
- $imagefile = $params->{'-image'};
- my $image = &getImage($widget, $imagefile);
- $params->{'-image'} = ($image) ? $image : "";
- }
-
- $item = $widget->add($itemtype,
- $parentgroup,
- -position => $coords,
- %{$params},
- );
-
- $params->{'-image'} = $imagefile if $imagefile;
-
-
- # ITEMS GEOMETRIQUES -> CURVE
- } else {
-
- $item = $widget->add($itemtype,
- $parentgroup,
- $coords,
- %{$params},
- );
-
- if ($itemtype eq 'curve' and $options{'-contours'}) {
- foreach my $contour (@{$options{'-contours'}}) {
- $widget->contour($item, @{$contour});
- }
- }
-
- # gestion du mode norender
- if ($options{'-texture'}) {
- my $texture = &getTexture($widget, $options{'-texture'});
- $widget->itemconfigure($item, -tile => $texture) if $texture;
- }
-
- if ($options{'-pattern'}) {
- my $bitmap = &getBitmap($options{'-pattern'});
- $widget->itemconfigure($item, -fillpattern => $bitmap) if $bitmap;
- }
-
- }
-
-
- # gestion des tags spécifiques
- if ($options{'-addtags'}) {
- my @tags = @{$options{'-addtags'}};
-
- my $params_tags = $params->{'-tags'};
- push (@tags, @{$params_tags}) if $params_tags;
-
- $widget->itemconfigure($item, -tags => \@tags);
-
- }
-
-
- #-------------------------------
- # TRANSFORMATIONS ZINC DE L'ITEM
-
- # transformation scale de l'item si nécessaire
- if ($options{'-scale'}) {
- my $scale = $options{'-scale'};
- $scale = [$scale, $scale] if (ref($scale) ne 'ARRAY');
- $widget->scale($item, @{$scale}) ;
- }
-
- # transformation rotate de l'item si nécessaire
- $widget->rotate($item, deg2rad($options{'-rotate'})) if ($options{'-rotate'});
-
- # transformation translate de l'item si nécessaire
- $widget->translate($item, @{$options{'-translate'}}) if ($options{'-translate'});
-
-
- # répétition de l'item
- if ($options{'-repeat'}) {
- push (@items, $item,
- &repeatZincItem($widget, $item, %{$options{'-repeat'}}));
- }
-
-
- #-----------------------
- # RELIEF ET OMBRE PORTEE
-
- # gestion du relief
- if ($options{'-relief'}) {
- my $target = (@items) ? \@items : $item;
- push (@reliefs, &graphicItemRelief($widget, $target, %{$options{'-relief'}}));
- }
-
- # gestion de l'ombre portée
- if ($options{'-shadow'}) {
- my $target = (@items) ? \@items : $item;
- push (@shadows, &graphicItemShadow($widget, $target, %{$options{'-shadow'}}));
- }
-
- push(@items, @reliefs) if @reliefs;
- push(@items, @shadows) if @shadows;
-
- return (@items) ? @items : $item;
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::repeatZincItem
-# Duplication (clonage) d'un objet Zinc de représentation
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# item : <tagOrId> identifiant de l'item source
-# options :
-# -num : <n> nombre d'item total (par defaut 2)
-# -dxy : <[dx, dy]> translation entre 2 duplications (par defaut [0,0])
-# -angle : <angle> rotation entre 2 duplications
-# -copytag : <sting> ajout d'un tag indexé pour chaque copie
-# -params : <hashtable> {clef => [value list]}> valeur de paramètre de chaque copie
-#-----------------------------------------------------------------------------------
-sub repeatZincItem {
- my ($widget, $item, %options) = @_;
- my @clones;
-
- # duplication d'une liste d'items -> appel récursif
- if (ref($item) eq 'ARRAY') {
- foreach my $part (@{$item}) {
- push (@clones, &repeatZincItem($widget, $part, %options));
- }
-
- return wantarray ? @clones : \@clones;
- }
-
- my $num = ($options{'-num'}) ? $options{'-num'} : 2;
- my ($dx, $dy) = (defined $options{'-dxy'}) ? @{$options{'-dxy'}} : (0, 0);
- my $angle = $options{'-angle'};
- my $params = $options{'-params'};
- my $copytag = $options{'-copytag'};
- my @tags;
-
- if ($copytag) {
- @tags = $widget->itemcget($item, -tags);
- unshift (@tags, $copytag."0");
- $widget->itemconfigure($item, -tags => \@tags);
- }
-
- for (my $i = 1; $i < $num; $i++) {
- my $clone;
-
- if ($copytag) {
- $tags[0] = $copytag.$i;
- $clone = $widget->clone($item, -tags => \@tags);
-
- } else {
- $clone = $widget->clone($item);
- }
-
- push(@clones, $clone);
- $widget->translate($clone, $dx*$i, $dy*$i);
- $widget->rotate($clone, deg2rad($angle*$i)) if $angle;
-
- if ($params) {
- while (my ($attrib, $value) = each(%{$params})) {
- $widget->itemconfigure($clone, $attrib => $value->[$i]);
- }
- }
- }
-
- return wantarray ? @clones : \@clones;
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# FONCTIONS GEOMETRIQUES
-#-----------------------------------------------------------------------------------
-
-#-----------------------------------------------------------------------------------
-# Graphics::metaCoords
-# retourne une liste de coordonnées en utilisant la fonction du type d'item spécifié
-#-----------------------------------------------------------------------------------
-# paramètres : (passés par %options)
-# -type : <string> type de primitive utilisée
-# -coords : <coordsList> coordonnées nécessitée par la fonction [type]Coords
-#
-# les autres options spécialisées au type seront passés à la fonction [type]coords
-#-----------------------------------------------------------------------------------
-sub metaCoords {
- my (%options) = @_;
- my $pts;
-
- my $type = delete $options{'-type'};
- my $coords = delete $options{'-coords'};
-
- if ($type eq 'roundedrectangle') {
- $pts = &roundedRectangleCoords($coords, %options);
-
- } elsif ($type eq 'hippodrome') {
- $pts = &hippodromeCoords($coords, %options);
-
- } elsif ($type eq 'ellipse') {
- $pts = &ellipseCoords($coords, %options);
-
- } elsif ($type eq 'roundedcurve') {
- $pts = &roundedCurveCoords($coords, %options);
-
- } elsif ($type eq 'polygone') {
- $pts = &polygonCoords($coords, %options);
-
- } elsif ($type eq 'polyline') {
- $pts = &polylineCoords($coords, %options);
-
- } elsif ($type eq 'curveline') {
- $pts = &curveLineCoords($coords, %options);
- }
-
- return $pts;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::ZincItem2CurveCoords
-# retourne une liste des coordonnées 'Curve' d'un l'item Zinc
-# rectangle, arc ou curve
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# item : <tagOrId> identifiant de l'item source
-# options :
-# -linear : <boolean> réduction à des segments non curviligne (par défaut 0)
-# -realcoords : <boolean> coordonnées à transformer dans le groupe père (par défaut 0)
-# -adjust : <boolean> ajustement de la courbe de bezier (par défaut 1)
-#-----------------------------------------------------------------------------------
-sub ZincItem2CurveCoords {
- my ($widget, $item, %options) = @_;
-
- my $itemtype = $widget->type($item);
- return unless ($itemtype);
-
- my $linear = $options{-linear};
- my $realcoords = $options{-realcoords};
- my $adjust = (defined $options{-adjust}) ? $options{-adjust} : 1;
-
- my @itemcoords = $widget->coords($item);
-
- my $coords;
- my @multi;
-
- if ($itemtype eq 'rectangle') {
- $coords = &roundedRectangleCoords(\@itemcoords, -radius => 0);
-
- } elsif ($itemtype eq 'arc') {
- $coords = &ellipseCoords(\@itemcoords);
- $coords = &curve2polylineCoords($coords, $adjust) if $linear;
-
- } elsif ($itemtype eq 'curve') {
- my $numcontours = $widget->contour($item);
-
- if ($numcontours < 2) {
- $coords = \@itemcoords;
- $coords = &curve2polylineCoords($coords, $adjust) if $linear;
-
-
- } else {
- if ($linear) {
- @multi = &curveItem2polylineCoords($widget, $item);
-
- } else {
- for (my $contour = 0; $contour < $numcontours; $contour++) {
- my @points = $widget->coords($item, $contour);
- push (@multi, \@points);
- }
- }
-
- $coords = \@multi;
- }
- }
-
- if ($realcoords) {
- my $parentgroup = $widget->group($item);
- if (@multi) {
- my @newcoords;
- foreach my $points (@multi) {
- my @transcoords = $widget->transform($item, $parentgroup, $points);
- push(@newcoords, \@transcoords);
- }
-
- $coords = \@newcoords;
-
- } else {
- my @transcoords = $widget->transform($item, $parentgroup, $coords);
- $coords = \@transcoords;
- }
-
- }
-
- if (@multi) {
- return (wantarray) ? @{$coords} : $coords;
- } else {
- return (wantarray) ? ($coords) : $coords;
- }
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::roundedRectangleCoords
-# calcul des coords du rectangle à coins arrondis
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordsList> coordonnées bbox (haut-gauche et bas-droite) du rectangle
-# options :
-# -radius : <dimension> rayon de raccord d'angle
-# -corners : <booleanList> liste des raccords de sommets [0 (aucun raccord)|1] par défaut [1,1,1,1]
-#-----------------------------------------------------------------------------------
-sub roundedRectangleCoords {
- my ($coords, %options) = @_;
- my ($x0, $y0, $xn, $yn) = ($coords->[0]->[0], $coords->[0]->[1],
- $coords->[1]->[0], $coords->[1]->[1]);
-
- my $radius = $options{'-radius'};
- my $corners = $options{'-corners'} ? $options{'-corners'} : [1, 1, 1, 1];
-
- # attention aux formes 'négatives'
- if ($xn < $x0) {
- my $xs = $x0;
- ($x0, $xn) = ($xn, $xs);
- }
- if ($yn < $y0) {
- my $ys = $y0;
- ($y0, $yn) = ($yn, $ys);
- }
-
- my $height = &_min($xn -$x0, $yn - $y0);
-
- if (!defined $radius) {
- $radius = int($height/10);
- $radius = 3 if $radius < 3;
- }
-
- if (!$radius or $radius < 2) {
- return [[$x0, $y0],[$x0, $yn],[$xn, $yn],[$xn, $y0]];
-
- }
-
-
- # correction de radius si necessaire
- my $max_rad = $height;
- $max_rad /= 2 if (!defined $corners);
- $radius = $max_rad if $radius > $max_rad;
-
- # points remarquables
- my $ptd_delta = $radius * $const_ptd_factor;
- my ($x2, $x3) = ($x0 + $radius, $xn - $radius);
- my ($x1, $x4) = ($x2 - $ptd_delta, $x3 + $ptd_delta);
- my ($y2, $y3) = ($y0 + $radius, $yn - $radius);
- my ($y1, $y4) = ($y2 - $ptd_delta, $y3 + $ptd_delta);
-
- # liste des 4 points sommet du rectangle : angles sans raccord circulaire
- my @angle_pts = ([$x0, $y0],[$x0, $yn],[$xn, $yn],[$xn, $y0]);
-
- # liste des 4 segments quadratique : raccord d'angle = radius
- my @roundeds = ([[$x2, $y0],[$x1, $y0, 'c'],[$x0, $y1, 'c'],[$x0, $y2],],
- [[$x0, $y3],[$x0, $y4, 'c'],[$x1, $yn, 'c'],[$x2, $yn],],
- [[$x3, $yn],[$x4, $yn, 'c'],[$xn, $y4, 'c'],[$xn, $y3],],
- [[$xn, $y2],[$xn, $y1, 'c'],[$x4, $y0, 'c'],[$x3, $y0],]);
-
- my @pts = ();
- my $previous;
- for (my $i = 0; $i < 4; $i++) {
- if ($corners->[$i]) {
- if ($previous) {
- # on teste si non duplication de point
- my ($nx, $ny) = @{$roundeds[$i]->[0]};
- if ($previous->[0] == $nx and $previous->[1] == $ny) {
- pop(@pts);
- }
- }
- push(@pts, @{$roundeds[$i]});
- $previous = $roundeds[$i]->[3];
-
- } else {
- push(@pts, $angle_pts[$i]);
- }
- }
-
- return \@pts;
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::ellipseCoords
-# calcul des coords d'une ellipse
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordsList> coordonnées bbox du rectangle exinscrit
-# options :
-# -corners : <booleanList> liste des raccords de sommets [0 (aucun raccord)|1] par défaut [1,1,1,1]
-#-----------------------------------------------------------------------------------
-sub ellipseCoords {
- my ($coords, %options) = @_;
- my ($x0, $y0, $xn, $yn) = ($coords->[0]->[0], $coords->[0]->[1],
- $coords->[1]->[0], $coords->[1]->[1]);
-
- my $corners = $options{'-corners'} ? $options{'-corners'} : [1, 1, 1, 1];
-
- # attention aux formes 'négatives'
- if ($xn < $x0) {
- my $xs = $x0;
- ($x0, $xn) = ($xn, $xs);
- }
- if ($yn < $y0) {
- my $ys = $y0;
- ($y0, $yn) = ($yn, $ys);
- }
-
- # points remarquables
- my $dx = ($xn - $x0)/2 * $const_ptd_factor;
- my $dy = ($yn - $y0)/2 * $const_ptd_factor;
- my ($x2, $y2) = (($x0+$xn)/2, ($y0+$yn)/2);
- my ($x1, $x3) = ($x2 - $dx, $x2 + $dx);
- my ($y1, $y3) = ($y2 - $dy, $y2 + $dy);
-
- # liste des 4 points sommet de l'ellipse : angles sans raccord circulaire
- my @angle_pts = ([$x0, $y0],[$x0, $yn],[$xn, $yn],[$xn, $y0]);
-
- # liste des 4 segments quadratique : raccord d'angle = arc d'ellipse
- my @roundeds = ([[$x2, $y0],[$x1, $y0, 'c'],[$x0, $y1, 'c'],[$x0, $y2],],
- [[$x0, $y2],[$x0, $y3, 'c'],[$x1, $yn, 'c'],[$x2, $yn],],
- [[$x2, $yn],[$x3, $yn, 'c'],[$xn, $y3, 'c'],[$xn, $y2],],
- [[$xn, $y2],[$xn, $y1, 'c'],[$x3, $y0, 'c'],[$x2, $y0],]);
-
- my @pts = ();
- my $previous;
- for (my $i = 0; $i < 4; $i++) {
- if ($corners->[$i]) {
- if ($previous) {
- # on teste si non duplication de point
- my ($nx, $ny) = @{$roundeds[$i]->[0]};
- if ($previous->[0] == $nx and $previous->[1] == $ny) {
- pop(@pts);
- }
- }
- push(@pts, @{$roundeds[$i]});
- $previous = $roundeds[$i]->[3];
-
- } else {
- push(@pts, $angle_pts[$i]);
- }
- }
-
- return \@pts;
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::hippodromeCoords
-# calcul des coords d'un hippodrome
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordsList> coordonnées bbox du rectangle exinscrit
-# options :
-# -orientation : orientation forcée de l'hippodrome [horizontal|vertical]
-# -corners : liste des raccords de sommets [0|1] par défaut [1,1,1,1]
-# -trunc : troncatures [left|right|top|bottom|both]
-#-----------------------------------------------------------------------------------
-sub hippodromeCoords {
- my ($coords, %options) = @_;
- my ($x0, $y0, $xn, $yn) = ($coords->[0]->[0], $coords->[0]->[1],
- $coords->[1]->[0], $coords->[1]->[1]);
-
- my $orientation = ($options{'-orientation'}) ? $options{'-orientation'} : 'none';
-
- # orientation forcée de l'hippodrome (sinon hippodrome sur le plus petit coté)
- my $height = ($orientation eq 'horizontal') ? abs($yn - $y0)
- : ($orientation eq 'vertical') ? abs($xn - $x0) : &_min(abs($xn - $x0), abs($yn - $y0));
- my $radius = $height/2;
- my $corners = [1, 1, 1, 1];
-
- if ($options{'-corners'}) {
- $corners = $options{'-corners'};
-
- } elsif ($options{'-trunc'}) {
- my $trunc = $options{'-trunc'};
- if ($trunc eq 'both') {
- return [[$x0, $y0],[$x0, $yn],[$xn, $yn],[$xn, $y0]];
-
- } else {
- $corners = ($trunc eq 'left') ? [0, 0, 1, 1] :
- ($trunc eq 'right') ? [1, 1, 0, 0] :
- ($trunc eq 'top') ? [0, 1, 1, 0] :
- ($trunc eq 'bottom') ? [1, 0, 0, 1] : [1, 1, 1, 1];
-
- }
- }
-
- # l'hippodrome est un cas particulier de roundedRectangle
- # on retourne en passant la 'configuration' à la fonction générique roundedRectangleCoords
- return &roundedRectangleCoords($coords, -radius => $radius, -corners => $corners);
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::polygonCoords
-# calcul des coords d'un polygone régulier
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coords> point centre du polygone
-# options :
-# -numsides : <integer> nombre de cotés
-# -radius : <dimension> rayon de définition du polygone (distance centre-sommets)
-# -inner_radius : <dimension> rayon interne (polygone type étoile)
-# -corners : <booleanList> liste des raccords de sommets [0|1] par défaut [1,1,1,1]
-# -corner_radius : <dimension> rayon de raccord des cotés
-# -startangle : <angle> angle de départ en degré du polygone
-#-----------------------------------------------------------------------------------
-sub polygonCoords {
- my ($coords, %options) = @_;
-
- my $numsides = $options{'-numsides'};
- my $radius = $options{'-radius'};
- if ($numsides < 3 or !$radius) {
- print "Vous devez au moins spécifier un nombre de cotés >= 3 et un rayon...\n";
- return undef;
- }
-
- $coords = [0, 0] if (!defined $coords);
- my $startangle = ($options{'-startangle'}) ? $options{'-startangle'} : 0;
- my $anglestep = 360/$numsides;
- my $inner_radius = $options{'-inner_radius'};
- my @pts;
-
- # points du polygone
- for (my $i = 0; $i < $numsides; $i++) {
- my ($xp, $yp) = &rad_point($coords, $radius, $startangle + ($anglestep*$i));
- push(@pts, ([$xp, $yp]));
-
- # polygones 'étoiles'
- if ($inner_radius) {
- ($xp, $yp) = &rad_point($coords, $inner_radius, $startangle + ($anglestep*($i+ 0.5)));
- push(@pts, ([$xp, $yp]));
- }
- }
-
-
- @pts = reverse @pts;
-
- if ($options{'-corner_radius'}) {
- return &roundedCurveCoords(\@pts, -radius => $options{'-corner_radius'}, -corners => $options{'-corners'});
- } else {
- return \@pts;
- }
-}
-
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::roundedAngle
-# THIS FUNCTION IS NO MORE USED, NEITHER EXPORTED
-# curve d'angle avec raccord circulaire
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : identifiant du widget Zinc
-# parentgroup : <tagOrId> identifiant de l'item group parent
-# coords : <coordsList> les 3 points de l'angle
-# radius : <dimension> rayon de raccord
-#-----------------------------------------------------------------------------------
-sub roundedAngle {
- my ($widget, $parentgroup, $coords, $radius) = @_;
- my ($pt0, $pt1, $pt2) = @{$coords};
-
- my ($corner_pts, $center_pts) = &roundedAngleCoords($coords, $radius);
- my ($cx0, $cy0) = @{$center_pts};
-
- # valeur d'angle et angle formé par la bisectrice
- my ($angle) = &vertexAngle($pt0, $pt1, $pt2);
-
- $parentgroup = 1 if (!defined $parentgroup);
-
- $widget->add('curve', $parentgroup,
- [$pt0,@{$corner_pts},$pt2],
- -closed => 0,
- -linewidth => 1,
- -priority => 20,
- );
-
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::roundedAngleCoords
-# calcul des coords d'un raccord d'angle circulaire
-#-----------------------------------------------------------------------------------
-# le raccord circulaire de 2 droites sécantes est traditionnellement réalisé par un
-# arc (conique) du cercle inscrit de rayon radius tangent à ces 2 droites
-#
-# Quadratique :
-# une approche de cette courbe peut être réalisée simplement par le calcul de 4 points
-# spécifiques qui définiront - quelle que soit la valeur de l'angle formé par les 2
-# droites - le segment de raccord :
-# - les 2 points de tangence au cercle inscrit seront les points de début et de fin
-# du segment de raccord
-# - les 2 points de controle seront situés chacun sur le vecteur reliant le point de
-# tangence au sommet de l'angle (point secant des 2 droites)
-# leur position sur ce vecteur peut être simplifiée comme suit :
-# - à un facteur de 0.5523 de la distance au sommet pour un angle >= 90° et <= 270°
-# - à une 'réduction' de ce point vers le point de tangence pour les angles limites
-# de 90° vers 0° et de 270° vers 360°
-# ce facteur sera légérement modulé pour recouvrir plus précisement l'arc correspondant
-#-----------------------------------------------------------------------------------
-# coords : <coordsList> les 3 points de l'angle
-# radius : <dimension> rayon de raccord
-#-----------------------------------------------------------------------------------
-sub roundedAngleCoords {
- my ($coords, $radius) = @_;
- my ($pt0, $pt1, $pt2) = @{$coords};
-
- # valeur d'angle et angle formé par la bisectrice
- my ($angle, $bisecangle) = &vertexAngle($pt0, $pt1, $pt2);
-
- # distance au centre du cercle inscrit : rayon/sinus demi-angle
- my $sin = sin(deg2rad($angle/2));
- my $delta = ($sin) ? abs($radius / $sin) : $radius;
-
- # point centre du cercle inscrit de rayon $radius
- my $refangle = ($angle < 180) ? $bisecangle+90 : $bisecangle-90;
- my ($cx0, $cy0) = rad_point($pt1, $delta, $refangle);
-
- # points de tangeance : pts perpendiculaires du centre aux 2 droites
- my ($px1, $py1) = &perpendicularPoint([$cx0, $cy0], [$pt0, $pt1]);
- my ($px2, $py2) = &perpendicularPoint([$cx0, $cy0], [$pt1, $pt2]);
-
- # point de controle de la quadratique
- # facteur de positionnement sur le vecteur pt.tangence, sommet
- my $ptd_factor = $const_ptd_factor;
- if ($angle < 90 or $angle > 270) {
- my $diffangle = ($angle < 90) ? $angle : 360 - $angle;
- $ptd_factor -= (((90 - $diffangle)/90) * ($ptd_factor/4)) if $diffangle > 15 ;
- $ptd_factor = ($diffangle/90) * ($ptd_factor + ((1 - $ptd_factor) * (90 - $diffangle)/90));
- } else {
- my $diffangle = abs(180 - $angle);
- $ptd_factor += (((90 - $diffangle)/90) * ($ptd_factor/3)) if $diffangle > 15;
- }
-
- # delta xy aux pts de tangence
- my ($d1x, $d1y) = (($pt1->[0] - $px1) * $ptd_factor, ($pt1->[1] - $py1) * $ptd_factor);
- my ($d2x, $d2y) = (($pt1->[0] - $px2) * $ptd_factor, ($pt1->[1] - $py2) * $ptd_factor);
-
- # les 4 points de l'arc 'quadratique'
- my $corner_pts = [[$px1, $py1],[$px1+$d1x, $py1+$d1y, 'c'],
- [$px2+$d2x, $py2+$d2y, 'c'],[$px2, $py2]];
-
-
- # retourne le segment de quadratique et le centre du cercle inscrit
- return ($corner_pts, [$cx0, $cy0]);
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::roundedCurveCoords
-# retourne les coordonnées d'une curve à coins arrondis
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordsList> liste de coordonnées des points de la curve
-# options :
-# -radius : <dimension> rayon de raccord d'angle
-# -corners : <booleanList> liste des raccords de sommets [0|1] par défaut [1,1,1,1]
-#-----------------------------------------------------------------------------------
-sub roundedCurveCoords {
- my ($coords, %options) = @_;
- my $numfaces = scalar(@{$coords});
- my @curve_pts;
-
- my $radius = (defined $options{'-radius'}) ? $options{'-radius'} : 0;
- my $corners = $options{'-corners'};
-
- for (my $index = 0; $index < $numfaces; $index++) {
- if ($corners and !$corners->[$index]) {
- push(@curve_pts, $coords->[$index]);
-
- } else {
- my $prev = ($index) ? $index - 1 : $numfaces - 1;
- my $next = ($index > $numfaces - 2) ? 0 : $index + 1;
- my $anglecoords = [$coords->[$prev], $coords->[$index], $coords->[$next]];
-
- my ($quad_pts) = &roundedAngleCoords($anglecoords, $radius);
- push(@curve_pts, @{$quad_pts});
- }
- }
-
- return \@curve_pts;
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::polylineCoords
-# retourne les coordonnées d'une polyline
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordsList> liste de coordonnées des sommets de la polyline
-# options :
-# -radius : <dimension> rayon global de raccord d'angle
-# -corners : <booleanList> liste des raccords de sommets [0|1] par défaut [1,1,1,1],
-# -corners_radius : <dimensionList> liste des rayons de raccords de sommets
-#-----------------------------------------------------------------------------------
-sub polylineCoords {
- my ($coords, %options) = @_;
- my $numfaces = scalar(@{$coords});
- my @curve_pts;
-
- my $radius = ($options{'-radius'}) ? $options{'-radius'} : 0;
- my $corners_radius = $options{'-corners_radius'};
- my $corners = ($corners_radius) ? $corners_radius : $options{'-corners'};
-
- for (my $index = 0; $index < $numfaces; $index++) {
- if ($corners and !$corners->[$index]) {
- push(@curve_pts, $coords->[$index]);
-
- } else {
- my $prev = ($index) ? $index - 1 : $numfaces - 1;
- my $next = ($index > $numfaces - 2) ? 0 : $index + 1;
- my $anglecoords = [$coords->[$prev], $coords->[$index], $coords->[$next]];
-
- my $rad = ($corners_radius) ? $corners_radius->[$index] : $radius;
- my ($quad_pts) = &roundedAngleCoords($anglecoords, $rad);
- push(@curve_pts, @{$quad_pts});
- }
- }
-
- return \@curve_pts;
-
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::pathLineCoords
-# retourne les coordonnées d'une pathLine
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordsList> liste de coordonnées des points du path
-# options :
-# -closed : <boolean> ligne fermée
-# -shifting : <out|center|in> sens de décalage du path (par défaut center)
-# -linewidth : <dimension> epaisseur de la ligne
-#-----------------------------------------------------------------------------------
-sub pathLineCoords {
- my ($coords, %options) = @_;
- my $numfaces = scalar(@{$coords});
- my @pts;
-
- my $closed = $options{'-closed'};
- my $linewidth = ($options{'-linewidth'}) ? $options{'-linewidth'} : 2;
- my $shifting = ($options{'-shifting'}) ? $options{'-shifting'} : 'center';
-
- return undef if (!$numfaces or $linewidth < 2);
-
- my $previous = ($closed) ? $coords->[$numfaces - 1] : undef;
- my $next = $coords->[1];
- $linewidth /= 2 if ($shifting eq 'center');
-
- for (my $i = 0; $i < $numfaces; $i++) {
- my $pt = $coords->[$i];
-
- if (!$previous) {
- # extrémité de curve sans raccord -> angle plat
- $previous = [$pt->[0] + ($pt->[0] - $next->[0]), $pt->[1] + ($pt->[1] - $next->[1])];
- }
-
- my ($angle, $bisecangle) = &vertexAngle($previous, $pt, $next);
-
- # distance au centre du cercle inscrit : rayon/sinus demi-angle
- my $sin = sin(deg2rad($angle/2));
- my $delta = ($sin) ? abs($linewidth / $sin) : $linewidth;
-
- if ($shifting eq 'out' or $shifting eq 'in') {
- my $adding = ($shifting eq 'out') ? -90 : 90;
- push (@pts, &rad_point($pt, $delta, $bisecangle + $adding));
- push (@pts, @{$pt});
-
- } else {
- push (@pts, &rad_point($pt, $delta, $bisecangle-90));
- push (@pts, &rad_point($pt, $delta, $bisecangle+90));
-
- }
-
- if ($i == $numfaces - 2) {
- $next = ($closed) ? $coords->[0] :
- [$coords->[$i+1]->[0] + ($coords->[$i+1]->[0] - $pt->[0]), $coords->[$i+1]->[1] + ($coords->[$i+1]->[1] - $pt->[1])];
- } else {
- $next = $coords->[$i+2];
- }
-
- $previous = $coords->[$i];
- }
-
- if ($closed) {
- push (@pts, ($pts[0], $pts[1], $pts[2], $pts[3]));
- }
-
- return \@pts;
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::curveLineCoords
-# retourne les coordonnées d'une curveLine
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordsList> liste de coordonnées des points de la ligne
-# options :
-# -closed : <boolean> ligne fermée
-# -shifting : <out|center|in> sens de décalage du contour (par défaut center)
-# -linewidth : <dimension> epaisseur de la ligne
-#-----------------------------------------------------------------------------------
-sub curveLineCoords {
- my ($coords, %options) = @_;
- my $numfaces = scalar(@{$coords});
- my @gopts;
- my @backpts;
- my @pts;
-
- my $closed = $options{'-closed'};
- my $linewidth = (defined $options{'-linewidth'}) ? $options{'-linewidth'} : 2;
- my $shifting = ($options{'-shifting'}) ? $options{'-shifting'} : 'center';
-
- return undef if (!$numfaces or $linewidth < 2);
-
- my $previous = ($closed) ? $coords->[$numfaces - 1] : undef;
- my $next = $coords->[1];
- $linewidth /= 2 if ($shifting eq 'center');
-
- for (my $i = 0; $i < $numfaces; $i++) {
- my $pt = $coords->[$i];
-
- if (!$previous) {
- # extrémité de curve sans raccord -> angle plat
- $previous = [$pt->[0] + ($pt->[0] - $next->[0]), $pt->[1] + ($pt->[1] - $next->[1])];
- }
-
- my ($angle, $bisecangle) = &vertexAngle($previous, $pt, $next);
-
- # distance au centre du cercle inscrit : rayon/sinus demi-angle
- my $sin = sin(deg2rad($angle/2));
- my $delta = ($sin) ? abs($linewidth / $sin) : $linewidth;
-
- if ($shifting eq 'out' or $shifting eq 'in') {
- my $adding = ($shifting eq 'out') ? -90 : 90;
- push (@pts, &rad_point($pt, $delta, $bisecangle + $adding));
- push (@pts, @{$pt});
-
- } else {
- @pts = &rad_point($pt, $delta, $bisecangle+90);
- push (@gopts, \@pts);
- @pts = &rad_point($pt, $delta, $bisecangle-90);
- unshift (@backpts, \@pts);
- }
-
- if ($i == $numfaces - 2) {
- $next = ($closed) ? $coords->[0] :
- [$coords->[$i+1]->[0] + ($coords->[$i+1]->[0] - $pt->[0]), $coords->[$i+1]->[1] + ($coords->[$i+1]->[1] - $pt->[1])];
- } else {
- $next = $coords->[$i+2];
- }
-
- $previous = $coords->[$i];
- }
-
- push(@gopts, @backpts);
-
- if ($closed) {
- push (@gopts, ($gopts[0], $gopts[1]));
- }
-
- return \@gopts;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::shiftPathCoords
-# retourne les coordonnées d'un décalage de path
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordsList> liste de coordonnées des points du path
-# options :
-# -closed : <boolean> ligne fermée
-# -shifting : <'out'|'in'> sens de décalage du path (par défaut out)
-# -width : <dimension> largeur de décalage (par défaut 1)
-#-----------------------------------------------------------------------------------
-sub shiftPathCoords {
- my ($coords, %options) = @_;
- my $numfaces = scalar(@{$coords});
-
- my $closed = $options{'-closed'};
- my $width = (defined $options{'-width'}) ? $options{'-width'} : 1;
- my $shifting = ($options{'-shifting'}) ? $options{'-shifting'} : 'out';
-
- return $coords if (!$numfaces or !$width);
-
- my @pts;
-
- my $previous = ($closed) ? $coords->[$numfaces - 1] : undef;
- my $next = $coords->[1];
-
- for (my $i = 0; $i < $numfaces; $i++) {
- my $pt = $coords->[$i];
-
- if (!$previous) {
- # extrémité de curve sans raccord -> angle plat
- $previous = [$pt->[0] + ($pt->[0] - $next->[0]), $pt->[1] + ($pt->[1] - $next->[1])];
- }
-
- my ($angle, $bisecangle) = &vertexAngle($previous, $pt, $next);
-
- # distance au centre du cercle inscrit : rayon/sinus demi-angle
- my $sin = sin(deg2rad($angle/2));
- my $delta = ($sin) ? abs($width / $sin) : $width;
-
- my $adding = ($shifting eq 'out') ? -90 : 90;
- my ($x, $y) = &rad_point($pt, $delta, $bisecangle + $adding);
- push (@pts, [$x, $y]);
-
-
- if ($i > $numfaces - 3) {
- my $j = $numfaces - 1;
- $next = ($closed) ? $coords->[0] :
- [$pt->[0] + ($pt->[0] - $previous->[0]), $pt->[1] + ($pt->[1] - $previous->[1])];
-
- } else {
- $next = $coords->[$i+2];
- }
-
- $previous = $coords->[$i];
- }
-
- return \@pts;
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::perpendicularPoint
-# retourne les coordonnées du point perpendiculaire abaissé d'un point sur une ligne
-#-----------------------------------------------------------------------------------
-# paramètres :
-# point : <coords> coordonnées du point de référence
-# line : <coordsList> coordonnées des 2 points de la ligne de référence
-#-----------------------------------------------------------------------------------
-sub perpendicularPoint {
- my ($point, $line) = @_;
- my ($p1, $p2) = @{$line};
-
- # cas partiuculier de lignes ortho.
- my $min_dist = .01;
- if (abs($p2->[1] - $p1->[1]) < $min_dist) {
- # la ligne de référence est horizontale
- return ($point->[0], $p1->[1]);
-
- } elsif (abs($p2->[0] - $p1->[0]) < $min_dist) {
- # la ligne de référence est verticale
- return ($p1->[0], $point->[1]);
- }
-
- my $a1 = ($p2->[1] - $p1->[1]) / ($p2->[0] - $p1->[0]);
- my $b1 = $p1->[1] - ($a1 * $p1->[0]);
-
- my $a2 = -1.0 / $a1;
- my $b2 = $point->[1] - ($a2 * $point->[0]);
-
- my $x = ($b2 - $b1) / ($a1 - $a2);
- my $y = ($a1 * $x) + $b1;
-
- return ($x, $y);
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::lineAngle
-# retourne l'angle d'un point par rapport à un centre de référence
-#-----------------------------------------------------------------------------------
-# paramètres :
-# startpoint : <coords> coordonnées du point de départ du segment
-# endpoint : <coords> coordonnées du point d'extremité du segment
-#-----------------------------------------------------------------------------------
-sub lineAngle {
- my ($startpoint, $endpoint) = @_;
- my $angle = atan2($endpoint->[1] - $startpoint->[1], $endpoint->[0] - $startpoint->[0]);
-
- $angle += pi/2;
- $angle *= 180/pi;
- $angle += 360 if ($angle < 0);
-
- return $angle;
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::lineNormal
-# retourne la valeur d'angle perpendiculaire à une ligne
-#-----------------------------------------------------------------------------------
-# paramètres :
-# startpoint : <coords> coordonnées du point de départ du segment
-# endpoint : <coords> coordonnées du point d'extremité du segment
-#-----------------------------------------------------------------------------------
-sub lineNormal {
- my ($startpoint, $endpoint) = @_;
- my $angle = &lineAngle($startpoint, $endpoint) + 90;
-
- $angle -= 360 if ($angle > 360);
- return $angle;
-
-}
-
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::vertexAngle
-# retourne la valeur de l'angle formée par 3 points
-# ainsi que l'angle de la bisectrice
-#-----------------------------------------------------------------------------------
-# paramètres :
-# pt0 : <coords> coordonnées du premier point de définition de l'angle
-# pt1 : <coords> coordonnées du deuxième point de définition de l'angle
-# pt2 : <coords> coordonnées du troisième point de définition de l'angle
-#-----------------------------------------------------------------------------------
-sub vertexAngle {
- my ($pt0, $pt1, $pt2) = @_;
- my $angle1 = &lineAngle($pt0, $pt1);
- my $angle2 = &lineAngle($pt2, $pt1);
-
- $angle2 += 360 if $angle2 < $angle1;
- my $alpha = $angle2 - $angle1;
- my $bisectrice = $angle1 + ($alpha/2);
-
- return ($alpha, $bisectrice);
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::arc_pts
-# calcul des points constitutif d'un arc
-#-----------------------------------------------------------------------------------
-# paramètres :
-# center : <coordonnées> centre de l'arc,
-# radius : <dimension> rayon de l'arc,
-# options :
-# -angle : <angle> angle de départ en degré de l'arc (par défaut 0)
-# -extent : <angle> delta angulaire en degré de l'arc (par défaut 360),
-# -step : <dimension> pas de progresion en degré (par défaut 10)
-#-----------------------------------------------------------------------------------
-sub arc_pts {
- my ($center, $radius, %options) = @_;
- return unless ($radius);
-
- $center = [0, 0] if (!defined $center);
- my $angle = (defined $options{'-angle'}) ? $options{'-angle'} : 0;
- my $extent = (defined $options{'-extent'}) ? $options{'-extent'} : 360;
- my $step = (defined $options{'-step'}) ? $options{'-step'} : 10;
- my @pts = ();
-
- if ($extent > 0) {
- for (my $alpha = $angle; $alpha <= ($angle + $extent); $alpha += $step) {
- my ($xn, $yn) = &rad_point($center, $radius,$alpha);
- push (@pts, ([$xn, $yn]));
- }
- } else {
- for (my $alpha = $angle; $alpha >= ($angle + $extent); $alpha += $step) {
- push (@pts, &rad_point($center, $radius, $alpha));
- }
- }
-
- return @pts;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::rad_point
-# retourne le point circulaire défini par centre-rayon-angle
-#-----------------------------------------------------------------------------------
-# paramètres :
-# center : <coordonnée> coordonnée [x,y] du centre de l'arc,
-# radius : <dimension> rayon de l'arc,
-# angle : <angle> angle du point de circonférence avec le centre du cercle
-#-----------------------------------------------------------------------------------
-sub rad_point {
- my ($center, $radius, $angle) = @_;
- my $alpha = deg2rad($angle);
-
- my $xpt = $center->[0] + ($radius * cos($alpha));
- my $ypt = $center->[1] + ($radius * sin($alpha));
-
- return ($xpt, $ypt);
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::curveItem2polylineCoords
-# Conversion des coordonnées ZnItem curve (multicontours) en coordonnées polyline(s)
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# item : <tagOrId> identifiant de l'item source
-# options :
-# -tunits : <integer> nombre pas de division des segments bezier (par défaut 20)
-# -adjust : <boolean> ajustement de la courbe de bezier (par défaut 1)
-#-----------------------------------------------------------------------------------
-sub curveItem2polylineCoords {
- my ($widget, $item, %options) = @_;
- return unless ($widget and $widget->type($item));
-
- my @coords;
- my $numcontours = $widget->contour($item);
- my $parentgroup = $widget->group($item);
-
- for (my $contour = 0; $contour < $numcontours; $contour++) {
- my @points = $widget->coords($item, $contour);
- my @contourcoords = &curve2polylineCoords(\@points, %options);
-
- push(@coords, \@contourcoords);
-
- }
-
- return wantarray ? @coords : \@coords;
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::curve2polylineCoords
-# Conversion curve -> polygone
-#-----------------------------------------------------------------------------------
-# paramètres :
-# points : <coordsList> liste des coordonnées curve à transformer
-# options :
-# -tunits : <integer> nombre pas de division des segments bezier (par défaut 20)
-# -adjust : <boolean> ajustement de la courbe de bezier (par défaut 1)
-#-----------------------------------------------------------------------------------
-sub curve2polylineCoords {
- my ($points, %options) = @_;
-
- my $tunits = ($options{'-tunits'}) ? $options{'-tunits'} : 20;
- my $adjust = (defined $options{'-adjust'}) ? $options{'-adjust'} : 1;
-
- my @poly;
- my $previous;
- my @bseg;
- my $numseg = 0;
- my $prevtype;
-
- foreach my $point (@{$points}) {
- my ($x, $y, $c) = @{$point};
- if ($c eq 'c') {
- push(@bseg, $previous) if (!@bseg);
- push(@bseg, $point);
-
- } else {
- if (@bseg) {
- push(@bseg, $point);
-
- if ($adjust) {
- my @pts = &bezierCompute(\@bseg, -skipend => 1);
- shift @pts;
- shift @pts;
- push(@poly, @pts);
-
- } else {
- my @pts = &bezierSegment(\@bseg, -tunits => $tunits, -skipend => 1);
- shift @pts;
- shift @pts;
- push(@poly, @pts);
-
- }
-
- @bseg = ();
- $numseg++;
- $prevtype = 'bseg';
-
- } else {
- push(@poly, ([$x, $y]));
- $prevtype = 'line';
- }
- }
-
- $previous = $point;
- }
-
-
- return wantarray ? @poly : \@poly;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::buildTabBoxItem
-# construit les items de représentations Zinc d'une boite à onglets
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# parentgroup : <tagOrId> identifiant de l'item group parent
-#
-# options :
-# -coords : <coordsList> coordonnées haut-gauche et bas-droite du rectangle
-# englobant du TabBox
-# -params : <hastable> arguments spécifiques des items curve à passer au widget
-# -texture : <imagefile> ajout d'une texture aux items curve
-# -tabtitles : <hashtable> table de hash de définition des titres onglets
-# -pageitems : <hashtable> table de hash de définition des pages internes
-# -relief : <hashtable> table de hash de définition du relief de forme
-#
-# (options de construction géometrique passées à tabBoxCoords)
-# -numpages : <integer> nombre de pages (onglets) de la boite
-# -anchor : <'n'|'e'|'s'|'w'> ancrage (positionnement) de la ligne d'onglets
-# -alignment : <'left'|'center'|'right'> alignement des onglets sur le coté d'ancrage
-# -tabwidth : <'auto'>|<dimension>|<dimensionList> : largeur des onglets
-# 'auto' largeur répartie, les largeurs sont auto-ajustée si besoin.
-# -tabheight : <'auto'>|<dimension> : hauteur des onglets
-# -tabshift : <'auto'>|<dimension> offset de 'biseau' entre base et haut de l'onglet (défaut auto)
-# -radius : <dimension> rayon des arrondis d'angle
-# -overlap : <'auto'>|<dimension> offset de recouvrement/séparation entre onglets
-# -corners : <booleanList> liste 'spécifique' des raccords de sommets [0|1]
-#-----------------------------------------------------------------------------------
-sub buildTabBoxItem {
- my ($widget, $parentgroup, %options) = @_;
- my $coords = $options{'-coords'};
- my $params = $options{'-params'};
- my @tags = @{$params->{'-tags'}};
- my $texture;
-
- if ($options{'-texture'}) {
- $texture = &getTexture($widget, $options{'-texture'});
- }
-
- my $titlestyle = $options{'-tabtitles'};
- my $titles = ($titlestyle) ? $titlestyle->{'-text'} : undef ;
-
- return undef if (!$coords);
-
- my @tabs;
- my ($shapes, $tcoords, $invert) = &tabBoxCoords($coords, %options);
- my $k = ($invert) ? scalar @{$shapes} : -1;
- foreach my $shape (reverse @{$shapes}) {
- $k += ($invert) ? -1 : +1;
- my $group = $widget->add('group', $parentgroup);
- $params->{'-tags'} = [@tags, $k, 'intercalaire'];
- my $form = $widget->add('curve', $group, $shape, %{$params});
- $widget->itemconfigure($form, -tile => $texture) if $texture;
-
- if ($options{'-relief'}) {
- &graphicItemRelief($widget, $form, %{$options{'-relief'}});
- }
-
- if ($options{'-page'}) {
- my $page = &buildZincItem($widget, $group, %{$options{'-page'}});
- }
-
- if ($titles) {
- my $tindex = ($invert) ? $k : $#{$shapes} - $k;
- $titlestyle->{'-itemtype'} = 'text';
- $titlestyle->{'-coords'} = $tcoords->[$tindex];
- $titlestyle->{'-params'}->{'-text'} = $titles->[$tindex],;
- $titlestyle->{'-params'}->{'-tags'} = [@tags, $tindex, 'titre'];
- &buildZincItem($widget, $group, %{$titlestyle});
-
- }
-
-
- }
-
- return @tabs;
-}
-
-
-#-----------------------------------------------------------------------------------
-# tabBoxCoords
-# Calcul des shapes de boites à onglets
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordList> coordonnées haut-gauche bas-droite du rectangle englobant
-# de la tabbox
-# options
-# -numpages : <integer> nombre de pages (onglets) de la boite
-# -anchor : <'n'|'e'|'s'|'w'> ancrage (positionnement) de la ligne d'onglets
-# -alignment : <'left'|'center'|'right'> alignement des onglets sur le coté d'ancrage
-# -tabwidth : <'auto'>|<dimension>|<dimensionList> : largeur des onglets
-# 'auto' largeur répartie, les largeurs sont auto-ajustée si besoin.
-# -tabheight : <'auto'>|<dimension> : hauteur des onglets
-# -tabshift : <'auto'>|<dimension> offset de 'biseau' entre base et haut de l'onglet (défaut auto)
-# -radius : <dimension> rayon des arrondis d'angle
-# -overlap : <'auto'>|<dimension> offset de recouvrement/séparation entre onglets
-# -corners : <booleanList> liste 'spécifique' des raccords de sommets [0|1]
-#-----------------------------------------------------------------------------------
-sub tabBoxCoords {
- my ($coords, %options) = @_;
-
- my ($x0, $y0, $xn, $yn) = (@{$coords->[0]}, @{$coords->[1]});
- my (@shapes, @titles_coords);
- my $inverse;
-
- my @options = keys(%options);
- my $numpages = $options{'-numpages'};
-
- if (!defined $x0 or !defined $y0 or !defined $xn or !defined $yn or !$numpages) {
- print "Vous devez au minimum spécifier le rectangle englobant et le nombre de pages\n";
- return undef;
-
- }
-
- my $anchor = ($options{'-anchor'}) ? $options{'-anchor'} : 'n';
- my $alignment = ($options{'-alignment'}) ? $options{'-alignment'} : 'left';
- my $len = ($options{'-tabwidth'}) ? $options{'-tabwidth'} : 'auto';
- my $thick = ($options{'-tabheight'}) ? $options{'-tabheight'} : 'auto';
- my $biso = ($options{'-tabshift'}) ? $options{'-tabshift'} : 'auto';
- my $radius = ($options{'-radius'}) ? $options{'-radius'} : 0;
- my $overlap = ($options{'-overlap'}) ? $options{'-overlap'} : 0;
- my $corners = $options{'-corners'};
- my $orientation = ($anchor eq 'n' or $anchor eq 's') ? 'horizontal' : 'vertical';
- my $maxwidth = ($orientation eq 'horizontal') ? ($xn - $x0) : ($yn - $y0);
- my $tabswidth = 0;
- my $align = 1;
-
- if ($len eq 'auto') {
- $tabswidth = $maxwidth;
- $len = ($tabswidth + ($overlap * ($numpages - 1)))/$numpages;
-
- } else {
- if (ref($len) eq 'ARRAY') {
- foreach my $w (@{$len}) {
- $tabswidth += ($w - $overlap);
- }
- $tabswidth += $overlap;
- } else {
- $tabswidth = ($len * $numpages) - ($overlap * ($numpages - 1));
- }
-
- if ($tabswidth > $maxwidth) {
- $tabswidth = $maxwidth;
- $len = ($tabswidth + ($overlap * ($numpages - 1)))/$numpages;
- }
-
- $align = 0 if ($alignment eq 'center' and (($maxwidth - $tabswidth) > $radius));
- }
-
-
- if ($thick eq 'auto') {
- $thick = ($orientation eq 'horizontal') ? int(($yn - $y0)/10) : int(($xn - $y0)/10);
- $thick = 10 if ($thick < 10);
- $thick = 40 if ($thick > 40);
- }
-
- if ($biso eq 'auto') {
- $biso = int($thick/2);
- }
-
- if (($alignment eq 'right' and $anchor ne 'w') or
- ($anchor eq 'w' and $alignment ne 'right')) {
-
- if (ref($len) eq 'ARRAY') {
- for (my $p = 0; $p < $numpages; $p++) {
- $len->[$p] *= -1;
- }
- } else {
- $len *= -1;
- }
- $biso *= -1;
- $overlap *= -1;
- }
-
- my ($biso1, $biso2) = ($alignment eq 'center') ? ($biso/2, $biso/2) : (0, $biso);
-
- my (@cadre, @tabdxy);
- my ($xref, $yref);
- if ($orientation eq 'vertical') {
- $thick *= -1 if ($anchor eq 'w');
- my ($startx, $endx) = ($anchor eq 'w') ? ($x0, $xn) : ($xn, $x0);
- my ($starty, $endy) = (($anchor eq 'w' and $alignment ne 'right') or
- ($anchor eq 'e' and $alignment eq 'right')) ?
- ($yn, $y0) : ($y0, $yn);
-
- $xref = $startx - $thick;
- $yref = $starty;
- if ($alignment eq 'center') {
- my $ratio = ($anchor eq 'w') ? -2 : 2;
- $yref += (($maxwidth - $tabswidth)/$ratio);
- }
-
- @cadre = ([$xref, $endy], [$endx, $endy], [$endx, $starty], [$xref, $starty]);
-
- # flag de retournement de la liste des pts de curve si nécessaire -> sens anti-horaire
- $inverse = ($alignment ne 'right');
-
- } else {
- $thick *= -1 if ($anchor eq 's');
- my ($startx, $endx) = ($alignment eq 'right') ? ($xn, $x0) : ($x0, $xn);
- my ($starty, $endy) = ($anchor eq 's') ? ($yn, $y0) : ($y0, $yn);
-
-
- $yref = $starty + $thick;
- $xref = ($alignment eq 'center') ? $x0 + (($maxwidth - $tabswidth)/2) : $startx;
-
- @cadre = ([$endx, $yref], [$endx, $endy], [$startx, $endy], [$startx, $yref]);
-
- # flag de retournement de la liste des pts de curve si nécessaire -> sens anti-horaire
- $inverse = (($anchor eq 'n' and $alignment ne 'right') or ($anchor eq 's' and $alignment eq 'right'));
- }
-
- for (my $i = 0; $i < $numpages; $i++) {
- my @pts = ();
-
- # décrochage onglet
- #push (@pts, ([$xref, $yref])) if $i > 0;
-
- # cadre
- push (@pts, @cadre);
-
- # points onglets
- push (@pts, ([$xref, $yref])) if ($i > 0 or !$align);
-
- my $tw = (ref($len) eq 'ARRAY') ? $len->[$i] : $len;
- @tabdxy = ($orientation eq 'vertical') ?
- ([$thick, $biso1],[$thick, $tw - $biso2],[0, $tw]) : ([$biso1, -$thick],[$tw - $biso2, -$thick],[$tw, 0]);
- foreach my $dxy (@tabdxy) {
- push (@pts, ([$xref + $dxy->[0], $yref + $dxy->[1]]));
- }
-
- if ($radius) {
- if (!defined $options{'-corners'}) {
- $corners = ($i > 0 or !$align) ? [0, 1, 1, 0, 0, 1, 1, 0] : [0, 1, 1, 0, 1, 1, 0, 0, 0];
- }
- my $curvepts = &roundedCurveCoords(\@pts, -radius => $radius, -corners => $corners);
- @{$curvepts} = reverse @{$curvepts} if ($inverse);
- push (@shapes, $curvepts);
- } else {
- @pts = reverse @pts if ($inverse);
- push (@shapes, \@pts);
- }
-
- if ($orientation eq 'horizontal') {
- push (@titles_coords, [$xref + ($tw - ($biso2 - $biso1))/2, $yref - ($thick/2)]);
- $xref += ($tw - $overlap);
-
- } else {
- push (@titles_coords, [$xref + ($thick/2), $yref + ($len - (($biso2 - $biso1)/2))/2]);
- $yref += ($len - $overlap);
- }
-
- }
-
- return (\@shapes, \@titles_coords, $inverse);
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::graphicItemRelief
-# construit un relief à l'item Zinc en utilisant des items Triangles
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# item : <tagOrId> identifiant de l'item zinc
-# options : <hash> table d'options
-# -closed : <boolean> le relief assure la fermeture de forme (défaut 1)
-# -profil : <'rounded'|'flat'> type de profil (defaut 'rounded')
-# -relief : <'raised'|'sunken'> (défaut 'raised')
-# -side : <'inside'|'outside'> relief interne ou externe à la forme (défaut 'inside')
-# -color : <color> couleur du relief (défaut couleur de la forme)
-# -smoothed : <boolean> facettes relief lissées ou non (défaut 1)
-# -lightangle : <angle> angle d'éclairage (défaut valeur générale widget)
-# -width : <dimension> 'épaisseur' du relief en pixel
-# -fine : <boolean> mode précision courbe de bezier (défaut 0 : auto-ajustée)
-#-----------------------------------------------------------------------------------
-sub graphicItemRelief {
- my ($widget, $item, %options) = @_;
- my @items;
-
- # relief d'une liste d'items -> appel récursif
- if (ref($item) eq 'ARRAY') {
- foreach my $part (@{$item}) {
- push(@items, &graphicItemRelief($widget, $part, %options));
- }
-
- } else {
- my $itemtype = $widget->type($item);
-
- return unless ($itemtype);
-
- my $parentgroup = $widget->group($item);
- my $priority = (defined $options{'-priority'}) ? $options{'-priority'} :
- $widget->itemcget($item, -priority)+1;
-
- # coords transformés (polyline) de l'item
- my $adjust = !$options{'-fine'};
- foreach my $coords (&ZincItem2CurveCoords($widget, $item, -linear => 1,
- -realcoords => 1,-adjust => $adjust)) {
- my ($pts, $colors) = &polylineReliefParams($widget, $item, $coords, %options);
-
- push(@items, $widget->add('triangles', $parentgroup, $pts,
- -priority => $priority,
- -colors => $colors));
- }
-
-
- # renforcement du contour
- if ($widget->itemcget($item, -linewidth)) {
- push(@items, $widget->clone($item, -filled => 0, -priority => $priority+1));
- }
- }
-
- return \@items;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::polylineReliefParams
-# retourne la liste des points et des couleurs nécessaires à la construction
-# de l'item Triangles du relief
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant widget Zinc
-# item : <tagOrId> identifiant item Zinc
-# options : <hash> table d'options
-# -closed : <boolean> le relief assure la fermeture de forme (défaut 1)
-# -profil : <'rounded'|'flat'> type de profil (defaut 'rounded')
-# -relief : <'raised'|'sunken'> (défaut 'raised')
-# -side : <'inside'|'outside'> relief interne ou externe à la forme (défaut 'inside')
-# -color : <color> couleur du relief (défaut couleur de la forme)
-# -smoothed : <boolean> facettes relief lissées ou non (défaut 1)
-# -lightangle : <angle> angle d'éclairage (défaut valeur générale widget)
-# -width : <dimension> 'épaisseur' du relief en pixel
-#-----------------------------------------------------------------------------------
-sub polylineReliefParams {
- my ($widget, $item, $coords, %options) = @_;
-
- my $closed = (defined $options{'-closed'}) ? $options{'-closed'} : 1;
- my $profil = ($options{'-profil'}) ? $options{'-profil'} : 'rounded';
- my $relief = ($options{'-relief'}) ? $options{'-relief'} : 'raised';
- my $side = ($options{'-side'}) ? $options{'-side'} : 'inside';
- my $basiccolor = ($options{'-color'}) ? $options{'-color'} : &zincItemPredominantColor($widget, $item);
- my $smoothed = (defined $options{'-smooth'}) ? $options{'-smooth'} : 1;
- my $lightangle = (defined $options{'-lightangle'}) ? $options{'-lightangle'}
- : $widget->cget('-lightangle');
-
- my $width = $options{'-width'};
- if (!$width or $width < 1) {
- my ($x0, $y0, $x1, $y1) = $widget->bbox($item);
- $width = &_min($x1 -$x0, $y1 - $y0)/10;
- $width = 2 if ($width < 2);
- }
-
- my $numfaces = scalar(@{$coords});
- my $previous = ($closed) ? $coords->[$numfaces - 1] : undef;
- my $next = $coords->[1];
-
- my @pts;
- my @colors;
- my $alpha = 100;
- if ($basiccolor =~ /;/) {
- ($basiccolor, $alpha) = split /;/, $basiccolor;
-
- }
-
- $alpha /= 2 if (!($options{'-color'} =~ /;/) and $profil eq 'flat');
-
- my $reliefalphas = ($profil eq 'rounded') ? [0,$alpha] : [$alpha, $alpha];
-
- for (my $i = 0; $i < $numfaces; $i++) {
- my $pt = $coords->[$i];
-
- if (!$previous) {
- # extrémité de curve sans raccord -> angle plat
- $previous = [$pt->[0] + ($pt->[0] - $next->[0]), $pt->[1] + ($pt->[1] - $next->[1])];
- }
-
- my ($angle, $bisecangle) = &vertexAngle($previous, $pt, $next);
-
- # distance au centre du cercle inscrit : rayon/sinus demi-angle
- my $sin = sin(deg2rad($angle/2));
- my $delta = ($sin) ? abs($width / $sin) : $width;
- my $decal = ($side eq 'outside') ? -90 : 90;
-
- my @shift_pt = &rad_point($pt, $delta, $bisecangle+$decal);
- push (@pts, @shift_pt);
- push (@pts, @{$pt});
-
- if (!$smoothed and $i) {
- push (@pts, @shift_pt);
- push (@pts, @{$pt});
- }
-
- my $faceangle = 360 -(&lineNormal($previous, $next)+90);
-
- my $light = abs($lightangle - $faceangle);
- $light = 360 - $light if ($light > 180);
- $light = 1 if $light < 1;
-
- my $lumratio = ($relief eq 'sunken') ? (180-$light)/180 : $light/180;
-
- if (!$smoothed and $i) {
- push(@colors, ($colors[-2],$colors[-1]));
- }
-
- if ($basiccolor) {
- # création des couleurs dérivées
- my $shade = &LightingColor($basiccolor, $lumratio);
- my $color0 = $shade.";".$reliefalphas->[0];
- my $color1 = $shade.";".$reliefalphas->[1];
- push(@colors, ($color0, $color1));
-
- } else {
- my $c = (255*$lumratio);
- my $color0 = &hexaRGBcolor($c, $c, $c, $reliefalphas->[0]);
- my $color1 = &hexaRGBcolor($c, $c, $c, $reliefalphas->[1]);
- push(@colors, ($color0, $color1));
- }
-
- if ($i == $numfaces - 2) {
- $next = ($closed) ? $coords->[0] :
- [$coords->[$i+1]->[0] + ($coords->[$i+1]->[0] - $pt->[0]), $coords->[$i+1]->[1] + ($coords->[$i+1]->[1] - $pt->[1])];
- } else {
- $next = $coords->[$i+2];
- }
-
- $previous = $coords->[$i];
- }
-
- if ($closed) {
- push (@pts, ($pts[0], $pts[1], $pts[2], $pts[3]));
- push (@colors, ($colors[0], $colors[1]));
-
- if (!$smoothed) {
- push (@pts, ($pts[0], $pts[1], $pts[2], $pts[3]));
- push (@colors, ($colors[0], $colors[1]));
- }
-
- }
-
-
- return (\@pts, \@colors);
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::graphicItemShadow
-# Création d'une ombre portée à l'item
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant widget Zinc
-# item : <tagOrId> identifiant item Zinc
-# options : <hash> table d'options
-# -opacity : <percent> opacité de l'ombre (défaut 50)
-# -filled : <boolean> remplissage totale de l'ombre (hors bordure) (defaut 1)
-# -lightangle : <angle> angle d'éclairage (défaut valeur générale widget)
-# -distance : <dimension> distance de projection de l'ombre en pixel
-# -enlarging : <dimension> grossi de l'ombre portée en pixels (defaut 0)
-# -width : <dimension> taille de diffusion/diffraction (défaut 4)
-# -color : <color> couleur de l'ombre portée (défaut black)
-#-----------------------------------------------------------------------------------
-sub graphicItemShadow {
- my ($widget, $item, %options) = @_;
- my @items;
-
- # relief d'une liste d'items -> appel récursif
- if (ref($item) eq 'ARRAY') {
- foreach my $part (@{$item}) {
- push(@items, &graphicItemShadow($widget, $part, %options));
- }
-
- return \@items;
-
- } else {
-
- my $itemtype = $widget->type($item);
-
- return unless ($itemtype);
-
- # création d'un groupe à l'ombre portée
- my $parentgroup = ($options{'-parentgroup'}) ? $options{'-parentgroup'} :
- $widget->group($item);
- my $priority = (defined $options{'-priority'}) ? $options{'-priority'} :
- ($widget->itemcget($item, -priority))-1;
- $priority = 0 if ($priority < 0);
-
- my $shadow = $widget->add('group', $parentgroup, -priority => $priority);
-
- if ($itemtype eq 'text') {
- my $opacity = (defined $options{'-opacity'}) ? $options{'-opacity'} : 50;
- my $color = ($options{'-color'}) ? $options{'-color'} : '#000000';
-
- my $clone = $widget->clone($item, -color => $color.";".$opacity);
- $widget->chggroup($clone, $shadow);
-
- } else {
-
- # création des items (de dessin) de l'ombre
- my $filled = (defined $options{'-filled'}) ? $options{'-filled'} : 1;
-
- # coords transformés (polyline) de l'item
- foreach my $coords (&ZincItem2CurveCoords($widget, $item, -linear => 1, -realcoords => 1)) {
- my ($t_pts, $i_pts, $colors) = &polylineShadowParams($widget, $item, $coords, %options);
-
- # option filled : remplissage hors bordure de l'ombre portée (item curve)
- if ($filled) {
- if (@items) {
- $widget->contour($items[0], 'add', 0, $i_pts);
-
- } else {
- push(@items, $widget->add('curve', $shadow, $i_pts,
- -linewidth => 0,
- -filled => 1,
- -fillcolor => $colors->[0],
- ));
- }
- }
-
- # bordure de diffusion de l'ombre (item triangles)
- push(@items, $widget->add('triangles', $shadow, $t_pts,
- -colors => $colors));
- }
- }
-
- # positionnement de l'ombre portée
- my $distance = (defined $options{'-distance'}) ? $options{'-distance'} : 10;
- my $lightangle = (defined $options{'-lightangle'}) ? $options{'-lightangle'}
- : $widget->cget('-lightangle');
-
- my ($dx, $dy) = &rad_point([0, 0], $distance, $lightangle+180);
- $widget->translate($shadow, $dx, -$dy);
-
- return $shadow;
-
- }
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::polylineShadowParams
-# retourne les listes des points et de couleurs nécessaires à la construction des
-# items triangles (bordure externe) et curve (remplissage interne) de l'ombre portée
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant widget Zinc
-# item : <tagOrId> identifiant item Zinc
-# options : <hash> table d'options
-# -opacity : <percent> opacité de l'ombre (défaut 50)
-# -lightangle : <angle> angle d'éclairage (défaut valeur générale widget)
-# -distance : <dimension> distance de projection de l'ombre en pixel (défaut 10)
-# -enlarging : <dimension> grossi de l'ombre portée en pixels (defaut 2)
-# -width : <dimension> taille de diffusion/diffraction (défaut distance -2)
-# -color : <color> couleur de l'ombre portée (défaut black)
-#-----------------------------------------------------------------------------------
-sub polylineShadowParams {
- my ($widget, $item, $coords, %options) = @_;
-
- my $distance = (defined $options{'-distance'}) ? $options{'-distance'} : 10;
- my $width = (defined $options{'-width'}) ? $options{'-width'} : $distance-2;
- my $opacity = (defined $options{'-opacity'}) ? $options{'-opacity'} : 50;
- my $color = ($options{'-color'}) ? $options{'-color'} : '#000000';
- my $enlarging = (defined $options{'-enlarging'}) ? $options{'-enlarging'} : 2;
-
- if ($enlarging) {
- $coords = &shiftPathCoords($coords, -width => $enlarging, -closed => 1, -shifting => 'out');
- }
-
- my $numfaces = scalar(@{$coords});
- my $previous = $coords->[$numfaces - 1];
- my $next = $coords->[1];
-
- my @t_pts;
- my @i_pts;
- my @colors;
- my ($color0, $color1) = ($color.";$opacity", $color.";0");
-
- for (my $i = 0; $i < $numfaces; $i++) {
- my $pt = $coords->[$i];
-
- if (!$previous) {
- # extrémité de curve sans raccord -> angle plat
- $previous = [$pt->[0] + ($pt->[0] - $next->[0]), $pt->[1] + ($pt->[1] - $next->[1])];
- }
-
- my ($angle, $bisecangle) = &vertexAngle($previous, $pt, $next);
-
- # distance au centre du cercle inscrit : rayon/sinus demi-angle
- my $sin = sin(deg2rad($angle/2));
- my $delta = ($sin) ? abs($width / $sin) : $width;
- my $decal = 90;
-
- my @shift_pt = &rad_point($pt, $delta, $bisecangle+$decal);
- push (@i_pts, @shift_pt);
- push (@t_pts, @shift_pt);
- push (@t_pts, @{$pt});
-
- push(@colors, ($color0, $color1));
-
- if ($i == $numfaces - 2) {
- $next = $coords->[0];
- } else {
- $next = $coords->[$i+2];
- }
-
- $previous = $coords->[$i];
- }
-
- # fermeture
- push(@t_pts, ($t_pts[0], $t_pts[1],$t_pts[2],$t_pts[3]));
- push(@i_pts, ($t_pts[0], $t_pts[1]));
- push(@colors, ($color0, $color1,$color0,$color1));
-
- return (\@t_pts, \@i_pts, \@colors);
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::bezierSegment
-# Calcul d'une approximation de segment (Quadratique ou Cubique) de bezier
-#-----------------------------------------------------------------------------------
-# paramètres :
-# points : <[P1, C1, <C1>, P2]> liste des points définissant le segment de bezier
-#
-# options :
-# -tunits : <integer> nombre pas de division des segments bezier (par défaut 20)
-# -skipend : <boolean> : ne pas retourner le dernier point du segment (chainage)
-#-----------------------------------------------------------------------------------
-sub bezierSegment {
- my ($coords, %options) = @_;
- my $tunits = ($options{'-tunits'}) ? $options{'-tunits'} : 20;
- my $skipendpt = $options{'-skipend'};
-
- my @pts;
-
- my $lastpt = ($skipendpt) ? $tunits-1 : $tunits;
- foreach (my $i = 0; $i <= $lastpt; $i++) {
- my $t = ($i) ? ($i/$tunits) : $i;
- push(@pts, &bezierPoint($t, $coords));
- }
-
- return wantarray ? @pts : \@pts;
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::bezierPoint
-# calcul d'un point du segment (Quadratique ou Cubique) de bezier
-# params :
-# t = <n> (représentation du temps : de 0 à 1)
-# coords = (P1, C1, <C1>, P2) liste des points définissant le segment de bezier
-# P1 et P2 : extémités du segment et pts situés sur la courbe
-# C1 <C2> : point(s) de contrôle du segment
-#-----------------------------------------------------------------------------------
-# courbe bezier niveau 2 sur (P1, P2, P3)
-# P(t) = (1-t)²P1 + 2t(1-t)P2 + t²P3
-#
-# courbe bezier niveau 3 sur (P1, P2, P3, P4)
-# P(t) = (1-t)³P1 + 3t(1-t)²P2 + 3t²(1-t)P3 + t³P4
-#-----------------------------------------------------------------------------------
-sub bezierPoint {
- my ($t, $coords) = @_;
- my ($p1, $c1, $c2, $p2) = @{$coords};
-
- # quadratique
- if (!defined $p2) {
- $p2 = $c2;
- $c2 = undef;
- }
-
- # extrémités : points sur la courbe
- return wantarray ? @{$p1} : $p1 if (!$t);
- return wantarray ? @{$p2} : $p2 if ($t >= 1.0);
-
-
- my $t2 = $t * $t;
- my $t3 = $t2 * $t;
- my @pt;
-
- # calcul pour x et y
- foreach my $i (0, 1) {
-
- if (defined $c2) {
- my $r1 = (1 - (3*$t) + (3*$t2) - $t3) * $p1->[$i];
- my $r2 = ( (3*$t) - (6*$t2) + (3*$t3)) * $c1->[$i];
- my $r3 = ( (3*$t2) - (3*$t3)) * $c2->[$i];
- my $r4 = ( $t3) * $p2->[$i];
-
- $pt[$i] = ($r1 + $r2 + $r3 + $r4);
-
- } else {
- my $r1 = (1 - (2*$t) + $t2) * $p1->[$i];
- my $r2 = ( (2*$t) - (2*$t2)) * $c1->[$i];
- my $r3 = ( $t2) * $p2->[$i];
-
- $pt[$i] = ($r1 + $r2 + $r3);
- }
- }
-
- #return wantarray ? @pt : \@pt;
- return \@pt;
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::bezierCompute
-# Retourne une liste de coordonnées décrivant un segment de bezier
-#-----------------------------------------------------------------------------------
-# paramètres :
-# coords : <coordsList> liste des points définissant le segment de bezier
-#
-# options :
-# -precision : <dimension> seuil limite du calcul d'approche de la courbe
-# -skipend : <boolean> : ne pas retourner le dernier point du segment (chaînage bezier)
-#-----------------------------------------------------------------------------------
-sub bezierCompute {
- my ($coords, %options) = @_;
- my $precision = ($options{'-precision'}) ? $options{'-precision'} : $bezierClosenessThreshold;
- my $lastit = [];
-
- &subdivideBezier($coords, $lastit, $precision);
-
- push(@{$lastit}, $coords->[3]) if (!$options{'-skipend'});
-
- return wantarray ? @{$lastit} : $lastit;
-}
-
-#------------------------------------------------------------------------------------
-# Graphics::smallEnought
-# intégration code Stéphane Conversy : calcul points bezier (précision auto ajustée)
-#------------------------------------------------------------------------------------
-# distance is something like num/den with den=sqrt(something)
-# what we want is to test that distance is smaller than precision,
-# so we have distance < precision ? eq. to distance^2 < precision^2 ?
-# eq. to (num^2/something) < precision^2 ?
-# eq. to num^2 < precision^2*something
-# be careful with huge values though (hence 'long long')
-# with common values: 9add 9mul
-#------------------------------------------------------------------------------------
-sub smallEnoughBezier {
- my ($bezier, $precision) = @_;
- my ($x, $y) = (0, 1);
- my ($A, $B) = ($bezier->[0], $bezier->[3]);
-
- my $den = (($A->[$y]-$B->[$y])*($A->[$y]-$B->[$y])) + (($B->[$x]-$A->[$x])*($B->[$x]-$A->[$x]));
- my $p = $precision*$precision;
-
- # compute distance between P1|P2 and P0|P3
- my $M = $bezier->[1];
- my $num1 = (($M->[$x]-$A->[$x])*($A->[$y]-$B->[$y])) + (($M->[$y]-$A->[$y])*($B->[$x]-$A->[$x]));
-
- $M = $bezier->[2];
- my $num2 = (($M->[$x]-$A->[$x])*($A->[$y]-$B->[$y])) + (($M->[$y]-$A->[$y])*($B->[$x]-$A->[$x]));
-
- # take the max
- $num1 = $num2 if ($num2 > $num1);
-
- return ($p*$den > ($num1*$num1)) ? 1 : 0;
-
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::subdivideBezier
-# subdivision d'une courbe de bezier
-#-----------------------------------------------------------------------------------
-sub subdivideBezier {
- my ($bezier, $it, $precision, $integeropt) = @_;
- my ($b0, $b1, $b2, $b3) = @{$bezier};
-
- if (&smallEnoughBezier($bezier, $precision)) {
- push(@{$it}, ([$b0->[0],$b0->[1]]));
-
- } else {
- my ($left, $right);
-
- foreach my $i (0, 1) {
-
- if ($integeropt) {
- # int optimized (6+3=9)add + (5+3=8)shift
-
- $left->[0][$i] = $b0->[$i];
- $left->[1][$i] = ($b0->[$i] + $b1->[$i]) >> 1;
- $left->[2][$i] = ($b0->[$i] + $b2->[$i] + ($b1->[$i] << 1)) >> 2; # keep precision
- my $tmp = ($b1->[$i] + $b2->[$i]);
- $left->[3][$i] = ($b0->[$i] + $b3->[$i] + ($tmp << 1) + $tmp) >> 3;
-
- $right->[3][$i] = $b3->[$i];
- $right->[2][$i] = ($b3->[$i] + $b2->[$i]) >> 1;
- $right->[1][$i] = ($b3->[$i] + $b1->[$i] + ($b2->[$i] << 1) ) >> 2; # keep precision
- $right->[0][$i] = $left->[3]->[$i];
-
- } else {
- # float
-
- $left->[0][$i] = $b0->[$i];
- $left->[1][$i] = ($b0->[$i] + $b1->[$i]) / 2;
- $left->[2][$i] = ($b0->[$i] + (2*$b1->[$i]) + $b2->[$i]) / 4;
- $left->[3][$i] = ($b0->[$i] + (3*$b1->[$i]) + (3*$b2->[$i]) + $b3->[$i]) / 8;
-
- $right->[3][$i] = $b3->[$i];
- $right->[2][$i] = ($b3->[$i] + $b2->[$i]) / 2;
- $right->[1][$i] = ($b3->[$i] + (2*$b2->[$i]) + $b1->[$i]) / 4;
- $right->[0][$i] = ($b3->[$i] + (3*$b2->[$i]) + (3*$b1->[$i]) + $b0->[$i]) / 8;
-
- }
- }
-
- &subdivideBezier($left, $it, $precision, $integeropt);
- &subdivideBezier($right, $it, $precision, $integeropt);
-
- }
-}
-
-
-
-#-----------------------------------------------------------------------------------
-# RESOURCES GRAPHIQUES PATTERNS, TEXTURES, IMAGES, GRADIENTS, COULEURS...
-#-----------------------------------------------------------------------------------
-#-----------------------------------------------------------------------------------
-# Graphics::getPattern
-# retourne la ressource bitmap en l'initialisant si première utilisation
-#-----------------------------------------------------------------------------------
-# paramètres :
-# filename : nom du fichier bitmap pattern
-# options
-# -storage : <hastable> référence de la table de stockage de patterns
-#-----------------------------------------------------------------------------------
-sub getPattern {
- my ($filename, %options) = @_;
- my $table = (defined $options{'-storage'} and ref($options{'-storage'}) eq 'HASH') ?
- $options{'-storage'} : \%bitmaps;
-
- if (!exists($table->{$filename})) {
- my $bitmap = '@'.Tk::findINC($filename);
- $table->{$filename} = $bitmap if $bitmap;
-
- }
-
- return $table->{$filename};
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::getTexture
-# retourne l'image de texture en l'initialisant si première utilisation
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# filename : nom du fichier texture
-# options
-# -storage : <hastable> référence de la table de stockage de textures
-#-----------------------------------------------------------------------------------
-sub getTexture {
- my ($widget, $filename, %options) = @_;
- my $table = (defined $options{'-storage'} and ref($options{'-storage'}) eq 'HASH') ?
- $options{'-storage'} : \%textures;
-
- return &getImage($widget, $filename, -storage => $table);
-
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::getImage
-# retourne la ressource image en l'initialisant si première utilisation
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# filename : nom du fichier image
-# options
-# -storage : <hastable> référence de la table de stockage d'images
-#-----------------------------------------------------------------------------------
-sub getImage {
- my ($widget, $filename, %options) = @_;
- my $table = (defined $options{'-storage'} and ref($options{'-storage'}) eq 'HASH') ?
- $options{'-storage'} : \%images;
-
- if (!exists($table->{$filename})) {
- my $image;
- if ($filename =~ /.png|.PNG/) {
- $image = $widget->Photo(-format => 'png', -file => Tk::findINC($filename));
-
- } elsif ($filename =~ /.jpg|.JPG|.jpeg|.JPEG/) {
- $image = $widget->Photo(-format => 'jpeg', -file => Tk::findINC($filename));
-
- } else {
- $image = $widget->Photo(-file => Tk::findINC($filename));
- }
-
- $table->{$filename} = $image if $image;
-
- }
-
- return $table->{$filename};
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::init_pixmaps
-# initialise une liste de fichier image
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# filenames : <filenameList> list des noms des fichier image
-# options
-# -storage : <hastable> référence de la table de stockage d'images
-#-----------------------------------------------------------------------------------
-sub init_pixmaps {
- my ($widget, $filenames, %options) = @_;
- my @imgs = ();
-
- my @files = (ref($filenames) eq 'ARRAY') ? @{$filenames} : ($filenames);
-
- foreach (@files) {
- push(@imgs, &getImage($widget, $_, %options));
- }
-
- return @imgs;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::_min
-# retourne la plus petite valeur entre 2 valeurs
-#-----------------------------------------------------------------------------------
-sub _min {
- my ($n1, $n2) = @_;
- my $mini = ($n1 > $n2) ? $n2 : $n1;
- return $mini;
-
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::_max
-# retourne la plus grande valeur entre 2 valeurs
-#-----------------------------------------------------------------------------------
-sub _max {
- my ($n1, $n2) = @_;
- my $maxi = ($n1 > $n2) ? $n1 : $n2;
- return $maxi;
-
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::_trunc
-# fonction interne de troncature des nombres: n = position décimale
-#-----------------------------------------------------------------------------------
-sub _trunc {
- my ($val, $n) = @_;
- my $str;
- my $dec;
-
- ($val) =~ /([0-9]+)\.?([0-9]*)/;
- $str = ($val < 0) ? "-$1" : $1;
-
- if (($2 ne "") && ($n != 0)) {
- $dec = substr($2, 0, $n);
- if ($dec != 0) {
- $str = $str . "." . $dec;
- }
- }
- return $str;
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::setGradients
-# création de gradient nommés Zinc
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# grads : <hastable> table de hash de définition de couleurs zinc
-#-----------------------------------------------------------------------------------
-sub setGradients {
- my ($widget, $grads) = @_;
-
- # initialise les gradients de taches
- unless (@Gradients) {
- while (my ($name, $gradient) = each( %{$grads})) {
- # création des gradients nommés
- $widget->gname($gradient, $name);
- push(@Gradients, $name);
- }
- }
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::RGB_dec2hex
-# conversion d'une couleur RGB (255,255,255) au format Zinc '#ffffff'
-#-----------------------------------------------------------------------------------
-# paramètres :
-# rgb : <rgbColorList> liste de couleurs au format RGB
-#-----------------------------------------------------------------------------------
-sub RGB_dec2hex {
- my (@rgb) = @_;
- return (sprintf("#%04x%04x%04x", @rgb));
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::pathGraduate
-# création d'un jeu de couleurs dégradées pour item pathLine
-#-----------------------------------------------------------------------------------
-sub pathGraduate {
- my ($widget, $numcolors, $style) = @_;
-
- my $type = $style->{'-type'};
- my $triangles_colors;
-
- if ($type eq 'linear') {
- return &createGraduate($widget, $numcolors, $style->{'-colors'}, 2);
-
- } elsif ($type eq 'double') {
- my $colors1 = &createGraduate($widget, $numcolors/2+1, $style->{'-colors'}->[0]);
- my $colors2 = &createGraduate($widget, $numcolors/2+1, $style->{'-colors'}->[1]);
- my @colors;
- for (my $i = 0; $i <= $numcolors; $i++) {
- push(@colors, ($colors1->[$i], $colors2->[$i]));
- }
-
- return \@colors;
-
- } elsif ($type eq 'transversal') {
- my ($c1, $c2) = @{$style->{'-colors'}};
- my @colors = ($c1, $c2);
- for (my $i = 0; $i < $numcolors; $i++) {
- push(@colors, ($c1, $c2));
- }
-
- return \@colors;
- }
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::createGraduate
-# création d'un jeu de couleurs intermédiaires (dégradé) entre n couleurs
-#-----------------------------------------------------------------------------------
-sub createGraduate {
- my ($widget, $totalsteps, $refcolors, $repeat) = @_;
- my @colors;
-
- $repeat = 1 if (!$repeat);
- my $numgraduates = scalar @{$refcolors} - 1;
-
- if ($numgraduates < 1) {
- print "Le dégradé necessite au minimum 2 couleurs de référence...\n";
- return undef;
- }
-
- my $steps = ($numgraduates > 1) ? $totalsteps/($numgraduates -1) : $totalsteps;
-
- for (my $c = 0; $c < $numgraduates; $c++) {
- my ($c1, $c2) = ($refcolors->[$c], $refcolors->[$c+1]);
-
- for (my $i = 0 ; $i < $steps ; $i++) {
- my $color = MedianColor($c1, $c2, $i/($steps-1));
- for (my $k = 0; $k < $repeat; $k++) {
- push (@colors, $color);
- }
- }
-
- if ($c < $numgraduates - 1) {
- for (my $k = 0; $k < $repeat; $k++) {
- pop @colors;
- }
- }
- }
-
- return \@colors;
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::LightingColor
-# modification d'une couleur par sa composante luminosité
-#-----------------------------------------------------------------------------------
-# paramètres :
-# color : <color> couleur au format zinc
-# newL : <pourcent> (de 0 à 1) nouvelle valeur de luminosité
-#-----------------------------------------------------------------------------------
-sub LightingColor {
- my ($color, $newL) = @_;
- my ($H, $L, $S);
-
- if ($color and $newL) {
- my ($RGB) = &hexa2RGB($color);
- ($H, $L, $S) = @{&RGBtoHLS(@{$RGB})};
-
-
- $newL = 1 if $newL > 1;
- my ($nR, $nG, $nB) = @{&HLStoRGB($H, $newL, $S)};
- return &hexaRGBcolor($nR*255, $nG*255, $nB*255);
-
- }
-
- return undef;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::zincItemPredominantColor
-# retourne la couleur dominante d'un item ('barycentre' gradiant fillcolor)
-#-----------------------------------------------------------------------------------
-# paramètres :
-# widget : <widget> identifiant du widget zinc
-# item : <tagOrId> identifiant de l'item zinc
-#-----------------------------------------------------------------------------------
-sub zincItemPredominantColor {
- my ($widget, $item) = @_;
- my $type = $widget->type($item);
-
- if ($type eq 'text' or '$type' eq 'icon') {
- return $widget->itemcget($item, -color);
-
- } elsif ($type eq 'triangles' or
- $type eq 'rectangle' or
- $type eq 'arc' or
- $type eq 'curve') {
-
- my @colors;
-
- if ($type eq 'triangles') {
- @colors = $widget->itemcget($item, -colors);
-
- } else {
- my $grad = $widget->itemcget($item, -fillcolor);
-
- return $grad if (scalar (my @unused = (split / /, $grad)) < 2);
-
- my @colorparts = split /\|/, $grad;
- foreach my $section (@colorparts) {
- if ($section !~ /=/) {
- my ($color, $director, $position) = split / /, $section;
- push (@colors, $color);
- }
- }
- }
-
-
- my ($Rs, $Gs, $Bs, $As, $numcolors) = (0, 0, 0, 0, 0);
- foreach my $color (@colors) {
- my ($r, $g, $b, $a) = ZnColorToRGB($color);
- $Rs += $r;
- $Gs += $g;
- $Bs += $b;
- $As += $a;
- $numcolors++;
- }
-
- my $newR = int($Rs/$numcolors);
- my $newG = int($Gs/$numcolors);
- my $newB = int($Bs/$numcolors);
- my $newA = int($As/$numcolors);
-
- my $newcolor = &hexaRGBcolor($newR, $newG, $newB, $newA);
-
- return $newcolor
-
- } else {
- return '#777777';
- }
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::MedianColor
-# calcul d'une couleur intermédiaire défini par un ratio ($rate) entre 2 couleurs
-#-----------------------------------------------------------------------------------
-# paramètres :
-# color1 : <color> première couleur zinc
-# color2 : <color> seconde couleur zinc
-# rate : <pourcent> (de 0 à 1) position de la couleur intermédiaire
-#-----------------------------------------------------------------------------------
-sub MedianColor {
- my ($color1, $color2, $rate) = @_;
- $rate = 1 if ($rate > 1);
- $rate = 0 if ($rate < 0);
-
- my ($r0, $g0, $b0, $a0) = &ZnColorToRGB($color1);
- my ($r1, $g1, $b1, $a1) = &ZnColorToRGB($color2);
-
- my $r = $r0 + int(($r1 - $r0) * $rate);
- my $g = $g0 + int(($g1 - $g0) * $rate);
- my $b = $b0 + int(($b1 - $b0) * $rate);
- my $a = $a0 + int(($a1 - $a0) * $rate);
-
- return &hexaRGBcolor($r, $g, $b, $a);
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::ZnColorToRGB
-# conversion d'une couleur Zinc au format RGBA (255,255,255,100)
-#-----------------------------------------------------------------------------------
-# paramètres :
-# zncolor : <color> couleur au format hexa zinc (#ffffff ou #ffffffffffff)
-#-----------------------------------------------------------------------------------
-sub ZnColorToRGB {
- my ($zncolor) = @_;
-
- my ($color, $alpha) = split /;/, $zncolor;
- my $ndigits = (length($color) > 8) ? 4 : 2;
- my $R = hex(substr($color, 1, $ndigits));
- my $G = hex(substr($color, 1+$ndigits, $ndigits));
- my $B = hex(substr($color, 1+($ndigits*2), $ndigits));
-
- $alpha = 100 if (!defined $alpha or $alpha eq "");
-
- return ($R, $G, $B, $alpha);
-
-}
-
-#-----------------------------------------------------------------------------------
-# ALGORYTHMES DE CONVERSION ENTRE ESPACES DE COULEURS
-#-----------------------------------------------------------------------------------
-#-----------------------------------------------------------------------------------
-# Graphics::RGBtoLCH
-# Algorythme de conversion RGB -> CIE LCH°
-#-----------------------------------------------------------------------------------
-# paramètres :
-# r : <pourcent> (de 0 à 1) valeur de la composante rouge de la couleur RGB
-# g : <pourcent> (de 0 à 1) valeur de la composante verte de la couleur RGB
-# b : <pourcent> (de 0 à 1) valeur de la composante bleue de la couleur RGB
-#-----------------------------------------------------------------------------------
-sub RGBtoLCH {
- my ($r, $g, $b) = @_;
-
- # Conversion RGBtoXYZ
- my $gamma = 2.4;
- my $rgblimit = 0.03928;
-
-
- $r = ($r > $rgblimit) ? (($r + 0.055)/1.055)**$gamma : $r / 12.92;
- $g = ($g > $rgblimit) ? (($g + 0.055)/1.055)**$gamma : $g / 12.92;
- $b = ($b > $rgblimit) ? (($b + 0.055)/1.055)**$gamma : $b / 12.92;
-
- $r *= 100;
- $g *= 100;
- $b *= 100;
-
- my $X = (0.4124 * $r) + (0.3576 * $g) + (0.1805 * $b);
- my $Y = (0.2126 * $r) + (0.7152 * $g) + (0.0722 * $b);
- my $Z = (0.0193 * $r) + (0.1192 * $g) + (0.9505 * $b);
-
-
- # Conversion XYZtoLab
- $gamma = 1/3;
- my ($L, $A, $B);
-
- if ($Y == 0) {
- ($L, $A, $B) = (0, 0, 0);
-
- } else {
-
- my ($Xs, $Ys, $Zs) = ($X/$Xw, $Y/$Yw, $Z/$Zw);
-
- $Xs = ($Xs > 0.008856) ? $Xs**$gamma : (7.787 * $Xs) + (16/116);
- $Ys = ($Ys > 0.008856) ? $Ys**$gamma : (7.787 * $Ys) + (16/116);
- $Zs = ($Zs > 0.008856) ? $Zs**$gamma : (7.787 * $Zs) + (16/116);
-
- $L = (116.0 * $Ys) - 16.0;
-
- $A = 500 * ($Xs - $Ys);
- $B = 200 * ($Ys - $Zs);
-
- }
-
- # conversion LabtoLCH
- my ($C, $H);
-
-
- if ($A == 0) {
- $H = 0;
-
- } else {
-
- $H = atan2($B, $A);
-
- if ($H > 0) {
- $H = ($H / pi) * 180;
-
- } else {
- $H = 360 - ( abs($H) / pi) * 180
- }
- }
-
-
- $C = sqrt($A**2 + $B**2);
-
- return [$L, $C, $H];
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::LCHtoRGB
-# Algorythme de conversion CIE L*CH -> RGB
-#-----------------------------------------------------------------------------------
-# paramètres :
-# L : <pourcent> (de 0 à 1) valeur de la composante luminosité de la couleur CIE LCH
-# C : <pourcent> (de 0 à 1) valeur de la composante saturation de la couleur CIE LCH
-# H : <pourcent> (de 0 à 1) valeur de la composante teinte de la couleur CIE LCH
-#-----------------------------------------------------------------------------------
-sub LCHtoRGB {
- my ($L, $C, $H) = @_;
- my ($a, $b);
-
- # Conversion LCHtoLab
- $a = cos( deg2rad($H)) * $C;
- $b = sin( deg2rad($H)) * $C;
-
- # Conversion LabtoXYZ
- my $gamma = 3;
- my ($X, $Y, $Z);
-
- my $Ys = ($L + 16.0) / 116.0;
- my $Xs = ($a / 500) + $Ys;
- my $Zs = $Ys - ($b / 200);
-
-
- $Ys = (($Ys**$gamma) > 0.008856) ? $Ys**$gamma : ($Ys - 16 / 116) / 7.787;
- $Xs = (($Xs**$gamma) > 0.008856) ? $Xs**$gamma : ($Xs - 16 / 116) / 7.787;
- $Zs = (($Zs**$gamma) > 0.008856) ? $Zs**$gamma : ($Zs - 16 / 116) / 7.787;
-
-
- $X = $Xw * $Xs;
- $Y = $Yw * $Ys;
- $Z = $Zw * $Zs;
-
- # Conversion XYZtoRGB
- $gamma = 1/2.4;
- my $rgblimit = 0.00304;
- my ($R, $G, $B);
-
-
- $X /= 100;
- $Y /= 100;
- $Z /= 100;
-
- $R = (3.2410 * $X) + (-1.5374 * $Y) + (-0.4986 * $Z);
- $G = (-0.9692 * $X) + (1.8760 * $Y) + (0.0416 * $Z);
- $B = (0.0556 * $X) + (-0.2040 * $Y) + (1.0570 * $Z);
-
- $R = ($R > $rgblimit) ? (1.055 * ($R**$gamma)) - 0.055 : (12.92 * $R);
- $G = ($G > $rgblimit) ? (1.055 * ($G**$gamma)) - 0.055 : (12.92 * $G);
- $B = ($B > $rgblimit) ? (1.055 * ($B**$gamma)) - 0.055 : (12.92 * $B);
-
- $R = ($R < 0) ? 0 : ($R > 1.0) ? 1.0 : &_trunc($R, 5);
- $G = ($G < 0) ? 0 : ($G > 1.0) ? 1.0 : &_trunc($G, 5);
- $B = ($B < 0) ? 0 : ($B > 1.0) ? 1.0 : &_trunc($B, 5);
-
- return [$R, $G, $B];
-
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::RGBtoHLS
-# Algorythme de conversion RGB -> HLS
-#-----------------------------------------------------------------------------------
-# r : <pourcent> (de 0 à 1) valeur de la composante rouge de la couleur RGB
-# g : <pourcent> (de 0 à 1) valeur de la composante verte de la couleur RGB
-# b : <pourcent> (de 0 à 1) valeur de la composante bleue de la couleur RGB
-#-----------------------------------------------------------------------------------
-sub RGBtoHLS {
- my ($r, $g, $b) = @_;
- my ($H, $L, $S);
- my ($min, $max, $diff);
-
-
- $max = &max($r,$g,$b);
- $min = &min($r,$g,$b);
-
- # calcul de la luminosité
- $L = ($max + $min) / 2;
-
- # calcul de la saturation
- if ($max == $min) {
- # couleur a-chromatique (gris) $r = $g = $b
- $S = 0;
- $H = undef;
-
- return [$H, $L, $S];
- }
-
- # couleurs "Chromatiques" --------------------
-
- # calcul de la saturation
- if ($L <= 0.5) {
- $S = ($max - $min) / ($max + $min);
-
- } else {
- $S = ($max - $min) / (2 - $max - $min);
-
- }
-
- # calcul de la teinte
- $diff = $max - $min;
-
- if ($r == $max) {
- # couleur entre jaune et magenta
- $H = ($g - $b) / $diff;
-
- } elsif ($g == $max) {
- # couleur entre cyan et jaune
- $H = 2 + ($b - $r) / $diff;
-
- } elsif ($b == $max) {
- # couleur entre magenta et cyan
- $H = 4 + ($r - $g) / $diff;
- }
-
- # Conversion en degrés
- $H *= 60;
-
- # pour éviter une valeur négative
- if ($H < 0.0) {
- $H += 360;
- }
-
- return [$H, $L, $S];
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::HLStoRGB
-# Algorythme de conversion HLS -> RGB
-#-----------------------------------------------------------------------------------
-# paramètres :
-# H : <pourcent> (de 0 à 1) valeur de la composante teinte de la couleur HLS
-# L : <pourcent> (de 0 à 1) valeur de la composante luminosité de la couleur HLS
-# S : <pourcent> (de 0 à 1) valeur de la composante saturation de la couleur HLS
-#-----------------------------------------------------------------------------------
-sub HLStoRGB {
- my ($H, $L, $S) = @_;
- my ($R, $G, $B);
- my ($p1, $p2);
-
-
- if ($L <= 0.5) {
- $p2 = $L + ($L * $S);
-
- } else {
- $p2 = $L + $S - ($L * $S);
-
- }
-
- $p1 = 2.0 * $L - $p2;
-
- if ($S == 0) {
- # couleur a-chromatique (gris)
- # $R = $G = $B = $L
- $R = $L;
- $G = $L;
- $B = $L;
-
- } else {
- # couleurs "Chromatiques"
- $R = &hlsValue($p1, $p2, $H + 120);
- $G = &hlsValue($p1, $p2, $H);
- $B = &hlsValue($p1, $p2, $H - 120);
-
- }
-
- return [$R, $G, $B];
-
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::hlsValue (sous fonction interne HLStoRGB)
-#-----------------------------------------------------------------------------------
-sub hlsValue {
- my ($q1, $q2, $hue) = @_;
- my $value;
-
- $hue = &r_modp($hue, 360);
-
- if ($hue < 60) {
- $value = $q1 + ($q2 - $q1) * $hue / 60;
-
- } elsif ($hue < 180) {
- $value = $q2;
-
- } elsif ($hue < 240) {
- $value = $q1 + ($q2 - $q1) * (240 - $hue) / 60;
-
- } else {
- $value = $q1;
-
- }
-
- return $value;
-
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::hexaRGBcolor
-# conversion d'une couleur RGB (255,255,255) au format Zinc '#ffffff'
-#-----------------------------------------------------------------------------------
-sub hexaRGBcolor {
- my ($r, $g, $b, $a) = @_;
-
- if (defined $a) {
- my $hexacolor = sprintf("#%02x%02x%02x", ($r, $g, $b));
- return ($hexacolor.";".$a);
- }
-
- return (sprintf("#%02x%02x%02x", ($r, $g, $b)));
-}
-
-
-
-sub hexa2RGB {
- my ($hexastr) = @_;
- my ($r, $g, $b);
-
- if ($hexastr =~ /(\w\w)(\w\w)(\w\w)/) {
- $r = hex($1);
- $g = hex($2);
- $b = hex($3);
-
- return [$r/255, $g/255, $b/255] if (defined $r and defined $g and defined $b);
-
- }
-
- return undef;
-}
-
-#-----------------------------------------------------------------------------------
-# Graphics::max
-# renvoie la valeur maximum d'une liste de valeurs
-#-----------------------------------------------------------------------------------
-sub max {
- my (@values) = @_;
- return undef if !scalar(@values);
-
- my $max = undef;
-
- foreach my $val (@values) {
- if (!defined $max or $val > $max) {
- $max = $val;
- }
- }
-
- return $max;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::min
-# renvoie la valeur minimum d'une liste de valeurs
-#-----------------------------------------------------------------------------------
-sub min {
- my (@values) = @_;
- return undef if !scalar(@values);
-
- my $min = undef;
-
- foreach my $val (@values) {
- if (!defined $min or $val < $min) {
- $min = $val;
- }
- }
-
- return $min;
-}
-
-
-#-----------------------------------------------------------------------------------
-# Graphics::r_modp
-# fonction interne : renvoie le résultat POSITIF du modulo m d'un nombre x
-#-----------------------------------------------------------------------------------
-sub r_modp {
- my ($x, $m) = @_;
-
- return undef if $m == 0;
-
- my $value = $x%$m;
-
- if ($value < 0.0) {
- $value = $value + abs($m);
- }
-
- return $value;
-
-}
-
-
-1;
-
-
-__END__
-
diff --git a/Perl/Zinc/Graphics.pod b/Perl/Zinc/Graphics.pod
deleted file mode 100644
index 579b6d7..0000000
--- a/Perl/Zinc/Graphics.pod
+++ /dev/null
@@ -1,1749 +0,0 @@
-
-=head1 NAME
-
-Graphics : module Perl facilitant la creation d'objets graphiques complexes
-par une description simplifiee.
-
-
-=head1 SYNOPSIS
-
-use Graphics;
-
-&GraphicsFunction(@params, ?option => value?, ...);
-
-=head1 DESCRIPTION
-
-Z<>
-
-=head2 Fonctions exportées
-
-=head3 1. Création de composants graphiques
-
-=over
-
-=item B<o> buildZincItem(Z<>)
-
-=item B<o> repeatZincItem(Z<>)
-
-=item B<o> buildTabBoxItem(Z<>)
-
-=back
-
-=head3 2. Calculs de formes géométriques complexes
-
-=over
-
-=item B<o> roundedRectangleCoords(Z<>)
-
-=item B<o> hippodromeCoords(Z<>)
-
-=item B<o> ellipseCoords(Z<>)
-
-=item B<o> roundedCurveCoords(Z<>)
-
-=item B<o> polygonCoords(Z<>)
-
-=item B<o> polylineCoords(Z<>)
-
-=item B<o> curveLineCoords>(Z<>)
-
-=item B<o> pathLineCoords(Z<>)
-
-=item B<o> shiftPathCoords(Z<>)
-
-=item B<o> tabBoxCoords(Z<>)
-
-=back
-
-=head3 3. Création de relief et ombre portée
-
-=over
-
-=item B<o> graphicItemRelief(Z<>)
-
-=item B<o> graphicItemShadow(Z<>)
-
-=back
-
-=head3 4. Fonctions géométriques de base
-
-=over
-
-=item B<o> perpendicularPoint(Z<>)
-
-=item B<o> lineAngle(Z<>)
-
-=item B<o> vertexAngle(Z<>)
-
-=item B<o> arc_pts(Z<>)
-
-=item B<o> rad_point(Z<>)
-
-=item B<o> bezierCompute(Z<>)
-
-=item B<o> bezierSegment(Z<>)
-
-=item B<o> bezierPoint(Z<>)
-
-=back
-
-=head3 5. Gestion des ressources images
-
-=over
-
-=item B<o> getPattern(Z<>)
-
-=item B<o> getTexture(Z<>)
-
-=item B<o> getImage(Z<>)
-
-=item B<o> init_pixmaps(Z<>)
-
-=back
-
-=head3 6. Gestion des couleurs
-
-=over
-
-=item B<o> setGradiants(Z<>)
-
-=item B<o> zincItemPredominantColor(Z<>)
-
-=item B<o> ZnColorToRGB(Z<>)
-
-=item B<o> hexaRGBcolor(Z<>)
-
-=item B<o> createGraduate(Z<>)
-
-=item B<o> MedianColor(Z<>)
-
-=item B<o> LightingColor(Z<>)
-
-=item B<o> RGBtoLCH(Z<>)
-
-=item B<o> LCHtoRGB(Z<>)
-
-=item B<o> RGBtoHLS(Z<>)
-
-=item B<o> HLStoRGB(Z<>)
-
-=back
-
-Z<>
-
-=head2 1. Création de composants graphiques
-
-
-=over
-
-=item B<buildZincItem>(widget, parentgroup, options);
-
-Creation d'items de representations Zinc.
-Les objets graphiques generes peuvent etre complexes (geometrie, multi contours,
-operateur de forme, empilage d'items, reliefs, ombre portee, repetition,
-transformations...) mais sont decrits par des
-options geometriques ou de surfacage 2D 1/2 de haut niveau.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-<widget> identifiant du widget zinc.
-
-=item B<parentgroup>
-
-<tagOrId> identifiant de l'item group parent.
-
-
-=back
-
-
-=item B<Options> :
-
-
-=over
-
-=item B<-itemtype> => type
-
-Specifie le(s) type(s) d'item(s) souhaite(s). Peut etre celui d'un item
-natif zinc (B<group>, B<rectangle>, B<arc>, B<curve>, B<text>, B<icon>),
-ou un B<'metatype'> permettant de specifier des curves 'particulieres'. Les sections coniques
-de ces metatypes (raccords ou arcs) seront simulees par des segments quadratiques de bezier. Ces metatypes sont :
-
-=over
-
-=item roundedrectangle
-
-decrit par 2 cordonnees (haut-gauche et bas-droite du rectangle) et un rayon de raccord angulaire.
-Une liste optionnelle de realisation des raccords [0 = sans raccord|1 = avec raccord] permet de specifier pour chaque angle le type de raccord
-(angle ou arc).
-
-=item hippodrome
-
-decrit par 2 cordonnees (haut-gauche et bas-droite du rectangle englobant).
-Si l'orientation n'est pas specifiee, le rayon de raccord sera egal a la moitie du plus petit cote .
-Une liste optionnelle de realisation des raccords permet de specifier pour chaque angle le type de raccord
-(angle ou arc).
-
-=item ellipse
-
-decrit par 2 cordonnees (haut-gauche et bas-droite du rectangle englobant).
-Une liste optionnelle de realisation des raccords permet de specifier pour chaque angle le type de raccord
-(angle ou arc).
-
-=item polygone
-
-polygone regulier a n cotes, (triangle equilateral, carre, pentagone, hexagone...)
-convexe ou en etoile. Le polygone sera inscrit dans un cercle dont le rayon est passe en parametres
-(un 2eme rayon 'interne' decrira un polygone etoile). Un rayon de raccord et une liste de realisation des raccords permettent
-des variantes interressantes.
-
-=item roundedcurve
-
-curve multicontours a coins arrondis, de rayon raccord unique,
-pour specifier une forme quelconque.
-
-=item polyline
-
-curve multicontours a coins arrondis. Le rayon de chaque raccord pouvant etre defini
-specifiquement.
-
-=item pathline
-
-creation d'une ligne multisegments 'epaisse',
-realisee par 'decalage' par rapport a un path donne (largeur et sens de decalage
- [left|both|right] optionnels). Le contour transforme en surface avec l'item Zinc triangles
-permet d'appliquer un degrade de couleurs le long du trace (lineaire, transversal ou double).
-
-=back
-
-
-=item B<-coords> => \@xy
-
-<coords list> coordonnees geometriques ou de position de l'item.
-
-=item B<-metacoords> => \%metatype_params
-
-<hashtable> calcul des coordonnées de l'item par passage d'un [meta]type d'item
-différent de celui décrit par -itemtype. (ex. un pathline défini par un polygone)
-
-<coords list> coordonnees geometriques ou de position de l'item.
-
-=item B<-params> => \%zinc_attr
-
-<hashtable> parametres zinc de l'item.
-
-=item B<-contours> => \@list
-
-<contours list> arguments zinc d'ajout de contours .
-
-=item B<-clip>
-
-<coords list or hashtable> clipping d'un item group.
-
-=item B<-items>
-
-<hashtable> table d'items contenus dans un item group.
-provoque un appel récursif de la fonction buildZincItem().
-
-=item B<-texture>
-
-<imagefile> ajout d'une texture a l'item.
-
-=item B<-pattern>
-
-<imagefile> ajout d'un pattern a l'item.
-
-=item B<-relief>
-
-<hash table> creation d'un relief a l'item a l'aide d'item zinc triangles.
-Invoque la fonction du module Graphics graphicItemRelief()
-
-=item B<-shadow>
-
-<hash table> creation d'une ombre portee a l'item.
-Invoque la fonction du module Graphics graphicItemShadow()
-
-=item B<-repeat>
-
-<hash table> repetition de l'item.
-Invoque la fonction du module Graphics repeatZincItem()
-
-=item B<-scale> => scale factor or [xscale, yscale]
-
-application d'une transformation zinc->scale a l'item
-
-=item B<-translate> => [dx,dy]
-
- application d'une transformation zinc->translate a l'item
-
-=item B<-rotate> => <angle> (en degré)
-
-application d'une transformation zinc->rotate a l'item
-
-=item B<-addtags>
-
-<tags list> liste de tags specifiques a ajouter aux parametre item -tags.
-
-=item B<-name>
-
-<string> nom de l'item.
-
-=back
-
-=back
-
-Z<>
-
-=item B<repeatZincItem>(widget, item, options);
-
-Répétition (clonage) d'un objet Zinc de representation.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-<widget> identifiant du widget zinc.
-
-=item B<item>
-
-<tagOrId> identifiant de l'item zinc a dupliquer.
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-num> => integer
-
-Nombre de répétitions.
-
-=item B<-dxy> => [dx, dy]
-
-Paramètres de translation a appliquer entre 2 copies.
-
-=item B<-angle> => <angle>
-
-angle de rotation en degré a appliquer entre 2 copies.
-
-=item B<-copytag> => <tag name>
-
-ajout d'un tag indexé pour chaque copie.
-
-=item B<-params> => \%zinc_attr
-
-Paramétrage specialises de chaque copie
-
-
-=back
-
-=back
-
-Z<>
-
-=item B<buildTabBoxItem>(widget, parentgroup, options);
-
-Construit les items de représentation d'une boîte à onglets multi-pages.
-Le positionnement, la forme et la taille des onglets est définie automatiquement
-ou spécifiés par options. L'ajout de titres aux pages est possible. Des tags
-de base (intercalaires et titres) permettent de définir des interactions de
-sélection/navigation par bindings.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-<widget> identifiant du widget zinc.
-
-=item B<parentgroup>
-
-<tagOrId> identifiant de l'item group parent.
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-coords> => [[x0,y0],[x1,y1]]
-
-<coords> coordonnées haut-gauche et bas-droite de la BoundingBox du tabBox.
-
-=item B<-numpages>
-
-<integer> nombre de pages du TabBox.
-
-=item B<-anchor> => 'n'|'e'|'s'|'w'
-
-ancrage nord, est, sud ou ouest des onglets (par défaut 'n')
-
-=item B<-alignment> => 'left'|'center'|'right'
-
-alignement gauche, centré ou droit des onglets sur l'ancrage (par défaut left)
-
-=item B<-tabwidth> => 'auto'|<dimension>|<dimensionList>
-
-longeur des onglets : 'auto' longeur répartie sur le coté, longeur absolue ou liste de longeurs
-ces dimensions sont autoajustées si dépassement. (par défaut 'auto').
-
-=item B<-tabheight> => 'auto'|<dimension>
-
-hauteur des onglets (par défaut 'auto')
-
-=item B<-tabshift> => 'auto'|<dimension>
-
-offset de biseau entre la base et le haut de l'onglet (par défaut 'auto').
-
-=item B<-overlap> => 'auto'|<dimension>
-
-offset de décalage entre 2 onglets (par défaut 'auto').
-
-=item B<-radius>
-
-<dimension> rayon des arrondis d'angle des onglets. (par défaut 0)
-
-=item B<-corners>
-
-<booleanList> liste d'application du raccord aux angles sous forme booleenne
-0 = sans raccord 1 = avec raccord.
-
-=item B<-params> => \%zinc_attr
-
-<hashtable> parametres zinc de l'item.
-
-=item B<-texture>
-
-<imagefile> ajout d'une texture a l'item.
-
-=item B<-relief>
-
-<hash table> creation d'un relief pour les pages du tabBox.
-Invoque la fonction du module Graphics graphicItemRelief()
-
-=item B<-tabtitles>
-
-<hashtable> table de hash de définition des titres d'onglets (label, params).
-
-=item B<-pageitems>
-
-<hashtable> table d'items 'complémentaire' à réaliser pour chaque page.
-provoque un appel récursif de la fonction buildZincItem().
-
-
-=back
-
-=back
-
-=back
-
-Z<>
-
-=head2 2. Calculs de formes géométriques complexes
-
-=over
-
-=item B<roundedRectangleCoords>(coords, options);
-
-Retourne les coordonnées (curve) d'un rectangle à coins arrondis
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [[x0,y0],[x1,y1]]
-
-<coordList> coordonnées haut-gauche et bas-droite du rectangle.
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-radius>
-
-<dimension> rayon de raccord circulaire des angles.
-
-=item B<-corners> => \@cornersList
-
-Liste de réalisation des raccords de sommets [0 = pad de raccord (droit)| 1 = raccord circulaire].
-(par défaut [1,1,1,1]).
-
-=back
-
-=back
-
-Z<>
-
-=item B<hippodromeCoords>(coords, options);
-
-Retourne les coordonnées (curve) d'un hippodrome
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [[x0,y0],[x1,y1]]
-
-<coordList> coordonnées haut-gauche et bas-droite du rectangle exinscrit à l'hippodrome.
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-orientation> => <horizontal|vertical>
-
-orientation forcée de l'hippodrome (sinon hauteur = plus petit coté).
-
-=item B<-corners> => \@cornersList
-
-Liste de réalisation des raccords de sommets [0 = pad de raccord (droit)| 1 = raccord circulaire].
-(par défaut [1,1,1,1]).
-
-=item B<-trunc> => <left|right|top|bottom|both>
-
-troncatures des cotés circulaires de l'hippodrome.
-
-=back
-
-=back
-
-Z<>
-
-=item B<ellipseCoords>(coords, options);
-
-Retourne les coordonnées (curve) d'une ellipse
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [[x0,y0],[x1,y1]]
-
-<coordList> coordonnées haut-gauche et bas-droite du rectangle exinscrit.
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-corners> => \@cornersList
-
-Liste de réalisation des quadrants [0 = angle droit| 1 = raccord d'ellipse].
-(par défaut [1,1,1,1]).
-
-=back
-
-=back
-
-Z<>
-
-=item B<roundedCurveCoords>(coords, options);
-
-Retourne les coordonnées d'une curve à coins arrondis.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [[x0,y0],...[xn,yn]]
-
-<coordList> coordonnées de la curve
-
-=back
-
-=item B<Options> :
-
-=over
-
-B<-radius> : <dimension>
-rayon de raccord des angles. par defaut 0
-
-B<-corners> : <booleanList>
-liste d'application du raccord circulaire aux angles sous forme booleenne
-0 = sans raccord 1 = avec raccord. par defaut [1,1,...,1].
-
-=back
-
-=back
-
-Z<>
-
-=item B<polygonCoords>(coords, options);
-
-Retourne les coordonnées d'un polygone régulier à n cotés ou d'une étoile à
-n branches. Le polygone sera inscrit dans un cercle de rayon -radius, un 2ème
-rayon interne décrira les sommets interne de l'étoile. Raccords circulaires
-optionnels des sommets du polygone/étoile
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [x0,y0]
-
-<coords> coordonnées du centre du cercle exinscrit au polygone/étoile
-
-=back
-
-=item B<Options> :
-
-=over
-
-B<-numsides> : <dimension> nombre de cote du polygone ou nombre de branches de l'etoile
-
-B<-radius> : <dimension> rayon du cercle exinscrit au polygone
-
-B<-startangle> : <angle> angle de depart du trace de la figure
-
-B<-inner_radius> : <dimension> rayon du cercle des points 'internes' de l'etoile
-
-B<-corner_radius> : <dimension> rayon des raccords d'angles
-
-B<-corners> : <booleanList> liste d'application du raccord aux angles sous forme booleenne
-0 = sans raccord 1 = avec raccord. par defaut [1,1,1,1].
-
-=back
-
-=back
-
-Z<>
-
-=item B<polylineCoords>(coords, options);
-
-Retourne les coordonnées d'une polyline, ligne 'brisée' multi-segments
-avec raccords angulaires optionnels.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [[x0,y0],...[xn,yn]]
-
-<coordList> liste de coordonnées des sommets de la polyline
-
-=back
-
-=item B<Options> :
-
-=over
-
-B<-radius> : <dimension>
-rayon global de raccord des angles. par defaut 0
-
-B<-corners> : <booleanList>
-liste d'application du raccord circulaire aux angles sous forme booleenne
-0 = sans raccord 1 = avec raccord. par defaut [1,1,...,1].
-
-B<-corners_radius> : <dimensionList>
-Liste des rayons de raccord des angles.
-
-=back
-
-=back
-
-Z<>
-
-=item B<curveLineCoords>(coords, options);
-
-ATTENTION FONCTION EN CHANTIER
-
-Retourne les coordonnées curve (de surface) d'un stroke. la ligne est décrite
-le long d'un chemin et dessinée selon les attributs graphiques classiques 'stroke'
-(style d'épaisseur, d'extremité, de jointure, de tiret...)
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [[x0,y0],...[xn,yn]]
-
-<coordList> coordonnées de la curve
-
-=back
-
-=item B<Options> :
-
-=over
-
-B<-width> : <dimension>
-épaisseur de la ligne. par defaut 1
-
-B<-linecap> : <'butt'|'round'|'square'>
-Forme des extrémités des tracés ouverts.
-
-B<-linejoin> : <'miter'|'round'|'bevel'>
-Forme des sommets des tracés.
-
-B<-dasharray> : <'none'|motifList>
-Spécification du tireté : none (aucun) ou liste de longueurs tiret,[espace],[tiret]...
-permettant de définir le dessin du tireté (par défaut none)
-
-B<-dashoffset> : <dimension>
-distance décalage de départ dans le dessin du tireté (par défaut 0)
-
-=back
-
-=back
-
-Z<>
-
-=item B<pathLineCoords>(coords, %options);
-
-retourne les coordonnées (triangles) d'une ligne multisegments 'epaisse',
-realisee par 'décalage' par rapport à un path donné (largeur et sens de décalage
- [out|center|in] optionnels).
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [[x0,y0],...[xn,yn]]
-
-<coordList> liste de coordonnées du path
-
-=back
-
-=item B<Options> :
-
-=over
-
-B<-closed> : <boolean>
-fermeture du tracé. par defaut 0
-
-B<-shifting> : <'out'|'center'|'in'>
-sens de décalage de l'épaisseur de contour : 'center' (1/2 décalage de chaque coté du path) 'out' (décalage externe) 'in' (décalage interne) par défaut 'center'.
-
-B<-width> : <dimension>
-Largeur du décalage de ligne (par défaut 2).
-
-=back
-
-=back
-
-Z<>
-
-=item B<shiftPathCoords>(coords, %options);
-
-retourne les coordonnées curve de 'décalage' par rapport à un path donné.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [[x0,y0],...[xn,yn]]
-
-<coordList> liste de coordonnées du path
-
-=back
-
-=item B<Options> :
-
-=over
-
-B<-closed> : <boolean>
-fermeture du tracé. par defaut 0
-
-B<-shifting> : <'out'|'in'>
-sens de décalage du path : 'out' (décalage externe) 'in' (décalage interne) par défaut 'out'.
-
-B<-width> : <dimension>
-Largeur du décalage de ligne (par défaut 1).
-
-=back
-
-=back
-
-Z<>
-
-=item B<tabBoxCoords>(coords, options);
-
-Retourne les coordonnées de construction d'un TabBox (boîte à onglets) : liste de curve décrivant les 'pages' du TabBox et coordonnées de position des titres onglets.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords> => [[x0,y0],[x1,y1]]
-
-<coords> coordonnées haut-gauche et bas-droite de la BoundingBox du tabBox.
-
-=back
-
-=item B<Options> :
-
-=over
-
-B<-numpages> : <integer> nombre de pages du TabBox.
-
-B<-anchor> : <'n'|'e'|'s'|'w'> ancrage nord, est, sud ou ouest des onglets (par défaut 'n')
-
-B<-alignment> : <'left'|'center'|'right'> alignement gauche, centré ou droit des onglets sur l'ancrage (par défaut left)
-
-B<-tabwidth> : 'auto'|<dimension|dimensionList> longeur des onglets : 'auto' longeur répartie sur le coté, longeur absolue ou liste de longeurs
-ces dimensions sont autoajustées si dépassement. (par défaut 'auto').
-
-B<-tabheight> : 'auto'|<dimension> hauteur des onglets (par défaut 'auto')
-
-B<-tabshift> : 'auto'<dimension> offset de biseau entre la base et le haut de l'onglet (par défaut 'auto').
-
-B<-overlap> : 'auto'<dimension> offset de décalage entre 2 onglets (par défaut 'auto').
-
-B<-radius> : <dimension>
-rayon des arrondis d'angle des onglets. (par défaut 0)
-
-B<-corners> : <booleanList> liste d'application du raccord aux angles sous forme booleenne
-0 = sans raccord 1 = avec raccord.
-
-=back
-
-=back
-
-=back
-
-Z<>
-
-=head2 3. Création de reliefs et ombre portée
-
-Z<>
-
-=over
-
-=item B<graphicItemRelief>(widget, item, %options);
-
-Construit un relief à l'item géometrique
-(qui peut etre multicontours) en utilisant des items zinc triangles.
-Ce relief de type 'embossage' de forme possede un
-profil (flat ou rounded) et dérive en luminosite la couleur dominante
-de l'item (ou une couleur donnée) suivant l'orientation d'éclairage global zinc
--lighangle (ou un angle de lumière donné).
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-identifiant du widget zinc.
-
-=item B<item>
-
-identifiant de l'item zinc à mettre en relief.
-
-=back
-
-=item B<Options> :
-
-=over
-
-B<-closed> : <boolean> fermeture (de forme) du relief (par défaut 1).
-
-B<-profil> : <'flat'|'rounded'> type de profil du relief (par défaut 'rounded').
-
-B<-relief> : <'raised'|'sunken'> sens de l'embossage (par defaut 'raised').
-
-B<-side> : <outside|inside> position externe ou interne du relief (defaut 'inside').
-
-B<-color> : <color> couleur de base du relief (défaut couleur dominante de l'item).
-
-B<-smoothed> : <boolean> lissage des 'facettes' du relief (par defaut 1).
-
-B<-lightangle> : <angle> angle de la lumiere (par defaut attribut -lightangle du widget).
-
-B<-width> : <dimension> largeur du 'contour' relief.
-
-B<-fine> : <boolean> mode precision courbe de bezier (par defaut 0 : auto-ajustee).
-
-=back
-
-=back
-
-Z<>
-
-=item B<graphicItemShadow>(widget, item, %options);
-
-Cree une ombre portee a l'item geometrique
-(qui peut etre multicontours) en utilisant des items zinc triangles et curve.
-Cette ombre correspond a une projection de la forme en fonction
-d'une distance (par defaut 10) d'une orientation lumineuse (par defaut la valeur
-globale -lightangle du widget) et d'un 'grossissement' (par defaut 0).
-Une largeur 'width' de perimetre de diffusion/diffraction lumineuse (par defaut 4)
-qui permet de lisser le passage de l'ombre au fond, une couleur (par defaut black)
-et une opacite (par defaut 50) completent la specification.
-
-=over
-
-B<Parametres> :
-
-=over
-
-B<widget> : <widget> identifiant du widget zinc
-
-B<item> : <tagOrId> identifiant de l'item zinc
-
-=back
-
-B<Options> :
-
-=over
-
-B<-opacity> : <percent> poucentage d'opacite de l'ombre (par defaut 50).
-
-B<-distance> : <dimension> distance de projection de l'ombre (par defaut 10).
-
-B<-enlarging> : <dimension> 'grossissement' cone de projection (defaut 0).
-
-B<-color> : <color> couleur de l'ombre (par defaut black).
-
-B<-lightangle> : <angle> angle de la lumiere (par defaut attribut -lightangle du widget).
-
-B<-width> : <dimension> largeur du perimetre de diffusion/diffraction (par defaut 4).
-
-=back
-
-=back
-
-=back
-
-Z<>
-
-=head2 4. Fonctions géométriques de base
-
-Z<>
-
-=over
-
-=item B<perpendicularPoint>(point, line);
-
-retourne les coordonnées du point perpendiculaire abaissé d'un point sur une ligne.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<point> => [x, y]
-
-<coords> coordonnées du point de référence.
-
-=item B<line> => [[x0, y0],[x1, y1]]
-
-<coordsList> liste de coordonnées des deux points de la ligne de référence.
-
-=back
-
-=back
-
-Z<>
-
-
-=item B<lineAngle>(startpoint, endpoint);
-
-retourne l'angle formée par un vecteur, s'utilise aussi pour connaitre l'angle 'circulaire'
-d'un point par rapport à un centre de référence.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<startpoint> => [x, y]
-
-<coords> coordonnées du point de départ du segment (ou centre de référence).
-
-=item B<endpoint> => [x, y]
-
-<coords> coordonnées du point de fin du segment (ou point 'circulaire' de référence).
-
-=back
-
-=back
-
-Z<>
-
-=item B<lineNormal>(startpoint, endpoint);
-
-retourne la valeur d'angle perpendiculaire à un vecteur (utilisée par exemple
-pour mesurer l'incidence de lumière d'une facette).
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<startpoint> => [x, y]
-
-<coords> coordonnées du point de départ du segment (ou centre de référence).
-
-=item B<endpoint> => [x, y]
-
-<coords> coordonnées du point de fin du segment (ou point 'circulaire' de référence).
-
-=back
-
-=back
-
-Z<>
-
-=item B<vertexAngle>(point0, point1, point2);
-
-retourne la valeur de l'angle formé par trois points ainsi que la valeur d'angle
-de la bisectrice de l'angle (fonction utilisé pour les calculs de décalages de path.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<point0> => [x, y]
-
-<coords> coordonnées du premier point de définition de l'angle.
-
-=item B<point1> => [x, y]
-
-<coords> coordonnées du deuxième point de définition de l'angle (sommet).
-
-=item B<point2> => [x, y]
-
-<coords> coordonnées du troisième point de définition de l'angle.
-
-
-=back
-
-=back
-
-Z<>
-
-=item B<arc_pts>(center, radius, %options);
-
-Calcul des points constitutifs d'un arc
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<center> => [x0,y0]
-
-<coords> coordonnées du centre de l'arc.
-
-=item B<radius>
-
-<dimension> rayon de l'arc.
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-angle>
-
-<angle> angle de départ (en degré) de l'arc (par défaut 0)
-
-=item B<-extent>
-
-<angle> delta angulaire (en degré) de l'arc (par défaut 360)
-
-=item B<-step>
-
-<angle> pas de progression angulaire (en degré) de calcul des points (par défaut 10).
-
-=back
-
-=back
-
-Z<>
-
-=item B<rad_point>(center, radius, angle);
-
-Retourne le point circulaire défini par centre-rayon-angle.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<center> => [x0,y0]
-
-<coords> coordonnées du centre de l'arc.
-
-=item B<radius>
-
-<dimension> rayon de l'arc.
-
-=item B<angle>
-
-<angle> angle (en degré) du point de circonférence avec le centre du cercle.
-
-=back
-
-=back
-
-Z<>
-
-=item B<bezierSegment>(coords, %options);
-
-Calcul d'une approximation de segment (Quadratique ou Cubique) de bezier.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords>
-
-<coordsList> Liste de coordonnées des points définissant le segment de bezier.
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-tunits>
-
-<integer> nombre pas de division des segments bezier (par défaut 20)
-
-=item B<-skipend>
-
-<boolean> ne pas retourner le dernier point du segment (pour chaînage de segments).
-
-=back
-
-=back
-
-Z<>
-
-=item B<bezierPoint>(t, coords);
-
-Calcul d'un point du segment (Quadratique ou Cubique) de bezier.
-t représentation du temps (de 0 à 1).
-coords = (P1, C1, <C1>, P2) liste des points définissant le segment de bezier
-P1 et P2 : extémités du segment et pts situés sur la courbe
-C1 <C2> : point(s) de contrôle du segment
-
-courbe bezier niveau 2 sur (P1, P2, P3) P(t) = (1-t)²P1 + 2t(1-t)P2 + t²P3
-
-courbe bezier niveau 3 sur (P1, P2, P3, P4) P(t) = (1-t)³P1 + 3t(1-t)²P2 + 3t²(1-t)P3 + t³P4
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<t>
-
-<pourcent> (de 0 à 1) représentation du temps.
-
-=item B<coords>
-
-<coordsList> Liste de coordonnées des points définissant le segment de bezier.
-
-=back
-
-=back
-
-Z<>
-
-
-=item B<bezierCompute>(coords, %options);
-
-Calcul d'une approximation auto-ajustée de segment (Quadratique ou Cubique) de bezier.
-l'approximation se fait par subdivision successive de la courbe jusqu'à atteindre une
-distance avec la courbe théorique <= à la précision passée par option (par défaut 0.2).
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<coords>
-
-<coordsList> Liste de coordonnées des points définissant le segment de bezier.
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-precision>
-
-<dimension> seuil limite du calcul d'approche de la courbe (par défaut .2)
-
-=item B<-skipend>
-
-<boolean> ne pas retourner le dernier point du segment (pour chaînage de segments).
-
-=back
-
-=back
-
-=back
-
-Z<>
-
-=head2 5. Gestion des ressources images
-
-Z<>
-
-=over
-
-=item B<getPattern>(filename, %options);
-
-retourne et partage la ressource image bitmap en l'initialisant et la stockant si première utilisation.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<filename>
-
-<image filename> non du fichier bitmap pattern
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-storage>
-
-<hashtable> référence de la table de stockage privée des patterns.
-
-=back
-
-=back
-
-Z<>
-
-=item B<getTexture>(widget, filename, %options);
-
-retourne et partage la ressource image texture en l'initialisant et la stockant si première utilisation.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-<widget> identifiant du widget zinc.
-
-=item B<filename>
-
-<imagefile> non du fichier image texture
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-storage>
-
-<hashtable> référence de la table de stockage privée des textures.
-
-=back
-
-=back
-
-Z<>
-
-=item B<getImage>(widget, filename, %options);
-
-retourne et partage la ressource image en l'initialisant et la stockant si première utilisation.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-<widget> identifiant du widget zinc.
-
-=item B<filename>
-
-<imagefile> non du fichier image
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-storage>
-
-<hashtable> référence de la table de stockage privée des images.
-
-=back
-
-=back
-
-Z<>
-
-=item B<init_pixmaps>(widget, filenames, %options);
-
-Initialise et stocke un ensemble d'images.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-<widget> identifiant du widget zinc.
-
-=item B<filenames>
-
-<imagefileList> Liste des fichier images à initialiser.
-
-=back
-
-=item B<Options> :
-
-=over
-
-=item B<-storage>
-
-<hashtable> référence de la table de stockage privée des images.
-
-=back
-
-=back
-
-=back
-
-Z<>
-
-=head2 6. Gestion des couleurs
-
-Z<>
-
-=over
-
-=item B<setGradients>(widget, gradients);
-
-Création de gradiants nommés Zinc
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-<widget> identifiant du widget Zinc
-
-=item B<gradients>
-
-<hashtable> référence de la table de définition des gradiants zinc ('non' => 'zincGradient').
-
-=back
-
-=back
-
-Z<>
-
-=item B<zincItemPredominantColor>(widget, item);
-
-retourne la couleur dominante d'un item ('barycentre' gradiant fillcolor).
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-<widget> identifiant du widget Zinc
-
-=item B<item>
-
-<tagOrId> identifiant de l'item zinc.
-
-=back
-
-=back
-
-Z<>
-
-=item B<medianColor>(color1, color2, rate);
-
-calcul d'une couleur intermédiaire défini par un ratio ($rate) entre 2 couleurs.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<color1>
-
-<color> première couleur
-
-=item B<color2>
-
-<color> première couleur
-
-=item B<rate>
-
-<pourcent> (de 0 à 1) position de la couleur intermédiaire.
-
-=back
-
-=back
-
-Z<>
-
-=item B<createGraduate>(widget, steps, refcolors, repeat);
-
-création d'un jeu de couleurs intermédiaires (dégradé) entre n couleurs.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<widget>
-
-<widget> identifiant du widget Zinc
-
-=item B<steps>
-
-<integer> nombre totale de couleurs retournées.
-
-=item B<refcolors>
-
-<colorList> liste de couleurs servant à créer le dégradé.
-
-=item B<repeat>
-
-<integer> répétition de chaque couleur utilisé par exemple pour triangles path
-où la couleur est répétée 2 fois (par défaut 1).
-
-=back
-
-=back
-
-Z<>
-
-=item B<lightingColor>(color, newL);
-
-Modification d'une couleur par sa composante luminosité (exemple relief).
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<color>
-
-<color> couleur au format zinc.
-
-=item B<newL>
-
-<pourcent> (de 0 à 1) nouvelle valeur de luminosité.
-
-=back
-
-=back
-
-Z<>
-
-=item B<ZnColorToRGB>(zncolor);
-
-conversion d'une couleur Zinc hexa au format RGBA (255,255,255,100).
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<zncolor>
-
-<color> couleur au format hexa zinc (#ffffff ou #ffffffffffff).
-
-=back
-
-=back
-
-Z<>
-
-=item B<RGBtoLCH>(r, g, b);
-
-conversion d'une couleur de l'espace RGB à l'espace CIE LCH°.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<r>
-
-<pourcent> (de 0 à 1) valeur de la composante rouge de la couleur RGB.
-
-=item B<g>
-
-<pourcent> (de 0 à 1) valeur de la composante verte de la couleur RGB.
-
-=item B<b>
-
-<pourcent> (de 0 à 1) valeur de la composante bleue de la couleur RGB.
-
-=back
-
-=back
-
-Z<>
-
-=item B<LCHtoRGB>(L, C, H);
-
-conversion d'une couleur de l'espace CIE LCH° à l'espace RGB.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<L>
-
-<pourcent> (de 0 à 1) valeur de la composante luminosité de la couleur CIE LCH.
-
-=item B<C>
-
-C : <pourcent> (de 0 à 1) valeur de la composante saturation de la couleur CIE LCH
-
-=item B<H>
-
-H : <pourcent> (de 0 à 1) valeur de la composante teinte de la couleur CIE LCH
-
-=back
-
-=back
-
-Z<>
-
-=item B<RGBtoHLS>(r, g, b);
-
-conversion d'une couleur de l'espace RGB à l'espace HLS.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<r>
-
-<pourcent> (de 0 à 1) valeur de la composante rouge de la couleur RGB.
-
-=item B<g>
-
-<pourcent> (de 0 à 1) valeur de la composante verte de la couleur RGB.
-
-=item B<b>
-
-<pourcent> (de 0 à 1) valeur de la composante bleue de la couleur RGB.
-
-=back
-
-=back
-
-Z<>
-
-=item B<HLStoRGB>(H, L, S);
-
-conversion d'une couleur de l'espace HLS à l'espace RGB.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<H>
-
-<pourcent> (de 0 à 1) valeur de la composante teinte de la couleur HLS.
-
-=item B<L>
-
-C : <pourcent> (de 0 à 1) valeur de la composante luminosité de la couleur HLS.
-
-=item B<S>
-
-H : <pourcent> (de 0 à 1) valeur de la composante saturation de la couleur HLS.
-
-=back
-
-=back
-
-Z<>
-
-=item B<hexaRGBcolor>(r, g, b, a);
-
-conversion d'une couleur RGBA (255,255,255,100) au format Zinc '#ffffff'.
-
-=over
-
-=item B<Parametres> :
-
-=over
-
-=item B<r>
-
-<colorComposant> (0 à 255) composante rouge de la couleur rgba.
-
-=item B<g>
-
-<colorComposant> (0 à 255) composante verte de la couleur rgba.
-
-=item B<b>
-
-<colorComposant> (0 à 255) composante bleue de la couleur rgba.
-
-=item B<a>
-
-<colorComposant> (0 à 255) composante alpha de la couleur rgba.
-
-=back
-
-=back
-
-Z<>
-
-=back
-
-Z<>
-
-
-=head1 EXEMPLE
-
-my %gradset = (
- 'gdlens' => '=radial -15 -20|#ffb7b7;70|#bd6622;90',
- 'gdstar' => '=radial -15 -20|#ffb7b7;50|#bd6622;90');
-
-my %starstyle => (
- # table hash parametres et options
- -itemtype => 'group',
- -coords => [250, 250],
- -params => {-priority => 90,
- -tags => ['starlens', 'move'],
- -sensitive => 1,
- -atomic => 1,
- },
- -items => {
- 'lens' => {-itemtype => 'hippodrome',
- -coords => [[-200, -200],
- [200, 200]],
- -params => {-closed => 1,
- -filled => 1,
- -fillcolor => 'gdlens',
- -linewidth => 1.5,
- -linecolor => '#440000',
- -priority => 10,
- },
- -relief => {-width => 14,
- -profil => 'rounded',
- -lightangle => 135,
- },
- -shadow => {-distance => 20,
- -width => 18,
- -lightangle => 135,
- -opacity => 40,
- -enlarging => 6,
- },
- },
- 'star' => {-itemtype => 'polygone',
- -coords => [0, 0],
- -numsides => 5,
- -radius => 180,
- -inner_radius => 70,
- -corner_radius => 10,
- -startangle => 270,
- -corners => [0,1,0,1,0,1,0,1,0,1],
- -params => {-filled => 1,
- -fillcolor => 'gradstar',
- -linewidth => 1,
- -linecolor => '#330000',
- -priority => 20,
- },
- -relief => {-width => 10,
- -profil => 'rounded',
- -side => 'outside',
- -relief => 'sunken',
- },
- },
- },
- );
-
-
-&setGradients($widget, \%gradset);
-
-my $star = &buildZincItem($zinc, $topgroup, \%starstyle);
-
-=head1 AUTEURS
-
-Jean-Luc Vinot <vinot@cena.fr>
diff --git a/Perl/Zinc/Logo.pm b/Perl/Zinc/Logo.pm
deleted file mode 100644
index 486c904..0000000
--- a/Perl/Zinc/Logo.pm
+++ /dev/null
@@ -1,238 +0,0 @@
-package Tk::Zinc::Logo;
-
-#---------------------------------------------------------------
-#
-# Module : Logo.pm
-# $Id$
-#
-# Copyright (C) 2001-2003
-# Centre d'Études de la Navigation Aérienne
-# Authors: Jean-Luc Vinot <vinot@cena.fr>
-#
-#---------------------------------------------------------------
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use strict;
-use Carp;
-use Math::Trig;
-
-
-my @Gradiants;
-
-# paramètres de construction graphique
-my %builder = (-gradset => {'logoshape' => '=axial 270 |#ffffff;100 0 28|#66848c;100 96|#7192aa;100 100',
- 'logopoint' => '=radial -20 -20 |#ffffff;100 0|#f70000;100 48|#900000;100 80|#ab0000;100 100',
- 'logoptshad' => '=path 0 0 |#770000;64 0|#770000;70 78|#770000;0 100',
- },
-
- -shape => {-form => {-itemtype => 'curve',
- -coords => [[0,0],[106,0],[106,58],[122,41],[156,41],[131,69],[153,99],[203,41],
- [155,41],[155,0],[225.71,0],[251.34,0,'c'],[265.17,29.63,'c'],
- [248.71,49.27],[202,105],[246,105],[246,87],[246,59.385,'c'],[268.38,37,'c'],
- [296,37],[323.62,37,'c'],[346,59.385,'c'],[346,87],[346,148],[305,148],
- [305,87],[305,82.58,'c'],[301.42,79,'c'],[297,79],[292.58,79,'c'],
- [289,82.58,'c'],[289,87],[289,150],[251,150],[251,130],[251,125.58,'c'],
- [247.42,122,'c'],[243,122],[243,122],[238.58,122,'c'],[235,125.58,'c'],
- [235,130],[235,150],[168.12,150],[144.7,150,'c'],[132.38,122.57,'c'],
- [147.94,105.06],[148,105],[120,105],[104,81],[104,105],[74,105],[74,41],
- [52,41],[52,105],[20,105],[20,41],[0,41]],
-
- -contour => ['add', -1, [[395,78],[395,37],[364.62,37,'c'],[340,61.62,'c'],[340,92],
- [340,93],[340,123.38,'c'],[364.62,148,'c'],[395,148],[409,148],
- [409,107],[395,107],[386.72,107,'c'],[380,100.28,'c'],[380,92],
- [380,93],[380,84.72,'c'],[386.72,78,'c'],[395,78]]],
-
-
- -params => {-closed => 0,
- -filled => 1,
- -visible => 1,
- -fillcolor => 'logoshape',
- -linewidth => 2.5,
- -linecolor => '#000000',
- -priority => 40,
- -fillrule => 'nonzero',
- -tags => ['zinc_shape'],
- },
- },
-
- -shadow => {-clone => '-form',
- -translate => [6, 6],
- -params => {-fillcolor => '#000000;18',
- -linewidth => 0,
- -priority => 20,
- },
- },
- },
-
- -point => {-coords => [240, 96],
- -params => {-alpha => 80,
- -priority => 100,
- },
-
- -form => {-itemtype => 'arc',
- -coords => [[-20, -20], [20, 20]],
- -params => {-priority => 50,
- -filled => 1,
- -linewidth => 1,
- -linecolor => '#a10000;100',
- -fillcolor => 'logopoint',
- -closed => 1,
- },
- },
-
- -shadow => {-clone => '-form',
- -translate => [5, 5],
- -params => {-fillcolor => 'logoptshad',
- -linewidth => 0,
- -priority => 20,
- },
- },
- },
- );
-
-
-
-sub new {
- my $proto = shift;
- my $type = ref($proto) || $proto;
- my %params = @_;
-
- my $self = {};
- bless ($self, $type);
- if (exists $params{'-widget'}) {
- $self->{'-widget'} = $params{'-widget'};
- } else {
- croak "in Tk::Zinc::Logo constructor, the -widget attribute must be defined\n";
- }
- $self->{'-parent'} = (exists $params{'-parent'}) ? $params{'-parent'} : 1;
- $self->{'-priority'} = (exists $params{'-priority'}) ? $params{'-priority'} : 500;
- $self->{'-position'} = (exists $params{'-position'}) ? $params{'-position'} : [0, 0];
- $self->{'-scale'} = (exists $params{'-scale'}) ? $params{'-scale'} : [1, 1];
-
- $self->drawLogo();
-
- return bless $self, $type;
-}
-
-
-
-sub drawLogo {
- my ($self) = @_;
- my $zinc = $self->{'-widget'};
- my $parent = $self->{'-parent'};
- my $priority = $self->{'-priority'};
-
-
- if ($builder{'-gradset'}) {
- while (my ($name, $gradiant) = each( %{$builder{'-gradset'}})) {
- # création des gradiants nommés
- $zinc->gname($gradiant, $name) unless $zinc->gname($name);
- push(@Gradiants, $name);
- }
- }
-
- # création des groupes logo
- # logogroup : groupe de coordonnées
- my $logogroup = $self->{'-item'} = $zinc->add('group', $parent, -priority => $priority);
- $zinc->coords($logogroup, $self->{'-position'}) if ($self->{'-position'});
-
- # group de scaling
- my $group = $self->{'-scaleitem'} = $zinc->add('group', $logogroup);
- $zinc->scale($group, @{$self->{'-scale'}}) if ($self->{'-scale'});
-
-
- # création de l'item shape (Zinc)
- my $formstyle = $builder{'-shape'}->{'-form'};
- $self->ajustLineWidth($formstyle->{'-params'});
- my $shape = $zinc->add('curve', $group,
- $formstyle->{'-coords'},
- %{$formstyle->{'-params'}},
- );
-
- $zinc->contour($shape, @{$formstyle->{'-contour'}});
-
- # ombre portée de la shape
- my $shadstyle = $builder{'-shape'}->{'-shadow'};
- my $shadow = $zinc->clone($shape, %{$shadstyle->{'-params'}});
- $zinc->translate($shadow, @{$shadstyle->{'-translate'}}) if ($shadstyle->{'-translate'});
-
- # réalisation du point
- my $pointconf = $builder{'-point'};
- my $ptgroup = $zinc->add('group', $group, %{$pointconf->{'-params'}});
- $zinc->coords($ptgroup, $pointconf->{'-coords'});
-
- my $pointstyle = $pointconf->{'-form'};
- my $point = $zinc->add('arc', $ptgroup,
- $pointstyle->{'-coords'},
- %{$pointstyle->{'-params'}},
- );
-
- my $shadpoint = $zinc->clone($point, %{$shadstyle->{'-params'}});
- $shadstyle = $pointconf->{'-shadow'};
- $zinc->translate($shadpoint, @{$shadstyle->{'-translate'}});
-
-}
-
-
-sub ajustLineWidth {
- my ($self, $style, $scale) = @_;
-
- if ($style->{'-linewidth'}) {
- my ($sx, $sy) = @{$self->{'-scale'}};
- my $linewidth = $style->{'-linewidth'};
- if ($linewidth >= 2) {
- my $ratio = ($sx > $sy) ? $sy : $sx;
- $style->{'-linewidth'} = $linewidth * $ratio;
- }
- }
-}
-
-1;
-
-__END__
-
-=head1 NAME
-
-Tk::Zinc::Logo - a perl module for drawing the TkZinc logo.
-
-
-=head1 SYNOPSIS
-
- use Tk::Zinc::Logo;
- my $zinc = MainWindow->new()->Zinc()->pack;
- my $logo = $zinc->ZincLogo([options]);
-
-
-
-=head1 OPTIONS
-
-=over
-
-=item B<-parent> => zinc group
-
-Specify the parent group. Default is 1.
-
-=item B<-position> => [x, y]
-
-Specify the relative position of the logo in its parent group. Default is [0, 0].
-
-=item B<-priority> => integer
-
-Specify the priority of the logo in its parent group. Default is 500.
-
-=item B<-scale> => [sx, sy]
-
-Scecify the xscale and yscale factors of the logo. Default is [1, 1].
-
-
-=back
-
-
-=head1 AUTEUR
-
-Jean-Luc Vinot <vinot@cena.fr>
-
-
-
diff --git a/Perl/Zinc/Text.pm b/Perl/Zinc/Text.pm
deleted file mode 100644
index 63e9573..0000000
--- a/Perl/Zinc/Text.pm
+++ /dev/null
@@ -1,262 +0,0 @@
-package Tk::Zinc::Text;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-
-sub new {
- my $proto = shift;
- my $type = ref($proto) || $proto;
- my ($zinc) = @_;
- my $self = {};
-
- $zinc->bind('text', '<1>' => sub {startSel($zinc)});
- $zinc->bind('text', '<2>' => sub {pasteSel($zinc)});
- $zinc->bind('text', '<B1-Motion>' => sub {extendSel($zinc)});
- $zinc->bind('text', '<Shift-B1-Motion>' => sub {extendSel($zinc)});
- $zinc->bind('text', '<Shift-1>' => sub {
- my $e = $zinc->XEvent();
- my($x, $y) = ($e->x, $e->y);
- $zinc->select('adjust', 'current', "\@$x,$y"); });
- $zinc->bind('text', '<Left>' => sub {moveCur($zinc, -1);});
- $zinc->bind('text', '<Right>' => sub {moveCur($zinc, 1);});
- $zinc->bind('text', '<Up>' => sub {setCur($zinc, 'up');});
- $zinc->bind('text', '<Down>' => sub {setCur($zinc, 'down');});
- $zinc->bind('text', '<Control-a>' => sub {setCur($zinc, 'bol');});
- $zinc->bind('text', '<Home>' => sub {setCur($zinc, 'bol');});
- $zinc->bind('text', '<Control-e>' => sub {setCur($zinc, 'eol');});
- $zinc->bind('text', '<End>' => sub {setCur($zinc, 'eol');});
- $zinc->bind('text', '<Meta-less>' => sub {setCur($zinc, 0);});
- $zinc->bind('text', '<Meta-greater>' => sub {setCur($zinc, 'end');});
- $zinc->bind('text', '<KeyPress>' => sub {insertKey($zinc);});
- $zinc->bind('text', '<Shift-KeyPress>' => sub {insertKey($zinc);});
- $zinc->bind('text', '<Return>' => sub { insertChar($zinc, chr(10)); });
- $zinc->bind('text', '<BackSpace>' => sub {textDel($zinc, -1)});
- $zinc->bind('text', '<Control-h>' => sub {textDel($zinc, -1)});
- $zinc->bind('text', '<Delete>' => sub {textDel($zinc, 0)});
-
- bless ($self, $type);
- return $self;
-}
-
-
-sub pasteSel {
- my ($w) = @_;
- my $e = $w->XEvent;
- my($x, $y) = ($e->x(), $e->y());
- my @it = $w->focus();
-
- if (@it != 0) {
- eval { $w->insert(@it, "\@$x,$y", $w->SelectionGet()); };
- }
-}
-
-
-sub insertChar {
- my ($w, $c) = @_;
- my @it = $w->focus();
- my @selit = $w->select('item');
-
- if (@it == 0) {
- return;
- }
-
- if ((scalar(@selit) == scalar(@it)) &&
- ($selit[0] eq $it[0]) && ($selit[1] eq $it[1])) {
- $w->dchars(@it, 'sel.first', 'sel.last');
- }
- $w->insert(@it, 'insert', $c);
-}
-
-
-sub insertKey {
- my ($w) = @_;
- my $c = $w->XEvent->A();
-
- if ((ord($c) < 32) || (ord($c) == 128)) {
- return;
- }
-
- insertChar($w, $c);
-}
-
-
-sub setCur {
- my ($w, $where) = @_;
- my @it = $w->focus();
-
- if (@it != 0) {
- $w->cursor(@it, $where);
- }
-}
-
-
-sub moveCur {
- my ($w, $dir) = @_;
- my @it = $w->focus();
- my $index;
-
- if (@it != 0) {
- $index = $w->index(@it, 'insert');
- $w->cursor(@it, $index + $dir);
- }
-}
-
-
-sub startSel {
- my($w) = @_;
- my $e = $w->XEvent;
- my($x, $y) = ($e->x(), $e->y());
- my $part = $w->currentpart(1);
-
- $w->cursor('current', $part, "\@$x,$y");
- $w->focus('current', $part);
- $w->Tk::focus();
- $w->select('from', 'current', $part, "\@$x,$y");
-}
-
-
-sub extendSel {
- my($w) = @_;
- my $e = $w->XEvent;
- my($x, $y) = ($e->x, $e->y);
- my $part = $w->currentpart(1);
-
- $w->select('to', 'current', $part, "\@$x,$y");
-}
-
-
-sub textDel {
- my($w, $dir) = @_;
- my @it = $w->focus();
- my @selit = $w->select('item');
- my $ind;
-
- if (@it == 0) {
- return;
- }
-
- if ((scalar(@selit) == scalar(@it)) &&
- ($selit[0] eq $it[0]) && ($selit[1] eq $it[1])) {
- $w->dchars(@it, 'sel.first', 'sel.last');
- }
- else {
- $ind = $w->index(@it, 'insert') + $dir;
- $w->dchars(@it, $ind, $ind) if ($ind >= 0);
- }
-}
-
-1;
-__END__
-
-=head1 NAME
-
-Tk::Zinc::Text - Zinc extension for easing text input on text item or on fields
-
-=head1 SYNOPSIS
-
- use Tk::Zinc::Text;
-
- $zinc = $mw->Zinc();
- new Tk::Zinc::Text ($zinc);
- ....
- $zinc->addtag('text', 'withtag', $a_text);
- $zinc->addtag('text', 'withtag', $a_track);
- $zinc->addtag('text', 'withtag', $a_waypoint);
- $zinc->addtag('text', 'withtag', $a_tabular);
-
-=head1 DESCRIPTION
-
-This module implements text input with the mouse and keyboard 'a la emacs'.
-Text items must have the 'text' tag and must of course be sensitive.
-Track, waypoint and tabular items have fields and these fields can
-be edited the same way. Only sensitive fields can be edited. the following
-interactions are supported:
-
-=over 2
-
-=item B<click 1>
-
-To set the cursor position
-
-=item B<click 2>
-
-To paste the current selection
-
-=item B<drag 1>
-
-To make a selection
-
-=item B<shift drag 1>
-
-To extend the current selection
-
-=item B<shift 1>
-
-To extend the current selection
-
-=item B<left arrow>, B<right arrow>
-
-To move the cursor to the left or to the right
-
-=item B<up arrow>, B<down arrow>
-
-To move the cursor up or down a line
-
-=item B<ctrl+a>, B<home>
-
-To move the cursor at the begining of the line
-
-=item B<ctrl+e>, B<end>
-
-To move the cursor at the end of the line
-
-=item B<meta+<>, B<meta+E<gt>>
-
-To move the cursor at the beginning / end of the text
-
-=item B<BackSpace>, B<ctrl+h>
-
-To delete the char just before the cursor
-
-=item B<Delete>
-
-To delete the char just after the cursor
-
-=item B<Return>
-
-To insert a return char. This does not validate the input!
-
-=back
-
-=head1 BUGS
-
-No known bugs at this time. If you find one, please report them to the authors.
-
-=head1 SEE ALSO
-
-perl(1), Tk(1), Tk::Zinc(3), zinc-demos(1)
-
-=head1 AUTHORS
-
-Patrick Lecoanet <lecoanet@cena.fr>
-(and some documentation by Christophe Mertz <mertz@cena.fr>)
-
-=head1 COPYRIGHT
-
-CENA (C) 2002
-
-Tk::Zinc::Text is part of Zinc and has been developed by the CENA (Centres d'Etudes de la Navigation Aérienne)
-for its own needs in advanced HMI (Human Machine Interfaces or Interactions). Because we are confident
-in the benefit of free software, the CENA delivered this toolkit under the GNU
-Library General Public License.
-
-This code is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even
-the implied warranty of MER­CHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library
-General Public License for more details.
-
-=head1 HISTORY
-
-June 2002 : initial release with Zinc-perl 3.2.6
-
-=cut
diff --git a/Perl/Zinc/Trace.pm b/Perl/Zinc/Trace.pm
deleted file mode 100644
index f115171..0000000
--- a/Perl/Zinc/Trace.pm
+++ /dev/null
@@ -1,227 +0,0 @@
-#
-# Copyright (c) 1992-1994 The Regents of the University of California.
-# Copyright (c) 1994 Sun Microsystems, Inc.
-# Copyright (c) 1995-1999 Nick Ing-Simmons. All rights reserved.
-# This program is free software; you can redistribute it and/or
-# modify it under the same terms as Perl itself, subject
-# to additional disclaimer in Tk/license.terms due to partial
-# derivation from Tk8.0 sources.
-#
-# Copyright (c) 2002 CENA, C.Mertz <mert@cena.fr> to trace all
-# Tk::Zinc methods calls as well as the args in a human readable
-# form. Updated by D.Etienne.
-#
-# This package overloads the Tk::Methods function in order to trace
-# every Tk::Zinc method call in your application.
-#
-# This may be very usefull when your application segfaults and
-# when you have no idea where this happens in your code.
-#
-# $Id$
-#
-# To trap Tk::Zinc errors, use rather the Tk::Zinc::TraceErrors package.
-#
-# for using this file do some thing like :
-# perl -MTk::Zinc::Trace myappli.pl
-
-package Tk::Zinc::Trace;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use vars qw( $ForReplay );
-
-use Tk;
-use strict;
-use Tk::Zinc::TraceUtils;
-
-my $WidgetMethodfunction;
-my %moduleOptions;
-
-
-BEGIN {
- if (defined $ZincTraceErrors::on && $ZincTraceErrors::on == 1) {
- print STDERR "Tk::Zinc::Trace: incompatible package Tk::Zinc::TraceErrors is already ".
- "loaded (exit 1)\n";
- exit 1;
- }
- print "## Tk::Zinc::Trace ON\n";
- $ZincTrace::on = 1;
- require Getopt::Long;
- Getopt::Long::Configure('pass_through');
- Getopt::Long::GetOptions(\%moduleOptions, 'code');
- $ForReplay=1 if defined $moduleOptions{code} ;
- select STDOUT; $|=1; ## for flushing the trace output
- # save current Tk::Zinc::InitObject function; it will be invoked in
- # overloaded one (see below)
- use Tk;
- use Tk::Zinc;
- $WidgetMethodfunction = Tk::Zinc->can('WidgetMethod');
-
-}
-
-print "## following trace should be very close to a replay-script code\n" if $ForReplay;
-
-my $ZincCounter= "";
-my %ZincHash;
-
-#sub Tk::Zinc {
-# print "CREATING Zinc : @_";
-# &$ZincCreationMethodfunction;
-#}
-
-sub Tk::Zinc::WidgetMethod {
- my ($zinc, $name, @args) = @_;
- if (defined $Tk::Zinc::Trace::off and $Tk::Zinc::Trace::off > 0) {
- return &$WidgetMethodfunction(@_) if $WidgetMethodfunction;
- }
- my ($package, $filename, $line) = caller(1);
- $package="" unless defined $package;
- $filename="" unless defined $filename;
- $line="" unless defined $line;
- my $widget;
- if (defined $ZincHash{$zinc}) {
- $widget = $ZincHash{$zinc};
- } elsif ($ZincCounter) {
- $ZincHash{$zinc} = '$zinc'.$ZincCounter;
- $widget = '$zinc'.$ZincCounter;
- $ZincCounter++;
- } else {
- $ZincHash{$zinc} = '$zinc';
- $widget = '$zinc';
- $ZincCounter=1; # for the next zinc
- }
-
- if ($ForReplay) {
- print "$widget->$name";
- } else {
- print "TRACE: $filename line $line $name";
- }
-
- &printList(@args);
- # invoke function possibly overloaded in other modules
- if (wantarray()) {
- my @res = &$WidgetMethodfunction(@_) if $WidgetMethodfunction;
- if ($ForReplay) {
- print ";\n";
- } else {
- print " RETURNS ";
- &printList (@res);
- print "\n";
- }
- $zinc->update;
- return @res;
- } else {
- my $res = &$WidgetMethodfunction(@_) if $WidgetMethodfunction;
- if ($ForReplay) {
- print ";\n";
- } else {
- print " RETURNS ";
- &printItem ($res);
- print "\n";
- }
- $zinc->update;
- return $res;
- }
-}
-
-1;
-
-
-__END__
-
-=head1 NAME
-
-Tk::Zinc::Trace - A module to trace all Tk::Zinc method calls
-
-=head1 SYNOPSIS
-
-use Tk::Zinc::Trace;
-$Tk::Zinc::Trace:ForReplay = 1;
-
-or
-
-perl -MTk::Zinc::Trace YourZincBasedScript.pl [--code]
-
-=head1 DESCRIPTION
-
-When loaded, this module overloads a Tk mechanism so that every
-Tk::Zinc method call will be traced. Every call will also be followed by a
-$zinc->update() so that the method call will be effectively treated.
-
-This module can be very effective for debugging when Tk::Zinc
-core dumps and you have no clue which method call can be responsible for. If
-you just want to trace Tk::Zinc errors when calling a method you
-should rather use the Tk::Zinc::TraceErrors module
-
-The global variable $Tk::Zinc::Trace:off can be used to trace some specific blocks. If set to 1, traces are deactivated, if set to 0, traces are reactivated.
-
-If the global variable $Tk::Zinc::Trace:ForReplay is set or if the --code
-option is set in the second form, the printout will be very close to re-executable
-code, like this:
-
- ## following trace should be very close to a replay-script code
- $zinc->configure(-relief => 'sunken', -borderwidth => 3,
- -width => 700, -font => 10x20, -height => 600);
- $zinc->add('rectangle', 1, [10, 10, 100, 50],
- -fillcolor => 'green', -filled => 1, -linewidth => 10,
- -relief => 'roundridge', -linecolor => 'darkgreen');
- $zinc->add('text', 1, -font => -adobe-helvetica-bold-r-normal-*-120-*-*-*-*-*-* =>
- -text => 'A filled rectangle with a "roundridge" relief border of 10 pixels.',
- -anchor => 'nw', -position => [120, 20]);
- $zinc->add('track', 1, 6,
- -labelformat => 'x82x60+0+0 x60a0^0^0 x32a0^0>1 a0a0>2>1 x32a0>3>1 a0a0^0>2',
- -position => [20, 120], -speedvector => [40, -10], -speedvectormark => 1, -speedvectorticks => 1);
- $zinc->coords(4, [20, 120]);
-
-
-If not (the default), the printout will be more informtative, giving
-the following information:
-
-=over 6
-
-=item * the source filename where the method has been invoked
-
-=item * the line number in the source file
-
-=item * the TkZinc method name
-
-=item * the list of arguments in a human-readable form
-
-=item * the returned value
-
-=back
-
-The trace will look like:
-
- ## Tk::Zinc::Trace ON
- TRACE: /usr/lib/perl5/Tk/Widget.pm line 196 configure(-relief => 'sunken', -borderwidth => 3, -width => 700, -font => 10x20, -height => 600) RETURNS undef
- TRACE: Perl/demos/demos/zinc_lib/items.pl line 21 add('rectangle', 1, [10, 10, 100, 50], -fillcolor => 'green', -filled => 1, -linewidth => 10, -relief => 'roundridge', -linecolor => 'darkgreen') RETURNS 2
- TRACE: Perl/demos/demos/zinc_lib/items.pl line 25 add('text', 1, -font => -adobe-helvetica-bold-r-normal-*-120-*-*-*-*-*-* => -text => 'A filled rectangle with a "roundridge" relief border of 10 pixels.', -anchor => 'nw', -position => [120, 20]) RETURNS 3
- TRACE: Perl/demos/demos/zinc_lib/items.pl line 36 add('track', 1, 6, -labelformat => 'x82x60+0+0 x60a0^0^0 x32a0^0>1 a0a0>2>1 x32a0>3>1 a0a0^0>2', -position => [20, 120], -speedvector => [40, -10], -speedvectormark => 1, -speedvectorticks => 1) RETURNS 4
-
-=head1 AUTHOR
-
-C.Mertz <mertz@cena.fr> and D.Etienne <etienne@cena.fr>
-
-=head1 CAVEATS and BUGS
-
-This module cannot be used when Tk::Zinc::TraceErrors is already in use.
-
-As every Tk::Zinc method call is followed by an ->update call, this may
-dramatically slowdown an application. The trade-off is between application
-run-time and developper debug-time.
-
-When using an output "code-like" they are still part of the output which is
-not executable code. However, the ouptut could be easily and manually
-edited to be executable perl code.
-
-=head1 COPYRIGHT
-
-See Tk::Zinc copyright; LGPL
-
-=head1 SEE ALSO
-
-L<Tk::Zinc(3pm)>, L<Tk::Zinc::TraceErrors(3pm)>. L<Tk::Zinc::Debug(3pm)>.
-
-=cut
diff --git a/Perl/Zinc/TraceErrors.pm b/Perl/Zinc/TraceErrors.pm
deleted file mode 100644
index e74f28a..0000000
--- a/Perl/Zinc/TraceErrors.pm
+++ /dev/null
@@ -1,149 +0,0 @@
-#
-# Copyright (c) 1992-1994 The Regents of the University of California.
-# Copyright (c) 1994 Sun Microsystems, Inc.
-# Copyright (c) 1995-1999 Nick Ing-Simmons. All rights reserved.
-# This program is free software; you can redistribute it and/or
-# modify it under the same terms as Perl itself, subject
-# to additional disclaimer in Tk/license.terms due to partial
-# derivation from Tk8.0 sources.
-#
-# Copyright (c) 2003 CENA, D.Etienne <etienne@cena.fr> to trace all
-# Tk::Zinc errors.
-#
-# This package overloads the Tk::Zinc::WidgetMethods function in order to
-# to trap errors by calling every Tk::Zinc method in an eval() block.
-#
-# This may be very usefull when your application encounters errors such as
-# "error .... at /usr/lib/perl5/Tk.pm line 228". With ZincTraceErrors, the
-# module name, the line number and the complete error messages are reported
-# for each error.
-#
-# $Id$
-#
-# When you have no idea where this happens in your code or when your
-# application segfaults, use the Tk::Zinc::Trace package which traces every
-# Tk::Zinc method call.
-#
-# for using this file do some thing like :
-# perl -MTk::Zinc::TraceErrors myappli.pl
-
-package Tk::Zinc::TraceErrors;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use strict;
-use Tk::Zinc::TraceUtils;
-
-my $WidgetMethodfunction;
-my $bold = "";
-my $_bold = "";
-
-BEGIN {
- my $bold = "";
- my $_bold = "";
-
- if (defined $ZincTrace::on and $ZincTrace::on == 1) {
- print STDERR $bold."Tk::Zinc::TraceErrors: incompatible package Tk::Zinc::Trace is already ".
- "loaded".$_bold." (exit 1)\n";
- exit 1;
- }
- print $bold."Tk::Zinc::TraceErrors is ON".$_bold."\n";
- $ZincTraceErrors::on = 1;
- select STDOUT; $|=1; ## for flushing the trace output
- # save current Tk::Zinc::InitObject function; it will be invoked in
- # overloaded one (see below)
- use Tk;
- use Tk::Zinc;
- $WidgetMethodfunction = Tk::Zinc->can('WidgetMethod');
-
-}
-
-sub Tk::Zinc::WidgetMethod {
- my ($zinc, $name, @args) = @_;
- my ($package, $filename, $line) = caller(1);
- $package="" unless defined $package;
- $filename="" unless defined $filename;
- $line="" unless defined $line;
- # invoke function possibly overloaded in other modules
- my ($res, @res);
- if (wantarray()) {
- eval {@res = &$WidgetMethodfunction(@_) if $WidgetMethodfunction;};
- } else {
- eval {$res = &$WidgetMethodfunction(@_) if $WidgetMethodfunction;};
- }
- if ($@) {
- print $bold."error:".$_bold." $filename line $line $name";
- &printList (@args);
- my $msg = $@;
- $msg =~ s/at .*//g;
- print " ".$bold."returns".$_bold." $msg\n";
- }
- if (wantarray()) {
- return @res;
- } else {
- return $res;
- }
-}
-
-
-
-1;
-
-
-__END__
-
-=head1 NAME
-
-Tk::Zinc::TraceErrors - A module to trace all Tk::Zinc method calls which generate an error
-
-=head1 SYNOPSIS
-
-use Tk::Zinc::TraceErrors;
-
-or
-
-perl -MTk::Zinc::TraceErrors YourZincBasedScript.pl
-
-=head1 DESCRIPTION
-
-When loaded, this module overloads a Tk mechanism so that every
-Tk::Zinc method call will be traced if it provokes an error. The execution
-will then continue.
-
-This module can be very effective for debugging and application, specially
-when Tk gives an unusuable error message such as ".... errors in Tk.pm line 228"
-
-=over 6
-
-=item * the source filename where the method has been invoked
-
-=item * the line number in the source file
-
-=item * the TkZinc method name
-
-=item * the list of arguments in a human-readable form
-
-=item * the error message
-
-=back
-
-=head1 AUTHOR
-
-D.Etienne <etienne@cena.fr> and C.Mertz <mertz@cena.fr>
-
-=head1 CAVEAT
-
-This module cannot be used when Tk::Zinc::Trace is already in use.
-
-=head1 COPYRIGHT
-
-See Tk::Zinc copyright; LGPL
-
-=head1 SEE ALSO
-
-L<Tk::Zinc(3pm)>, L<Tk::Zinc::Trace(3pm)>. L<Tk::Zinc::Debug(3pm)>.
-
-=cut
-
diff --git a/Perl/Zinc/TraceUtils.pm b/Perl/Zinc/TraceUtils.pm
deleted file mode 100644
index 8a3bc76..0000000
--- a/Perl/Zinc/TraceUtils.pm
+++ /dev/null
@@ -1,111 +0,0 @@
-package Tk::Zinc::TraceUtils;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-use Tk;
-use Tk::Font;
-use Tk::Photo;
-
-require Exporter;
-@ISA = qw(Exporter);
-@EXPORT = qw(printItem printArray printList Item Array List);
-
-use strict;
-
-sub printItem {
- print &Item (@_);
-}
-
-sub printArray {
- print &Array (@_);
-}
-
-sub printList {
- print &List (@_);
-}
-
-
-### to print something
-sub Item {
- my ($value) = @_;
- my $ref = ref($value);
-# print "VALUE=$value REF=$ref\n";
- if ($ref eq 'ARRAY') {
- return Array ( @{$value} );
- } elsif ($ref eq 'CODE') {
- return "{CODE}";
- } elsif ($ref eq 'Tk::Photo') {
-# print " **** $value ***** ";
- return "Tk::Photo(\"". scalar $value->cget('-file') . "\")";
- } elsif ($ref eq 'Tk::Font') {
- return "'$value'";
- } elsif ($ref eq '') { # scalar
- if (defined $value) {
- if ($value =~ /^-?\d+(\.\d*(e[+-]?\d+)?)?$/ or # -1. or 1.0
- $value =~ /^-[a-zA-Z]([\w])*$/ # -option1 or -option-1
- ) {
- return $value;
- } elsif ($value eq ''
- or $value =~ /\s/
- or $value =~ /^[a-zA-Z]/
- or $value =~ /^[\W]/
- ) {
- return "'$value'";
- } else {
- return $value;
- }
- } else {
- return "_undef";
- }
- } else { # some class instance
- return $value;
- }
-
-} # end Item
-
-
-### to print a list of something
-sub Array {
- my (@values) = @_;
- if (! scalar @values) {
- return "[]";
- }
- else { # the list is not empty
- my $res = "[";
- while (@values) {
- my $value = shift @values;
- $res .= &Item ($value);
- $res .= ", " if (@values);
- }
- return $res. "]" ;
- }
-
-} # end Array
-
-
-sub List {
- my $res = "(";
- while (@_) {
- my $v = shift @_;
- $res .= Item ($v);
- if (@_ > 0) {
- ## still some elements
- if ($v =~ /^-\d+$/) {
- $res .= ", ";
- } elsif ($v =~ /^-\w+$/) {
- $res .= " => ";
- } else {
- $res .= ", ";
- }
- }
- }
- return $res. ")";
-
-} # end List
-
-
-1;
-
-
-
diff --git a/Perl/debug/.cvsignore b/Perl/debug/.cvsignore
deleted file mode 100644
index 625327a..0000000
--- a/Perl/debug/.cvsignore
+++ /dev/null
@@ -1,4 +0,0 @@
-Makefile
-Makefile.old
-blib
-pm_to_blib
diff --git a/Perl/demos/.cvsignore b/Perl/demos/.cvsignore
deleted file mode 100644
index c58b391..0000000
--- a/Perl/demos/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-Makefile
-pm_to_blib
diff --git a/Perl/demos/Makefile.PL b/Perl/demos/Makefile.PL
deleted file mode 100644
index 9b22bab..0000000
--- a/Perl/demos/Makefile.PL
+++ /dev/null
@@ -1,7 +0,0 @@
-use ExtUtils::MakeMaker;
-WriteMakefile(
- 'EXE_FILES' => ['zinc-demos'],
- 'PMLIBDIRS' => [ qw( Tk/demos/zinc_pm Tk/demos/zinc_contrib_lib
- Tk/demos/zinc_data Tk/demos/zinc_lib ) ],
- );
-
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);
- }
-}
-
-
diff --git a/Perl/demos/t/no-test.t b/Perl/demos/t/no-test.t
deleted file mode 100644
index a317b57..0000000
--- a/Perl/demos/t/no-test.t
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/usr/bin/perl
-
-BEGIN { $| = 1; print "1..1\n"; }
-END {print "ok 1\n";}
-
-print "No test for zinc demos, since they are by themselves Tk::Zinc tests\n";
-
-1;
diff --git a/Perl/demos/zinc-demos b/Perl/demos/zinc-demos
deleted file mode 100644
index 2bffb5a..0000000
--- a/Perl/demos/zinc-demos
+++ /dev/null
@@ -1,502 +0,0 @@
-#!/usr/bin/perl -w
-
-#$id: $
-
-eval 'exec /usr/bin/perl -w -S $0 ${1+"$@"}'
- if 0; # not running under some shell
-
-require 5.004;
-
-use Tk 800.000;
-use Tk::Zinc; # only for getting $Tk::Zinc::VERSION
-use lib Tk->findINC('demos/widget_lib');
-use Tk::widgets qw/Dialog ErrorDialog ROText/;
-use WidgetDemo;
-use subs qw/invoke lsearch see_code see_vars show_stat view_widget_code/;
-use vars qw/$MW $FONT $WIDTRIB/;
-use vars qw/$CODE $CODE_RERUN $CODE_TEXT $VARS $VIEW $VIEW_TEXT/;
-use vars qw/$BRAKES $LIGHTS $OIL $SOBER $TRANS $WIPERS/;
-use vars qw/$COLOR $FONT_STYLE $POINT_SIZE $DEMO_FILE %DEMO_DESCRIPTION/;
-use strict;
-
-use vars qw( $VERSION );
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-
-my $version = $Tk::Zinc::VERSION;
-print "Tkzinc version: $version\n";
-
-$MW = Tk::MainWindow->new;
-$MW->configure(-menu => my $menubar = $MW->Menu);
-
-{
- package WidgetWrap;
- @WidgetWrap::ISA = qw/Tk::MainWindow/;
-
- # This magic conspires with widget's AUTOLOAD subroutine to make user
- # contributed demonstrations that don't use WidgetDemo embed properly.
- # The trick works because widget creates a superclass of Tk::MainWindow
- # which invokes WidgetDemo() implicitly. You loose if you bypass the
- # inheritance mechanism and call Tk::MainWindow directly.
-
- sub new {
- my ($name) = $::DEMO_FILE =~ m#([^/]+).pl$#;
- $::MW->WidgetDemo(-name => $name, -text => $::DEMO_DESCRIPTION{$name} || "" );
- }
-}
-
-@MainWindow::ISA = 'WidgetWrap';
-
-$MW->title('TkZinc Perl demonstrations');
-$FONT = '-*-Helvetica-Medium-R-Normal--*-140-*-*-*-*-*-*';
-my $widget_lib = Tk->findINC('demos/widget_lib');
-# the previous simple statement $zinc_lib = Tk->findINC('demos/zinc_lib');
-# found in some cases such old directory empty (e.g. after a previous package de-installation)
-# So now, we look for a non-empty demos/zinc_lib directory (ie containing one of the demo!)
-my $zinc_lib = Tk->findINC('demos/zinc_lib/tiger.pl');
-($zinc_lib) = $zinc_lib =~ /(.*)\/tiger\.pl/;
-my $wd = "$widget_lib/WidgetDemo.pm";
-$WIDTRIB = Tk->findINC('demos/zinc_contrib_lib/README');
-($WIDTRIB) = $WIDTRIB =~ /(.*)\/README/;
-unless (Tk::tainting) {
- $WIDTRIB = $ENV{WIDTRIB} if defined $ENV{WIDTRIB};
- $WIDTRIB = $ARGV[0] if defined $ARGV[0];
-}
-
-# The code below creates the main window, consisting of a menu bar
-# and a text widget that explains how to use the program, plus lists
-# all of the demos as hypertext items.
-
-my $file = $menubar->cascade(qw/-label File -underline 0 -menuitems/ =>
- [
- [cascade => '~View', -menuitems =>
- [
- [command => '~zinc-demos', -command => [\&view_widget_code, __FILE__]],
- [command => '~WidgetDemo', -command => [\&view_widget_code, $wd]],
- ], # end cascade menuitems
- ], # end view cascade
- '',
- [command => '~Quit', -command => [\&exit]],
- ]);
-
-my $help = $menubar->cascade(qw/-label Help -underline 0 -menuitems/ =>
- [
- [command => '~About'],
- ]);
-
-my $T = $MW->Scrolled('ROText',
- -scrollbars => 'e',
- -wrap => 'word',
- -width => 60,
- -height => 30,
- -font => $FONT,
- -setgrid => 1,
-)->grid(qw/-sticky nsew/);
-$MW->gridRowconfigure( 0, -weight => 1); # allow expansion in both ...
-$MW->gridColumnconfigure(0, -weight => 1); # ... X and Y dimensions
-
-my $STATUS_VAR;
-my $status = $MW->Label(-textvariable => \$STATUS_VAR, qw/-anchor w/);
-$status->grid(qw/-sticky ew/);
-
-# Create a bunch of tags to use in the text widget, such as those for
-# section titles and demo descriptions. Also define the bindings for
-# tags.
-
-$T->tagConfigure(qw/title -font -*-Helvetica-Bold-R-Normal--*-180-*-*-*-*-*-*/);
-$T->tagConfigure(qw/demo -lmargin1 1c -lmargin2 1c -foreground blue/);
-
-if ($MW->depth == 1) {
- $T->tagConfigure(qw/hot -background black -foreground white/);
- $T->tagConfigure(qw/visited -lmargin1 1c -lmargin2 1c -underline 1/);
-} else {
- $T->tagConfigure(qw/hot -relief raised -borderwidth 1 -foreground red/);
- $T->tagConfigure(qw/visited -lmargin1 1c -lmargin2 1c -foreground/ =>
- '#303080');
-}
-
-$T->tagBind(qw/demo <ButtonRelease-1>/ => \&invoke);
-my $last_line = '';
-$T->tagBind(qw/demo <Enter>/ => [sub {
- my($text, $sv) = @_;
- my $e = $text->XEvent;
- my($x, $y) = ($e->x, $e->y);
- $last_line = $text->index("\@$x,$y linestart");
- $text->tagAdd('hot', $last_line, "$last_line lineend");
- $text->configure(qw/-cursor hand2/);
- show_stat $sv, $text, $text->index('current');
- }, \$STATUS_VAR]
-);
-$T->tagBind(qw/demo <Leave>/ => [sub {
- my($text, $sv) = @_;
- $text->tagRemove(qw/hot 1.0 end/);
- $text->configure(qw/-cursor xterm/);
- $$sv = '';
- }, \$STATUS_VAR]
-);
-$T->tagBind(qw/demo <Motion>/ => [sub {
- my($text, $sv) = @_;
- my $e = $text->XEvent;
- my($x, $y) = ($e->x, $e->y);
- my $new_line = $text->index("\@$x,$y linestart");
- if ($new_line ne $last_line) {
- $text->tagRemove(qw/hot 1.0 end/);
- $last_line = $new_line;
- $text->tagAdd('hot', $last_line, "$last_line lineend");
- }
- show_stat $sv, $text, $text->index('current');
- }, \$STATUS_VAR]
-);
-
-# Create the text for the text widget.
-
-$T->insert('end', "TkZinc perl Demonstrations ($version)\n", 'title');
-$T->insert('end',
-"\nThis application provides a front end for several short scripts in perl/Tk that demonstrate what you can do with the TkZinc widget. Each of the numbered lines below describes a demonstration; you can click on it to invoke the demonstration. Once the demonstration window appears, you can click the \"See Code\" button to see the Perl/Tk code that created the demonstration.\n");
-
-$T->insert('end', "\n", '', "Small applications\n", 'title');
-$T->insert('end', "1. A simple animated application \"the Wheel of Fortune\".\n", [qw/demo demo-wheelOfFortune/]);
-$T->insert('end', "2. A simple radar display.\n", [qw/demo demo-simpleradar/]);
-$T->insert('end', "3. Zetris a clone of the famous tetris game (requires openGL.)\n", [qw/demo demo-Zetris/]);
-$T->insert('end', "4. ATC sample fake electronic strips (nicer with openGL.)\n", [qw/demo demo-groups_in_ATC_strips/]);
-$T->insert('end', "5. The famous tiger using the X11 shape extension. (nicer with openGL)\n", [qw/demo demo-tiger/]);
-$T->insert('end', "6. A magic lens based on Graphics.pm. (nicer with openGL)\n", [qw/demo demo-MagicLens/]);
-
-
-$T->insert('end', "\n", '', "All Items\n", 'title');
-$T->insert('end', "1. Examples of all items.\n", [qw/demo demo-items/]);
-$T->insert('end', "2. All items options (and their types).\n", [qw/demo demo-all_options/]);
-$T->insert('end', "3. Examples of line style and line termination.\n", [qw/demo demo-lines/]);
-$T->insert('end', "4. Curves with multiple contours.\n", [qw/demo demo-contours/]);
-$T->insert('end', "5. Examples of labelformat.\n", [qw/demo demo-labelformat/]);
-$T->insert('end', "6. Use of mapinfos.\n", [qw/demo demo-mapinfo/]);
-$T->insert('end', "7. Curves with cubic bezier control points.\n", [qw/demo demo-curve_bezier/]);
-$T->insert('end', "8. Curves with multiple contours and various fillrule.\n", [qw/demo demo-fillrule/]);
-
-
-$T->insert('end', "\n", '', "Groups, Priority, Clipping and PathTags\n", 'title');
-$T->insert('end', "1. Groups and Priorities.\n", [qw/demo demo-groups_priority/]);
-$T->insert('end', "2. Clipping examples (with simple or multiple contours).\n", [qw/demo demo-clipping/]);
-$T->insert('end', "3. Group atomicity.\n", [qw/demo demo-atomic-groups/]);
-$T->insert('end', "4. \"Windows\" with four glasses using curve with multiple contours.\n", [qw/demo demo-window-contours/]);
-$T->insert('end', "5. A counter quite impossible to do without clipping (requires openGL).\n", [qw/demo demo-counter/]);
-$T->insert('end', "6. Using pathTags.\n", [qw/demo demo-path_tags/]);
-
-$T->insert('end', "\n", '', "Interactions\n", 'title');
-$T->insert('end', "1. Simple interaction on a track.\n", [qw/demo demo-simple_interaction_track/]);
-$T->insert('end', "2. Text input in a text item and a track item.\n", [qw/demo demo-textInput/]);
-
-
-$T->insert('end', "\n", '', "Transformation\n", 'title');
-$T->insert('end', "1. Translating.\n", [qw/demo demo-translation/]);
-$T->insert('end', "2. Rotating.\n", [qw/demo demo-rotation/]);
-$T->insert('end', "3. Zooming.\n", [qw/demo demo-zoom/]);
-$T->insert('end', "4. Transformation testbed.\n", [qw/demo demo-transforms/]);
-$T->insert('end', "5. Zooming/Rotating icon and text. (even without openGL)\n", [qw/demo demo-icon_zoom_resize/]);
-
-$T->insert('end', "\n", '', "Use of openGL\n", 'title');
-$T->insert('end', "1. A zoomable/rotatable TkZinc Logo (better with openGL).\n", [qw/demo demo-tkZincLogo/]);
-$T->insert('end', "2. Axial color variation on the X axis (requires openGL).\n", [qw/demo demo-color-x/]);
-$T->insert('end', "3. Axial color variation on the Y axis (requires openGL).\n", [qw/demo demo-color-y/]);
-$T->insert('end', "4. Circular color variation (requires openGL).\n", [qw/demo demo-color-circular/]);
-$T->insert('end', "5. Path and Conical color variations (requires openGL).\n", [qw/demo demo-color-path-and-conic/]);
-$T->insert('end', "6. The triangles item (requires openGL).\n", [qw/demo demo-triangles/]);
-$T->insert('end', "7. A set of demos based on Graphics.pm module (really better with openGL).\n", [qw/demo demo-testGraphics/]);
-
-
-
-$T->insert('end', "\n", '', "User Contributed Demonstrations\n", 'title');
-opendir(C, $WIDTRIB) or warn "Cannot open $WIDTRIB: $!";
-my(@dirent) = grep /^.+\.pl$/, sort(readdir C);
-closedir C;
-unshift @dirent, 'TEMPLATE.pl'; # I want it first
-my $i = 0;
-while ($_ = shift @dirent) {
- next if /TEMPLATE\.pl/ and $i != 0;
- unless (open(C, "$WIDTRIB/$_")) {
- warn "Cannot open $_: $!" unless /TEMPLATE\.pl/;
- next;
- }
- my($name) = /^(.*)\.pl$/;
- $_ = <C>; $_ = <C>;
- my($title) = /^#\s*(.*)$/;
- $DEMO_DESCRIPTION{$name} = $title;
- close C;
- $T->insert('end', ++$i . ". $title\n", ['demo', "demo-$name"]);
-}
-
-# Create all the dialogs required by this demonstration.
-
-my $DIALOG_ABOUT = $MW->Dialog(
- -title => 'About zinc-demos',
- -bitmap => 'info',
- -default_button => 'OK',
- -buttons => ['OK'],
- -text => "TkZinc Perl demonstrations\n\nPerl Version $]" .
- "\nTk Version $Tk::VERSION" .
- "\nTkZinc Version $Tk::Zinc::VERSION\n",
-);
-$help->cget(-menu)->entryconfigure('About',
- -command => [$DIALOG_ABOUT => 'Show'],
-);
-
-my $DIALOG_ICON = $MW->Dialog(
- -title => 'Bitmap Menu Entry',
- -bitmap => undef,
- -default_button => 'OK',
- -buttons => ['OK'],
- -text => 'The menu entry you invoked displays a bitmap rather than a text string. Other than this, it is just like any other menu entry.',
-);
-$DIALOG_ICON->configure(-bitmap => undef); # keep -w from complaining
-
-MainLoop;
-
-sub AUTOLOAD {
-
- # This routine handles the loading of most demo methods.
-
- my($demo) = @_;
-
- $T->Busy;
- {
- $DEMO_FILE = "$WIDTRIB/${demo}.pl" if -f "$WIDTRIB/${demo}.pl";
- $DEMO_FILE = "$zinc_lib/${demo}.pl" if -f "$zinc_lib/${demo}.pl";
- if (defined $DEMO_FILE) {
- do $DEMO_FILE ;
- } else { warn "No such demo: $demo.pl in either $WIDTRIB/ or $zinc_lib/\n"; }
- warn $@ if $@;
- }
- $T->Unbusy;
- goto &$::AUTOLOAD if defined &$::AUTOLOAD;
-
-} # end AUTOLOAD
-
-sub invoke {
-
- # This procedure is called when the user clicks on a demo description.
-
- my($text) = @_;
-
- my $index = $text->index('current');
- my @tags = $T->tagNames($index);
- my $i = lsearch('demo\-.*', @tags);
- return if $i < 0;
- my($demo) = $tags[$i] =~ /demo-(.*)/;
- $T->tagAdd('visited', "$index linestart", "$index lineend");
- {
- no strict 'refs';
- &$demo($demo);
- }
-
-} # end invoke
-
-sub lsearch {
-
- # Search the list using the supplied regular expression and return it's
- # ordinal, or -1 if not found.
-
- my($regexp, @list) = @_;
- my($i);
-
- for ($i=0; $i<=$#list; $i++) {
- return $i if $list[$i] =~ /$regexp/;
- }
- return -1;
-
-} # end lsearch
-
-sub see_code {
-
- # This procedure creates a toplevel window that displays the code for
- # a demonstration and allows it to be edited and reinvoked.
-
- my($demo) = @_;
-
- my $file = "${demo}.pl";
- if (not Exists $CODE) {
- $CODE = $MW->Toplevel;
- my $code_buttons = $CODE->Frame;
- $code_buttons->pack(qw/-side bottom -fill x/);
- my $code_buttons_dismiss = $code_buttons->Button(
- -text => 'Dismiss',
- -command => [$CODE => 'withdraw'],
- );
- $CODE_RERUN = $code_buttons->Button(-text => 'Rerun Demo');
- $CODE_TEXT = $CODE->Scrolled('Text',
- qw/-scrollbars e -height 40 -setgrid 1/);
- $code_buttons_dismiss->pack(qw/-side left -expand 1/);
- $CODE_RERUN->pack(qw/-side left -expand 1/);
- $CODE_TEXT->pack(qw/-side left -expand 1 -fill both/);
- } else {
- $CODE->deiconify;
- $CODE->raise;
- }
- $CODE_RERUN->configure(-command => sub {
- eval $CODE_TEXT->get(qw/1.0 end/);
- {
- no strict 'refs';
- &$demo($demo);
- }
- });
- $CODE->iconname($file);
- $file = "$WIDTRIB/${demo}.pl" if -f "$WIDTRIB/${demo}.pl";
- $file = "$zinc_lib/${demo}.pl" if -f "$zinc_lib/${demo}.pl";
- $CODE->title("Demo code: $file");
- $CODE_TEXT->delete(qw/1.0 end/);
- open(CODE, "<$file") or warn "Cannot open demo file $file: $!";
- {
- local $/ = undef;
- $CODE_TEXT->insert('1.0', <CODE>);
- }
- close CODE;
- $CODE_TEXT->markSet(qw/insert 1.0/);
-
-} # end see_code
-
-sub see_vars {
-
- # Create a top-level window that displays a bunch of global variable values
- # and keeps the display up-to-date even when the variables change value.
- # $args is a pointer to a list of list of 2:
- #
- # ["variable description", \$VAR]
- #
- # The old trick of passing a string to serve as the description and a soft
- # reference to the variable no longer works with lexicals and use strict.
-
- my($parent, $args) = @_;
-
- $VARS->destroy if Exists($VARS);
- $VARS = $parent->Toplevel;
- $VARS->geometry('+300+300');
- $VARS->title('Variable Values');
- $VARS->iconname('Variables');
-
- my $title = $VARS->Label(
- -text => 'Variable Values:',
- -width => 20,
- -anchor => 'center',
- -font => '-*-helvetica-medium-r-normal--*-180-*-*-*-*-*-*',
- );
- $title->pack(qw/-side top -fill x/);
- my($label, $var);
- foreach my $i (@$args) {
- ($label, $var) = @$i;
- my $wf = $VARS->Frame->pack(qw/-anchor w/);
- $wf->Label(-text => "$label: ")->pack(qw/-side left/);
- $wf->Label(-textvariable => $var)->pack(qw/-side left/);
- }
- $VARS->Button(-text => 'OK', -command => [$VARS => 'destroy'])->
- pack(qw/-side bottom -pady 2/);
-
-} # end see_vars
-
-sub show_stat {
-
- # Display name of current demonstration. $sv is a reference to the
- # status Label -textvariable, $text is the Text widget reference and
- # $index is the demonstration index in the Text widget.
-
- my($sv, $text, $index) = @_;
-
- my @tags = $text->tagNames($index);
- my $i = lsearch('demo\-.*', @tags);
- return if $i < 0;
- my($demo) = $tags[$i] =~ /demo-(.*)/;
- $$sv = "Click Button-1 to run the \"$demo\" demonstration.";
-
-} # end show_stat
-
-sub view_widget_code {
-
- # Expose a file's innards to the world too, but only for viewing.
-
- my($widget) = @_;
-
- if (not Exists $VIEW) {
- $VIEW = $MW->Toplevel;
- $VIEW->iconname('widget');
- my $view_buttons = $VIEW->Frame;
- $view_buttons->pack(qw/-side bottom -expand 1 -fill x/);
- my $view_buttons_dismiss = $view_buttons->Button(
- -text => 'Dismiss',
- -command => [$VIEW => 'withdraw'],
- );
- $view_buttons_dismiss->pack(qw/-side left -expand 1/);
- $VIEW_TEXT = $VIEW->Scrolled('Text',
- qw/-scrollbars e -height 40 -setgrid 1/);
- $VIEW_TEXT->pack(qw/-side left -expand 1 -fill both/);
- } else {
- $VIEW->deiconify;
- $VIEW->raise;
- }
- $VIEW->title("Demo code: $widget");
- $VIEW_TEXT->configure(qw/-state normal/);
- $VIEW_TEXT->delete(qw/1.0 end/);
- open(VIEW, "<$widget") or warn "Cannot open demo file $widget: $!";
- {
- local $/ = undef;
- $VIEW_TEXT->insert('1.0', <VIEW>);
- }
- close VIEW;
- $VIEW_TEXT->markSet(qw/insert 1.0/);
- $VIEW_TEXT->configure(qw/-state disabled/);
-
-} # end view_widget_code
-
-__END__
-
-=head1 NAME
-
-zinc-demos - Demonstration of TkZinc widget functionnality
-
-=head1 SYNOPSYS
-
- zinc-demos [ directory ]
-
-=head1 DESCRIPTION
-
-This script demonstrates the various functions offered by Tk Zinc widget.
-This file only contains code to
-generate the main window for the application, which invokes individual
-demonstrations. The code for the actual demonstrations is contained in
-separate ".pl" files in the "zinc_lib" directory, which are autoloaded
-by this script as needed.
-
-widget looks in the directory specified on the command line to load user
-contributed demonstrations. If no directory name is specified when widget is
-invoked and the environment variable WIDTRIB is defined then demonstrations
-are loaded from the WIDTRIB directory. If WIDTRIB is undefined then widget
-defaults to the released user contributed directory, "zinc_contrib_lib".
-
-=head2 History
-
- #
- # Stephen O. Lidie, LUCC, 96/03/11. lusol@Lehigh.EDU
- # Stephen O. Lidie, LUCC, 97/01/01. lusol@Lehigh.EDU
- # Stephen O. Lidie, LUCC, 97/02/11. lusol@Lehigh.EDU
- # Stephen O. Lidie, LUCC, 97/06/07. lusol@Lehigh.EDU
- # Update for Tk402.00x. Total revamp: WidgetDemo, Scrolled, released
- # composites, -menuitems, qw//, etcetera. Perl 5.004 required.
- # Stephen O. Lidie, LUCC, 98/03/10. lusol@Lehigh.EDU
- # Update for Tk8.
- # Stephen O. Lidie, LUCC, 98/06/26. Stephen.O.Lidie@Lehigh.EDU
- # Add Common Dialogs for Tk800.007.
- # Stephen.O.Lidie@Lehigh.EDU, 1999/11/29, Lehigh University.
- # Demo some "dash patch" changes.
- # Stephen.O.Lidie@Lehigh.EDU, 2000/01/11, Lehigh University.
- # Update menubar to Tk 8, fix color palette Menubutton demo.
- # Stephen.O.Lidie@Lehigh.EDU, 2000/07/06, Lehigh University.
- # Remove inswt() from widget and styles.pl to show the proper Perl/Tk
- # idiom for inserting Text tags. Various and sundry cleanups.
- # Christophe Mertz <mertz@cena.fr>, 2002/03/06, CENA fr
- # adaptation for zinc demos purposes.
-
-=head1 AUTHOR
-
-Steve Lidie <Stephen.O.Lidie@Lehigh.EDU> and slight adaptation by Christophe Mertz <mertz@cena.fr>
-
-=head1 SEE ALSO
-
-The zinc documentation is available as a pdf file refman.pdf and as an html pages refman/index.html
-
-=cut
diff --git a/Perl/export2cpan b/Perl/export2cpan
deleted file mode 100755
index 232f42c..0000000
--- a/Perl/export2cpan
+++ /dev/null
@@ -1,173 +0,0 @@
-#!/usr/bin/perl
-
-#
-# If we want to extract a release right out of the repository
-# just pass the release tag as first parameter and the script
-# will leave a tarball in the current directory after chewing
-# a moment in /tmp.
-# the first argument should be a CVS tag looking like cpan_3_2_95
-# or cpan_3_295. The second underscore will be removed for computing the
-#
-
-# In the other case (no parameters) the script supposes we are
-# in the Perl subdir of a Tkzinc working directory and it will
-# setup zinc-perl for compilation in export2cpan/tk-zinc-<version>.
-# The source files are taken from the working directory. This is
-# the anticipated behavior when developping/testing or making
-# a debian package from the rules file.
-# $Id$
-
-use strict;
-
-my $ZINC_PREFIX = 'tk-zinc';
-my $DEFAULT_SERVER = 'liszt.pii.ath.cena.fr';
-my $TMP = '/tmp/forCPAN';
-
-# computing major, minor and patchlevel from var defined in ../configure.in
-sub version4cpan {
- my $configure_in = "../configure.in";
-
- open(FD, "<$configure_in") or die "Could not open file $configure_in";
-
- my ($major, $minor, $patchlevel);
- while (<FD>) {
- if (/^MAJOR_VERSION=(\d+)/)
- {
- $major = $1;
- }
- elsif (/^MINOR_VERSION=(\d+)/)
- {
- $minor = $1;
- }
- elsif (/^PATCHLEVEL=(\d+)/)
- {
- $patchlevel = $1;
- }
- }
-
- close (FD);
-
- return "$major.$minor$patchlevel";
-}
-
-my $VERSION;
-my $FROM_CVS = (scalar(@ARGV) != 0);
-my $DIR_FROM_CVS;
-my $CWD;
-chomp($CWD = `pwd`);
-#
-# See if parameters are given (there should be a cvs tag
-# and may be the repository machine).
-#
-if ($FROM_CVS) {
- my $tag_version;
- my $cvstag = $ARGV[0];
- my $server = $DEFAULT_SERVER;
- if (scalar(@ARGV) == 2) {
- $server = $ARGV[1];
- }
- print "Building a CPAN release tarball from tag $cvstag.\n";
- $cvstag =~ /^.*?([\d_]+)$/;
- my $tag_version = $1;
- if ($tag_version =~ /(\d+)_(\d+)_(\d+)/) {
- $tag_version = "$1_$2$3";
- }
- $VERSION = version4cpan; # version computed from the source directory
- $DIR_FROM_CVS = "$ZINC_PREFIX-$VERSION";
- system("rm -rf $TMP");
- system ("mkdir $TMP");
- chdir("$TMP");
- # the following command always fail with cvs 1.11.1p1 !!
- # my $command = "cd $TMP; cvs -d $server:/pii/repository export -r $cvstag -d $DIR_FROM_CVS Tkzinc";
- my $command = "cd $TMP; cvs -d /pii/repository export -r $cvstag -d $DIR_FROM_CVS Tkzinc";
- print "$command\n";
- my $error = system($command);
- die "CVS extraction did not succeed" if $error;
- chdir("$DIR_FROM_CVS/Perl");
- my $EXTRACTED_VERSION = version4cpan; # version gotten from the tagged CVS files
- if ($EXTRACTED_VERSION ne $VERSION) {
- print "Oops! the tag version '$tag_version' does not match the version '$VERSION' in the sources, aborting\n";
- exit(1);
- }
- system ("cd $TMP/$DIR_FROM_CVS; ./configure");
-}
-else {
- $VERSION = version4cpan;
- print "cd ..; ./configure\n";
- system ("cd ..; ./configure"); # for creating Zinc.pm and Makefile.pl from xxx.in files
-}
-
-print "VERSION $VERSION\n";
-
-# using rsync if available rather than cp
-my $CP = 'cp -r';
-my $CPonlyIfDifferent = 'cp -r';
-my $RSYNC = 0;
-if (-x '/usr/bin/rsync') {
- $CP = '/usr/bin/rsync -rp'; # the --delete option has been removed to avoid deleting Makefile in demos
- $CPonlyIfDifferent = '/usr/bin/rsync -rc';
-# print "\$CP = '$CP'\n";
- $RSYNC = 1;
-} elsif (-x '/usr/local/bin/rsync') {
- $CP = '/usr/local/bin/rsync -rp'; # the --delete option has been removed to avoid deleting Makefile in demos
- $CPonlyIfDifferent = '/usr/local/bin/rsync -rc';
-# print "\$CP = '$CP'\n";
- $RSYNC = 1;
-}
-
-my $EXPORT_DIR = '../export2cpan';
-my $VERSION_DIR = "$ZINC_PREFIX-$VERSION";
-
-if (-d "$EXPORT_DIR/$VERSION_DIR" and !$RSYNC) {
- system("rm -rf $EXPORT_DIR/$VERSION_DIR");
-}
-
-if (! -d $EXPORT_DIR) {
- mkdir($EXPORT_DIR);
-}
-if (! -d "$EXPORT_DIR/$VERSION_DIR") {
- mkdir("$EXPORT_DIR/$VERSION_DIR");
-}
-symlink ("$EXPORT_DIR/$VERSION_DIR", "$EXPORT_DIR/$ZINC_PREFIX");
-
-my @files=('t', 'Zinc.xs', 'demos', 'README', 'Zinc');
-
-
-foreach my $f (@files) {
- system("$CP $f $EXPORT_DIR/$VERSION_DIR");
-}
-
-
-system("$CP Zinc.pm $EXPORT_DIR/$VERSION_DIR");
-system("$CP Makefile.PL $EXPORT_DIR/$VERSION_DIR");
-system("$CP ../libtess/*.c $EXPORT_DIR/$VERSION_DIR");
-system("$CP ../libtess/*.h $EXPORT_DIR/$VERSION_DIR");
-system("$CP ../generic/*.c $EXPORT_DIR/$VERSION_DIR");
-system("$CP ../generic/*.h $EXPORT_DIR/$VERSION_DIR");
-system("$CP ../win/*.c $EXPORT_DIR/$VERSION_DIR");
-
-
-#
-# If working for an exported copy, build a tarball in the
-# current dir.
-#
-if ($FROM_CVS) {
- chdir("$EXPORT_DIR/$VERSION_DIR");
-
- #
- # Remove the .cvsignore files
- system('find . -name .cvsignore | xargs rm -f');
-
- #
- # Create the MANIFEST file
- use ExtUtils::Manifest qw( mkmanifest );
- $ExtUtils::Manifest::Quiet = 1;
- &mkmanifest();
-
- chdir('..');
-
- system("tar zcf $TMP/$ZINC_PREFIX-$VERSION.tar.gz $VERSION_DIR");
- chdir($CWD);
- print "The tarball is in $TMP/$ZINC_PREFIX-$VERSION.tar.gz\n";
- print "You may want to clean up after testing in $TMP/$DIR_FROM_CVS\n";
-}
diff --git a/Perl/t/.cvsignore b/Perl/t/.cvsignore
deleted file mode 100644
index 532f21c..0000000
--- a/Perl/t/.cvsignore
+++ /dev/null
@@ -1,2 +0,0 @@
-*.log
-*.log.prev
diff --git a/Perl/t/AnimatedGradient.t b/Perl/t/AnimatedGradient.t
deleted file mode 100644
index e65f9a3..0000000
--- a/Perl/t/AnimatedGradient.t
+++ /dev/null
@@ -1,175 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: AnimatedGradient.t,v 1.1 2004-09-20 20:07:06 mertz Exp $
-# Author: Christophe Mertz mertz@intuilab.com
-#
-
-# this test mainly does funny effects when openGL is on
-
-
-# testing all the import
-
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 18;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc;
- 1;
- }) {
- print "unable to load Tk::Zinc";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-use strict;
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 200, -height => 200, -backcolor => "white",
- -render => 1)->pack;
-
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc has been created");
-
-$zinc->add('text', 1, -position => [10,5], -text =>
-"the gradient fills a rectangle
-which is clipped by the curve
-made of two circles...\n"x5);
-
-
-my $circle1 = $zinc->add('arc', 1, [20,20,180,180]);
-my $circle2 = $zinc->add('arc', 1, [70,70,130,130]);
-
-my $curve = $zinc->add('curve', 1, [],
- -fillcolor => 'red', -filled => 1, -linewidth => 1);
-$zinc->contour($curve, 'add', 1, $circle1);
-$zinc->contour($curve, 'add', -1, $circle2);
-
-$zinc->remove($circle1);
-$zinc->remove($circle2);
-
-my $gradient;
-for (1..4) {
- for (my $i = 0; $i <=360; $i++) {
- $gradient = "=axial $i | red | white 50 | blue";
- $zinc->itemconfigure($curve, -fillcolor => $gradient);
- $zinc->update;
- }
-}
-pass("turning gradient one side");
-
-for (1..4) {
- for (1..100) {
- $zinc->translate($curve,0.5,0.5);
- $zinc->update;
- }
- for (1..800) {
- $zinc->rotate($curve, 3.14159/400, 100,100);
- $zinc->update;
- }
- for (1..100) {
- $zinc->translate($curve,0.5,0.5);
- $zinc->update;
- }
-
- for (1..400) {
- $zinc->translate($curve,-0.5,-0.5);
- $zinc->update;
- }
- for (1..200) {
- $zinc->translate($curve,0.5,0.5);
- $zinc->update;
- }
- pass ("shaking the circle around");
-}
-
-for (1..4) {
- for (my $i = 359; $i > 0; $i--) {
- $gradient = "=axial $i | red | white 50 | blue";
- $zinc->itemconfigure($curve, -fillcolor => $gradient);
- $zinc->update;
- }
-}
-pass("turning gradient the other side");
-
-
-my $gr = $zinc->add('group', 1);
-my $rect = $zinc->add('rectangle', $gr, [0,-480,200,180], -filled => 1,
- -fillcolor => "=axial 90 |blue|white 10|red 20|white 30|blue 40|white 50|red 60|white 70|blue 80|white 90|red");
-
-$zinc->chggroup($curve, $gr);
-$zinc->itemconfigure($curve, -visible => 0);
-
-$zinc->itemconfigure($gr, -clip => $curve);
-
-
-pass("displaying a translated rectangle filled with froggy colors and clipped by two circles");
-for (1..2) {
- for (my $i = 0; $i<500 ; $i++) {
- $zinc->translate($rect, 0,1);
- $zinc->update;
- }
- for (my $i = 0; $i<500 ; $i++) {
- $zinc->translate($rect, 0,-1);
- $zinc->update;
- }
- pass ("a thousand translation");
-}
-
-$zinc->translate($rect, 0,250);
-
-
-for (1..1000) {
- $zinc->scale($rect, 1, 0.998, 100,100);
- $zinc->update;
-}
-pass("a thousand scaling down");
-
-
-for (1..360) {
- $zinc->rotate($rect, 3.14159/180, 100,100);
- $zinc->update;
-}
-pass("360 rotation of 1°");
-
-
-for (1..360) {
- $zinc->rotate($rect, -3.14159/180, 100,100);
- $zinc->update;
-}
-pass("360 rotation of 1°");
-
-
-for (1..360) {
- $zinc->rotate($rect, -3.14159/180, 100,100);
- $zinc->update;
-}
-
-
-for (1..1000) {
- $zinc->scale($rect, 1, 1/0.998, 100,100);
- $zinc->update;
-}
-pass("a thousand scaling up");
-
-
-
-for (1..4) {
- for my $i (0..200) {
- $zinc->itemconfigure($gr, -alpha => (200-$i)/2);
- $zinc->update;
- }
- for my $i (0..200) {
- $zinc->itemconfigure($gr, -alpha => $i/2);
- $zinc->update;
- }
- pass("fade out/in in 400 steps");
-}
diff --git a/Perl/t/Bbox.t b/Perl/t/Bbox.t
deleted file mode 100644
index 5840fc3..0000000
--- a/Perl/t/Bbox.t
+++ /dev/null
@@ -1,242 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: Bbox.t,v 1.7 2004-11-16 20:46:14 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing all the import
-
-BEGIN {
- if (!eval q{
- use Test::More tests => 12;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc;
- use Tk::Font;
- 1;
- }) {
- print "unable to load Tk::Zinc";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- MainWindow->new();
- 1;
- }) {
- print "# tests only work properly when it is possible to create a mainwindow in your env\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-
-$mw = MainWindow->new();
-$zinc = $mw->Zinc(-width => 400, -height => 400)->pack;
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc has been created");
-
-my $coords = [ [10,10], [40, 40] ];
-
-
-my $font = $zinc->fontCreate('font20pixels', -size => -20);
-#my @metrics = $zinc->fontMetrics('font20pixels');
-#print "metrics = @metrics\n";
-my $linespace = $zinc->fontMetrics('font20pixels', -linespace);
-
-my $txt1 = $zinc->add('text', 1,
- -font => 'font20pixels',
- -alignment => 'center',
- #-text => 'text', # an empty text
- -position => [30,25],
- );
-#print "bbox=(", join(',', $zinc->bbox($txt1)),")\n";
-
-# from v3.30 the bbox of an empty text is ()
-ok(&similarFlatArray ([$zinc->bbox($txt1)],
- [],
- [],
- ),
- "bbox of empty text");
-
-my $width = $zinc->fontMeasure('font20pixels', 'dummy');
-#print "width = $width\n";
-my $txt2 = $zinc->add('text', 1,
- -font => 'font20pixels',
- -alignment => 'left',
- -text => 'dummy',
- -position => [200,100],
- );
-# print "bbox=(", join(',', $zinc->bbox($txt2)),")\n";
-
-ok(&similarFlatArray ([$zinc->bbox($txt2)],
- [200,100, 200+$width, 100+$linespace],
- [4,4, 4,4 ],
- ),
- "bbox of 'dummy' text");
-
-my $txt3 = $zinc->add('text', 1,
- -font => 'font20pixels',
- -alignment => 'center',
- -text => 'dummy',
- -position => [200,200],
- );
-# print "bbox=(", join(',', $zinc->bbox($txt3)),")\n";
-
-ok(&similarFlatArray ([$zinc->bbox($txt3)],
- [200,200, 200+$width, 200+$linespace],
- [4,4, 4,4 ],
- ),
- "bbox of 'dummy' aligned-centered text");
-
-my $txt4 = $zinc->add('text', 1,
- -font => 'font20pixels',
- -anchor => 'center',
- -text => 'dummy',
- -position => [200,100],
- );
-# print "bbox=(", join(',', $zinc->bbox($txt4)),")\n";
-
-ok(&similarFlatArray ([$zinc->bbox($txt4)],
- [200-$width/2,100-$linespace/2, 200+$width/2, 100+$linespace/2],
- [4,4, 4,4 ],
- ),
- "bbox of 'dummy' centered text");
-
-
-### testing bbox of fields or labels of track/waypoint and tabular items
-my $track = $zinc->add('track', 1, 4, -position => [56, 78]);
-# print "bbox11=(", $bbox,")\n";
-
-is($zinc->bbox(-label, $track), (),
- "bbox of a track label without labelformat is ()");
-
-my $bbox = $zinc->bbox(-field, 0, $track);
-#print "bbox22=(", $bbox,")\n";
-
-is( $bbox, undef, "bbox of a track field without labelformat is undef");
-
-
-$zinc->itemconfigure($track, -labelformat => 'x20x18+0+0');
-#print "bbox=(", join(',', $zinc->bbox(-label, $track)),")\n";
-
-$bbox = eval { $zinc->bbox(-field, 4, $track) } ;
-#print "bbox=(", $bbox,")\n";
-
-is( $bbox, (),
- "bbox of a track field which field is out of bound is undef");
-
-my $wpt = $zinc->add('waypoint', 1, 0, -position => [561, 781]);
-#print "wpt bbox=(", join(',', $zinc->bbox($wpt)),")\n";
-ok(&similarFlatArray ([ $zinc->bbox($wpt) ],
- [ 561,781, 561,781],
- [4,4, 4,4],
- ),
- "coords of a waypoint without label");
-
-
-my $tab = $zinc->add('tabular', 1, 1, -position => [61, 81]);
-is_deeply([ $zinc->bbox($tab) ],
- [ ],
- "bbox of a tabular without labelformat");
-
-#print "tab bbox=(", join(',', $zinc->bbox(-label, $tab)),")\n";
-is_deeply([ $zinc->bbox(-label, $tab) ],
- [ ],
- "bbox of a tabular without labelformat");
-
-#print "tab bbox=(", join(',', $zinc->bbox(-field, 0, $tab)),")\n";
-is_deeply([ $zinc->bbox(-field, 0, $tab) ],
- [ ],
- "bbox of a tabular field without labelformat");
-
-
-# $zinc->itemconfigure($tab, -labelformat => 'x20x18+0+0');
-# is_deeply([ $zinc->coords($tab) ],
-# [ 61,81 ],
-# "coords of a tabular with a labelformat");
-
-
-
-
-sub similarPoints {
- my ($ref1, $ref2)= @_;
- diag ("waiting a reference for \$ref1" . ref ($ref1)), return 0 unless ref ($ref1) eq 'ARRAY';
- diag ("waiting a reference for \$ref2"), return 0 unless ref ($ref2) eq 'ARRAY';
-
- my @array1 = @{$ref1};
- my @array2 = @{$ref2};
-
- diag ("arrays for \$ref1 and \$ref2 are not of same length"), return 0
- unless scalar @array1 == @array2;
-
- for my $i (0.. $#array1) {
- my $pt1 = $array1[$i];
- my $pt2 = $array2[$i];
- diag ("waiting a reference to a point in elt $i \$ref1"), return 0
- unless ref $pt1 eq 'ARRAY';
- my (@pt1) = @{$pt1};
- diag ("waiting a reference to a point (x,y) in elt $i \$ref1"), return 0
- unless scalar @pt1 == 2 and &numerical($pt1[0]) and &numerical($pt1[1]) ;
-
- diag ("waiting a reference to a point in elt $i \$ref1"), return 0
- unless ref $pt2 eq 'ARRAY';
- my (@pt2) = @{$pt2};
- diag ("waiting a reference to a point (x,y) in elt $i \$ref2"), return 0
- unless scalar @pt2 == 2 and &numerical($pt2[0]) and &numerical($pt2[1]) ;
-
- diag ("delta > 0.001 between x of pt$i"), return 0 if abs($pt1[0]-$pt2[0]) > 0.001;
- diag ("delta > 0.001 between y of pt$i"), return 0 if abs($pt1[1]-$pt2[1]) > 0.001;
- }
- return 1;
-}
-
-## ref1 is the obtained array
-## ref2 is the expected array
-sub similarFlatArray {
- my ($ref1, $ref2, $deltaref)= @_;
- diag ("waiting a reference for \$ref1"), return 0 unless ref ($ref1) eq 'ARRAY';
- diag ("waiting a reference for \$ref2"), return 0 unless ref ($ref2) eq 'ARRAY';
- diag ("waiting a reference for \$deltaref"), return 0 unless ref ($deltaref) eq 'ARRAY';
-
- my @array1 = @{$ref1};
- my @array2 = @{$ref2};
- my @deltaarray = @{$deltaref};
- diag ("arrays obtained, expected and deltas are not of same length,".$#array1.",".$#array2.",".$#deltaarray), return 0
- unless ($#array1 == $#array2) and ($#array2 == $#deltaarray);
- for my $i (0.. $#array1) {
- my $a = $array1[$i];
- my $b = $array2[$i];
- my $delta = $deltaarray[$i];
- diag ("waiting a numeric value for elt $i of obtained array"), return 0
- unless &numerical($a);
- diag ("waiting a numeric value for elt $i of expected array"), return 0
- unless &numerical($b);
- diag ("waiting a numeric value for elt $i of deltas array"), return 0
- unless &numerical($delta);
-
- diag ("delta > $delta between elt $i of obtained array ($a) and expected array ($b)"), return 0
- if (abs($a-$b) > $delta) ;
- }
- return 1;
-}
-
-
-sub numerical {
- my ($v) = @_;
- return 0 unless defined $v;
- ### this really works!!
- return $v eq $v*1;
- }
-
-
-diag("############## bbox test");
-
-
diff --git a/Perl/t/Coords.t b/Perl/t/Coords.t
deleted file mode 100644
index b8c4662..0000000
--- a/Perl/t/Coords.t
+++ /dev/null
@@ -1,151 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: Coords.t,v 1.6 2004-05-24 19:56:23 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing all the import
-
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 21;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc;
- 1;
- }) {
- print "unable to load Tk::Zinc";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- MainWindow->new();
- 1;
- }) {
- print "# tests only work properly when it is possible to create a mainwindow in your env\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-
-$mw = MainWindow->new();
-$zinc = $mw->Zinc(-width => 100, -height => 100);
-
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc has been created");
-
-my $rect = $zinc->add('rectangle', 1, [10,20,40,50]);
-
-
-is_deeply([ $zinc->coords($rect) ],
- [ [10,20], [40, 50] ],
- "coords are list of arrays");
-
-is_deeply([ $zinc->coords($rect,0) ],
- [ [10,20], [40, 50] ],
- "coords of first contour is a list of arrays");
-
-is_deeply([ $zinc->coords($rect,0,0) ],
- [ 10,20 ],
- "coords of one point of a contour is a list of two numbers");
-
-is_deeply([ $zinc->coords($rect,0,1) ],
- [ 40,50 ],
- "coords of one point of a contour is a list of two numbers");
-
-my $curve = $zinc->add('curve', 1, [ [10,20] ,[40,50,'c'], [90,10,'c'], [30,60] ]);
-
-is_deeply([ $zinc->coords($curve) ],
- [ [10,20] ,[40,50,'c'], [90,10,'c'], [30,60] ],
- "coords of a curve is a list of arrays");
-
-is_deeply([ $zinc->coords($curve,0) ],
- [ [10,20] ,[40,50,'c'], [90,10,'c'], [30,60] ],
- "coords of contour 0 of a curve is a list of arrays");
-
-is_deeply([ $zinc->coords($curve,0,0) ],
- [ 10,20 ],
- "coords of first point of contour 0 of a curve is list of two numbers");
-
-is_deeply([ $zinc->coords($curve,0,1) ],
- [ 40,50,'c' ],
- "coords of a control point of a curve contour is list of three elements");
-
-my $text = $zinc->add('text', 1, -position => [10,20], -text => 'test');
-
-is_deeply([ $zinc->coords($text) ],
- [ 10,20 ],
- "coords of a text");
-
-is_deeply([ $zinc->coords($text,0) ],
- [ 10,20 ],
- "coords of text contour");
-
-is_deeply([ $zinc->coords($text,0,0) ],
- [ 10,20 ],
- "coords of text contour first point");
-
-
-my $group = $zinc->add('group', 1);
-
-is_deeply([ $zinc->coords($group) ],
- [ 0,0 ],
- "coords of a empty group, not moved");
-
-$zinc->translate($group, 23, 45);
-#my @coords = @{$zinc->coords($group)}[0];
-#print "coords = @coords", $coords[0][0], $coords[0][1], "\n";
-is_deeply([ $zinc->coords($group) ],
- [ 23,45 ],
- "coords of a empty group, translated");
-
-
-my $track = $zinc->add('track', 1, 0, -position => [56, 78]);
-is_deeply([ $zinc->coords($track) ],
- [ 56,78 ],
- "coords of a track");
-
-my $wpt = $zinc->add('waypoint', 1, 0, -position => [561, 781]);
-is_deeply([ $zinc->coords($wpt) ],
- [ 561,781 ],
- "coords of a waypoint");
-
-my $tab = $zinc->add('tabular', 1, 1, -position => [61, 81]);
-is_deeply([ $zinc->coords($tab) ],
- [ 61,81 ],
- "coords of a empty tabular");
-$zinc->itemconfigure($tab, -labelformat => 'x20x18+0+0');
-is_deeply([ $zinc->coords($tab) ],
- [ 61,81 ],
- "coords of a tabular with a labelformat");
-
-
-my $arc = $zinc->add('arc', 1, [13,31, 42,24]);
-is_deeply([ $zinc->coords($arc) ],
- [ [13,31], [42,24] ],
- "coords of an arc");
-
-my $tri = $zinc->add('triangles', 1, [ [10,20], [30,40], [50,60], [70,80], [90,99] ]);
-is_deeply([ $zinc->coords($tri) ],
- [ [10,20], [30,40], [50,60], [70,80], [90,99] ],
- "coords of an triangle");
-
-my $photoMickey = $zinc->Photo('mickey.gif', -file => Tk->findINC("demos/images/mickey.gif"));
-my $icon = $zinc->add('icon', 1, -position => [20,100], -image => $photoMickey);
-is_deeply([ $zinc->coords($icon) ],
- [ 20,100 ],
- "coords of an icon");
-
-diag("############## coords test");
-
-
diff --git a/Perl/t/Images.t b/Perl/t/Images.t
deleted file mode 100644
index 99111c5..0000000
--- a/Perl/t/Images.t
+++ /dev/null
@@ -1,212 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: Images.t,v 1.5 2004-05-12 12:33:33 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing all the -tile, -image, -mask, -fillpattern, -linepattern widget and items options
-
-# this script can be used with an optionnal argument, an integer giving
-# the delay in seconds during which the graphic updates will be displayed
-# this is usefull for visual inspection!
-
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 36;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc;
- 1;
- }) {
- print "unable to load Tk::Zinc";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- $mw = MainWindow->new();
- 1;
- }) {
- print "# tests only work properly when it is possible to create a mainwindow in your env\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-
-$zinc = $mw->Zinc(-render => 0,
- -width => 400, -height => 400)->pack;
-
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc has been created");
-
-#### creating different images, bitmaps and pixmaps...
-my $photoMickey = $zinc->Photo('mickey.gif', -file => Tk->findINC("demos/images/mickey.gif"));
-like ($photoMickey, qr/^Tk::Photo=HASH/ , "creating a Tk::Photo with a .gif");
-
-my $bitmap = $zinc->Bitmap('file.xbm', -file => Tk->findINC("file.xbm"));
-like ($bitmap, qr/^Tk::Bitmap=HASH/ , "creating a Tk::Bitmap with a .xbm");
-
-my $xpm = $zinc->Photo('QuitPB.xpm', -file => Tk->findINC("demos/images/QuitPB.xpm"));
-like ($xpm, qr/^Tk::Photo=HASH/ , "creating a Tk::Photo with a .xpm");
-
-#### tiling Tk::Zinc
-$zinc->configure(-tile => $xpm);
-if ($Tk::VERSION < 804) {
- is ($zinc->cget(-tile), "QuitPB.xpm", "verifying Tk::Zinc -tile option value");
-} else {
- is ($zinc->cget(-tile), $xpm, "verifying Tk::Zinc -tile option value");
-}
-
-&wait ("-tile of Tk::Zinc with QuitPB.xpm");
-
-$zinc->configure(-tile => $photoMickey);
-if ($Tk::VERSION < 804) {
- is ($zinc->cget(-tile), "mickey.gif", "verifying Tk::Zinc -tile option value");
-} else {
- is ($zinc->cget(-tile), $photoMickey, "verifying Tk::Zinc -tile option value");
-}
-&wait ("-tile of Tk::Zinc with mickey.gif");
-
-# modifying the Tk::Photo to see if the Tk::Zinc -tile changes
-$photoMickey->read( Tk->findINC("demos/images/earth.gif") );
-&wait ("-tile of Tk::Zinc should display the earth VISUAL INSPECTION!"); sleep 1;
-# going back to the "real" mickey
-$photoMickey->read( Tk->findINC("demos/images/mickey.gif") );
-&wait ("-tile of Tk::Zinc should display mickey again VISUAL INSPECTION!"); sleep 1;
-
-$zinc->configure(-tile => "");
-if ($Tk::VERSION < 804) {
- is ($zinc->cget(-tile), "", "removing Tk::Zinc -tile");
-} else {
- is ($zinc->cget(-tile), undef, "removing Tk::Zinc -tile");
-}
-&wait ("-tile of Tk::Zinc with nothing");
-
-
-
-#### rectangle item
-my $rect1 = $zinc->add('rectangle', 1, [10,10,190,190], -filled => 1);
-
-
-$zinc->itemconfigure($rect1, -tile => $xpm);
-is ($zinc->itemcget($rect1, -tile), "QuitPB.xpm", "verifying rectangle -tile option value");
-&wait ("-tile of rectangle with QuitPB.xpm");
-
-$zinc->itemconfigure($rect1, -tile => $photoMickey);
-is ($zinc->itemcget($rect1, -tile), "mickey.gif", "verifying rectangle -tile option value");
-&wait ("-tile of rectangle with mickey");
-
-# modifying the Tk::Photo to see if the rectangle -tile changes
-$photoMickey->read( Tk->findINC("demos/images/earth.gif") );
-&wait ("-tile of rectangle should display the earth VISUAL INSPECTION!"); sleep 1;
-# going back to the "real" mickey
-$photoMickey->read( Tk->findINC("demos/images/mickey.gif") );
-&wait ("-tile of rectangle should display mickey again VISUAL INSPECTION!"); sleep 1;
-
-
-$zinc->itemconfigure($rect1, -tile => "");
-is ($zinc->itemcget($rect1, -tile), "", "removing rectangle -tile");
-&wait ("-tile of rectangle with nothing");
-
-TODO: {
- local $TODO = "because it makes Tk::Zinc dying" if 1;
-
- # the next line makes Tk::Zinc (v3.29x) dying... so I comment it out the 3 next lines
- # $zinc->itemconfigure($rect1, -fillpattern => $bitmap);
- # is ($zinc->itemcget($rect1, -fillpattern), $bitmap, "verifying rectangle -fillpattern option value as a Tk::Bitmap");
- # &wait ("displaying a rectangle with -fillpattern as a Tk::Bitmap");
-}
-
-$zinc->itemconfigure($rect1, -fillpattern => 'AlphaStipple3');
-is ($zinc->itemcget($rect1, -fillpattern), 'AlphaStipple3', "verifying rectangle -fillpattern option value");
-&wait ("-fillpattern of rectangle with 'AlphaStipple3'");
-
-$zinc->itemconfigure($rect1, -fillpattern => "");
-is ($zinc->itemcget($rect1, -fillpattern), "", "removing rectangle -fillpattern");
-&wait ("-fillpattern of rectangle with nothing");
-
-
-$zinc->itemconfigure($rect1, -filled => 0,-linepattern => 'AlphaStipple3', -linecolor => "red");
-is ($zinc->itemcget($rect1, -linepattern), 'AlphaStipple3', "verifying rectangle -linepattern option value");
-&wait ("-linepattern of rectangle with 'AlphaStipple3'");
-
-$zinc->itemconfigure($rect1, -linepattern => "");
-is ($zinc->itemcget($rect1, -linepattern), "", "removing rectangle -linepattern");
-&wait ("-linepattern of rectangle with nothing");
-
-$zinc->remove($rect1);
-
-##### icon item
-my $icon1 = $zinc->add('icon', 1, -position => [20,100], -image => $photoMickey);
-&wait ("displaying an icon");
-
-$zinc->remove($icon1);
-
-my $icon2 = $zinc->add('icon', 1, -position => [40,100]);
-
-SKIP: {
- skip "with Tk::Zinc < 3.295", 4 if ($Tk::Zinc::VERSION < 3.295);
-
- $zinc->itemconfigure($icon2, -image => $bitmap);
-
- &wait ("displaying an icon with -image as a Tk::Bitmap");
- is ($zinc->itemcget($icon2, -image), 'file.xbm', "verifying icon -image option value as file.xbm");
- $zinc->itemconfigure($icon2, -image => "");
-
- $zinc->itemconfigure($icon2, -image => '@'.Tk->findINC("openfile.xbm"));
- is ($zinc->itemcget($icon2, -image), '@'.Tk->findINC("openfile.xbm"),"verifying icon -image option value as @/path/openfile.xbm");
- &wait ("displaying an icon with -image as a \@filename.xbm");
-}
-$zinc->remove($icon2);
-
-my $icon3 = $zinc->add('icon', 1, -position => [60,100], -mask => '@'.Tk->findINC("openfolder.xbm"),
- -color => "red");
-is ($zinc->itemcget($icon3, -mask), '@'.Tk->findINC("openfolder.xbm"),"verifying icon -mask option value as \@/path/openfolder.xbm");
-&wait ("displaying an icon with -mask as a \@filename.xbm");
-
-$zinc->itemconfigure($icon3, -image => "");
-is ($zinc->itemcget($icon3, -image), "", "removing icon -image");
-
-TODO: {
- local $TODO = "because it makes Tk::Zinc dying" if 1;
-
- # the next line makes Tk::Zinc (v3.29x) dying... so I comment it out the 3 next lines
- # $zinc->itemconfigure($icon3, -mask => $bitmap);
- # is ($zinc->itemcget($icon3, -mask), $bitmap, "verifying icon -mask option value as a Tk::Bitmap");
- # &wait ("displaying an icon with -mask as a Tk::Bitmap");
-}
-
-$zinc->remove($icon3);
-
-# We should also test that changing the content of a Tk::Photo should change the display of an icon
-
-
-
-sub wait {
- $zinc->update;
- ok (1, $_[0]);
-
- my $delay = $ARGV[0];
- if (defined $delay) {
- $zinc->update;
- if ($delay =~ /^\d+$/) {
- sleep $delay;
- } else {
- sleep 1;
- }
- }
-
-}
-
-
-
-diag("############## Images test");
diff --git a/Perl/t/Import.t b/Perl/t/Import.t
deleted file mode 100644
index a051e29..0000000
--- a/Perl/t/Import.t
+++ /dev/null
@@ -1,31 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: Import.t,v 1.2 2004-04-02 12:01:49 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing all the import
-
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 6;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-require_ok( 'Tk::Zinc' );
-require_ok( 'Tk::Zinc::Debug' );
-require_ok( 'Tk::Zinc::Trace' );
-# require_ok( 'Tk::Zinc::TraceErrors' ); # incompatible with the previous one
-# we do not test the previous, as it should be equivalent!
-require_ok( 'Tk::Zinc::Graphics' );
-require_ok( 'Tk::Zinc::Logo' );
-require_ok( 'Tk::Zinc::Text' );
-diag("############## all imports");
diff --git a/Perl/t/PreviousKnownBugs.t b/Perl/t/PreviousKnownBugs.t
deleted file mode 100644
index 934cdf7..0000000
--- a/Perl/t/PreviousKnownBugs.t
+++ /dev/null
@@ -1,61 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: PreviousKnownBugs.t,v 1.3 2004-04-02 12:01:49 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing all the import
-
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 2;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc;
- 1;
- }) {
- print "unable to load Tk::Zinc";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- MainWindow->new();
- 1;
- }) {
- print "# tests only work properly when it is possible to create a mainwindow in your env\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-#use Tk::Zinc;
-
-$mw = MainWindow->new();
-$zinc = $mw->Zinc(-width => 100, -height => 100);
-
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc has been created");
-
-# following bug detected by A. Lemort
-my $curve = $zinc->add('curve', 1, [[0, 0], [0, 100, 'c'], [100,100, 'c'], [100, 0]]) ;
-$zinc->coords($curve, [[500,0], [500, 100], [600, 100], [600, 0]]);
-
-my @coords = $zinc->coords($curve,0);
-
-
-is_deeply([ @coords ],
- [ [500,0], [500, 100], [600, 100], [600, 0] ],
- "lemort bug 17 sept 2003 v3.2.94; testing correct value");
-
-
-
-diag("############## all known bugs");
diff --git a/Perl/t/Test/Builder.pm b/Perl/t/Test/Builder.pm
deleted file mode 100644
index 6f3edd8..0000000
--- a/Perl/t/Test/Builder.pm
+++ /dev/null
@@ -1,1408 +0,0 @@
-package Test::Builder;
-
-use 5.004;
-
-# $^C was only introduced in 5.005-ish. We do this to prevent
-# use of uninitialized value warnings in older perls.
-$^C ||= 0;
-
-use strict;
-use vars qw($VERSION $CLASS);
-$VERSION = '0.17';
-$CLASS = __PACKAGE__;
-
-my $IsVMS = $^O eq 'VMS';
-
-# Make Test::Builder thread-safe for ithreads.
-BEGIN {
- use Config;
- if( $] >= 5.008 && $Config{useithreads} ) {
- require threads;
- require threads::shared;
- threads::shared->import;
- }
- else {
- *share = sub { 0 };
- *lock = sub { 0 };
- }
-}
-
-use vars qw($Level);
-my($Test_Died) = 0;
-my($Have_Plan) = 0;
-my $Original_Pid = $$;
-my $Curr_Test = 0; share($Curr_Test);
-my @Test_Results = (); share(@Test_Results);
-my @Test_Details = (); share(@Test_Details);
-
-
-=head1 NAME
-
-Test::Builder - Backend for building test libraries
-
-=head1 SYNOPSIS
-
- package My::Test::Module;
- use Test::Builder;
- require Exporter;
- @ISA = qw(Exporter);
- @EXPORT = qw(ok);
-
- my $Test = Test::Builder->new;
- $Test->output('my_logfile');
-
- sub import {
- my($self) = shift;
- my $pack = caller;
-
- $Test->exported_to($pack);
- $Test->plan(@_);
-
- $self->export_to_level(1, $self, 'ok');
- }
-
- sub ok {
- my($test, $name) = @_;
-
- $Test->ok($test, $name);
- }
-
-
-=head1 DESCRIPTION
-
-Test::Simple and Test::More have proven to be popular testing modules,
-but they're not always flexible enough. Test::Builder provides the a
-building block upon which to write your own test libraries I<which can
-work together>.
-
-=head2 Construction
-
-=over 4
-
-=item B<new>
-
- my $Test = Test::Builder->new;
-
-Returns a Test::Builder object representing the current state of the
-test.
-
-Since you only run one test per program, there is B<one and only one>
-Test::Builder object. No matter how many times you call new(), you're
-getting the same object. (This is called a singleton).
-
-=cut
-
-my $Test;
-sub new {
- my($class) = shift;
- $Test ||= bless ['Move along, nothing to see here'], $class;
- return $Test;
-}
-
-=back
-
-=head2 Setting up tests
-
-These methods are for setting up tests and declaring how many there
-are. You usually only want to call one of these methods.
-
-=over 4
-
-=item B<exported_to>
-
- my $pack = $Test->exported_to;
- $Test->exported_to($pack);
-
-Tells Test::Builder what package you exported your functions to.
-This is important for getting TODO tests right.
-
-=cut
-
-my $Exported_To;
-sub exported_to {
- my($self, $pack) = @_;
-
- if( defined $pack ) {
- $Exported_To = $pack;
- }
- return $Exported_To;
-}
-
-=item B<plan>
-
- $Test->plan('no_plan');
- $Test->plan( skip_all => $reason );
- $Test->plan( tests => $num_tests );
-
-A convenient way to set up your tests. Call this and Test::Builder
-will print the appropriate headers and take the appropriate actions.
-
-If you call plan(), don't call any of the other methods below.
-
-=cut
-
-sub plan {
- my($self, $cmd, $arg) = @_;
-
- return unless $cmd;
-
- if( $Have_Plan ) {
- die sprintf "You tried to plan twice! Second plan at %s line %d\n",
- ($self->caller)[1,2];
- }
-
- if( $cmd eq 'no_plan' ) {
- $self->no_plan;
- }
- elsif( $cmd eq 'skip_all' ) {
- return $self->skip_all($arg);
- }
- elsif( $cmd eq 'tests' ) {
- if( $arg ) {
- return $self->expected_tests($arg);
- }
- elsif( !defined $arg ) {
- die "Got an undefined number of tests. Looks like you tried to ".
- "say how many tests you plan to run but made a mistake.\n";
- }
- elsif( !$arg ) {
- die "You said to run 0 tests! You've got to run something.\n";
- }
- }
- else {
- require Carp;
- my @args = grep { defined } ($cmd, $arg);
- Carp::croak("plan() doesn't understand @args");
- }
-
- return 1;
-}
-
-=item B<expected_tests>
-
- my $max = $Test->expected_tests;
- $Test->expected_tests($max);
-
-Gets/sets the # of tests we expect this test to run and prints out
-the appropriate headers.
-
-=cut
-
-my $Expected_Tests = 0;
-sub expected_tests {
- my($self, $max) = @_;
-
- if( defined $max ) {
- $Expected_Tests = $max;
- $Have_Plan = 1;
-
- $self->_print("1..$max\n") unless $self->no_header;
- }
- return $Expected_Tests;
-}
-
-
-=item B<no_plan>
-
- $Test->no_plan;
-
-Declares that this test will run an indeterminate # of tests.
-
-=cut
-
-my($No_Plan) = 0;
-sub no_plan {
- $No_Plan = 1;
- $Have_Plan = 1;
-}
-
-=item B<has_plan>
-
- $plan = $Test->has_plan
-
-Find out whether a plan has been defined. $plan is either C<undef> (no plan has been set), C<no_plan> (indeterminate # of tests) or an integer (the number of expected tests).
-
-=cut
-
-sub has_plan {
- return($Expected_Tests) if $Expected_Tests;
- return('no_plan') if $No_Plan;
- return(undef);
-};
-
-
-=item B<skip_all>
-
- $Test->skip_all;
- $Test->skip_all($reason);
-
-Skips all the tests, using the given $reason. Exits immediately with 0.
-
-=cut
-
-my $Skip_All = 0;
-sub skip_all {
- my($self, $reason) = @_;
-
- my $out = "1..0";
- $out .= " # Skip $reason" if $reason;
- $out .= "\n";
-
- $Skip_All = 1;
-
- $self->_print($out) unless $self->no_header;
- exit(0);
-}
-
-=back
-
-=head2 Running tests
-
-These actually run the tests, analogous to the functions in
-Test::More.
-
-$name is always optional.
-
-=over 4
-
-=item B<ok>
-
- $Test->ok($test, $name);
-
-Your basic test. Pass if $test is true, fail if $test is false. Just
-like Test::Simple's ok().
-
-=cut
-
-sub ok {
- my($self, $test, $name) = @_;
-
- # $test might contain an object which we don't want to accidentally
- # store, so we turn it into a boolean.
- $test = $test ? 1 : 0;
-
- unless( $Have_Plan ) {
- require Carp;
- Carp::croak("You tried to run a test without a plan! Gotta have a plan.");
- }
-
- lock $Curr_Test;
- $Curr_Test++;
-
- $self->diag(<<ERR) if defined $name and $name =~ /^[\d\s]+$/;
- You named your test '$name'. You shouldn't use numbers for your test names.
- Very confusing.
-ERR
-
- my($pack, $file, $line) = $self->caller;
-
- my $todo = $self->todo($pack);
-
- my $out;
- my $result = {};
- share($result);
-
- unless( $test ) {
- $out .= "not ";
- @$result{ 'ok', 'actual_ok' } = ( ( $todo ? 1 : 0 ), 0 );
- }
- else {
- @$result{ 'ok', 'actual_ok' } = ( 1, $test );
- }
-
- $out .= "ok";
- $out .= " $Curr_Test" if $self->use_numbers;
-
- if( defined $name ) {
- $name =~ s|#|\\#|g; # # in a name can confuse Test::Harness.
- $out .= " - $name";
- $result->{name} = $name;
- }
- else {
- $result->{name} = '';
- }
-
- if( $todo ) {
- my $what_todo = $todo;
- $out .= " # TODO $what_todo";
- $result->{reason} = $what_todo;
- $result->{type} = 'todo';
- }
- else {
- $result->{reason} = '';
- $result->{type} = '';
- }
-
- $Test_Results[$Curr_Test-1] = $result;
- $out .= "\n";
-
- $self->_print($out);
-
- unless( $test ) {
- my $msg = $todo ? "Failed (TODO)" : "Failed";
- $self->diag(" $msg test ($file at line $line)\n");
- }
-
- return $test ? 1 : 0;
-}
-
-=item B<is_eq>
-
- $Test->is_eq($got, $expected, $name);
-
-Like Test::More's is(). Checks if $got eq $expected. This is the
-string version.
-
-=item B<is_num>
-
- $Test->is_num($got, $expected, $name);
-
-Like Test::More's is(). Checks if $got == $expected. This is the
-numeric version.
-
-=cut
-
-sub is_eq {
- my($self, $got, $expect, $name) = @_;
- local $Level = $Level + 1;
-
- if( !defined $got || !defined $expect ) {
- # undef only matches undef and nothing else
- my $test = !defined $got && !defined $expect;
-
- $self->ok($test, $name);
- $self->_is_diag($got, 'eq', $expect) unless $test;
- return $test;
- }
-
- return $self->cmp_ok($got, 'eq', $expect, $name);
-}
-
-sub is_num {
- my($self, $got, $expect, $name) = @_;
- local $Level = $Level + 1;
-
- if( !defined $got || !defined $expect ) {
- # undef only matches undef and nothing else
- my $test = !defined $got && !defined $expect;
-
- $self->ok($test, $name);
- $self->_is_diag($got, '==', $expect) unless $test;
- return $test;
- }
-
- return $self->cmp_ok($got, '==', $expect, $name);
-}
-
-sub _is_diag {
- my($self, $got, $type, $expect) = @_;
-
- foreach my $val (\$got, \$expect) {
- if( defined $$val ) {
- if( $type eq 'eq' ) {
- # quote and force string context
- $$val = "'$$val'"
- }
- else {
- # force numeric context
- $$val = $$val+0;
- }
- }
- else {
- $$val = 'undef';
- }
- }
-
- return $self->diag(sprintf <<DIAGNOSTIC, $got, $expect);
- got: %s
- expected: %s
-DIAGNOSTIC
-
-}
-
-=item B<isnt_eq>
-
- $Test->isnt_eq($got, $dont_expect, $name);
-
-Like Test::More's isnt(). Checks if $got ne $dont_expect. This is
-the string version.
-
-=item B<isnt_num>
-
- $Test->is_num($got, $dont_expect, $name);
-
-Like Test::More's isnt(). Checks if $got ne $dont_expect. This is
-the numeric version.
-
-=cut
-
-sub isnt_eq {
- my($self, $got, $dont_expect, $name) = @_;
- local $Level = $Level + 1;
-
- if( !defined $got || !defined $dont_expect ) {
- # undef only matches undef and nothing else
- my $test = defined $got || defined $dont_expect;
-
- $self->ok($test, $name);
- $self->_cmp_diag('ne', $got, $dont_expect) unless $test;
- return $test;
- }
-
- return $self->cmp_ok($got, 'ne', $dont_expect, $name);
-}
-
-sub isnt_num {
- my($self, $got, $dont_expect, $name) = @_;
- local $Level = $Level + 1;
-
- if( !defined $got || !defined $dont_expect ) {
- # undef only matches undef and nothing else
- my $test = defined $got || defined $dont_expect;
-
- $self->ok($test, $name);
- $self->_cmp_diag('!=', $got, $dont_expect) unless $test;
- return $test;
- }
-
- return $self->cmp_ok($got, '!=', $dont_expect, $name);
-}
-
-
-=item B<like>
-
- $Test->like($this, qr/$regex/, $name);
- $Test->like($this, '/$regex/', $name);
-
-Like Test::More's like(). Checks if $this matches the given $regex.
-
-You'll want to avoid qr// if you want your tests to work before 5.005.
-
-=item B<unlike>
-
- $Test->unlike($this, qr/$regex/, $name);
- $Test->unlike($this, '/$regex/', $name);
-
-Like Test::More's unlike(). Checks if $this B<does not match> the
-given $regex.
-
-=cut
-
-sub like {
- my($self, $this, $regex, $name) = @_;
-
- local $Level = $Level + 1;
- $self->_regex_ok($this, $regex, '=~', $name);
-}
-
-sub unlike {
- my($self, $this, $regex, $name) = @_;
-
- local $Level = $Level + 1;
- $self->_regex_ok($this, $regex, '!~', $name);
-}
-
-=item B<maybe_regex>
-
- $Test->maybe_regex(qr/$regex/);
- $Test->maybe_regex('/$regex/');
-
-Convenience method for building testing functions that take regular
-expressions as arguments, but need to work before perl 5.005.
-
-Takes a quoted regular expression produced by qr//, or a string
-representing a regular expression.
-
-Returns a Perl value which may be used instead of the corresponding
-regular expression, or undef if it's argument is not recognised.
-
-For example, a version of like(), sans the useful diagnostic messages,
-could be written as:
-
- sub laconic_like {
- my ($self, $this, $regex, $name) = @_;
- my $usable_regex = $self->maybe_regex($regex);
- die "expecting regex, found '$regex'\n"
- unless $usable_regex;
- $self->ok($this =~ m/$usable_regex/, $name);
- }
-
-=cut
-
-
-sub maybe_regex {
- my ($self, $regex) = @_;
- my $usable_regex = undef;
- if( ref $regex eq 'Regexp' ) {
- $usable_regex = $regex;
- }
- # Check if it looks like '/foo/'
- elsif( my($re, $opts) = $regex =~ m{^ /(.*)/ (\w*) $ }sx ) {
- $usable_regex = length $opts ? "(?$opts)$re" : $re;
- };
- return($usable_regex)
-};
-
-sub _regex_ok {
- my($self, $this, $regex, $cmp, $name) = @_;
-
- local $Level = $Level + 1;
-
- my $ok = 0;
- my $usable_regex = $self->maybe_regex($regex);
- unless (defined $usable_regex) {
- $ok = $self->ok( 0, $name );
- $self->diag(" '$regex' doesn't look much like a regex to me.");
- return $ok;
- }
-
- {
- local $^W = 0;
- my $test = $this =~ /$usable_regex/ ? 1 : 0;
- $test = !$test if $cmp eq '!~';
- $ok = $self->ok( $test, $name );
- }
-
- unless( $ok ) {
- $this = defined $this ? "'$this'" : 'undef';
- my $match = $cmp eq '=~' ? "doesn't match" : "matches";
- $self->diag(sprintf <<DIAGNOSTIC, $this, $match, $regex);
- %s
- %13s '%s'
-DIAGNOSTIC
-
- }
-
- return $ok;
-}
-
-=item B<cmp_ok>
-
- $Test->cmp_ok($this, $type, $that, $name);
-
-Works just like Test::More's cmp_ok().
-
- $Test->cmp_ok($big_num, '!=', $other_big_num);
-
-=cut
-
-sub cmp_ok {
- my($self, $got, $type, $expect, $name) = @_;
-
- my $test;
- {
- local $^W = 0;
- local($@,$!); # don't interfere with $@
- # eval() sometimes resets $!
- $test = eval "\$got $type \$expect";
- }
- local $Level = $Level + 1;
- my $ok = $self->ok($test, $name);
-
- unless( $ok ) {
- if( $type =~ /^(eq|==)$/ ) {
- $self->_is_diag($got, $type, $expect);
- }
- else {
- $self->_cmp_diag($got, $type, $expect);
- }
- }
- return $ok;
-}
-
-sub _cmp_diag {
- my($self, $got, $type, $expect) = @_;
-
- $got = defined $got ? "'$got'" : 'undef';
- $expect = defined $expect ? "'$expect'" : 'undef';
- return $self->diag(sprintf <<DIAGNOSTIC, $got, $type, $expect);
- %s
- %s
- %s
-DIAGNOSTIC
-}
-
-=item B<BAILOUT>
-
- $Test->BAILOUT($reason);
-
-Indicates to the Test::Harness that things are going so badly all
-testing should terminate. This includes running any additional test
-scripts.
-
-It will exit with 255.
-
-=cut
-
-sub BAILOUT {
- my($self, $reason) = @_;
-
- $self->_print("Bail out! $reason");
- exit 255;
-}
-
-=item B<skip>
-
- $Test->skip;
- $Test->skip($why);
-
-Skips the current test, reporting $why.
-
-=cut
-
-sub skip {
- my($self, $why) = @_;
- $why ||= '';
-
- unless( $Have_Plan ) {
- require Carp;
- Carp::croak("You tried to run tests without a plan! Gotta have a plan.");
- }
-
- lock($Curr_Test);
- $Curr_Test++;
-
- my %result;
- share(%result);
- %result = (
- 'ok' => 1,
- actual_ok => 1,
- name => '',
- type => 'skip',
- reason => $why,
- );
- $Test_Results[$Curr_Test-1] = \%result;
-
- my $out = "ok";
- $out .= " $Curr_Test" if $self->use_numbers;
- $out .= " # skip $why\n";
-
- $Test->_print($out);
-
- return 1;
-}
-
-
-=item B<todo_skip>
-
- $Test->todo_skip;
- $Test->todo_skip($why);
-
-Like skip(), only it will declare the test as failing and TODO. Similar
-to
-
- print "not ok $tnum # TODO $why\n";
-
-=cut
-
-sub todo_skip {
- my($self, $why) = @_;
- $why ||= '';
-
- unless( $Have_Plan ) {
- require Carp;
- Carp::croak("You tried to run tests without a plan! Gotta have a plan.");
- }
-
- lock($Curr_Test);
- $Curr_Test++;
-
- my %result;
- share(%result);
- %result = (
- 'ok' => 1,
- actual_ok => 0,
- name => '',
- type => 'todo_skip',
- reason => $why,
- );
-
- $Test_Results[$Curr_Test-1] = \%result;
-
- my $out = "not ok";
- $out .= " $Curr_Test" if $self->use_numbers;
- $out .= " # TODO & SKIP $why\n";
-
- $Test->_print($out);
-
- return 1;
-}
-
-
-=begin _unimplemented
-
-=item B<skip_rest>
-
- $Test->skip_rest;
- $Test->skip_rest($reason);
-
-Like skip(), only it skips all the rest of the tests you plan to run
-and terminates the test.
-
-If you're running under no_plan, it skips once and terminates the
-test.
-
-=end _unimplemented
-
-=back
-
-
-=head2 Test style
-
-=over 4
-
-=item B<level>
-
- $Test->level($how_high);
-
-How far up the call stack should $Test look when reporting where the
-test failed.
-
-Defaults to 1.
-
-Setting $Test::Builder::Level overrides. This is typically useful
-localized:
-
- {
- local $Test::Builder::Level = 2;
- $Test->ok($test);
- }
-
-=cut
-
-sub level {
- my($self, $level) = @_;
-
- if( defined $level ) {
- $Level = $level;
- }
- return $Level;
-}
-
-$CLASS->level(1);
-
-
-=item B<use_numbers>
-
- $Test->use_numbers($on_or_off);
-
-Whether or not the test should output numbers. That is, this if true:
-
- ok 1
- ok 2
- ok 3
-
-or this if false
-
- ok
- ok
- ok
-
-Most useful when you can't depend on the test output order, such as
-when threads or forking is involved.
-
-Test::Harness will accept either, but avoid mixing the two styles.
-
-Defaults to on.
-
-=cut
-
-my $Use_Nums = 1;
-sub use_numbers {
- my($self, $use_nums) = @_;
-
- if( defined $use_nums ) {
- $Use_Nums = $use_nums;
- }
- return $Use_Nums;
-}
-
-=item B<no_header>
-
- $Test->no_header($no_header);
-
-If set to true, no "1..N" header will be printed.
-
-=item B<no_ending>
-
- $Test->no_ending($no_ending);
-
-Normally, Test::Builder does some extra diagnostics when the test
-ends. It also changes the exit code as described in Test::Simple.
-
-If this is true, none of that will be done.
-
-=cut
-
-my($No_Header, $No_Ending) = (0,0);
-sub no_header {
- my($self, $no_header) = @_;
-
- if( defined $no_header ) {
- $No_Header = $no_header;
- }
- return $No_Header;
-}
-
-sub no_ending {
- my($self, $no_ending) = @_;
-
- if( defined $no_ending ) {
- $No_Ending = $no_ending;
- }
- return $No_Ending;
-}
-
-
-=back
-
-=head2 Output
-
-Controlling where the test output goes.
-
-It's ok for your test to change where STDOUT and STDERR point to,
-Test::Builder's default output settings will not be affected.
-
-=over 4
-
-=item B<diag>
-
- $Test->diag(@msgs);
-
-Prints out the given $message. Normally, it uses the failure_output()
-handle, but if this is for a TODO test, the todo_output() handle is
-used.
-
-Output will be indented and marked with a # so as not to interfere
-with test output. A newline will be put on the end if there isn't one
-already.
-
-We encourage using this rather than calling print directly.
-
-Returns false. Why? Because diag() is often used in conjunction with
-a failing test (C<ok() || diag()>) it "passes through" the failure.
-
- return ok(...) || diag(...);
-
-=for blame transfer
-Mark Fowler <mark@twoshortplanks.com>
-
-=cut
-
-sub diag {
- my($self, @msgs) = @_;
- return unless @msgs;
-
- # Prevent printing headers when compiling (i.e. -c)
- return if $^C;
-
- # Escape each line with a #.
- foreach (@msgs) {
- $_ = 'undef' unless defined;
- s/^/# /gms;
- }
-
- push @msgs, "\n" unless $msgs[-1] =~ /\n\Z/;
-
- local $Level = $Level + 1;
- my $fh = $self->todo ? $self->todo_output : $self->failure_output;
- local($\, $", $,) = (undef, ' ', '');
- print $fh @msgs;
-
- return 0;
-}
-
-=begin _private
-
-=item B<_print>
-
- $Test->_print(@msgs);
-
-Prints to the output() filehandle.
-
-=end _private
-
-=cut
-
-sub _print {
- my($self, @msgs) = @_;
-
- # Prevent printing headers when only compiling. Mostly for when
- # tests are deparsed with B::Deparse
- return if $^C;
-
- local($\, $", $,) = (undef, ' ', '');
- my $fh = $self->output;
-
- # Escape each line after the first with a # so we don't
- # confuse Test::Harness.
- foreach (@msgs) {
- s/\n(.)/\n# $1/sg;
- }
-
- push @msgs, "\n" unless $msgs[-1] =~ /\n\Z/;
-
- print $fh @msgs;
-}
-
-
-=item B<output>
-
- $Test->output($fh);
- $Test->output($file);
-
-Where normal "ok/not ok" test output should go.
-
-Defaults to STDOUT.
-
-=item B<failure_output>
-
- $Test->failure_output($fh);
- $Test->failure_output($file);
-
-Where diagnostic output on test failures and diag() should go.
-
-Defaults to STDERR.
-
-=item B<todo_output>
-
- $Test->todo_output($fh);
- $Test->todo_output($file);
-
-Where diagnostics about todo test failures and diag() should go.
-
-Defaults to STDOUT.
-
-=cut
-
-my($Out_FH, $Fail_FH, $Todo_FH);
-sub output {
- my($self, $fh) = @_;
-
- if( defined $fh ) {
- $Out_FH = _new_fh($fh);
- }
- return $Out_FH;
-}
-
-sub failure_output {
- my($self, $fh) = @_;
-
- if( defined $fh ) {
- $Fail_FH = _new_fh($fh);
- }
- return $Fail_FH;
-}
-
-sub todo_output {
- my($self, $fh) = @_;
-
- if( defined $fh ) {
- $Todo_FH = _new_fh($fh);
- }
- return $Todo_FH;
-}
-
-sub _new_fh {
- my($file_or_fh) = shift;
-
- my $fh;
- unless( UNIVERSAL::isa($file_or_fh, 'GLOB') ) {
- $fh = do { local *FH };
- open $fh, ">$file_or_fh" or
- die "Can't open test output log $file_or_fh: $!";
- }
- else {
- $fh = $file_or_fh;
- }
-
- return $fh;
-}
-
-unless( $^C ) {
- # We dup STDOUT and STDERR so people can change them in their
- # test suites while still getting normal test output.
- open(TESTOUT, ">&STDOUT") or die "Can't dup STDOUT: $!";
- open(TESTERR, ">&STDERR") or die "Can't dup STDERR: $!";
-
- # Set everything to unbuffered else plain prints to STDOUT will
- # come out in the wrong order from our own prints.
- _autoflush(\*TESTOUT);
- _autoflush(\*STDOUT);
- _autoflush(\*TESTERR);
- _autoflush(\*STDERR);
-
- $CLASS->output(\*TESTOUT);
- $CLASS->failure_output(\*TESTERR);
- $CLASS->todo_output(\*TESTOUT);
-}
-
-sub _autoflush {
- my($fh) = shift;
- my $old_fh = select $fh;
- $| = 1;
- select $old_fh;
-}
-
-
-=back
-
-
-=head2 Test Status and Info
-
-=over 4
-
-=item B<current_test>
-
- my $curr_test = $Test->current_test;
- $Test->current_test($num);
-
-Gets/sets the current test # we're on.
-
-You usually shouldn't have to set this.
-
-=cut
-
-sub current_test {
- my($self, $num) = @_;
-
- lock($Curr_Test);
- if( defined $num ) {
- unless( $Have_Plan ) {
- require Carp;
- Carp::croak("Can't change the current test number without a plan!");
- }
-
- $Curr_Test = $num;
- if( $num > @Test_Results ) {
- my $start = @Test_Results ? $#Test_Results + 1 : 0;
- for ($start..$num-1) {
- my %result;
- share(%result);
- %result = ( ok => 1,
- actual_ok => undef,
- reason => 'incrementing test number',
- type => 'unknown',
- name => undef
- );
- $Test_Results[$_] = \%result;
- }
- }
- }
- return $Curr_Test;
-}
-
-
-=item B<summary>
-
- my @tests = $Test->summary;
-
-A simple summary of the tests so far. True for pass, false for fail.
-This is a logical pass/fail, so todos are passes.
-
-Of course, test #1 is $tests[0], etc...
-
-=cut
-
-sub summary {
- my($self) = shift;
-
- return map { $_->{'ok'} } @Test_Results;
-}
-
-=item B<details>
-
- my @tests = $Test->details;
-
-Like summary(), but with a lot more detail.
-
- $tests[$test_num - 1] =
- { 'ok' => is the test considered a pass?
- actual_ok => did it literally say 'ok'?
- name => name of the test (if any)
- type => type of test (if any, see below).
- reason => reason for the above (if any)
- };
-
-'ok' is true if Test::Harness will consider the test to be a pass.
-
-'actual_ok' is a reflection of whether or not the test literally
-printed 'ok' or 'not ok'. This is for examining the result of 'todo'
-tests.
-
-'name' is the name of the test.
-
-'type' indicates if it was a special test. Normal tests have a type
-of ''. Type can be one of the following:
-
- skip see skip()
- todo see todo()
- todo_skip see todo_skip()
- unknown see below
-
-Sometimes the Test::Builder test counter is incremented without it
-printing any test output, for example, when current_test() is changed.
-In these cases, Test::Builder doesn't know the result of the test, so
-it's type is 'unkown'. These details for these tests are filled in.
-They are considered ok, but the name and actual_ok is left undef.
-
-For example "not ok 23 - hole count # TODO insufficient donuts" would
-result in this structure:
-
- $tests[22] = # 23 - 1, since arrays start from 0.
- { ok => 1, # logically, the test passed since it's todo
- actual_ok => 0, # in absolute terms, it failed
- name => 'hole count',
- type => 'todo',
- reason => 'insufficient donuts'
- };
-
-=cut
-
-sub details {
- return @Test_Results;
-}
-
-=item B<todo>
-
- my $todo_reason = $Test->todo;
- my $todo_reason = $Test->todo($pack);
-
-todo() looks for a $TODO variable in your tests. If set, all tests
-will be considered 'todo' (see Test::More and Test::Harness for
-details). Returns the reason (ie. the value of $TODO) if running as
-todo tests, false otherwise.
-
-todo() is pretty part about finding the right package to look for
-$TODO in. It uses the exported_to() package to find it. If that's
-not set, it's pretty good at guessing the right package to look at.
-
-Sometimes there is some confusion about where todo() should be looking
-for the $TODO variable. If you want to be sure, tell it explicitly
-what $pack to use.
-
-=cut
-
-sub todo {
- my($self, $pack) = @_;
-
- $pack = $pack || $self->exported_to || $self->caller(1);
-
- no strict 'refs';
- return defined ${$pack.'::TODO'} ? ${$pack.'::TODO'}
- : 0;
-}
-
-=item B<caller>
-
- my $package = $Test->caller;
- my($pack, $file, $line) = $Test->caller;
- my($pack, $file, $line) = $Test->caller($height);
-
-Like the normal caller(), except it reports according to your level().
-
-=cut
-
-sub caller {
- my($self, $height) = @_;
- $height ||= 0;
-
- my @caller = CORE::caller($self->level + $height + 1);
- return wantarray ? @caller : $caller[0];
-}
-
-=back
-
-=cut
-
-=begin _private
-
-=over 4
-
-=item B<_sanity_check>
-
- _sanity_check();
-
-Runs a bunch of end of test sanity checks to make sure reality came
-through ok. If anything is wrong it will die with a fairly friendly
-error message.
-
-=cut
-
-#'#
-sub _sanity_check {
- _whoa($Curr_Test < 0, 'Says here you ran a negative number of tests!');
- _whoa(!$Have_Plan and $Curr_Test,
- 'Somehow your tests ran without a plan!');
- _whoa($Curr_Test != @Test_Results,
- 'Somehow you got a different number of results than tests ran!');
-}
-
-=item B<_whoa>
-
- _whoa($check, $description);
-
-A sanity check, similar to assert(). If the $check is true, something
-has gone horribly wrong. It will die with the given $description and
-a note to contact the author.
-
-=cut
-
-sub _whoa {
- my($check, $desc) = @_;
- if( $check ) {
- die <<WHOA;
-WHOA! $desc
-This should never happen! Please contact the author immediately!
-WHOA
- }
-}
-
-=item B<_my_exit>
-
- _my_exit($exit_num);
-
-Perl seems to have some trouble with exiting inside an END block. 5.005_03
-and 5.6.1 both seem to do odd things. Instead, this function edits $?
-directly. It should ONLY be called from inside an END block. It
-doesn't actually exit, that's your job.
-
-=cut
-
-sub _my_exit {
- $? = $_[0];
-
- return 1;
-}
-
-
-=back
-
-=end _private
-
-=cut
-
-$SIG{__DIE__} = sub {
- # We don't want to muck with death in an eval, but $^S isn't
- # totally reliable. 5.005_03 and 5.6.1 both do the wrong thing
- # with it. Instead, we use caller. This also means it runs under
- # 5.004!
- my $in_eval = 0;
- for( my $stack = 1; my $sub = (CORE::caller($stack))[3]; $stack++ ) {
- $in_eval = 1 if $sub =~ /^\(eval\)/;
- }
- $Test_Died = 1 unless $in_eval;
-};
-
-sub _ending {
- my $self = shift;
-
- _sanity_check();
-
- # Don't bother with an ending if this is a forked copy. Only the parent
- # should do the ending.
- do{ _my_exit($?) && return } if $Original_Pid != $$;
-
- # Bailout if plan() was never called. This is so
- # "require Test::Simple" doesn't puke.
- do{ _my_exit(0) && return } if !$Have_Plan && !$Test_Died;
-
- # Figure out if we passed or failed and print helpful messages.
- if( @Test_Results ) {
- # The plan? We have no plan.
- if( $No_Plan ) {
- $self->_print("1..$Curr_Test\n") unless $self->no_header;
- $Expected_Tests = $Curr_Test;
- }
-
- # 5.8.0 threads bug. Shared arrays will not be auto-extended
- # by a slice. Worse, we have to fill in every entry else
- # we'll get an "Invalid value for shared scalar" error
- for my $idx ($#Test_Results..$Expected_Tests-1) {
- my %empty_result = ();
- share(%empty_result);
- $Test_Results[$idx] = \%empty_result
- unless defined $Test_Results[$idx];
- }
-
- my $num_failed = grep !$_->{'ok'}, @Test_Results[0..$Expected_Tests-1];
- $num_failed += abs($Expected_Tests - @Test_Results);
-
- if( $Curr_Test < $Expected_Tests ) {
- $self->diag(<<"FAIL");
-Looks like you planned $Expected_Tests tests but only ran $Curr_Test.
-FAIL
- }
- elsif( $Curr_Test > $Expected_Tests ) {
- my $num_extra = $Curr_Test - $Expected_Tests;
- $self->diag(<<"FAIL");
-Looks like you planned $Expected_Tests tests but ran $num_extra extra.
-FAIL
- }
- elsif ( $num_failed ) {
- $self->diag(<<"FAIL");
-Looks like you failed $num_failed tests of $Expected_Tests.
-FAIL
- }
-
- if( $Test_Died ) {
- $self->diag(<<"FAIL");
-Looks like your test died just after $Curr_Test.
-FAIL
-
- _my_exit( 255 ) && return;
- }
-
- _my_exit( $num_failed <= 254 ? $num_failed : 254 ) && return;
- }
- elsif ( $Skip_All ) {
- _my_exit( 0 ) && return;
- }
- elsif ( $Test_Died ) {
- $self->diag(<<'FAIL');
-Looks like your test died before it could output anything.
-FAIL
- }
- else {
- $self->diag("No tests run!\n");
- _my_exit( 255 ) && return;
- }
-}
-
-END {
- $Test->_ending if defined $Test and !$Test->no_ending;
-}
-
-=head1 THREADS
-
-In perl 5.8.0 and later, Test::Builder is thread-safe. The test
-number is shared amongst all threads. This means if one thread sets
-the test number using current_test() they will all be effected.
-
-=head1 EXAMPLES
-
-CPAN can provide the best examples. Test::Simple, Test::More,
-Test::Exception and Test::Differences all use Test::Builder.
-
-=head1 SEE ALSO
-
-Test::Simple, Test::More, Test::Harness
-
-=head1 AUTHORS
-
-Original code by chromatic, maintained by Michael G Schwern
-E<lt>schwern@pobox.comE<gt>
-
-=head1 COPYRIGHT
-
-Copyright 2002 by chromatic E<lt>chromatic@wgz.orgE<gt>,
- Michael G Schwern E<lt>schwern@pobox.comE<gt>.
-
-This program is free software; you can redistribute it and/or
-modify it under the same terms as Perl itself.
-
-See F<http://www.perl.com/perl/misc/Artistic.html>
-
-=cut
-
-1;
diff --git a/Perl/t/Test/Harness.pm b/Perl/t/Test/Harness.pm
deleted file mode 100644
index 0897455..0000000
--- a/Perl/t/Test/Harness.pm
+++ /dev/null
@@ -1,1168 +0,0 @@
-# -*- Mode: cperl; cperl-indent-level: 4 -*-
-# $Id$
-
-package Test::Harness;
-
-require 5.004;
-use Test::Harness::Straps;
-use Test::Harness::Assert;
-use Exporter;
-use Benchmark;
-use Config;
-use strict;
-
-use vars qw($VERSION $Verbose $Switches $Have_Devel_Corestack $Curtest
- $Columns $verbose $switches $ML $Strap
- @ISA @EXPORT @EXPORT_OK $Last_ML_Print
- );
-
-# Backwards compatibility for exportable variable names.
-*verbose = *Verbose;
-*switches = *Switches;
-
-$Have_Devel_Corestack = 0;
-
-$VERSION = '2.30';
-
-$ENV{HARNESS_ACTIVE} = 1;
-
-END {
- # For VMS.
- delete $ENV{HARNESS_ACTIVE};
-}
-
-# Some experimental versions of OS/2 build have broken $?
-my $Ignore_Exitcode = $ENV{HARNESS_IGNORE_EXITCODE};
-
-my $Files_In_Dir = $ENV{HARNESS_FILELEAK_IN_DIR};
-
-my $Ok_Slow = $ENV{HARNESS_OK_SLOW};
-
-$Strap = Test::Harness::Straps->new;
-
-@ISA = ('Exporter');
-@EXPORT = qw(&runtests);
-@EXPORT_OK = qw($verbose $switches);
-
-$Verbose = $ENV{HARNESS_VERBOSE} || 0;
-$Switches = "-w";
-$Columns = $ENV{HARNESS_COLUMNS} || $ENV{COLUMNS} || 80;
-$Columns--; # Some shells have trouble with a full line of text.
-
-
-=head1 NAME
-
-Test::Harness - run perl standard test scripts with statistics
-
-=head1 SYNOPSIS
-
- use Test::Harness;
-
- runtests(@test_files);
-
-=head1 DESCRIPTION
-
-B<STOP!> If all you want to do is write a test script, consider using
-Test::Simple. Otherwise, read on.
-
-(By using the Test module, you can write test scripts without
-knowing the exact output this module expects. However, if you need to
-know the specifics, read on!)
-
-Perl test scripts print to standard output C<"ok N"> for each single
-test, where C<N> is an increasing sequence of integers. The first line
-output by a standard test script is C<"1..M"> with C<M> being the
-number of tests that should be run within the test
-script. Test::Harness::runtests(@tests) runs all the testscripts
-named as arguments and checks standard output for the expected
-C<"ok N"> strings.
-
-After all tests have been performed, runtests() prints some
-performance statistics that are computed by the Benchmark module.
-
-=head2 The test script output
-
-The following explains how Test::Harness interprets the output of your
-test program.
-
-=over 4
-
-=item B<'1..M'>
-
-This header tells how many tests there will be. For example, C<1..10>
-means you plan on running 10 tests. This is a safeguard in case your
-test dies quietly in the middle of its run.
-
-It should be the first non-comment line output by your test program.
-
-In certain instances, you may not know how many tests you will
-ultimately be running. In this case, it is permitted for the 1..M
-header to appear as the B<last> line output by your test (again, it
-can be followed by further comments).
-
-Under B<no> circumstances should 1..M appear in the middle of your
-output or more than once.
-
-
-=item B<'ok', 'not ok'. Ok?>
-
-Any output from the testscript to standard error is ignored and
-bypassed, thus will be seen by the user. Lines written to standard
-output containing C</^(not\s+)?ok\b/> are interpreted as feedback for
-runtests(). All other lines are discarded.
-
-C</^not ok/> indicates a failed test. C</^ok/> is a successful test.
-
-
-=item B<test numbers>
-
-Perl normally expects the 'ok' or 'not ok' to be followed by a test
-number. It is tolerated if the test numbers after 'ok' are
-omitted. In this case Test::Harness maintains temporarily its own
-counter until the script supplies test numbers again. So the following
-test script
-
- print <<END;
- 1..6
- not ok
- ok
- not ok
- ok
- ok
- END
-
-will generate
-
- FAILED tests 1, 3, 6
- Failed 3/6 tests, 50.00% okay
-
-=item B<test names>
-
-Anything after the test number but before the # is considered to be
-the name of the test.
-
- ok 42 this is the name of the test
-
-Currently, Test::Harness does nothing with this information.
-
-=item B<Skipping tests>
-
-If the standard output line contains the substring C< # Skip> (with
-variations in spacing and case) after C<ok> or C<ok NUMBER>, it is
-counted as a skipped test. If the whole testscript succeeds, the
-count of skipped tests is included in the generated output.
-C<Test::Harness> reports the text after C< # Skip\S*\s+> as a reason
-for skipping.
-
- ok 23 # skip Insufficient flogiston pressure.
-
-Similarly, one can include a similar explanation in a C<1..0> line
-emitted if the test script is skipped completely:
-
- 1..0 # Skipped: no leverage found
-
-=item B<Todo tests>
-
-If the standard output line contains the substring C< # TODO> after
-C<not ok> or C<not ok NUMBER>, it is counted as a todo test. The text
-afterwards is the thing that has to be done before this test will
-succeed.
-
- not ok 13 # TODO harness the power of the atom
-
-=begin _deprecated
-
-Alternatively, you can specify a list of what tests are todo as part
-of the test header.
-
- 1..23 todo 5 12 23
-
-This only works if the header appears at the beginning of the test.
-
-This style is B<deprecated>.
-
-=end _deprecated
-
-These tests represent a feature to be implemented or a bug to be fixed
-and act as something of an executable "thing to do" list. They are
-B<not> expected to succeed. Should a todo test begin succeeding,
-Test::Harness will report it as a bonus. This indicates that whatever
-you were supposed to do has been done and you should promote this to a
-normal test.
-
-=item B<Bail out!>
-
-As an emergency measure, a test script can decide that further tests
-are useless (e.g. missing dependencies) and testing should stop
-immediately. In that case the test script prints the magic words
-
- Bail out!
-
-to standard output. Any message after these words will be displayed by
-C<Test::Harness> as the reason why testing is stopped.
-
-=item B<Comments>
-
-Additional comments may be put into the testing output on their own
-lines. Comment lines should begin with a '#', Test::Harness will
-ignore them.
-
- ok 1
- # Life is good, the sun is shining, RAM is cheap.
- not ok 2
- # got 'Bush' expected 'Gore'
-
-=item B<Anything else>
-
-Any other output Test::Harness sees it will silently ignore B<BUT WE
-PLAN TO CHANGE THIS!> If you wish to place additional output in your
-test script, please use a comment.
-
-=back
-
-
-=head2 Taint mode
-
-Test::Harness will honor the C<-T> in the #! line on your test files. So
-if you begin a test with:
-
- #!perl -T
-
-the test will be run with taint mode on.
-
-
-=head2 Configuration variables.
-
-These variables can be used to configure the behavior of
-Test::Harness. They are exported on request.
-
-=over 4
-
-=item B<$Test::Harness::verbose>
-
-The global variable $Test::Harness::verbose is exportable and can be
-used to let runtests() display the standard output of the script
-without altering the behavior otherwise.
-
-=item B<$Test::Harness::switches>
-
-The global variable $Test::Harness::switches is exportable and can be
-used to set perl command line options used for running the test
-script(s). The default value is C<-w>.
-
-=back
-
-
-=head2 Failure
-
-It will happen, your tests will fail. After you mop up your ego, you
-can begin examining the summary report:
-
- t/base..............ok
- t/nonumbers.........ok
- t/ok................ok
- t/test-harness......ok
- t/waterloo..........dubious
- Test returned status 3 (wstat 768, 0x300)
- DIED. FAILED tests 1, 3, 5, 7, 9, 11, 13, 15, 17, 19
- Failed 10/20 tests, 50.00% okay
- Failed Test Stat Wstat Total Fail Failed List of Failed
- -----------------------------------------------------------------------
- t/waterloo.t 3 768 20 10 50.00% 1 3 5 7 9 11 13 15 17 19
- Failed 1/5 test scripts, 80.00% okay. 10/44 subtests failed, 77.27% okay.
-
-Everything passed but t/waterloo.t. It failed 10 of 20 tests and
-exited with non-zero status indicating something dubious happened.
-
-The columns in the summary report mean:
-
-=over 4
-
-=item B<Failed Test>
-
-The test file which failed.
-
-=item B<Stat>
-
-If the test exited with non-zero, this is its exit status.
-
-=item B<Wstat>
-
-The wait status of the test I<umm, I need a better explanation here>.
-
-=item B<Total>
-
-Total number of tests expected to run.
-
-=item B<Fail>
-
-Number which failed, either from "not ok" or because they never ran.
-
-=item B<Failed>
-
-Percentage of the total tests which failed.
-
-=item B<List of Failed>
-
-A list of the tests which failed. Successive failures may be
-abbreviated (ie. 15-20 to indicate that tests 15, 16, 17, 18, 19 and
-20 failed).
-
-=back
-
-
-=head2 Functions
-
-Test::Harness currently only has one function, here it is.
-
-=over 4
-
-=item B<runtests>
-
- my $allok = runtests(@test_files);
-
-This runs all the given @test_files and divines whether they passed
-or failed based on their output to STDOUT (details above). It prints
-out each individual test which failed along with a summary report and
-a how long it all took.
-
-It returns true if everything was ok. Otherwise it will die() with
-one of the messages in the DIAGNOSTICS section.
-
-=for _private
-
-This is just _run_all_tests() plus _show_results()
-
-=cut
-
-sub runtests {
- my(@tests) = @_;
-
- local ($\, $,);
-
- my($tot, $failedtests) = _run_all_tests(@tests);
- _show_results($tot, $failedtests);
-
- my $ok = _all_ok($tot);
-
- assert(($ok xor keys %$failedtests),
- q{ok status jives with $failedtests});
-
- return $ok;
-}
-
-=begin _private
-
-=item B<_all_ok>
-
- my $ok = _all_ok(\%tot);
-
-Tells you if this test run is overall successful or not.
-
-=cut
-
-sub _all_ok {
- my($tot) = shift;
-
- return $tot->{bad} == 0 && ($tot->{max} || $tot->{skipped}) ? 1 : 0;
-}
-
-=item B<_globdir>
-
- my @files = _globdir $dir;
-
-Returns all the files in a directory. This is shorthand for backwards
-compatibility on systems where glob() doesn't work right.
-
-=cut
-
-sub _globdir {
- opendir DIRH, shift;
- my @f = readdir DIRH;
- closedir DIRH;
-
- return @f;
-}
-
-=item B<_run_all_tests>
-
- my($total, $failed) = _run_all_tests(@test_files);
-
-Runs all the given @test_files (as runtests()) but does it quietly (no
-report). $total is a hash ref summary of all the tests run. Its keys
-and values are this:
-
- bonus Number of individual todo tests unexpectedly passed
- max Number of individual tests ran
- ok Number of individual tests passed
- sub_skipped Number of individual tests skipped
- todo Number of individual todo tests
-
- files Number of test files ran
- good Number of test files passed
- bad Number of test files failed
- tests Number of test files originally given
- skipped Number of test files skipped
-
-If $total->{bad} == 0 and $total->{max} > 0, you've got a successful
-test.
-
-$failed is a hash ref of all the test scripts which failed. Each key
-is the name of a test script, each value is another hash representing
-how that script failed. Its keys are these:
-
- name Name of the test which failed
- estat Script's exit value
- wstat Script's wait status
- max Number of individual tests
- failed Number which failed
- percent Percentage of tests which failed
- canon List of tests which failed (as string).
-
-Needless to say, $failed should be empty if everything passed.
-
-B<NOTE> Currently this function is still noisy. I'm working on it.
-
-=cut
-
-#'#
-sub _run_all_tests {
- my(@tests) = @_;
- local($|) = 1;
- my(%failedtests);
-
- # Test-wide totals.
- my(%tot) = (
- bonus => 0,
- max => 0,
- ok => 0,
- files => 0,
- bad => 0,
- good => 0,
- tests => scalar @tests,
- sub_skipped => 0,
- todo => 0,
- skipped => 0,
- bench => 0,
- );
-
- my @dir_files = _globdir $Files_In_Dir if defined $Files_In_Dir;
- my $t_start = new Benchmark;
-
- my $width = _leader_width(@tests);
- foreach my $tfile (@tests) {
- $Last_ML_Print = 0; # so each test prints at least once
- my($leader, $ml) = _mk_leader($tfile, $width);
- local $ML = $ml;
- print $leader;
-
- $tot{files}++;
-
- $Strap->{_seen_header} = 0;
- my %results = $Strap->analyze_file($tfile) or
- do { warn "$Strap->{error}\n"; next };
-
- # state of the current test.
- my @failed = grep { !$results{details}[$_-1]{ok} }
- 1..@{$results{details}};
- my %test = (
- ok => $results{ok},
- 'next' => $Strap->{'next'},
- max => $results{max},
- failed => \@failed,
- bonus => $results{bonus},
- skipped => $results{skip},
- skip_reason => $results{skip_reason},
- skip_all => $Strap->{skip_all},
- ml => $ml,
- );
-
- $tot{bonus} += $results{bonus};
- $tot{max} += $results{max};
- $tot{ok} += $results{ok};
- $tot{todo} += $results{todo};
- $tot{sub_skipped} += $results{skip};
-
- my($estatus, $wstatus) = @results{qw(exit wait)};
-
- if ($results{passing}) {
- if ($test{max} and $test{skipped} + $test{bonus}) {
- my @msg;
- push(@msg, "$test{skipped}/$test{max} skipped: $test{skip_reason}")
- if $test{skipped};
- push(@msg, "$test{bonus}/$test{max} unexpectedly succeeded")
- if $test{bonus};
- print "$test{ml}ok\n ".join(', ', @msg)."\n";
- } elsif ($test{max}) {
- print "$test{ml}ok\n";
- } elsif (defined $test{skip_all} and length $test{skip_all}) {
- print "skipped\n all skipped: $test{skip_all}\n";
- $tot{skipped}++;
- } else {
- print "skipped\n all skipped: no reason given\n";
- $tot{skipped}++;
- }
- $tot{good}++;
- }
- else {
- # List unrun tests as failures.
- if ($test{'next'} <= $test{max}) {
- push @{$test{failed}}, $test{'next'}..$test{max};
- }
- # List overruns as failures.
- else {
- my $details = $results{details};
- foreach my $overrun ($test{max}+1..@$details)
- {
- next unless ref $details->[$overrun-1];
- push @{$test{failed}}, $overrun
- }
- }
-
- if ($wstatus) {
- $failedtests{$tfile} = _dubious_return(\%test, \%tot,
- $estatus, $wstatus);
- $failedtests{$tfile}{name} = $tfile;
- }
- elsif($results{seen}) {
- if (@{$test{failed}} and $test{max}) {
- my ($txt, $canon) = canonfailed($test{max},$test{skipped},
- @{$test{failed}});
- print "$test{ml}$txt";
- $failedtests{$tfile} = { canon => $canon,
- max => $test{max},
- failed => scalar @{$test{failed}},
- name => $tfile,
- percent => 100*(scalar @{$test{failed}})/$test{max},
- estat => '',
- wstat => '',
- };
- } else {
- print "Don't know which tests failed: got $test{ok} ok, ".
- "expected $test{max}\n";
- $failedtests{$tfile} = { canon => '??',
- max => $test{max},
- failed => '??',
- name => $tfile,
- percent => undef,
- estat => '',
- wstat => '',
- };
- }
- $tot{bad}++;
- } else {
- print "FAILED before any test output arrived\n";
- $tot{bad}++;
- $failedtests{$tfile} = { canon => '??',
- max => '??',
- failed => '??',
- name => $tfile,
- percent => undef,
- estat => '',
- wstat => '',
- };
- }
- }
-
- if (defined $Files_In_Dir) {
- my @new_dir_files = _globdir $Files_In_Dir;
- if (@new_dir_files != @dir_files) {
- my %f;
- @f{@new_dir_files} = (1) x @new_dir_files;
- delete @f{@dir_files};
- my @f = sort keys %f;
- print "LEAKED FILES: @f\n";
- @dir_files = @new_dir_files;
- }
- }
- }
- $tot{bench} = timediff(new Benchmark, $t_start);
-
- $Strap->_restore_PERL5LIB;
-
- return(\%tot, \%failedtests);
-}
-
-=item B<_mk_leader>
-
- my($leader, $ml) = _mk_leader($test_file, $width);
-
-Generates the 't/foo........' $leader for the given $test_file as well
-as a similar version which will overwrite the current line (by use of
-\r and such). $ml may be empty if Test::Harness doesn't think you're
-on TTY.
-
-The $width is the width of the "yada/blah.." string.
-
-=cut
-
-sub _mk_leader {
- my($te, $width) = @_;
- chomp($te);
- $te =~ s/\.\w+$/./;
-
- if ($^O eq 'VMS') { $te =~ s/^.*\.t\./\[.t./s; }
- my $blank = (' ' x 77);
- my $leader = "$te" . '.' x ($width - length($te));
- my $ml = "";
-
- $ml = "\r$blank\r$leader"
- if -t STDOUT and not $ENV{HARNESS_NOTTY} and not $Verbose;
-
- return($leader, $ml);
-}
-
-=item B<_leader_width>
-
- my($width) = _leader_width(@test_files);
-
-Calculates how wide the leader should be based on the length of the
-longest test name.
-
-=cut
-
-sub _leader_width {
- my $maxlen = 0;
- my $maxsuflen = 0;
- foreach (@_) {
- my $suf = /\.(\w+)$/ ? $1 : '';
- my $len = length;
- my $suflen = length $suf;
- $maxlen = $len if $len > $maxlen;
- $maxsuflen = $suflen if $suflen > $maxsuflen;
- }
- # + 3 : we want three dots between the test name and the "ok"
- return $maxlen + 3 - $maxsuflen;
-}
-
-
-sub _show_results {
- my($tot, $failedtests) = @_;
-
- my $pct;
- my $bonusmsg = _bonusmsg($tot);
-
- if (_all_ok($tot)) {
- print "All tests successful$bonusmsg.\n";
- } elsif (!$tot->{tests}){
- die "FAILED--no tests were run for some reason.\n";
- } elsif (!$tot->{max}) {
- my $blurb = $tot->{tests}==1 ? "script" : "scripts";
- die "FAILED--$tot->{tests} test $blurb could be run, ".
- "alas--no output ever seen\n";
- } else {
- $pct = sprintf("%.2f", $tot->{good} / $tot->{tests} * 100);
- my $percent_ok = 100*$tot->{ok}/$tot->{max};
- my $subpct = sprintf " %d/%d subtests failed, %.2f%% okay.",
- $tot->{max} - $tot->{ok}, $tot->{max},
- $percent_ok;
-
- my($fmt_top, $fmt) = _create_fmts($failedtests);
-
- # Now write to formats
- for my $script (sort keys %$failedtests) {
- $Curtest = $failedtests->{$script};
- write;
- }
- if ($tot->{bad}) {
- $bonusmsg =~ s/^,\s*//;
- print "$bonusmsg.\n" if $bonusmsg;
- die "Failed $tot->{bad}/$tot->{tests} test scripts, $pct% okay.".
- "$subpct\n";
- }
- }
-
- printf("Files=%d, Tests=%d, %s\n",
- $tot->{files}, $tot->{max}, timestr($tot->{bench}, 'nop'));
-}
-
-
-my %Handlers = ();
-$Strap->{callback} = sub {
- my($self, $line, $type, $totals) = @_;
- print $line if $Verbose;
-
- my $meth = $Handlers{$type};
- $meth->($self, $line, $type, $totals) if $meth;
-};
-
-
-$Handlers{header} = sub {
- my($self, $line, $type, $totals) = @_;
-
- warn "Test header seen more than once!\n" if $self->{_seen_header};
-
- $self->{_seen_header}++;
-
- warn "1..M can only appear at the beginning or end of tests\n"
- if $totals->{seen} &&
- $totals->{max} < $totals->{seen};
-};
-
-$Handlers{test} = sub {
- my($self, $line, $type, $totals) = @_;
-
- my $curr = $totals->{seen};
- my $next = $self->{'next'};
- my $max = $totals->{max};
- my $detail = $totals->{details}[-1];
-
- if( $detail->{ok} ) {
- _print_ml_less("ok $curr/$max");
-
- if( $detail->{type} eq 'skip' ) {
- $totals->{skip_reason} = $detail->{reason}
- unless defined $totals->{skip_reason};
- $totals->{skip_reason} = 'various reasons'
- if $totals->{skip_reason} ne $detail->{reason};
- }
- }
- else {
- _print_ml("NOK $curr");
- }
-
- if( $curr > $next ) {
- print "Test output counter mismatch [test $curr]\n";
- }
- elsif( $curr < $next ) {
- print "Confused test output: test $curr answered after ".
- "test ", $next - 1, "\n";
- }
-
-};
-
-$Handlers{bailout} = sub {
- my($self, $line, $type, $totals) = @_;
-
- die "FAILED--Further testing stopped" .
- ($self->{bailout_reason} ? ": $self->{bailout_reason}\n" : ".\n");
-};
-
-
-sub _print_ml {
- print join '', $ML, @_ if $ML;
-}
-
-
-# For slow connections, we save lots of bandwidth by printing only once
-# per second.
-sub _print_ml_less {
- if( !$Ok_Slow || $Last_ML_Print != time ) {
- _print_ml(@_);
- $Last_ML_Print = time;
- }
-}
-
-sub _bonusmsg {
- my($tot) = @_;
-
- my $bonusmsg = '';
- $bonusmsg = (" ($tot->{bonus} subtest".($tot->{bonus} > 1 ? 's' : '').
- " UNEXPECTEDLY SUCCEEDED)")
- if $tot->{bonus};
-
- if ($tot->{skipped}) {
- $bonusmsg .= ", $tot->{skipped} test"
- . ($tot->{skipped} != 1 ? 's' : '');
- if ($tot->{sub_skipped}) {
- $bonusmsg .= " and $tot->{sub_skipped} subtest"
- . ($tot->{sub_skipped} != 1 ? 's' : '');
- }
- $bonusmsg .= ' skipped';
- }
- elsif ($tot->{sub_skipped}) {
- $bonusmsg .= ", $tot->{sub_skipped} subtest"
- . ($tot->{sub_skipped} != 1 ? 's' : '')
- . " skipped";
- }
-
- return $bonusmsg;
-}
-
-# Test program go boom.
-sub _dubious_return {
- my($test, $tot, $estatus, $wstatus) = @_;
- my ($failed, $canon, $percent) = ('??', '??');
-
- printf "$test->{ml}dubious\n\tTest returned status $estatus ".
- "(wstat %d, 0x%x)\n",
- $wstatus,$wstatus;
- print "\t\t(VMS status is $estatus)\n" if $^O eq 'VMS';
-
- if (corestatus($wstatus)) { # until we have a wait module
- if ($Have_Devel_Corestack) {
- Devel::CoreStack::stack($^X);
- } else {
- print "\ttest program seems to have generated a core\n";
- }
- }
-
- $tot->{bad}++;
-
- if ($test->{max}) {
- if ($test->{'next'} == $test->{max} + 1 and not @{$test->{failed}}) {
- print "\tafter all the subtests completed successfully\n";
- $percent = 0;
- $failed = 0; # But we do not set $canon!
- }
- else {
- push @{$test->{failed}}, $test->{'next'}..$test->{max};
- $failed = @{$test->{failed}};
- (my $txt, $canon) = canonfailed($test->{max},$test->{skipped},@{$test->{failed}});
- $percent = 100*(scalar @{$test->{failed}})/$test->{max};
- print "DIED. ",$txt;
- }
- }
-
- return { canon => $canon, max => $test->{max} || '??',
- failed => $failed,
- percent => $percent,
- estat => $estatus, wstat => $wstatus,
- };
-}
-
-
-sub _create_fmts {
- my($failedtests) = @_;
-
- my $failed_str = "Failed Test";
- my $middle_str = " Stat Wstat Total Fail Failed ";
- my $list_str = "List of Failed";
-
- # Figure out our longest name string for formatting purposes.
- my $max_namelen = length($failed_str);
- foreach my $script (keys %$failedtests) {
- my $namelen = length $failedtests->{$script}->{name};
- $max_namelen = $namelen if $namelen > $max_namelen;
- }
-
- my $list_len = $Columns - length($middle_str) - $max_namelen;
- if ($list_len < length($list_str)) {
- $list_len = length($list_str);
- $max_namelen = $Columns - length($middle_str) - $list_len;
- if ($max_namelen < length($failed_str)) {
- $max_namelen = length($failed_str);
- $Columns = $max_namelen + length($middle_str) + $list_len;
- }
- }
-
- my $fmt_top = "format STDOUT_TOP =\n"
- . sprintf("%-${max_namelen}s", $failed_str)
- . $middle_str
- . $list_str . "\n"
- . "-" x $Columns
- . "\n.\n";
-
- my $fmt = "format STDOUT =\n"
- . "@" . "<" x ($max_namelen - 1)
- . " @>> @>>>> @>>>> @>>> ^##.##% "
- . "^" . "<" x ($list_len - 1) . "\n"
- . '{ $Curtest->{name}, $Curtest->{estat},'
- . ' $Curtest->{wstat}, $Curtest->{max},'
- . ' $Curtest->{failed}, $Curtest->{percent},'
- . ' $Curtest->{canon}'
- . "\n}\n"
- . "~~" . " " x ($Columns - $list_len - 2) . "^"
- . "<" x ($list_len - 1) . "\n"
- . '$Curtest->{canon}'
- . "\n.\n";
-
- eval $fmt_top;
- die $@ if $@;
- eval $fmt;
- die $@ if $@;
-
- return($fmt_top, $fmt);
-}
-
-{
- my $tried_devel_corestack;
-
- sub corestatus {
- my($st) = @_;
-
- my $did_core;
- eval { # we may not have a WCOREDUMP
- local $^W = 0; # *.ph files are often *very* noisy
- require 'wait.ph';
- $did_core = WCOREDUMP($st);
- };
- if( $@ ) {
- $did_core = $st & 0200;
- }
-
- eval { require Devel::CoreStack; $Have_Devel_Corestack++ }
- unless $tried_devel_corestack++;
-
- return $did_core;
- }
-}
-
-sub canonfailed ($$@) {
- my($max,$skipped,@failed) = @_;
- my %seen;
- @failed = sort {$a <=> $b} grep !$seen{$_}++, @failed;
- my $failed = @failed;
- my @result = ();
- my @canon = ();
- my $min;
- my $last = $min = shift @failed;
- my $canon;
- if (@failed) {
- for (@failed, $failed[-1]) { # don't forget the last one
- if ($_ > $last+1 || $_ == $last) {
- if ($min == $last) {
- push @canon, $last;
- } else {
- push @canon, "$min-$last";
- }
- $min = $_;
- }
- $last = $_;
- }
- local $" = ", ";
- push @result, "FAILED tests @canon\n";
- $canon = join ' ', @canon;
- } else {
- push @result, "FAILED test $last\n";
- $canon = $last;
- }
-
- push @result, "\tFailed $failed/$max tests, ";
- if ($max) {
- push @result, sprintf("%.2f",100*(1-$failed/$max)), "% okay";
- } else {
- push @result, "?% okay";
- }
- my $ender = 's' x ($skipped > 1);
- my $good = $max - $failed - $skipped;
- if ($skipped) {
- my $skipmsg = " (less $skipped skipped test$ender: $good okay, ";
- if ($max) {
- my $goodper = sprintf("%.2f",100*($good/$max));
- $skipmsg .= "$goodper%)";
- } else {
- $skipmsg .= "?%)";
- }
- push @result, $skipmsg;
- }
- push @result, "\n";
- my $txt = join "", @result;
- ($txt, $canon);
-}
-
-=end _private
-
-=back
-
-=cut
-
-
-1;
-__END__
-
-
-=head1 EXPORT
-
-C<&runtests> is exported by Test::Harness by default.
-
-C<$verbose> and C<$switches> are exported upon request.
-
-
-=head1 DIAGNOSTICS
-
-=over 4
-
-=item C<All tests successful.\nFiles=%d, Tests=%d, %s>
-
-If all tests are successful some statistics about the performance are
-printed.
-
-=item C<FAILED tests %s\n\tFailed %d/%d tests, %.2f%% okay.>
-
-For any single script that has failing subtests statistics like the
-above are printed.
-
-=item C<Test returned status %d (wstat %d)>
-
-Scripts that return a non-zero exit status, both C<$? E<gt>E<gt> 8>
-and C<$?> are printed in a message similar to the above.
-
-=item C<Failed 1 test, %.2f%% okay. %s>
-
-=item C<Failed %d/%d tests, %.2f%% okay. %s>
-
-If not all tests were successful, the script dies with one of the
-above messages.
-
-=item C<FAILED--Further testing stopped: %s>
-
-If a single subtest decides that further testing will not make sense,
-the script dies with this message.
-
-=back
-
-=head1 ENVIRONMENT
-
-=over 4
-
-=item C<HARNESS_ACTIVE>
-
-Harness sets this before executing the individual tests. This allows
-the tests to determine if they are being executed through the harness
-or by any other means.
-
-=item C<HARNESS_COLUMNS>
-
-This value will be used for the width of the terminal. If it is not
-set then it will default to C<COLUMNS>. If this is not set, it will
-default to 80. Note that users of Bourne-sh based shells will need to
-C<export COLUMNS> for this module to use that variable.
-
-=item C<HARNESS_COMPILE_TEST>
-
-When true it will make harness attempt to compile the test using
-C<perlcc> before running it.
-
-B<NOTE> This currently only works when sitting in the perl source
-directory!
-
-=item C<HARNESS_FILELEAK_IN_DIR>
-
-When set to the name of a directory, harness will check after each
-test whether new files appeared in that directory, and report them as
-
- LEAKED FILES: scr.tmp 0 my.db
-
-If relative, directory name is with respect to the current directory at
-the moment runtests() was called. Putting absolute path into
-C<HARNESS_FILELEAK_IN_DIR> may give more predictable results.
-
-=item C<HARNESS_IGNORE_EXITCODE>
-
-Makes harness ignore the exit status of child processes when defined.
-
-=item C<HARNESS_NOTTY>
-
-When set to a true value, forces it to behave as though STDOUT were
-not a console. You may need to set this if you don't want harness to
-output more frequent progress messages using carriage returns. Some
-consoles may not handle carriage returns properly (which results in a
-somewhat messy output).
-
-=item C<HARNESS_OK_SLOW>
-
-If true, the C<ok> messages are printed out only every second.
-This reduces output and therefore may for example help testing
-over slow connections.
-
-=item C<HARNESS_PERL_SWITCHES>
-
-Its value will be prepended to the switches used to invoke perl on
-each test. For example, setting C<HARNESS_PERL_SWITCHES> to C<-W> will
-run all tests with all warnings enabled.
-
-=item C<HARNESS_VERBOSE>
-
-If true, Test::Harness will output the verbose results of running
-its tests. Setting $Test::Harness::verbose will override this.
-
-=back
-
-=head1 EXAMPLE
-
-Here's how Test::Harness tests itself
-
- $ cd ~/src/devel/Test-Harness
- $ perl -Mblib -e 'use Test::Harness qw(&runtests $verbose);
- $verbose=0; runtests @ARGV;' t/*.t
- Using /home/schwern/src/devel/Test-Harness/blib
- t/base..............ok
- t/nonumbers.........ok
- t/ok................ok
- t/test-harness......ok
- All tests successful.
- Files=4, Tests=24, 2 wallclock secs ( 0.61 cusr + 0.41 csys = 1.02 CPU)
-
-=head1 SEE ALSO
-
-L<Test> and L<Test::Simple> for writing test scripts, L<Benchmark> for
-the underlying timing routines, L<Devel::CoreStack> to generate core
-dumps from failed tests and L<Devel::Cover> for test coverage
-analysis.
-
-=head1 AUTHORS
-
-Either Tim Bunce or Andreas Koenig, we don't know. What we know for
-sure is, that it was inspired by Larry Wall's TEST script that came
-with perl distributions for ages. Numerous anonymous contributors
-exist. Andreas Koenig held the torch for many years, and then
-Michael G Schwern.
-
-Current maintainer is Andy Lester C<< <andy@petdance.com> >>.
-
-=head1 LICENSE
-
-This program is free software; you can redistribute it and/or
-modify it under the same terms as Perl itself.
-
-See L<http://www.perl.com/perl/misc/Artistic.html>
-
-=head1 TODO
-
-Provide a way of running tests quietly (ie. no printing) for automated
-validation of tests. This will probably take the form of a version
-of runtests() which rather than printing its output returns raw data
-on the state of the tests. (Partially done in Test::Harness::Straps)
-
-Document the format.
-
-Fix HARNESS_COMPILE_TEST without breaking its core usage.
-
-Figure a way to report test names in the failure summary.
-
-Rework the test summary so long test names are not truncated as badly.
-(Partially done with new skip test styles)
-
-Deal with VMS's "not \nok 4\n" mistake.
-
-Add option for coverage analysis.
-
-Trap STDERR.
-
-Implement Straps total_results()
-
-Remember exit code
-
-Completely redo the print summary code.
-
-Implement Straps callbacks. (experimentally implemented)
-
-Straps->analyze_file() not taint clean, don't know if it can be
-
-Fix that damned VMS nit.
-
-HARNESS_TODOFAIL to display TODO failures
-
-Add a test for verbose.
-
-Change internal list of test results to a hash.
-
-Fix stats display when there's an overrun.
-
-Fix so perls with spaces in the filename work.
-
-=for _private
-
-Keeping whittling away at _run_all_tests()
-
-=for _private
-
-Clean up how the summary is printed. Get rid of those damned formats.
-
-=head1 BUGS
-
-HARNESS_COMPILE_TEST currently assumes it's run from the Perl source
-directory.
-
-=cut
diff --git a/Perl/t/Test/Harness/Assert.pm b/Perl/t/Test/Harness/Assert.pm
deleted file mode 100644
index 3ee23e3..0000000
--- a/Perl/t/Test/Harness/Assert.pm
+++ /dev/null
@@ -1,68 +0,0 @@
-# $Id$
-
-package Test::Harness::Assert;
-
-use strict;
-require Exporter;
-use vars qw($VERSION @EXPORT @ISA);
-
-$VERSION = '0.01';
-
-@ISA = qw(Exporter);
-@EXPORT = qw(assert);
-
-
-=head1 NAME
-
-Test::Harness::Assert - simple assert
-
-=head1 SYNOPSIS
-
- ### FOR INTERNAL USE ONLY ###
-
- use Test::Harness::Assert;
-
- assert( EXPR, $name );
-
-=head1 DESCRIPTION
-
-A simple assert routine since we don't have Carp::Assert handy.
-
-B<For internal use by Test::Harness ONLY!>
-
-=head2 Functions
-
-=over 4
-
-=item B<assert>
-
- assert( EXPR, $name );
-
-If the expression is false the program aborts.
-
-=cut
-
-sub assert ($;$) {
- my($assert, $name) = @_;
-
- unless( $assert ) {
- require Carp;
- my $msg = 'Assert failed';
- $msg .= " - '$name'" if defined $name;
- $msg .= '!';
- Carp::croak($msg);
- }
-
-}
-
-=head1 AUTHOR
-
-Michael G Schwern E<lt>schwern@pobox.comE<gt>
-
-=head1 SEE ALSO
-
-L<Carp::Assert>
-
-=cut
-
-1;
diff --git a/Perl/t/Test/Harness/Iterator.pm b/Perl/t/Test/Harness/Iterator.pm
deleted file mode 100644
index 5e22793..0000000
--- a/Perl/t/Test/Harness/Iterator.pm
+++ /dev/null
@@ -1,61 +0,0 @@
-package Test::Harness::Iterator;
-
-use strict;
-use vars qw($VERSION);
-$VERSION = 0.01;
-
-
-=head1 NAME
-
-Test::Harness::Iterator - Internal Test::Harness Iterator
-
-=head1 SYNOPSIS
-
- use Test::Harness::Iterator;
- use Test::Harness::Iterator;
- my $it = Test::Harness::Iterator->new(\*TEST);
- my $it = Test::Harness::Iterator->new(\@array);
-
- my $line = $it->next;
-
-
-=head1 DESCRIPTION
-
-B<FOR INTERNAL USE ONLY!>
-
-This is a simple iterator wrapper for arrays and filehandles.
-
-=cut
-
-sub new {
- my($proto, $thing) = @_;
-
- my $self = {};
- if( ref $thing eq 'GLOB' ) {
- bless $self, 'Test::Harness::Iterator::FH';
- $self->{fh} = $thing;
- }
- elsif( ref $thing eq 'ARRAY' ) {
- bless $self, 'Test::Harness::Iterator::ARRAY';
- $self->{idx} = 0;
- $self->{array} = $thing;
- }
- else {
- warn "Can't iterate with a ", ref $thing;
- }
-
- return $self;
-}
-
-package Test::Harness::Iterator::FH;
-sub next {
- my $fh = $_[0]->{fh};
- return scalar <$fh>;
-}
-
-
-package Test::Harness::Iterator::ARRAY;
-sub next {
- my $self = shift;
- return $self->{array}->[$self->{idx}++];
-}
diff --git a/Perl/t/Test/Harness/Straps.pm b/Perl/t/Test/Harness/Straps.pm
deleted file mode 100644
index 4d971b7..0000000
--- a/Perl/t/Test/Harness/Straps.pm
+++ /dev/null
@@ -1,667 +0,0 @@
-# -*- Mode: cperl; cperl-indent-level: 4 -*-
-# $Id$
-
-package Test::Harness::Straps;
-
-use strict;
-use vars qw($VERSION);
-use Config;
-$VERSION = '0.15';
-
-use Test::Harness::Assert;
-use Test::Harness::Iterator;
-
-# Flags used as return values from our methods. Just for internal
-# clarification.
-my $TRUE = (1==1);
-my $FALSE = !$TRUE;
-my $YES = $TRUE;
-my $NO = $FALSE;
-
-
-=head1 NAME
-
-Test::Harness::Straps - detailed analysis of test results
-
-=head1 SYNOPSIS
-
- use Test::Harness::Straps;
-
- my $strap = Test::Harness::Straps->new;
-
- # Various ways to interpret a test
- my %results = $strap->analyze($name, \@test_output);
- my %results = $strap->analyze_fh($name, $test_filehandle);
- my %results = $strap->analyze_file($test_file);
-
- # UNIMPLEMENTED
- my %total = $strap->total_results;
-
- # Altering the behavior of the strap UNIMPLEMENTED
- my $verbose_output = $strap->dump_verbose();
- $strap->dump_verbose_fh($output_filehandle);
-
-
-=head1 DESCRIPTION
-
-B<THIS IS ALPHA SOFTWARE> in that the interface is subject to change
-in incompatible ways. It is otherwise stable.
-
-Test::Harness is limited to printing out its results. This makes
-analysis of the test results difficult for anything but a human. To
-make it easier for programs to work with test results, we provide
-Test::Harness::Straps. Instead of printing the results, straps
-provide them as raw data. You can also configure how the tests are to
-be run.
-
-The interface is currently incomplete. I<Please> contact the author
-if you'd like a feature added or something change or just have
-comments.
-
-=head1 Construction
-
-=head2 C<new>
-
- my $strap = Test::Harness::Straps->new;
-
-Initialize a new strap.
-
-=cut
-
-sub new {
- my($proto) = shift;
- my($class) = ref $proto || $proto;
-
- my $self = bless {}, $class;
- $self->_init;
-
- return $self;
-}
-
-=head2 C<_init>
-
- $strap->_init;
-
-Initialize the internal state of a strap to make it ready for parsing.
-
-=cut
-
-sub _init {
- my($self) = shift;
-
- $self->{_is_vms} = $^O eq 'VMS';
- $self->{_is_win32} = $^O eq 'Win32';
-}
-
-=head1 Analysis
-
-=head2 C<analyze>
-
- my %results = $strap->analyze($name, \@test_output);
-
-Analyzes the output of a single test, assigning it the given C<$name>
-for use in the total report. Returns the C<%results> of the test.
-See L<Results>.
-
-C<@test_output> should be the raw output from the test, including
-newlines.
-
-=cut
-
-sub analyze {
- my($self, $name, $test_output) = @_;
-
- my $it = Test::Harness::Iterator->new($test_output);
- return $self->_analyze_iterator($name, $it);
-}
-
-
-sub _analyze_iterator {
- my($self, $name, $it) = @_;
-
- $self->_reset_file_state;
- $self->{file} = $name;
- my %totals = (
- max => 0,
- seen => 0,
-
- ok => 0,
- todo => 0,
- skip => 0,
- bonus => 0,
-
- details => []
- );
-
- # Set them up here so callbacks can have them.
- $self->{totals}{$name} = \%totals;
- while( defined(my $line = $it->next) ) {
- $self->_analyze_line($line, \%totals);
- last if $self->{saw_bailout};
- }
-
- $totals{skip_all} = $self->{skip_all} if defined $self->{skip_all};
-
- my $passed = ($totals{max} == 0 && defined $totals{skip_all}) ||
- ($totals{max} && $totals{seen} &&
- $totals{max} == $totals{seen} &&
- $totals{max} == $totals{ok});
- $totals{passing} = $passed ? 1 : 0;
-
- return %totals;
-}
-
-
-sub _analyze_line {
- my($self, $line, $totals) = @_;
-
- my %result = ();
-
- $self->{line}++;
-
- my $type;
- if( $self->_is_header($line) ) {
- $type = 'header';
-
- $self->{saw_header}++;
-
- $totals->{max} += $self->{max};
- }
- elsif( $self->_is_test($line, \%result) ) {
- $type = 'test';
-
- $totals->{seen}++;
- $result{number} = $self->{'next'} unless $result{number};
-
- # sometimes the 'not ' and the 'ok' are on different lines,
- # happens often on VMS if you do:
- # print "not " unless $test;
- # print "ok $num\n";
- if( $self->{saw_lone_not} &&
- ($self->{lone_not_line} == $self->{line} - 1) )
- {
- $result{ok} = 0;
- }
-
- my $pass = $result{ok};
- $result{type} = 'todo' if $self->{todo}{$result{number}};
-
- if( $result{type} eq 'todo' ) {
- $totals->{todo}++;
- $pass = 1;
- $totals->{bonus}++ if $result{ok}
- }
- elsif( $result{type} eq 'skip' ) {
- $totals->{skip}++;
- $pass = 1;
- }
-
- $totals->{ok}++ if $pass;
-
- if( $result{number} > 100000 && $result{number} > $self->{max} ) {
- warn "Enormous test number seen [test $result{number}]\n";
- warn "Can't detailize, too big.\n";
- }
- else {
- $totals->{details}[$result{number} - 1] =
- {$self->_detailize($pass, \%result)};
- }
-
- # XXX handle counter mismatch
- }
- elsif ( $self->_is_bail_out($line, \$self->{bailout_reason}) ) {
- $type = 'bailout';
- $self->{saw_bailout} = 1;
- }
- else {
- $type = 'other';
- }
-
- $self->{callback}->($self, $line, $type, $totals) if $self->{callback};
-
- $self->{'next'} = $result{number} + 1 if $type eq 'test';
-}
-
-=head2 C<analyze_fh>
-
- my %results = $strap->analyze_fh($name, $test_filehandle);
-
-Like C<analyze>, but it reads from the given filehandle.
-
-=cut
-
-sub analyze_fh {
- my($self, $name, $fh) = @_;
-
- my $it = Test::Harness::Iterator->new($fh);
- $self->_analyze_iterator($name, $it);
-}
-
-=head2 C<analyze_file>
-
- my %results = $strap->analyze_file($test_file);
-
-Like C<analyze>, but it runs the given C<$test_file> and parses its
-results. It will also use that name for the total report.
-
-=cut
-
-sub analyze_file {
- my($self, $file) = @_;
-
- unless( -e $file ) {
- $self->{error} = "$file does not exist";
- return;
- }
-
- unless( -r $file ) {
- $self->{error} = "$file is not readable";
- return;
- }
-
- local $ENV{PERL5LIB} = $self->_INC2PERL5LIB;
-
- my $cmd = $self->{_is_vms} ? "MCR $^X" :
- $self->{_is_win32} ? Win32::GetShortPathName($^X)
- : $^X;
-
- my $switches = $self->_switches($file);
-
- # *sigh* this breaks under taint, but open -| is unportable.
- unless( open(FILE, "$cmd $switches $file|") ) {
- print "can't run $file. $!\n";
- return;
- }
-
- my %results = $self->analyze_fh($file, \*FILE);
- my $exit = close FILE;
- $results{'wait'} = $?;
- if( $? && $self->{_is_vms} ) {
- eval q{use vmsish "status"; $results{'exit'} = $?};
- }
- else {
- $results{'exit'} = _wait2exit($?);
- }
- $results{passing} = 0 unless $? == 0;
-
- $self->_restore_PERL5LIB();
-
- return %results;
-}
-
-
-eval { require POSIX; &POSIX::WEXITSTATUS(0) };
-if( $@ ) {
- *_wait2exit = sub { $_[0] >> 8 };
-}
-else {
- *_wait2exit = sub { POSIX::WEXITSTATUS($_[0]) }
-}
-
-
-=head2 C<_switches>
-
- my $switches = $self->_switches($file);
-
-Formats and returns the switches necessary to run the test.
-
-=cut
-
-sub _switches {
- my($self, $file) = @_;
-
- local *TEST;
- open(TEST, $file) or print "can't open $file. $!\n";
- my $first = <TEST>;
- my $s = $Test::Harness::Switches || '';
- $s .= " $ENV{'HARNESS_PERL_SWITCHES'}"
- if exists $ENV{'HARNESS_PERL_SWITCHES'};
-
- if ($first =~ /^#!.*\bperl.*\s-\w*([Tt]+)/) {
- # When taint mode is on, PERL5LIB is ignored. So we need to put
- # all that on the command line as -Is.
- $s .= join " ", qq[ "-$1"], map {qq["-I$_"]} $self->_filtered_INC;
- }
- elsif ($^O eq 'MacOS') {
- # MacPerl's putenv is broken, so it will not see PERL5LIB.
- $s .= join " ", map {qq["-I$_"]} $self->_filtered_INC;
- }
-
- close(TEST) or print "can't close $file. $!\n";
-
- return $s;
-}
-
-
-=head2 C<_INC2PERL5LIB>
-
- local $ENV{PERL5LIB} = $self->_INC2PERL5LIB;
-
-Takes the current value of C<@INC> and turns it into something suitable
-for putting onto C<PERL5LIB>.
-
-=cut
-
-sub _INC2PERL5LIB {
- my($self) = shift;
-
- $self->{_old5lib} = $ENV{PERL5LIB};
-
- return join $Config{path_sep}, $self->_filtered_INC;
-}
-
-=head2 C<_filtered_INC>
-
- my @filtered_inc = $self->_filtered_INC;
-
-Shortens C<@INC> by removing redundant and unnecessary entries.
-Necessary for OSes with limited command line lengths, like VMS.
-
-=cut
-
-sub _filtered_INC {
- my($self, @inc) = @_;
- @inc = @INC unless @inc;
-
- # VMS has a 255-byte limit on the length of %ENV entries, so
- # toss the ones that involve perl_root, the install location
- # for VMS
- if( $self->{_is_vms} ) {
- @inc = grep !/perl_root/i, @inc;
- }
-
- return @inc;
-}
-
-
-=head2 C<_restore_PERL5LIB>
-
- $self->_restore_PERL5LIB;
-
-This restores the original value of the C<PERL5LIB> environment variable.
-Necessary on VMS, otherwise a no-op.
-
-=cut
-
-sub _restore_PERL5LIB {
- my($self) = shift;
-
- return unless $self->{_is_vms};
-
- if (defined $self->{_old5lib}) {
- $ENV{PERL5LIB} = $self->{_old5lib};
- }
-}
-
-=head1 Parsing
-
-Methods for identifying what sort of line you're looking at.
-
-=head2 C<_is_comment>
-
- my $is_comment = $strap->_is_comment($line, \$comment);
-
-Checks if the given line is a comment. If so, it will place it into
-C<$comment> (sans #).
-
-=cut
-
-sub _is_comment {
- my($self, $line, $comment) = @_;
-
- if( $line =~ /^\s*\#(.*)/ ) {
- $$comment = $1;
- return $YES;
- }
- else {
- return $NO;
- }
-}
-
-=head2 C<_is_header>
-
- my $is_header = $strap->_is_header($line);
-
-Checks if the given line is a header (1..M) line. If so, it places how
-many tests there will be in C<< $strap->{max} >>, a list of which tests
-are todo in C<< $strap->{todo} >> and if the whole test was skipped
-C<< $strap->{skip_all} >> contains the reason.
-
-=cut
-
-# Regex for parsing a header. Will be run with /x
-my $Extra_Header_Re = <<'REGEX';
- ^
- (?: \s+ todo \s+ ([\d \t]+) )? # optional todo set
- (?: \s* \# \s* ([\w:]+\s?) (.*) )? # optional skip with optional reason
-REGEX
-
-sub _is_header {
- my($self, $line) = @_;
-
- if( my($max, $extra) = $line =~ /^1\.\.(\d+)(.*)/ ) {
- $self->{max} = $max;
- assert( $self->{max} >= 0, 'Max # of tests looks right' );
-
- if( defined $extra ) {
- my($todo, $skip, $reason) = $extra =~ /$Extra_Header_Re/xo;
-
- $self->{todo} = { map { $_ => 1 } split /\s+/, $todo } if $todo;
-
- if( $self->{max} == 0 ) {
- $reason = '' unless defined $skip and $skip =~ /^Skip/i;
- }
-
- $self->{skip_all} = $reason;
- }
-
- return $YES;
- }
- else {
- return $NO;
- }
-}
-
-=head2 C<_is_test>
-
- my $is_test = $strap->_is_test($line, \%test);
-
-Checks if the $line is a test report (ie. 'ok/not ok'). Reports the
-result back in C<%test> which will contain:
-
- ok did it succeed? This is the literal 'ok' or 'not ok'.
- name name of the test (if any)
- number test number (if any)
-
- type 'todo' or 'skip' (if any)
- reason why is it todo or skip? (if any)
-
-If will also catch lone 'not' lines, note it saw them
-C<< $strap->{saw_lone_not} >> and the line in C<< $strap->{lone_not_line} >>.
-
-=cut
-
-my $Report_Re = <<'REGEX';
- ^
- (not\ )? # failure?
- ok\b
- (?:\s+(\d+))? # optional test number
- \s*
- (.*) # and the rest
-REGEX
-
-my $Extra_Re = <<'REGEX';
- ^
- (.*?) (?:(?:[^\\]|^)# (.*))?
- $
-REGEX
-
-sub _is_test {
- my($self, $line, $test) = @_;
-
- # We pulverize the line down into pieces in three parts.
- if( my($not, $num, $extra) = $line =~ /$Report_Re/ox ) {
- my($name, $control) = split /(?:[^\\]|^)#/, $extra if $extra;
- my($type, $reason) = $control =~ /^\s*(\S+)(?:\s+(.*))?$/ if $control;
-
- $test->{number} = $num;
- $test->{ok} = $not ? 0 : 1;
- $test->{name} = $name;
-
- if( defined $type ) {
- $test->{type} = $type =~ /^TODO$/i ? 'todo' :
- $type =~ /^Skip/i ? 'skip' : 0;
- }
- else {
- $test->{type} = '';
- }
- $test->{reason} = $reason;
-
- return $YES;
- }
- else{
- # Sometimes the "not " and "ok" will be on seperate lines on VMS.
- # We catch this and remember we saw it.
- if( $line =~ /^not\s+$/ ) {
- $self->{saw_lone_not} = 1;
- $self->{lone_not_line} = $self->{line};
- }
-
- return $NO;
- }
-}
-
-=head2 C<_is_bail_out>
-
- my $is_bail_out = $strap->_is_bail_out($line, \$reason);
-
-Checks if the line is a "Bail out!". Places the reason for bailing
-(if any) in $reason.
-
-=cut
-
-sub _is_bail_out {
- my($self, $line, $reason) = @_;
-
- if( $line =~ /^Bail out!\s*(.*)/i ) {
- $$reason = $1 if $1;
- return $YES;
- }
- else {
- return $NO;
- }
-}
-
-=head2 C<_reset_file_state>
-
- $strap->_reset_file_state;
-
-Resets things like C<< $strap->{max} >> , C<< $strap->{skip_all} >>,
-etc. so it's ready to parse the next file.
-
-=cut
-
-sub _reset_file_state {
- my($self) = shift;
-
- delete @{$self}{qw(max skip_all todo)};
- $self->{line} = 0;
- $self->{saw_header} = 0;
- $self->{saw_bailout}= 0;
- $self->{saw_lone_not} = 0;
- $self->{lone_not_line} = 0;
- $self->{bailout_reason} = '';
- $self->{'next'} = 1;
-}
-
-=head1 Results
-
-The C<%results> returned from C<analyze()> contain the following
-information:
-
- passing true if the whole test is considered a pass
- (or skipped), false if its a failure
-
- exit the exit code of the test run, if from a file
- wait the wait code of the test run, if from a file
-
- max total tests which should have been run
- seen total tests actually seen
- skip_all if the whole test was skipped, this will
- contain the reason.
-
- ok number of tests which passed
- (including todo and skips)
-
- todo number of todo tests seen
- bonus number of todo tests which
- unexpectedly passed
-
- skip number of tests skipped
-
-So a successful test should have max == seen == ok.
-
-
-There is one final item, the details.
-
- details an array ref reporting the result of
- each test looks like this:
-
- $results{details}[$test_num - 1] =
- { ok => is the test considered ok?
- actual_ok => did it literally say 'ok'?
- name => name of the test (if any)
- type => 'skip' or 'todo' (if any)
- reason => reason for the above (if any)
- };
-
-Element 0 of the details is test #1. I tried it with element 1 being
-#1 and 0 being empty, this is less awkward.
-
-=head2 C<_detailize>
-
- my %details = $strap->_detailize($pass, \%test);
-
-Generates the details based on the last test line seen. C<$pass> is
-true if it was considered to be a passed test. C<%test> is the results
-of the test you're summarizing.
-
-=cut
-
-sub _detailize {
- my($self, $pass, $test) = @_;
-
- my %details = ( ok => $pass,
- actual_ok => $test->{ok}
- );
-
- assert( !(grep !defined $details{$_}, keys %details),
- 'test contains the ok and actual_ok info' );
-
- # We don't want these to be undef because they are often
- # checked and don't want the checker to have to deal with
- # uninitialized vars.
- foreach my $piece (qw(name type reason)) {
- $details{$piece} = defined $test->{$piece} ? $test->{$piece} : '';
- }
-
- return %details;
-}
-
-=head1 EXAMPLES
-
-See F<examples/mini_harness.plx> for an example of use.
-
-=head1 AUTHOR
-
-Michael G Schwern C<< <schwern@pobox.com> >>, currently maintained by
-Andy Lester C<< <andy@petdance.com> >>.
-
-=head1 SEE ALSO
-
-L<Test::Harness>
-
-=cut
-
-
-1;
diff --git a/Perl/t/Test/More.pm b/Perl/t/Test/More.pm
deleted file mode 100644
index 03f7552..0000000
--- a/Perl/t/Test/More.pm
+++ /dev/null
@@ -1,1248 +0,0 @@
-package Test::More;
-
-use 5.004;
-
-use strict;
-use Test::Builder;
-
-
-# Can't use Carp because it might cause use_ok() to accidentally succeed
-# even though the module being used forgot to use Carp. Yes, this
-# actually happened.
-sub _carp {
- my($file, $line) = (caller(1))[1,2];
- warn @_, " at $file line $line\n";
-}
-
-
-
-require Exporter;
-use vars qw($VERSION @ISA @EXPORT %EXPORT_TAGS $TODO);
-$VERSION = '0.47';
-@ISA = qw(Exporter);
-@EXPORT = qw(ok use_ok require_ok
- is isnt like unlike is_deeply
- cmp_ok
- skip todo todo_skip
- pass fail
- eq_array eq_hash eq_set
- $TODO
- plan
- can_ok isa_ok
- diag
- );
-
-my $Test = Test::Builder->new;
-
-
-# 5.004's Exporter doesn't have export_to_level.
-sub _export_to_level
-{
- my $pkg = shift;
- my $level = shift;
- (undef) = shift; # redundant arg
- my $callpkg = caller($level);
- $pkg->export($callpkg, @_);
-}
-
-
-=head1 NAME
-
-Test::More - yet another framework for writing test scripts
-
-=head1 SYNOPSIS
-
- use Test::More tests => $Num_Tests;
- # or
- use Test::More qw(no_plan);
- # or
- use Test::More skip_all => $reason;
-
- BEGIN { use_ok( 'Some::Module' ); }
- require_ok( 'Some::Module' );
-
- # Various ways to say "ok"
- ok($this eq $that, $test_name);
-
- is ($this, $that, $test_name);
- isnt($this, $that, $test_name);
-
- # Rather than print STDERR "# here's what went wrong\n"
- diag("here's what went wrong");
-
- like ($this, qr/that/, $test_name);
- unlike($this, qr/that/, $test_name);
-
- cmp_ok($this, '==', $that, $test_name);
-
- is_deeply($complex_structure1, $complex_structure2, $test_name);
-
- SKIP: {
- skip $why, $how_many unless $have_some_feature;
-
- ok( foo(), $test_name );
- is( foo(42), 23, $test_name );
- };
-
- TODO: {
- local $TODO = $why;
-
- ok( foo(), $test_name );
- is( foo(42), 23, $test_name );
- };
-
- can_ok($module, @methods);
- isa_ok($object, $class);
-
- pass($test_name);
- fail($test_name);
-
- # Utility comparison functions.
- eq_array(\@this, \@that);
- eq_hash(\%this, \%that);
- eq_set(\@this, \@that);
-
- # UNIMPLEMENTED!!!
- my @status = Test::More::status;
-
- # UNIMPLEMENTED!!!
- BAIL_OUT($why);
-
-
-=head1 DESCRIPTION
-
-B<STOP!> If you're just getting started writing tests, have a look at
-Test::Simple first. This is a drop in replacement for Test::Simple
-which you can switch to once you get the hang of basic testing.
-
-The purpose of this module is to provide a wide range of testing
-utilities. Various ways to say "ok" with better diagnostics,
-facilities to skip tests, test future features and compare complicated
-data structures. While you can do almost anything with a simple
-C<ok()> function, it doesn't provide good diagnostic output.
-
-
-=head2 I love it when a plan comes together
-
-Before anything else, you need a testing plan. This basically declares
-how many tests your script is going to run to protect against premature
-failure.
-
-The preferred way to do this is to declare a plan when you C<use Test::More>.
-
- use Test::More tests => $Num_Tests;
-
-There are rare cases when you will not know beforehand how many tests
-your script is going to run. In this case, you can declare that you
-have no plan. (Try to avoid using this as it weakens your test.)
-
- use Test::More qw(no_plan);
-
-In some cases, you'll want to completely skip an entire testing script.
-
- use Test::More skip_all => $skip_reason;
-
-Your script will declare a skip with the reason why you skipped and
-exit immediately with a zero (success). See L<Test::Harness> for
-details.
-
-If you want to control what functions Test::More will export, you
-have to use the 'import' option. For example, to import everything
-but 'fail', you'd do:
-
- use Test::More tests => 23, import => ['!fail'];
-
-Alternatively, you can use the plan() function. Useful for when you
-have to calculate the number of tests.
-
- use Test::More;
- plan tests => keys %Stuff * 3;
-
-or for deciding between running the tests at all:
-
- use Test::More;
- if( $^O eq 'MacOS' ) {
- plan skip_all => 'Test irrelevant on MacOS';
- }
- else {
- plan tests => 42;
- }
-
-=cut
-
-sub plan {
- my(@plan) = @_;
-
- my $caller = caller;
-
- $Test->exported_to($caller);
-
- my @imports = ();
- foreach my $idx (0..$#plan) {
- if( $plan[$idx] eq 'import' ) {
- my($tag, $imports) = splice @plan, $idx, 2;
- @imports = @$imports;
- last;
- }
- }
-
- $Test->plan(@plan);
-
- __PACKAGE__->_export_to_level(1, __PACKAGE__, @imports);
-}
-
-sub import {
- my($class) = shift;
- goto &plan;
-}
-
-
-=head2 Test names
-
-By convention, each test is assigned a number in order. This is
-largely done automatically for you. However, it's often very useful to
-assign a name to each test. Which would you rather see:
-
- ok 4
- not ok 5
- ok 6
-
-or
-
- ok 4 - basic multi-variable
- not ok 5 - simple exponential
- ok 6 - force == mass * acceleration
-
-The later gives you some idea of what failed. It also makes it easier
-to find the test in your script, simply search for "simple
-exponential".
-
-All test functions take a name argument. It's optional, but highly
-suggested that you use it.
-
-
-=head2 I'm ok, you're not ok.
-
-The basic purpose of this module is to print out either "ok #" or "not
-ok #" depending on if a given test succeeded or failed. Everything
-else is just gravy.
-
-All of the following print "ok" or "not ok" depending on if the test
-succeeded or failed. They all also return true or false,
-respectively.
-
-=over 4
-
-=item B<ok>
-
- ok($this eq $that, $test_name);
-
-This simply evaluates any expression (C<$this eq $that> is just a
-simple example) and uses that to determine if the test succeeded or
-failed. A true expression passes, a false one fails. Very simple.
-
-For example:
-
- ok( $exp{9} == 81, 'simple exponential' );
- ok( Film->can('db_Main'), 'set_db()' );
- ok( $p->tests == 4, 'saw tests' );
- ok( !grep !defined $_, @items, 'items populated' );
-
-(Mnemonic: "This is ok.")
-
-$test_name is a very short description of the test that will be printed
-out. It makes it very easy to find a test in your script when it fails
-and gives others an idea of your intentions. $test_name is optional,
-but we B<very> strongly encourage its use.
-
-Should an ok() fail, it will produce some diagnostics:
-
- not ok 18 - sufficient mucus
- # Failed test 18 (foo.t at line 42)
-
-This is actually Test::Simple's ok() routine.
-
-=cut
-
-sub ok ($;$) {
- my($test, $name) = @_;
- $Test->ok($test, $name);
-}
-
-=item B<is>
-
-=item B<isnt>
-
- is ( $this, $that, $test_name );
- isnt( $this, $that, $test_name );
-
-Similar to ok(), is() and isnt() compare their two arguments
-with C<eq> and C<ne> respectively and use the result of that to
-determine if the test succeeded or failed. So these:
-
- # Is the ultimate answer 42?
- is( ultimate_answer(), 42, "Meaning of Life" );
-
- # $foo isn't empty
- isnt( $foo, '', "Got some foo" );
-
-are similar to these:
-
- ok( ultimate_answer() eq 42, "Meaning of Life" );
- ok( $foo ne '', "Got some foo" );
-
-(Mnemonic: "This is that." "This isn't that.")
-
-So why use these? They produce better diagnostics on failure. ok()
-cannot know what you are testing for (beyond the name), but is() and
-isnt() know what the test was and why it failed. For example this
-test:
-
- my $foo = 'waffle'; my $bar = 'yarblokos';
- is( $foo, $bar, 'Is foo the same as bar?' );
-
-Will produce something like this:
-
- not ok 17 - Is foo the same as bar?
- # Failed test (foo.t at line 139)
- # got: 'waffle'
- # expected: 'yarblokos'
-
-So you can figure out what went wrong without rerunning the test.
-
-You are encouraged to use is() and isnt() over ok() where possible,
-however do not be tempted to use them to find out if something is
-true or false!
-
- # XXX BAD! $pope->isa('Catholic') eq 1
- is( $pope->isa('Catholic'), 1, 'Is the Pope Catholic?' );
-
-This does not check if C<$pope->isa('Catholic')> is true, it checks if
-it returns 1. Very different. Similar caveats exist for false and 0.
-In these cases, use ok().
-
- ok( $pope->isa('Catholic') ), 'Is the Pope Catholic?' );
-
-For those grammatical pedants out there, there's an C<isn't()>
-function which is an alias of isnt().
-
-=cut
-
-sub is ($$;$) {
- $Test->is_eq(@_);
-}
-
-sub isnt ($$;$) {
- $Test->isnt_eq(@_);
-}
-
-*isn't = \&isnt;
-
-
-=item B<like>
-
- like( $this, qr/that/, $test_name );
-
-Similar to ok(), like() matches $this against the regex C<qr/that/>.
-
-So this:
-
- like($this, qr/that/, 'this is like that');
-
-is similar to:
-
- ok( $this =~ /that/, 'this is like that');
-
-(Mnemonic "This is like that".)
-
-The second argument is a regular expression. It may be given as a
-regex reference (i.e. C<qr//>) or (for better compatibility with older
-perls) as a string that looks like a regex (alternative delimiters are
-currently not supported):
-
- like( $this, '/that/', 'this is like that' );
-
-Regex options may be placed on the end (C<'/that/i'>).
-
-Its advantages over ok() are similar to that of is() and isnt(). Better
-diagnostics on failure.
-
-=cut
-
-sub like ($$;$) {
- $Test->like(@_);
-}
-
-
-=item B<unlike>
-
- unlike( $this, qr/that/, $test_name );
-
-Works exactly as like(), only it checks if $this B<does not> match the
-given pattern.
-
-=cut
-
-sub unlike {
- $Test->unlike(@_);
-}
-
-
-=item B<cmp_ok>
-
- cmp_ok( $this, $op, $that, $test_name );
-
-Halfway between ok() and is() lies cmp_ok(). This allows you to
-compare two arguments using any binary perl operator.
-
- # ok( $this eq $that );
- cmp_ok( $this, 'eq', $that, 'this eq that' );
-
- # ok( $this == $that );
- cmp_ok( $this, '==', $that, 'this == that' );
-
- # ok( $this && $that );
- cmp_ok( $this, '&&', $that, 'this || that' );
- ...etc...
-
-Its advantage over ok() is when the test fails you'll know what $this
-and $that were:
-
- not ok 1
- # Failed test (foo.t at line 12)
- # '23'
- # &&
- # undef
-
-It's also useful in those cases where you are comparing numbers and
-is()'s use of C<eq> will interfere:
-
- cmp_ok( $big_hairy_number, '==', $another_big_hairy_number );
-
-=cut
-
-sub cmp_ok($$$;$) {
- $Test->cmp_ok(@_);
-}
-
-
-=item B<can_ok>
-
- can_ok($module, @methods);
- can_ok($object, @methods);
-
-Checks to make sure the $module or $object can do these @methods
-(works with functions, too).
-
- can_ok('Foo', qw(this that whatever));
-
-is almost exactly like saying:
-
- ok( Foo->can('this') &&
- Foo->can('that') &&
- Foo->can('whatever')
- );
-
-only without all the typing and with a better interface. Handy for
-quickly testing an interface.
-
-No matter how many @methods you check, a single can_ok() call counts
-as one test. If you desire otherwise, use:
-
- foreach my $meth (@methods) {
- can_ok('Foo', $meth);
- }
-
-=cut
-
-sub can_ok ($@) {
- my($proto, @methods) = @_;
- my $class = ref $proto || $proto;
-
- unless( @methods ) {
- my $ok = $Test->ok( 0, "$class->can(...)" );
- $Test->diag(' can_ok() called with no methods');
- return $ok;
- }
-
- my @nok = ();
- foreach my $method (@methods) {
- local($!, $@); # don't interfere with caller's $@
- # eval sometimes resets $!
- eval { $proto->can($method) } || push @nok, $method;
- }
-
- my $name;
- $name = @methods == 1 ? "$class->can('$methods[0]')"
- : "$class->can(...)";
-
- my $ok = $Test->ok( !@nok, $name );
-
- $Test->diag(map " $class->can('$_') failed\n", @nok);
-
- return $ok;
-}
-
-=item B<isa_ok>
-
- isa_ok($object, $class, $object_name);
- isa_ok($ref, $type, $ref_name);
-
-Checks to see if the given $object->isa($class). Also checks to make
-sure the object was defined in the first place. Handy for this sort
-of thing:
-
- my $obj = Some::Module->new;
- isa_ok( $obj, 'Some::Module' );
-
-where you'd otherwise have to write
-
- my $obj = Some::Module->new;
- ok( defined $obj && $obj->isa('Some::Module') );
-
-to safeguard against your test script blowing up.
-
-It works on references, too:
-
- isa_ok( $array_ref, 'ARRAY' );
-
-The diagnostics of this test normally just refer to 'the object'. If
-you'd like them to be more specific, you can supply an $object_name
-(for example 'Test customer').
-
-=cut
-
-sub isa_ok ($$;$) {
- my($object, $class, $obj_name) = @_;
-
- my $diag;
- $obj_name = 'The object' unless defined $obj_name;
- my $name = "$obj_name isa $class";
- if( !defined $object ) {
- $diag = "$obj_name isn't defined";
- }
- elsif( !ref $object ) {
- $diag = "$obj_name isn't a reference";
- }
- else {
- # We can't use UNIVERSAL::isa because we want to honor isa() overrides
- local($@, $!); # eval sometimes resets $!
- my $rslt = eval { $object->isa($class) };
- if( $@ ) {
- if( $@ =~ /^Can't call method "isa" on unblessed reference/ ) {
- if( !UNIVERSAL::isa($object, $class) ) {
- my $ref = ref $object;
- $diag = "$obj_name isn't a '$class' it's a '$ref'";
- }
- } else {
- die <<WHOA;
-WHOA! I tried to call ->isa on your object and got some weird error.
-This should never happen. Please contact the author immediately.
-Here's the error.
-$@
-WHOA
- }
- }
- elsif( !$rslt ) {
- my $ref = ref $object;
- $diag = "$obj_name isn't a '$class' it's a '$ref'";
- }
- }
-
-
-
- my $ok;
- if( $diag ) {
- $ok = $Test->ok( 0, $name );
- $Test->diag(" $diag\n");
- }
- else {
- $ok = $Test->ok( 1, $name );
- }
-
- return $ok;
-}
-
-
-=item B<pass>
-
-=item B<fail>
-
- pass($test_name);
- fail($test_name);
-
-Sometimes you just want to say that the tests have passed. Usually
-the case is you've got some complicated condition that is difficult to
-wedge into an ok(). In this case, you can simply use pass() (to
-declare the test ok) or fail (for not ok). They are synonyms for
-ok(1) and ok(0).
-
-Use these very, very, very sparingly.
-
-=cut
-
-sub pass (;$) {
- $Test->ok(1, @_);
-}
-
-sub fail (;$) {
- $Test->ok(0, @_);
-}
-
-=back
-
-=head2 Diagnostics
-
-If you pick the right test function, you'll usually get a good idea of
-what went wrong when it failed. But sometimes it doesn't work out
-that way. So here we have ways for you to write your own diagnostic
-messages which are safer than just C<print STDERR>.
-
-=over 4
-
-=item B<diag>
-
- diag(@diagnostic_message);
-
-Prints a diagnostic message which is guaranteed not to interfere with
-test output. Handy for this sort of thing:
-
- ok( grep(/foo/, @users), "There's a foo user" ) or
- diag("Since there's no foo, check that /etc/bar is set up right");
-
-which would produce:
-
- not ok 42 - There's a foo user
- # Failed test (foo.t at line 52)
- # Since there's no foo, check that /etc/bar is set up right.
-
-You might remember C<ok() or diag()> with the mnemonic C<open() or
-die()>.
-
-B<NOTE> The exact formatting of the diagnostic output is still
-changing, but it is guaranteed that whatever you throw at it it won't
-interfere with the test.
-
-=cut
-
-sub diag {
- $Test->diag(@_);
-}
-
-
-=back
-
-=head2 Module tests
-
-You usually want to test if the module you're testing loads ok, rather
-than just vomiting if its load fails. For such purposes we have
-C<use_ok> and C<require_ok>.
-
-=over 4
-
-=item B<use_ok>
-
- BEGIN { use_ok($module); }
- BEGIN { use_ok($module, @imports); }
-
-These simply use the given $module and test to make sure the load
-happened ok. It's recommended that you run use_ok() inside a BEGIN
-block so its functions are exported at compile-time and prototypes are
-properly honored.
-
-If @imports are given, they are passed through to the use. So this:
-
- BEGIN { use_ok('Some::Module', qw(foo bar)) }
-
-is like doing this:
-
- use Some::Module qw(foo bar);
-
-don't try to do this:
-
- BEGIN {
- use_ok('Some::Module');
-
- ...some code that depends on the use...
- ...happening at compile time...
- }
-
-instead, you want:
-
- BEGIN { use_ok('Some::Module') }
- BEGIN { ...some code that depends on the use... }
-
-
-=cut
-
-sub use_ok ($;@) {
- my($module, @imports) = @_;
- @imports = () unless @imports;
-
- my $pack = caller;
-
- local($@,$!); # eval sometimes interferes with $!
- eval <<USE;
-package $pack;
-require $module;
-'$module'->import(\@imports);
-USE
-
- my $ok = $Test->ok( !$@, "use $module;" );
-
- unless( $ok ) {
- chomp $@;
- $Test->diag(<<DIAGNOSTIC);
- Tried to use '$module'.
- Error: $@
-DIAGNOSTIC
-
- }
-
- return $ok;
-}
-
-=item B<require_ok>
-
- require_ok($module);
-
-Like use_ok(), except it requires the $module.
-
-=cut
-
-sub require_ok ($) {
- my($module) = shift;
-
- my $pack = caller;
-
- local($!, $@); # eval sometimes interferes with $!
- eval <<REQUIRE;
-package $pack;
-require $module;
-REQUIRE
-
- my $ok = $Test->ok( !$@, "require $module;" );
-
- unless( $ok ) {
- chomp $@;
- $Test->diag(<<DIAGNOSTIC);
- Tried to require '$module'.
- Error: $@
-DIAGNOSTIC
-
- }
-
- return $ok;
-}
-
-=back
-
-=head2 Conditional tests
-
-Sometimes running a test under certain conditions will cause the
-test script to die. A certain function or method isn't implemented
-(such as fork() on MacOS), some resource isn't available (like a
-net connection) or a module isn't available. In these cases it's
-necessary to skip tests, or declare that they are supposed to fail
-but will work in the future (a todo test).
-
-For more details on the mechanics of skip and todo tests see
-L<Test::Harness>.
-
-The way Test::More handles this is with a named block. Basically, a
-block of tests which can be skipped over or made todo. It's best if I
-just show you...
-
-=over 4
-
-=item B<SKIP: BLOCK>
-
- SKIP: {
- skip $why, $how_many if $condition;
-
- ...normal testing code goes here...
- }
-
-This declares a block of tests that might be skipped, $how_many tests
-there are, $why and under what $condition to skip them. An example is
-the easiest way to illustrate:
-
- SKIP: {
- eval { require HTML::Lint };
-
- skip "HTML::Lint not installed", 2 if $@;
-
- my $lint = new HTML::Lint;
- isa_ok( $lint, "HTML::Lint" );
-
- $lint->parse( $html );
- is( $lint->errors, 0, "No errors found in HTML" );
- }
-
-If the user does not have HTML::Lint installed, the whole block of
-code I<won't be run at all>. Test::More will output special ok's
-which Test::Harness interprets as skipped, but passing, tests.
-It's important that $how_many accurately reflects the number of tests
-in the SKIP block so the # of tests run will match up with your plan.
-
-It's perfectly safe to nest SKIP blocks. Each SKIP block must have
-the label C<SKIP>, or Test::More can't work its magic.
-
-You don't skip tests which are failing because there's a bug in your
-program, or for which you don't yet have code written. For that you
-use TODO. Read on.
-
-=cut
-
-#'#
-sub skip {
- my($why, $how_many) = @_;
-
- unless( defined $how_many ) {
- # $how_many can only be avoided when no_plan is in use.
- _carp "skip() needs to know \$how_many tests are in the block"
- unless $Test::Builder::No_Plan;
- $how_many = 1;
- }
-
- for( 1..$how_many ) {
- $Test->skip($why);
- }
-
- local $^W = 0;
- last SKIP;
-}
-
-
-=item B<TODO: BLOCK>
-
- TODO: {
- local $TODO = $why if $condition;
-
- ...normal testing code goes here...
- }
-
-Declares a block of tests you expect to fail and $why. Perhaps it's
-because you haven't fixed a bug or haven't finished a new feature:
-
- TODO: {
- local $TODO = "URI::Geller not finished";
-
- my $card = "Eight of clubs";
- is( URI::Geller->your_card, $card, 'Is THIS your card?' );
-
- my $spoon;
- URI::Geller->bend_spoon;
- is( $spoon, 'bent', "Spoon bending, that's original" );
- }
-
-With a todo block, the tests inside are expected to fail. Test::More
-will run the tests normally, but print out special flags indicating
-they are "todo". Test::Harness will interpret failures as being ok.
-Should anything succeed, it will report it as an unexpected success.
-You then know the thing you had todo is done and can remove the
-TODO flag.
-
-The nice part about todo tests, as opposed to simply commenting out a
-block of tests, is it's like having a programmatic todo list. You know
-how much work is left to be done, you're aware of what bugs there are,
-and you'll know immediately when they're fixed.
-
-Once a todo test starts succeeding, simply move it outside the block.
-When the block is empty, delete it.
-
-
-=item B<todo_skip>
-
- TODO: {
- todo_skip $why, $how_many if $condition;
-
- ...normal testing code...
- }
-
-With todo tests, it's best to have the tests actually run. That way
-you'll know when they start passing. Sometimes this isn't possible.
-Often a failing test will cause the whole program to die or hang, even
-inside an C<eval BLOCK> with and using C<alarm>. In these extreme
-cases you have no choice but to skip over the broken tests entirely.
-
-The syntax and behavior is similar to a C<SKIP: BLOCK> except the
-tests will be marked as failing but todo. Test::Harness will
-interpret them as passing.
-
-=cut
-
-sub todo_skip {
- my($why, $how_many) = @_;
-
- unless( defined $how_many ) {
- # $how_many can only be avoided when no_plan is in use.
- _carp "todo_skip() needs to know \$how_many tests are in the block"
- unless $Test::Builder::No_Plan;
- $how_many = 1;
- }
-
- for( 1..$how_many ) {
- $Test->todo_skip($why);
- }
-
- local $^W = 0;
- last TODO;
-}
-
-=item When do I use SKIP vs. TODO?
-
-B<If it's something the user might not be able to do>, use SKIP.
-This includes optional modules that aren't installed, running under
-an OS that doesn't have some feature (like fork() or symlinks), or maybe
-you need an Internet connection and one isn't available.
-
-B<If it's something the programmer hasn't done yet>, use TODO. This
-is for any code you haven't written yet, or bugs you have yet to fix,
-but want to put tests in your testing script (always a good idea).
-
-
-=back
-
-=head2 Comparison functions
-
-Not everything is a simple eq check or regex. There are times you
-need to see if two arrays are equivalent, for instance. For these
-instances, Test::More provides a handful of useful functions.
-
-B<NOTE> These are NOT well-tested on circular references. Nor am I
-quite sure what will happen with filehandles.
-
-=over 4
-
-=item B<is_deeply>
-
- is_deeply( $this, $that, $test_name );
-
-Similar to is(), except that if $this and $that are hash or array
-references, it does a deep comparison walking each data structure to
-see if they are equivalent. If the two structures are different, it
-will display the place where they start differing.
-
-Barrie Slaymaker's Test::Differences module provides more in-depth
-functionality along these lines, and it plays well with Test::More.
-
-B<NOTE> Display of scalar refs is not quite 100%
-
-=cut
-
-use vars qw(@Data_Stack);
-my $DNE = bless [], 'Does::Not::Exist';
-sub is_deeply {
- my($this, $that, $name) = @_;
-
- my $ok;
- if( !ref $this || !ref $that ) {
- $ok = $Test->is_eq($this, $that, $name);
- }
- else {
- local @Data_Stack = ();
- if( _deep_check($this, $that) ) {
- $ok = $Test->ok(1, $name);
- }
- else {
- $ok = $Test->ok(0, $name);
- $ok = $Test->diag(_format_stack(@Data_Stack));
- }
- }
-
- return $ok;
-}
-
-sub _format_stack {
- my(@Stack) = @_;
-
- my $var = '$FOO';
- my $did_arrow = 0;
- foreach my $entry (@Stack) {
- my $type = $entry->{type} || '';
- my $idx = $entry->{'idx'};
- if( $type eq 'HASH' ) {
- $var .= "->" unless $did_arrow++;
- $var .= "{$idx}";
- }
- elsif( $type eq 'ARRAY' ) {
- $var .= "->" unless $did_arrow++;
- $var .= "[$idx]";
- }
- elsif( $type eq 'REF' ) {
- $var = "\${$var}";
- }
- }
-
- my @vals = @{$Stack[-1]{vals}}[0,1];
- my @vars = ();
- ($vars[0] = $var) =~ s/\$FOO/ \$got/;
- ($vars[1] = $var) =~ s/\$FOO/\$expected/;
-
- my $out = "Structures begin differing at:\n";
- foreach my $idx (0..$#vals) {
- my $val = $vals[$idx];
- $vals[$idx] = !defined $val ? 'undef' :
- $val eq $DNE ? "Does not exist"
- : "'$val'";
- }
-
- $out .= "$vars[0] = $vals[0]\n";
- $out .= "$vars[1] = $vals[1]\n";
-
- $out =~ s/^/ /msg;
- return $out;
-}
-
-
-=item B<eq_array>
-
- eq_array(\@this, \@that);
-
-Checks if two arrays are equivalent. This is a deep check, so
-multi-level structures are handled correctly.
-
-=cut
-
-#'#
-sub eq_array {
- my($a1, $a2) = @_;
- return 1 if $a1 eq $a2;
-
- my $ok = 1;
- my $max = $#$a1 > $#$a2 ? $#$a1 : $#$a2;
- for (0..$max) {
- my $e1 = $_ > $#$a1 ? $DNE : $a1->[$_];
- my $e2 = $_ > $#$a2 ? $DNE : $a2->[$_];
-
- push @Data_Stack, { type => 'ARRAY', idx => $_, vals => [$e1, $e2] };
- $ok = _deep_check($e1,$e2);
- pop @Data_Stack if $ok;
-
- last unless $ok;
- }
- return $ok;
-}
-
-sub _deep_check {
- my($e1, $e2) = @_;
- my $ok = 0;
-
-# my $eq;
- {
- # Quiet uninitialized value warnings when comparing undefs.
- local $^W = 0;
-
- if( $e1 eq $e2 ) {
- $ok = 1;
- }
- else {
- if( UNIVERSAL::isa($e1, 'ARRAY') and
- UNIVERSAL::isa($e2, 'ARRAY') )
- {
- $ok = eq_array($e1, $e2);
- }
- elsif( UNIVERSAL::isa($e1, 'HASH') and
- UNIVERSAL::isa($e2, 'HASH') )
- {
- $ok = eq_hash($e1, $e2);
- }
- elsif( UNIVERSAL::isa($e1, 'REF') and
- UNIVERSAL::isa($e2, 'REF') )
- {
- push @Data_Stack, { type => 'REF', vals => [$e1, $e2] };
- $ok = _deep_check($$e1, $$e2);
- pop @Data_Stack if $ok;
- }
- elsif( UNIVERSAL::isa($e1, 'SCALAR') and
- UNIVERSAL::isa($e2, 'SCALAR') )
- {
- push @Data_Stack, { type => 'REF', vals => [$e1, $e2] };
- $ok = _deep_check($$e1, $$e2);
- }
- else {
- push @Data_Stack, { vals => [$e1, $e2] };
- $ok = 0;
- }
- }
- }
-
- return $ok;
-}
-
-
-=item B<eq_hash>
-
- eq_hash(\%this, \%that);
-
-Determines if the two hashes contain the same keys and values. This
-is a deep check.
-
-=cut
-
-sub eq_hash {
- my($a1, $a2) = @_;
- return 1 if $a1 eq $a2;
-
- my $ok = 1;
- my $bigger = keys %$a1 > keys %$a2 ? $a1 : $a2;
- foreach my $k (keys %$bigger) {
- my $e1 = exists $a1->{$k} ? $a1->{$k} : $DNE;
- my $e2 = exists $a2->{$k} ? $a2->{$k} : $DNE;
-
- push @Data_Stack, { type => 'HASH', idx => $k, vals => [$e1, $e2] };
- $ok = _deep_check($e1, $e2);
- pop @Data_Stack if $ok;
-
- last unless $ok;
- }
-
- return $ok;
-}
-
-=item B<eq_set>
-
- eq_set(\@this, \@that);
-
-Similar to eq_array(), except the order of the elements is B<not>
-important. This is a deep check, but the irrelevancy of order only
-applies to the top level.
-
-B<NOTE> By historical accident, this is not a true set comparision.
-While the order of elements does not matter, duplicate elements do.
-
-=cut
-
-# We must make sure that references are treated neutrally. It really
-# doesn't matter how we sort them, as long as both arrays are sorted
-# with the same algorithm.
-sub _bogus_sort { local $^W = 0; ref $a ? 0 : $a cmp $b }
-
-sub eq_set {
- my($a1, $a2) = @_;
- return 0 unless @$a1 == @$a2;
-
- # There's faster ways to do this, but this is easiest.
- return eq_array( [sort _bogus_sort @$a1], [sort _bogus_sort @$a2] );
-}
-
-=back
-
-
-=head2 Extending and Embedding Test::More
-
-Sometimes the Test::More interface isn't quite enough. Fortunately,
-Test::More is built on top of Test::Builder which provides a single,
-unified backend for any test library to use. This means two test
-libraries which both use Test::Builder B<can be used together in the
-same program>.
-
-If you simply want to do a little tweaking of how the tests behave,
-you can access the underlying Test::Builder object like so:
-
-=over 4
-
-=item B<builder>
-
- my $test_builder = Test::More->builder;
-
-Returns the Test::Builder object underlying Test::More for you to play
-with.
-
-=cut
-
-sub builder {
- return Test::Builder->new;
-}
-
-=back
-
-
-=head1 NOTES
-
-Test::More is B<explicitly> tested all the way back to perl 5.004.
-
-Test::More is thread-safe for perl 5.8.0 and up.
-
-=head1 BUGS and CAVEATS
-
-=over 4
-
-=item Making your own ok()
-
-If you are trying to extend Test::More, don't. Use Test::Builder
-instead.
-
-=item The eq_* family has some caveats.
-
-=item Test::Harness upgrades
-
-no_plan and todo depend on new Test::Harness features and fixes. If
-you're going to distribute tests that use no_plan or todo your
-end-users will have to upgrade Test::Harness to the latest one on
-CPAN. If you avoid no_plan and TODO tests, the stock Test::Harness
-will work fine.
-
-If you simply depend on Test::More, it's own dependencies will cause a
-Test::Harness upgrade.
-
-=back
-
-
-=head1 HISTORY
-
-This is a case of convergent evolution with Joshua Pritikin's Test
-module. I was largely unaware of its existence when I'd first
-written my own ok() routines. This module exists because I can't
-figure out how to easily wedge test names into Test's interface (along
-with a few other problems).
-
-The goal here is to have a testing utility that's simple to learn,
-quick to use and difficult to trip yourself up with while still
-providing more flexibility than the existing Test.pm. As such, the
-names of the most common routines are kept tiny, special cases and
-magic side-effects are kept to a minimum. WYSIWYG.
-
-
-=head1 SEE ALSO
-
-L<Test::Simple> if all this confuses you and you just want to write
-some tests. You can upgrade to Test::More later (it's forward
-compatible).
-
-L<Test::Differences> for more ways to test complex data structures.
-And it plays well with Test::More.
-
-L<Test> is the old testing module. Its main benefit is that it has
-been distributed with Perl since 5.004_05.
-
-L<Test::Harness> for details on how your test results are interpreted
-by Perl.
-
-L<Test::Unit> describes a very featureful unit testing interface.
-
-L<Test::Inline> shows the idea of embedded testing.
-
-L<SelfTest> is another approach to embedded testing.
-
-
-=head1 AUTHORS
-
-Michael G Schwern E<lt>schwern@pobox.comE<gt> with much inspiration
-from Joshua Pritikin's Test module and lots of help from Barrie
-Slaymaker, Tony Bowden, chromatic and the perl-qa gang.
-
-
-=head1 COPYRIGHT
-
-Copyright 2001 by Michael G Schwern E<lt>schwern@pobox.comE<gt>.
-
-This program is free software; you can redistribute it and/or
-modify it under the same terms as Perl itself.
-
-See F<http://www.perl.com/perl/misc/Artistic.html>
-
-=cut
-
-1;
diff --git a/Perl/t/TestLog.pm b/Perl/t/TestLog.pm
deleted file mode 100644
index 6c84604..0000000
--- a/Perl/t/TestLog.pm
+++ /dev/null
@@ -1,306 +0,0 @@
-package TestLog;
-
-# $Id$
-# These test facilities has been developped by C. Mertz <mertz@cena.fr>
-
-use IO::Handle; # for autoflushing the logs
-use Carp;
-
-use Exporter;
-@ISA = qw(Exporter);
-
-use vars qw( $VERSION @ISA);
-($VERSION) = sprintf("%d.%02d", q$Revision$ =~ /(\d+)\.(\d+)/);
-@EXPORT = qw( openLog setZincLog log test_eval test_no_eval printableItem printableArray printableList
- equal_flat_arrays nequal_cplx_arrays);
-use strict;
-
-use constant ERROR => '--an error--';
-
-my $selected_loglevel;
-
-sub openLog {
- my ($outfile, $loglevel, $no_logfile) = @_;
-
- $selected_loglevel = $loglevel;
- if (defined $no_logfile && $no_logfile) {
- open LOG, "> /dev/null";
- }
- else {
- if ( open LOG, "$outfile.prev" ) {
- close LOG;
- unlink "$outfile.prev";
- }
- if ( open LOG, $outfile ) {
- close LOG;
- link $outfile, "$outfile.prev";
- unlink "$outfile";
- }
-
- open LOG,"> $outfile";
- autoflush LOG 1; # autoflush is important so that logs are up-to-date if Zinc crashes!
- }
-}
-
-
-
-### print log information to the logfile
-### if $level is <= than selected_loglevel (def = 0) then print log on the stdout
-### - a loglevel of -100 means an error to be logged with #### prefix
-### - a loglevel of -10 means an error in the test to be logged with ## prefix
-### - a loglevel of 0 means an message to be usually printed (and logged in any case)
-### - a loglevel greater than 1 is for trace only
-
-
-sub log {
- my ($loglevel, @strgs) = @_;
- if ($loglevel <= $selected_loglevel) {
- print "#### " if $loglevel == -100;
- print "## " if $loglevel == -10;
- print @strgs;
- }
- print LOG "#### " if $loglevel == -100;
- print LOG "## " if $loglevel == -10;
- print LOG @strgs;
-} # end log
-
-my $zinc;
-## to init the $zinc
-sub setZincLog {
- ($zinc)=@_;
-}
-
-
-my %method_with_tagOrId =
- ("anchorxy" => 1, "bbox" => 1, "bind" => 1, "chggroup" => 1,
- "clone" => 1, "contour" => 1, "coords"=> 1, "cursor" => 1,
- "dchars" => 1, "dtag" => 1, "focus" => 1, "gettags" => 1,
- "group" => 1, # blabla... to complete
- "itemcget" => 1, "itemconfigure" => 1, # blabla... to complete
- "remove" => 1,
- );
-
-### evaluate $zinc->$method(@args); and verifies that NO ERROR occurs
-### - a loglevel of -100 means an error to be logged with #### prefix
-### - a loglevel of -10 means an error in the test, to be logged with ##
-### - a loglevel of of 0 or greater is for trace only (usefull when an error occurs)
-sub test_eval {
- my ($loglevel, $method, @args) = @_;
-
- my @strs;
- my $start_index = 0;
- my $string2log = "\$zinc->$method (";
- if (scalar @args) {
- if ($method_with_tagOrId{$method} and $args[0] =~ /^\d+$/) {
- my $type = $zinc->type($args[0]);
- $string2log .= &printableItem($args[0]) . " (a". ucfirst($type) . ")";
- } else {
- $string2log .= &printableItem($args[0]) ;
- }
- $string2log .= ", " if $#args > 0 ;
- my $rest = &printableList(@args[1..$#args]);
- $rest =~ s/^\(//; ### suppressing the first ( char
- $string2log .= $rest;
- } else {
- $string2log .= ")";
- }
- if ($method eq 'itemcget' or $method eq 'get') {
- $string2log .= "; # := " ;
- } else {
- $string2log .= ";\n";
- }
- &log ($loglevel, $string2log);
-
- my (@res, $res);
- if (wantarray()) {
- @res = eval { $zinc->$method (@args) } ;
- if ($method eq 'itemcget' or $method eq 'get') {
- &log ($loglevel, printableList(@res) . "\n" );
- }
- } else {
- $res = eval { $zinc->$method (@args) } ;
- if ($method eq 'itemcget' or $method eq 'get') {
- &log ($loglevel, &printableItem($res) . "\n");
- }
- }
-
- if ($@) { # in case of error, logging!
- &log (-100, "Error while evaluating: $string2log;");
- &log (-100, $@);
- my $msgl = &Carp::longmess;
- my ($msg2) = $msgl =~ /.*?( at .*)/s ;
- &log (-100, "\t$msg2");
- return (ERROR);
- } else {
- if (wantarray()) {
- return @res;
- }
- else {
- return $res;
- }
- }
-} # end of test_eval
-
-### evaluate $zinc->$method(@args); and verifies that AN ERROR occurs
-### - a loglevel of -100 means an NO error to be loggued with #### prefix
-### - a loglevel of -10 means NO error in the test to be loggued with ## prefix
-### - a loglevel of of 0 or greater is for trace only if NO error occured
-sub test_no_eval {
- my ($reason, $loglevel, $method, @args) = @_;
-
- my @strs;
- my $start_index = 0;
- my $string2log = "\$zinc->$method (";
- if (scalar @args) {
- if ($method_with_tagOrId{$method} and $args[0] =~ /^\d+$/) {
- my $type = $zinc->type($args[0]);
- $string2log .= &printableItem($args[0]) . " (a". ucfirst($type) . ")";
- } else {
- $string2log .= &printableItem($args[0]) ;
- }
- $string2log .= ", " if $#args > 0 ;
- my $rest = &printableList(@args[1..$#args]);
- $rest =~ s/^\(//; ### suppressing the first ( char
- $string2log .= $rest;
- } else {
- $string2log .= ")";
- }
-
- eval { $zinc->$method (@args) } ;
-
- # in case of NO error, logging!
- if ($@) {
-# print "errormsg=$@";
- my ($error_msg) = $@ =~ /(.*)\s*at \/usr\//;
- $error_msg = $@ if !defined $error_msg ;
- &log ($loglevel, " # When $reason : $string2log;\n # the error msg is: $error_msg\n");
- } else {
- &log (-100, "An error SHOULD have occured while evaluating:\n####\t$string2log;\n####\tbecause $reason\n");
- }
-} # end of test_no_eval
-
-
-### return a printable string of something in a readable form
-sub printableItem {
- my ($value) = @_;
- my $ref = ref($value);
- if ($ref eq 'ARRAY') {
- return printableArray ( @{$value} );
- }
- elsif ($ref eq 'Tk::Photo') {
- return 'Tk::Photo("'. $value->cget(-file) . '")';
- }
- elsif ($ref eq '') { # scalar
- if (defined $value) {
- if ($value eq '') {
- return "''";
- } elsif ($value =~ /^-[a-zA-Z_]+$/) {
- ## for the -attribut
- return $value;
- } elsif ($value =~ /\s/
- or $value =~ /[a-zA-Z]/
- or $value =~ /^[\W]$/ ) {
- return "'$value'";
- } else {
- return $value;
- }
- }
- else {
- return "undef";
- }
- }
- else { # some class instance
- return $value;
- }
-} # end printableItem
-
-### to print an array of something
-sub printableArray {
- my (@values) = @_;
- if (! scalar @values) {
- return "[]";
- }
- else { # the array is not empty
- my $res = "[ ";
- while (@values) {
- my $value = shift @values;
- $res .= &printableItem($value);
- next unless (@values);
- if ($value =~ /^-\w+/) {
- $res .= " => ";
- } elsif (@_) {
- $res .= ", ";
- }
-
- }
- return ($res . " ]") ;
- }
-} # end printableArray
-
-sub printableList {
- my $res = "(";
- while (@_) {
- my $v = shift @_;
- $res .= &printableItem($v);
- if (defined $v and $v =~ /^-\w+/ and @_) {
- $res .= " => ";
- } elsif (@_) {
- $res .= ", ";
- }
- }
- return $res . ")";
-} # end printableList
-
-
-## return 1 if arrays of scalars have the same length and every items are eq
-sub equal_flat_arrays {
- my ($refArray1, $refArray2) = @_;
- my @array1 = @{$refArray1};
- my @array2 = @{$refArray2};
-
- return 0 if ($#array1 != $#array2);
-
- for my $i (0..$#array1) {
- return 0 if ($array1[$i] ne $array2[$i]);
- }
- return 1;
-} # equal_arrays
-
-
-## return 0 if arrays of anything are equal
-## return 'length' if their length are different
-## return xx if some elements are différents
-## arrays may be arrays of arrays of arrays ...
-sub nequal_cplx_arrays {
- my ($refArray1, $refArray2) = @_;
- my @array1 = @{$refArray1};
- my @array2 = @{$refArray2};
-
-# print "array1=", &printableArray(@array1), "\narray2=",&printableArray(@array2),"\n";
- return 'length' if ($#array1 != $#array2);
-
- for my $i (0..$#array1) {
- my $el1 = $array1[$i];
- my $el2 = $array2[$i];
-
- if (ref($el1)) {
-# print "REF el1=",ref($el1),"\n";
- if (!ref($el2)) {
- return "elts at index $i are different: $el1 != $el2\n";
- } elsif (ref($el2) ne ref($el1)) {
- return "elts at index $i are of different type: ".
- ref($el2), " ne ", ref($el1), "\n";
- } elsif (ref($el2) eq 'ARRAY') {
- if (my $res = &nequal_cplx_arrays ($el1,$el2)) {
- return "elts at index $i are different: $res";
- }
- }
- } elsif (ref($el2) or $el1 ne $el2) {
- return "elts at index $i are different $el1 != $el2\n";
- }
- }
- return 0;
-} # nequal_cplx_arrays
-
-
-1;
diff --git a/Perl/t/Text.t b/Perl/t/Text.t
deleted file mode 100644
index bd43a4b..0000000
--- a/Perl/t/Text.t
+++ /dev/null
@@ -1,58 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: Text.t,v 1.2 2004-04-02 12:01:49 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing all the import
-
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 5;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc;
- 1;
- }) {
- print "unable to load Tk::Zinc";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- MainWindow->new();
- 1;
- }) {
- print "# tests only work properly when it is possible to create a mainwindow in your env\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-
-$mw = MainWindow->new();
-$zinc = $mw->Zinc(-width => 100, -height => 100);
-
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc has been created");
-
-# following a mail in zinc@tls.cena.fr (23 sept 2003) by A. Lemort
-# we verify that the -width attribute of text items is converted as an integer
-my $text = $zinc->add('text', 1, -position => [10,10], -text => "text");
-
-&ok ($zinc->itemconfigure($text, -width => 10.1) or 1, "setting width to 10.1");
-&is ($zinc->itemcget($text, -width), 10, "width attribute was converted to an integer");
-&ok ($zinc->itemconfigure($text, -width => 9.9) or 1, "setting width to 10.9");
-&is ($zinc->itemcget($text, -width), 9, "width attribute was converted to lower integer");
-
-
-
-diag("############## text items test");
diff --git a/Perl/t/Transformations.t b/Perl/t/Transformations.t
deleted file mode 100644
index e736837..0000000
--- a/Perl/t/Transformations.t
+++ /dev/null
@@ -1,304 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: Transformations.t,v 1.3 2004-04-02 12:03:34 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing all the import
-
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 21;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc;
- 1;
- }) {
- print "unable to load Tk::Zinc";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- MainWindow->new();
- 1;
- }) {
- print "# tests only work properly when it is possible to create a mainwindow in your env\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-
-$mw = MainWindow->new();
-$zinc = $mw->Zinc(-width => 100, -height => 100);
-my $coords = [ [10,10], [40, 40] ];
-
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc has been created");
-
-my $g = $zinc->add('group',1);
-$zinc->scale($g,2,2);
-my $rect1 = $zinc->add('rectangle', $g, [10,10,40,40]);
-
-# todo : add a test for the to-come method to get a transform!
-
-is_deeply([ $zinc->coords($rect1) ],
- [ [10,10], [40, 40] ],
- "coords are not modified by the group transform!");
-
-is_deeply([
- $zinc->transform(1, $g, [100, 100, 300, 500] )
- ],
- [ 50, 50, 150, 250 ],
- "transform from window coordinates to group");
-
-is_deeply([
- $zinc->transform($g, 1, [$zinc->coords($rect1)] )
- ],
- [ [20,20], [80, 80] ],
- "transform to window coordinates");
-
-
-# question suggested by D. Etienne (30 sept 2003):
-# is it possible to get the window coordinate of a transformed item?
-# the answer is of course yes and it is verified here.
-my $rect2 = $zinc->add('rectangle', 1, [10,10,40,40]);
-
-# applying a transform to the rectangle:
-$zinc->scale($rect2, 2,2);
-
-# todo : add a test for the to-come method to get a transform!
-
-is_deeply([ $zinc->coords($rect1) ],
- [ [10,10], [40, 40] ],
- "coords are not modified by the item transform!");
-
-is_deeply([
- $zinc->transform(1, $rect2, [100, 100, 300, 500] )
- ],
- [ 50, 50, 150, 250 ],
- "transform window coordinates with same transform than rect2 ");
-is_deeply([
- $zinc->transform($rect2, 1, [$zinc->coords($rect2)] )
- ],
- [ [20,20], [80, 80] ],
- "transform rect2 coordinates to window coordinates, with group 1");
-
-is_deeply([
- $zinc->transform($rect2, 'device', [$zinc->coords($rect2)] )
- ],
- [ [20,20], [80, 80] ],
- "transform rect2 coordinates to window coordinates with 'device'");
-
-$zinc->scale(1, 0.5, 0.5);
-
-is_deeply([
- $zinc->transform($rect2, 'device', [$zinc->coords($rect2)] )
- ],
- [ [10,10], [40, 40] ],
- "transform rect2 coordinates to window coordinates with 'device'");
-
-# setting the top group transformation to the id, with a translation with tset
-$zinc->tset(1, 1,0, 0,1, -20,-10);
-is_deeply([
- $zinc->transform($rect2, 'device', [$zinc->coords($rect2)] )
- ],
- [ [0,10], [60, 70] ],
- "rect2 window coordinates with 'device' after topgroup transfo setting");
-
-# restting top group transformation
-$zinc->treset(1);
-is_deeply([
- $zinc->transform($rect2, 'device', [$zinc->coords($rect2)] )
- ],
- [ [20,20], [80, 80] ],
- "rect2 window coordinates with 'device' after topgroup treset");
-
-# resetting the rect2 trasnformation
-$zinc->treset($rect2);
-is_deeply([
- $zinc->transform($rect2, 'device', [$zinc->coords($rect2)] )
- ],
- [ [10,10], [40, 40] ],
- "rect2 window coordinates with 'device' after rect2 treset");
-
-$zinc->treset($rect2);
-$zinc->skew($rect2, 10,00);
-$zinc->skew($rect2, -10,00);
-ok(&similarPoints ([
- $zinc->transform($rect2, 'device', [$zinc->coords($rect2)] )
- ],
- [ [10, 10], [40, 40] ]),
- "rect2 window coordinates with 'device' after rect2 skew (back and forth)");
-
-
-$zinc->treset($rect2);
-$zinc->skew($rect2, -10,00);
-$zinc->skew($rect2, 10,00);
-ok(&similarPoints ([
- $zinc->transform($rect2, 'device', [$zinc->coords($rect2)] )
- ],
- [ [10, 10], [40, 40] ]),
- "rect2 window coordinates with 'device' after rect2 skew (forth and back)");
-
-
-$zinc->treset($rect2);
-$zinc->translate($rect2, 34,43);
-$zinc->translate($rect2, 15,15, 'absolute'); # the previous relative translation will be overridden
-is_deeply([
- $zinc->transform($rect2, 'device', [$zinc->coords($rect2)] )
- ],
- [ [25,25], [55, 55] ],
- "rect2 window coordinates with 'device' after rect2 absolute translation");
-
-if (0) {
-$zinc->treset($rect2);
-print "0 ", $zinc->tget($rect2, 'rotation'), "\n";
-$zinc->rotate($rect2, 3.14159);
-print "+3.14 ", $zinc->tget($rect2, 'rotation'), "\n";
-$zinc->rotate($rect2, -3.14159, 0);
-print "0 ", $zinc->tget($rect2, 'rotation'), "\n";
-$zinc->rotate($rect2, 180, 1);
-print "180 ", $zinc->tget($rect2, 'rotation'), "\n";
-$zinc->rotate($rect2, -3.14159, 100, 200);
-print "0 ", $zinc->tget($rect2, 'rotation'), "\n";
-$zinc->rotate($rect2, -3.14159, 0, 100, 200);
-print "3.14 ", $zinc->tget($rect2, 'rotation'), "\n";
-$zinc->rotate($rect2, 180, 1, 100, 200);
-print "0 ", $zinc->tget($rect2, 'rotation'), "\n";
-$zinc->rotate($rect2, 180, 1, 100, 200, 300);
-print "3.14 ", $zinc->tget($rect2, 'rotation'), "\n";
-$zinc->rotate($rect2, 180, 1, 100, 200, 300, 600);
-print $zinc->tget($rect2, 'rotation'), "\n";
-$zinc->rotate($rect2, 180, 1, 100, 200, 300, 600, 900);
-print $zinc->tget($rect2, 'rotation'), "\n";
-}
-
-$zinc->treset($rect2);
-$zinc->translate($rect2, 40,50);
-$zinc->scale($rect2, 2,3);
-$zinc->rotate($rect2, 3.1415/2);
-
-my ($m00, $m01, $m10, $m11, $m20, $m21) = $zinc->tget($rect2);
-#print "matrix: $m00, $m01, $m10, $m11, $m20, $m21\n";
-ok(&similarFlatArray ([$zinc->tget($rect2)],
- [0, 2, -3, 0, -150, 80],
- [0.001, 0.001, 0.001, 0.001, 1, 1]),
- "tget of rect2");
-
-my ($xTranslate, $yTranslate, $xScale, $yScale, $angle, $skew) = $zinc->tget($rect2, 'all');
-#print "matrix: $xTranslate, $yTranslate, $xScale, $yScale, $angle, $skew\n";
-ok(&similarFlatArray ([$zinc->tget($rect2,'all')],
- [-150, 80, 2, 3, 3.14159/2, 0 ],
- [1, 1, 0.001, 0.001, 0.001, 0.001]),
- "tget 'all' of rect2");
-
-
-($xTranslate, $yTranslate) = $zinc->tget($rect2, 'translation');
-#print "translate: $xTranslate, $yTranslate\n";
-ok(&similarFlatArray ([$zinc->tget($rect2,'translation')],
- [-150, 80],
- [1, 1 ]),
- "tget 'translation' of rect2");
-
-($xScale, $yScale) = $zinc->tget($rect2, 'scale');
-#print "scale: $xScale, $yScale\n";
-ok(&similarFlatArray ([$zinc->tget($rect2,'scale')],
- [2, 3, ],
- [0.001, 0.001]),
- "tget 'scale' of rect2");
-
-($m00, $m01, $m10, $m11, $m20, $m21) = $zinc->tget($rect2, 'rotation');
-ok(&similarFlatArray ([$zinc->tget($rect2,'rotation')],
- [3.14159/2],
- [0.001 ]),
- "tget 'rotation' of rect2");
-
-#$zinc->skew($rect2, 10,0);
-ok(&similarFlatArray ([$zinc->tget($rect2,'skew')],
- [0],
- [0.001 ]),
- "tget 'skew' of rect2");
-
-
-sub similarPoints {
- my ($ref1, $ref2)= @_;
- diag ("waiting a reference for \$ref1" . ref ($ref1)), return 0 unless ref ($ref1) eq 'ARRAY';
- diag ("waiting a reference for \$ref2"), return 0 unless ref ($ref2) eq 'ARRAY';
-
- my @array1 = @{$ref1};
- my @array2 = @{$ref2};
-
- diag ("arrays for \$ref1 and \$ref2 are not of same length"), return 0
- unless scalar @array1 == @array2;
-
- for my $i (0.. $#array1) {
- my $pt1 = $array1[$i];
- my $pt2 = $array2[$i];
- diag ("waiting a reference to a point in elt $i \$ref1"), return 0
- unless ref $pt1 eq 'ARRAY';
- my (@pt1) = @{$pt1};
- diag ("waiting a reference to a point (x,y) in elt $i \$ref1"), return 0
- unless scalar @pt1 == 2 and &numerical($pt1[0]) and &numerical($pt1[1]) ;
-
- diag ("waiting a reference to a point in elt $i \$ref1"), return 0
- unless ref $pt2 eq 'ARRAY';
- my (@pt2) = @{$pt2};
- diag ("waiting a reference to a point (x,y) in elt $i \$ref2"), return 0
- unless scalar @pt2 == 2 and &numerical($pt2[0]) and &numerical($pt2[1]) ;
-
- diag ("delta > 0.001 between x of pt$i"), return 0 if abs($pt1[0]-$pt2[0]) > 0.001;
- diag ("delta > 0.001 between y of pt$i"), return 0 if abs($pt1[1]-$pt2[1]) > 0.001;
- }
- return 1;
-}
-
-sub similarFlatArray {
- my ($ref1, $ref2, $deltaref)= @_;
- diag ("waiting a reference for \$ref1"), return 0 unless ref ($ref1) eq 'ARRAY';
- diag ("waiting a reference for \$ref2"), return 0 unless ref ($ref2) eq 'ARRAY';
- diag ("waiting a reference for \$deltaref"), return 0 unless ref ($deltaref) eq 'ARRAY';
-
- my @array1 = @{$ref1};
- my @array2 = @{$ref2};
- my @deltaarray = @{$deltaref};
- diag ("arrays for \$ref1 and \$ref2 and \$deltaref are not of same length,".$#array1.",".$#array2.",".$#deltaarray), return 0
- unless ($#array1 == $#array2) and ($#array2 == $#deltaarray);
- for my $i (0.. $#array1) {
- my $a = $array1[$i];
- my $b = $array2[$i];
- my $delta = $deltaarray[$i];
- diag ("waiting a numeric value for elt $i of \$ref1"), return 0
- unless &numerical($a);
- diag ("waiting a numeric value for elt $i of \$ref2"), return 0
- unless &numerical($b);
- diag ("waiting a numeric value for elt $i of \$deltaref"), return 0
- unless &numerical($delta);
-
- diag ("delta > $delta between elt $i of \$ref1 ($a) and \$ref2 ($b)"), return 0
- if (abs($a-$b) > $delta) ;
- }
- return 1;
-}
-
-
-sub numerical {
- my ($v) = @_;
- return 0 unless defined $v;
- ### this really works!!
- return $v eq $v*1;
- }
-
-
-diag("############## transformations test");
-
-
diff --git a/Perl/t/find.t b/Perl/t/find.t
deleted file mode 100644
index b30be97..0000000
--- a/Perl/t/find.t
+++ /dev/null
@@ -1,200 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: find.t,v 1.4 2004-09-01 09:00:44 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing find methods
-
-# this script can be used with an optionnal argument, an integer giving
-# the delay in seconds during which the graphic updates will be displayed
-# this is usefull for visual inspection!
-
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 22;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc;
- 1;
- }) {
- print "unable to load Tk::Zinc";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- $mw = MainWindow->new();
- 1;
- }) {
- print "# tests only work properly when it is possible to create a mainwindow in your env\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-
-$zinc = $mw->Zinc(-render => 0,
- -width => 400, -height => 400)->pack;
-
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc has been created");
-
-
-### creating rectangles:
-$g1 = $zinc->add('group',1, -tags => "gr1");
-$text = $zinc->add('text', $g1, -position => [-100,-100]);
-$g2 = $zinc->add('group',$g1, -tags => "gr2");
-
-$rect11 = $zinc->add('rectangle', $g2, [ 10,10,40,40]);
-$rect12 = $zinc->add('rectangle', $g2, [ 50,10,80,40]);
-$rect13 = $zinc->add('rectangle', $g2, [ 90,10,120,40]);
-$rect21 = $zinc->add('rectangle', $g2, [ 10,50,40,80]);
-$rect22 = $zinc->add('rectangle', $g2, [ 50,50,80,80], -tags => 'middle');
-$rect23 = $zinc->add('rectangle', $g2, [ 90,50,120,80]);
-$rect31 = $zinc->add('rectangle', $g2, [ 10,90,40,120]);
-$rect32 = $zinc->add('rectangle', $g2, [ 50,90,80,120]);
-$rect33 = $zinc->add('rectangle', $g2, [ 90,90,120,120]);
-$zinc->update;
-
-my @list;
-
-@list = $zinc->find('overlapping', 20,20,110,110, $g2);
-&ok (&eq_array (\@list ,
- [ $rect33, $rect32, $rect31, $rect23, $rect22, $rect21, $rect13, $rect12, $rect11, ]),
- "find overlapping all rectangles");
-
-@list = $zinc->find('enclosed', 20,20,110,110, $g2);
-&ok (&eq_array (\@list ,
- [ $rect22 ]),
- "find enclosed the middle rectangle");
-
-@list = $zinc->find('enclosed', 0,0,110,110, $g2);
-&ok (&eq_array (\@list ,
- [ $rect22 , $rect21, $rect12, $rect11 ]),
- "find enclosed the 4 left up rectangles");
-
-@list = $zinc->find('ancestor', $rect33);
-&ok (&eq_array (\@list ,
- [ $g2 , $g1, 1 ]),
- "find ancestor of one rectangle");
-
-@list = $zinc->find('withtag', ".gr1.");
-#print "@list\n";
-&ok (&eq_array (\@list ,
- [ $g2, $text, ]),
- "find direct descendant of group tagged gr1");
-
-@list = $zinc->find('withtag', ".gr1*");
-#print "@list\n";
-&is_deeply ( [ @list ] ,
- [ $g2, ($zinc->find('withtag', ".gr1.gr2*"), $text ) ],
- "find all descendant of group tagged gr1");
-
-&is_deeply ( [ ($zinc->find('withtag', ".gr1.gr2*")) ],
- [ ($zinc->find('withtag', "*gr2*")) ],
- "comparing full pathtag and reduced pathtag to a group");
-
-&is_deeply ( [ ($zinc->find('withtag', ".gr1.gr2.middle")) ],
- [ ($zinc->find('withtag', "*gr2.middle")) ],
- "comparing full pathtag and reduced pathtag to a rectangle");
-
-&is_deeply ( [ ($zinc->find('withtag', ".gr1.gr2.middle")) ],
- [ ($zinc->find('withtag', "*middle")) ],
- "comparing full pathtag and reduced pathtag to a rectangle");
-
-&is_deeply ( [ ($zinc->find('withtag', ".gr1.gr2.middle")) ],
- [ ($zinc->find('withtag', "middle")) ],
- "comparing full pathtag and reduced pathtag to a rectangle");
-
-&is_deeply ( [ ($zinc->find('withtype', "group")) ],
- [ $g1, $g2 ],
- "find with type 'group'");
-
-&is_deeply ( [ ($zinc->find('withtype', "group", ".$g1.")) ],
- [ $g2 ],
- "find with type 'group' starting from g1");
-
-&is_deeply ( [ ($zinc->find('withtype', "group", ".$g1.")) ],
- [ ($zinc->find('withtype', "group", ".$g1*")) ],
- "find with type 'group' starting from g1");
-
-&is_deeply ( [ ($zinc->find('withtype', "rectangle")) ],
- [ $rect33, $rect32, $rect31, $rect23, $rect22, $rect21, $rect13, $rect12, $rect11, ],
- "find with type 'rectangle'");
-&is_deeply ( [ ($zinc->find('withtype', "rectangle", ".$g1*")) ],
- [ ($zinc->find('withtype', "rectangle")) ],
- "find with type 'rectangle' starting from .g1*");
-
-
-## testing overlapping find with atomic group (for testig the bug
-## reported by D. Etienne the 11th June 04
-$zinc->itemconfigure($g2, -atomic => 1);
-@list = $zinc->find('overlapping', 20,20,110,110);
-print "overlapping17 (",join (',', @list),") \$g2=$g2\n";
-&ok (&eq_array (\@list ,
- [ $g2 ]),
- "find overlapping when group becomes atomic, without specifying starting group");
-
-@list = $zinc->find('overlapping', 20,20,110,110,1);
-print "overlapping18 (",join (',', @list),") \$g2=$g2\n";
-&ok (&eq_array (\@list ,
- [ $g2 ]),
- "find overlapping when group becomes atomic, starting from group 1");
-
-@list = $zinc->find('overlapping', 20,20,110,110,1,1);
-&ok (&eq_array (\@list ,
- [ $g2 ]),
- "find overlapping when group becomes atomic, recursively, starting from group 1");
-
-
-## testing enclosing find with atomic group
-@list = $zinc->find('enclosed', 0,0,200,200);
-print "enclosing20 (",join (',', @list),") \$g2=$g2\n";
-&ok (&eq_array (\@list ,
- [ $g2 ]),
- "find enclosed when group becomes atomic, without specifying starting group");
-
-@list = $zinc->find('enclosed', 0,0,200,200, 1);
-print "enclosing21 (",join (',', @list),") \$g2=$g2\n";
-&ok (&eq_array (\@list ,
- [ $g2 ]),
- "find enclosed when group becomes atomic, starting from group 1");
-
-@list = $zinc->find('enclosed', 0,2,200,200, 1,1);
-print "enclosing22 (",join (',', @list),") \$g2=$g2\n";
-&ok (&eq_array (\@list ,
- [ $g2 ]),
- "find enclosed when group becomes atomic, recursively, starting from group 1");
-
-# Tk::MainLoop;
-
-
-
-sub wait {
- $zinc->update;
- ok (1, $_[0]);
-
- my $delay = $ARGV[0];
- if (defined $delay) {
- $zinc->update;
- if ($delay =~ /^\d+$/) {
- sleep $delay;
- } else {
- sleep 1;
- }
- }
-
-}
-
-
-
-diag("############## Images test");
diff --git a/Perl/t/test-methods.pl b/Perl/t/test-methods.pl
deleted file mode 100644
index 9becf7e..0000000
--- a/Perl/t/test-methods.pl
+++ /dev/null
@@ -1,689 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This non-regression test has been developped by C. Mertz <mertz@cena.fr>
-
-use Tk;
-use Tk::Zinc;
-use Getopt::Long;
-use TestLog;
-
-use strict;
-
-use constant ERROR => '--an error--';
-
-
-# the following list be coherent with the treatments done in the TEST section.
-my @testsList = (
- 1 => 'test_contour_and_coords (quick)',
- 2 => 'test_forbidden_operations_on_root_group (quick)',
- 3 => 'test_errors (quick)',
- 4 => 'test_bboxes (quick)',
- 5 => 'test_gradient_coding (quick)',
- );
-my %testsHash;
-{ my @tests = @testsList;
- while (@tests) {
- my $num = shift (@tests);
- my $comment = shift (@tests);
- $testsHash{ $num } = $comment;
- }
-}
-
-unshift (@INC, "/usr/lib/perl5/Tk"); # for getting Tk some images;
-
-# les variables positionnées en fonction des options de la ligne de commande
-my $opt_log = 0;
-my $opt_trace = "";
-my $opt_render = -1;
-my $opt_type = 0;
-my $outfile;
-my $opt_tests = "all";
-
-# on récupère les options
-Getopt::Long::Configure('pass_through');
-my $optstatus = GetOptions('log=i' => \$opt_log,
- 'out=s' => \$outfile,
- 'trace=s' => \$opt_trace,
- 'render:s' => \$opt_render,
- 'type=s' => \$opt_type,
- 'help' => \&usage,
- 'tests:s' => \$opt_tests,
- );
-
-# on teste la validité de l'option -render!
-if ($opt_render eq '') {
- print "-render option have no value!\n";
- &usage;
-}
-$opt_render = 1 if $opt_render == -1;
-unless ($opt_render==0 or $opt_render==1 or $opt_render==2) {
- print "-render option value must be 0, 1 or 2!\n";
- &usage;
-}
-
-
-$outfile = "methods-$Tk::Zinc::VERSION.log" if (!defined $outfile);
-
-&openLog($outfile, $opt_log);
-
-sub usage {
- my ($text) = @_;
- print $text,"\n" if (defined $text);
- print "test-methods [options]\n";
- print " A non-regression test suite for zinc.\n";
- print " Some exhaustive test of TkZinc methods. Of course everything is not tested yet\n";
- print " options are:\n";
- print " -help to print this short help\n";
- print " -log <n> trace level, defaulted to 0; higher level trace more infos\n";
- print " -out filename the log filename. defaulted to methods-<version><-rendering>.log\n";
- print " NB: the previous log file is always renamed with a .prev suffix\n";
- print " -render 0|1|2 to select the render option of TkZinc (defaulted to 1)\n";
- print " -trace <an_item_option> to better trace usage of an option\n";
- print " -type <a_zinc_item_type> to limits tests to this item type.\n";
- print " -tests to get the list of available tests.\n";
- print " -tests i,j,k... to define the list of tests to pass.\n";
- exit;
-}
-
-my $mw = MainWindow->new();
-
-&log (0, "testing Zinc-perl Version=" . $Tk::Zinc::VERSION . " - ", $mw->zinc(), "\n");
-
-## must be done after the LOG file is open
-my @tests = &parseTestsOpt($opt_tests);
-my %tests;
-foreach my $t (@tests) {$tests{$t} = $t }
-
-
-# The explanation displayed when running this demo
-my $label=$mw->Label(-text => "This is a non-regression test, testing
-some sets of methods!",
- -justify => 'left')->pack(-padx => 10, -pady => 10);
-
-
-# Creating the zinc widget
-my $zinc = $mw->Zinc(-width => 500, -height => 500,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 0, -relief => 'sunken',
- -render => $opt_render,
- )->pack;
-
-&setZincLog($zinc);
-
-sub test_gradient_coding {
- &log (0, "#---- Start of test_gradient_coding ----\n");
- my $log_level = 2 ;
- ### CM to be done!
-
- ### first testing legal gradient
- foreach (0..2) {
- my $i=0;
- foreach my $g ("red", "bLue","#ff00ff","rgb:12/34/56","CIEXYZ:1.2/0.9/3.4",
- "CIEuvY:0.5/.4/0.9", "CIExyY:.52/0.1/0.8", "CIELab:99.1/43./56.1",
- "CIELuv:88/-1/-2.1", "TekHVC:345/1.2/100",
- ) {
- ## first simple color, with different X legal coding
- &test_eval ($log_level, "gname", $g,"grad".$i);
- $i++;
- ## the same color with transparency
- my $transparency = ($i * 4) % 101;
- &test_eval ($log_level, "gname", "$g;$transparency","grad".$i);
- $i++;
- }
-
- ## different axial gradient without the gradient type at the beginning
- foreach my $g ("red|blue", "red |blue", "red | blue",
- "red|green|blue", "red |green|blue", "red |green |blue", "red | green|blue"
- , "red |green| blue", "red |green | blue", "red | green | blue") {
- ## first simple color, with different X legal coding
- &test_eval ($log_level, "gname", $g,"grad".$i);
- $i++;
- }
- ## different axial gradient with explicit gradient type at the beginning
- ## and different angle value!
- foreach my $angle qw(0 12 90 271 360) {
- foreach my $g ("=axial $angle |red|blue",
- "=axial $angle | red|blue",
- "=axial $angle | red |blue",
- "=axial $angle | red | blue",
- "=axial $angle | red|green|blue",
- "=axial $angle |red |green|blue",
- "=axial $angle |red |green |blue",
- "=axial $angle |red | green|blue",
- "red |green| blue",
- "red |green | blue",
- "red | green | blue",
- ) {
- ## first simple color, with different X legal coding
- &test_eval ($log_level, "gname", $g,"grad".$i);
- $i++;
- }
- }
- # and now deleting unused named gradient
- foreach my $j (0..$i-1) {
- &test_eval ($log_level, "gdelete", "grad".$j);
- }
- }
-
- ### and now testing illegal gradient
- my $i=-1;
- &test_no_eval ("X color name with blank inside",
- $log_level, "gname", "navy blue","grad".$i++);
- &test_no_eval ("bad gradient type",
- $log_level, "gname", "=badtype 1 |red|blue","grad".$i++);
- &test_no_eval ("axial gradient with excessive parameters",
- $log_level, "gname", "=axial 67 1 |red|blue","grad".$i++);
- &test_no_eval ("radial gradient with excessive parameters",
- $log_level, "gname", "=radial 30 32 1 |red|blue","grad".$i++);
- &test_no_eval ("path gradient with excessive parameters",
- $log_level, "gname", "=path 30 32 1 |red|blue","grad".$i++);
- ## testing bad types for gradient type
- # to be done
- foreach my $j (0..$i-1) {
- &test_eval ($log_level, "gdelete", "grad".$j);
- }
-
- &log (0, "#---- End of test_gradient_coding -----\n");
-} # end of test_gradient_coding
-
-## TkZinc bbox method doesn't return correct values for bbox. This test
-# function tries to find out in which cases these bbox are wrong
-sub test_bboxes {
- &log (0, "#---- Start of test_bboxes ----\n");
- &creating_items; # to know exactly which items exists at the beginning of this test
-
- # Rectangles
- &bbox_must_be($zinc->add('rectangle', 1, [100,200,300,400]),
- [100,200,300,400], "a simple rectangle");
- &bbox_must_be($zinc->add('rectangle', 1, [300,400,100,200]),
- [100,200,300,400], "a simple reversed rectangle");
-
- # Rectangles with linewidth = 2, 3, 4 and 5
- &bbox_must_be($zinc->add('rectangle', 1, [100,200,300,400], -linewidth =>2),
- [100,200,300,400], "a simple rectangle with linewidth of 2");
- &bbox_must_be($zinc->add('rectangle', 1, [100,200,300,400], -linewidth =>3),
- [100,200,300,400], "a simple rectangle with linewidth of 3");
- &bbox_must_be($zinc->add('rectangle', 1, [100,200,300,400], -linewidth =>4),
- [100,200,300,400], "a simple rectangle with linewidth of 4");
- &bbox_must_be($zinc->add('rectangle', 1, [100,200,300,400], -linewidth =>5),
- [100,200,300,400], "a simple rectangle with linewidth of 5");
-
- # Rectangular curves
- &bbox_must_be($zinc->add('curve', 1, [ [100,200], [300,200], [300,400], [100,400] ],
- -linewidth =>0),
- [100,200,300,400], "a rectangular curve of linewidth => 0");
- &bbox_must_be($zinc->add('curve', 1, [ [100,200], [300,200], [300,400], [100,400] ]),
- [100,200,300,400], "a rectangular curve of linewidth => 1");
- &bbox_must_be($zinc->add('curve', 1, [ [100,200], [300,200], [300,400], [100,400] ],
- -linewidth => 2),
- [100,200,300,400], "a rectangular curve of linewidth => 2");
- &bbox_must_be($zinc->add('curve', 1, [ [100,200], [300,200], [300,400], [100,400] ],
- -linewidth => 3),
- [100,200,300,400], "a rectangular curve of linewidth => 3");
- &bbox_must_be($zinc->add('curve', 1, [ [100,200], [300,200], [300,400], [100,400] ],
- -linewidth => 5),
- [100,200,300,400], "a rectangular curve");
-
- # triangular curves (with a sharp angle)
- &bbox_must_be($zinc->add('curve', 1, [ [0,0], [100,0], [0,10] ]),
- [0,0,100,10], "a triangular curve of linewidth => 1)");
-
- # Arcs
- &bbox_must_be($zinc->add('arc', 1, [100,200,300,400]),
- [100,200,300,400], "an arc");
- &bbox_must_be($zinc->add('arc', 1, [100,200,300,400], -linewidth => 2),
- [100,200,300,400], "an arc of linewidth => 2");
- &bbox_must_be($zinc->add('arc', 1, [100,200,300,400], -linewidth => 3),
- [100,200,300,400], "an arc of linewidth => 3");
-
-
- &log (0, "#---- End of test_bboxes -----\n");
-} # end of test_bboxes
-
-sub bbox_must_be {
- my ($item, $bbox_ref, $explanation) = @_;
- my @computed_bbox=$zinc->bbox($item);
- my @theoritical_bbox = @{$bbox_ref};
- unless (&equal_flat_arrays (\@theoritical_bbox, \@computed_bbox)) {
- &log(-10, "bad bbox of $explanation:\n ## computed = ", &printableArray(\@computed_bbox),
- " theoritical = ", &printableArray(\@theoritical_bbox), "\n");
- }
-} # end of bbox_must_be
-
-
-sub test_contour_and_coords {
- &log (0, "#---- Start of test_contour_and_coords ----\n");
- my $log_level = 2 ;
-
- $zinc->add('rectangle', 1, [ [100,200], [400,300] ], -tags => ['rect1']);
- my $contour_rect = [ [100,200], [100,300], [400,300], [400,200] ];
- my $rev_contour_rect = [ [100,200], [400,200], [400,300], [100,300] ];
-
- $zinc->add('rectangle', 1, [ 100,200, 400,300 ], -tags => ['rect2']);
- &verify_coords_of_contour ('eq','rect1', 'rect2', 0);
- &verify_coords_of_contour_points ('eq','rect1', 'rect2', 0);
-
-
- $zinc->add('arc', 1, [ [100,200], [400,300] ], -tags => ['arc1']);
- $zinc->add('arc', 1, [ 100,200, 400,300 ], -tags => ['arc2']);
- &verify_coords_of_contour ('eq','arc1', 'arc2', 0);
- &verify_coords_of_contour_points ('eq','arc1', 'arc2', 0);
-
- my $contour1 = [ [100,200], [400,300,'c'], [500,100], [350,10, 'c'], [300,500,'c'], [50,100] ];
- my $contour2 = [ 100,200, 400,300, 500,100, 350,10, 300,500, 50,100 ];
- my $contour3 = [ [100,200], [400,300], [500,100], [350,10], [300,500], [50,100]];
- $zinc->add('curve', 1, $contour1, -tags => ['curve1']);
- $zinc->add('curve', 1, $contour2, -tags => ['curve2']);
- $zinc->add('curve', 1, $contour3, -tags => ['curve3']);
- &verify_coords_of_contour ('ne','curve1', 'curve2', 0);
- &verify_coords_of_contour_points ('ne','curve1', 'curve2', 0);
-
- &verify_coords_of_contour ('eq','curve2', 'curve3', 0);
- &verify_coords_of_contour_points ('ne','curve2', 'curve3', 0);
-
- ## testing contours
- $zinc->add('curve', 1, [], -tags => ['curve_contour_0']);
- $zinc->add('curve', 1, [], -tags => ['curve_contour_plus']);
- $zinc->add('curve', 1, [], -tags => ['curve_contour_minus']);
- $zinc->contour('curve_contour_0','add',0, $contour1);
- $zinc->contour('curve_contour_plus','add',+1, $contour1);
- $zinc->contour('curve_contour_minus','add',-1, $contour1);
- &verify_coords_of_contour ('eq','curve1', 'curve_contour_0', 0);
- &verify_coords_of_contour ('ne','curve_contour_plus', 'curve_contour_minus', 0);
- if (&nequal_cplx_arrays ($zinc->coords('curve_contour_0',0),
- $zinc->coords('curve_contour_minus',0))) {
- &verify_coords_of_contour ('eq','curve1', 'curve_contour_plus', 0);
- } else {
- &verify_coords_of_contour ('eq','curve1', 'curve_contour_minus', 0);
- }
- $zinc->add('curve', 1, [], -tags => ['curve_contour_minus_plus']);
- $zinc->contour('curve_contour_minus_plus','add',1,
- [$zinc->coords('curve_contour_minus',0)]);
- &verify_coords_of_contour ('eq','curve1', 'curve_contour_minus_plus', 0);
-
- ## the following curves are similar, because the first contour is
- ## always set counterclockwise
- $zinc->add('curve', 1, $contour_rect, -tags => ['curve_rect_coords']);
- $zinc->add('curve', 1, $rev_contour_rect, -tags => ['curve_rect_coords_reversed']);
- &verify_coords_of_contour ('ne','curve_rect_coords', 'curve_rect_coords_reversed', 0); # we should test they are reversed
-
- $zinc->add('curve', 1, [], -tags => ['curve_rect_0']);
- $zinc->add('curve', 1, [], -tags => ['curve_rect_plus']);
- $zinc->add('curve', 1, [], -tags => ['curve_rect_minus']);
-
- ## the following lines are errors: we cannot add an item as contour with flag 0
- &test_no_eval ("adding a contour from a rectangle with flag=0",
- $log_level, "contour", 'curve_rect_0','add',0, 'rect1');
- &test_no_eval ("adding a contour from an arc with flag=0",
- $log_level, "contour", 'curve_rect_0','add',0, 'arc1');
-
- $zinc->contour('curve_rect_plus','add',1, 'rect1');
- $zinc->contour('curve_rect_minus','add',-1, 'rect1');
- &verify_coords_of_contour ('ne','curve_rect_plus', 'curve_rect_minus', 0);
- &verify_coords_of_contour ('eq','curve_rect_coords', 'curve_rect_plus', 0);
- &verify_coords_of_contour ('eq','curve_rect_coords_reversed', 'curve_rect_minus', 0);
-
- $zinc->add('tabular',1, 2, -tags => ['tabular1']);
- $zinc->add('track',1, 2, -tags => ['track1']);
- $zinc->add('waypoint',1, 2, -tags => ['waypoint1']);
- $zinc->add('reticle',1, -tags => ['reticle1']);
-
- ## we test now the following errors: we cannot use a track, waypoint, reticle, map as a contour
- &test_eval ($log_level, "contour", 'curve_rect_0','add',1, 'tabular1');
- &test_no_eval ("using the contour of a track",
- $log_level, "contour", 'curve_rect_0','add',1, 'track1');
- &test_no_eval ("using the contour of a waypoint",
- $log_level, "contour", 'curve_rect_0','add',1, 'waypoint1');
- &test_no_eval ("using the contour of a reticle",
- $log_level, "contour", 'curve_rect_0','add',1, 'reticle1');
-
- ## we test now the following errors: we cannot add a contour to track, waypoint, rectangle...
- &test_no_eval ("adding a contour to a track",
- $log_level, "contour", 'track1','add',1, 'rect1');
- &test_no_eval ("adding a contour to a waypoint",
- $log_level, "contour", 'waypoint1','add',1, 'rect1');
- &test_no_eval ("adding a contour to a rectangle",
- $log_level, "contour", 'rect1','add',1, 'rect2');
-
- &test_no_eval ("adding a contour with a malformed list",
- $log_level, "contour", 'curve_rect_0','add',1, [1]);
- &test_no_eval ("adding a contour with a malformed list",
- $log_level, "contour", 'curve_rect_0','add',1, [1, 2, 3]);
- &test_no_eval ("adding a contour with a malformed list",
- $log_level, "contour", 'curve_rect_0','add',1, [1, 2, 'c']);
- &test_no_eval ("adding a contour with a malformed list",
- $log_level, "contour", 'curve_rect_0','add',1, [1, 2, [3, 4] ]);
- &test_no_eval ("adding a contour with a malformed list",
- $log_level, "contour", 'curve_rect_0','add',1, [1, 2, [3, 4], [5, 6] ]);
-
- # we should test here what happens when successive points are identical in a curve
-
- # we should test here what happens when the last point is identical to the first point in a curve
-
- &log (0, "#---- End of test_contour_and_coords -----\n");
-} # end of test_contour_and_coords
-
-
-
-sub test_forbidden_operations_on_root_group {
- &log (0, "#---- Start of test_forbidden_operations_on_root_group ----\n");
- my $log_level = 2 ;
-
- my @all_items = $zinc->find('withtag',".1*");
- print "Items before deleting 1: @all_items\n";
- &test_no_eval ("removing the root group",
- $log_level, "remove", 1); ## cannot delete root group
- @all_items = $zinc->find('withtag',".1*");
- print "Items after deleting 1: @all_items\n";
- $zinc->add('group', 1, -tags => "g2");
- # cannot chggroup root group:
- &test_no_eval ("changing the group of the root group",
- $log_level, "chggroup", 1,"g2");
- # cannot clone root group
- &test_no_eval ("cloning the root group",
- $log_level, "clone", 1);
-
- &log (0, "#---- End of test_forbidden_operations_on_root_group -----\n");
-} # end of test_forbidden_operations_on_root_group
-
-
-### tests all errors as defined in the refman
-sub test_errors {
- &log (0, "#---- Start of test_errors ----\n");
- my $log_level = 2 ;
-
- &creating_items;
-
- ## add method with bad argument
- # In a curve, it is an error to have more than two succcessive control points
- # or to start or finish a curve with a control point.
- &test_no_eval ("having more than two succcessive control points",
- $log_level, "add", 'curve', 1,
- [ [10,20], [30,40,'c'], [50,60,'c'], [70,80,'c'], [90,100] ]);
- &test_no_eval ("starting a curve with a control point",
- $log_level, "add", 'curve', 1,
- [ [30,40,'c'], [50,60], [70,80], [90,100] ]);
- &test_no_eval ("finishing a curve with a control point",
- $log_level, "add", 'curve', 1,
- [ [30,40,], [50,60,'c'], [70,80], [90,100,'c'] ]);
-
- # Text indices
- # sel.first Refers to the first character of the selection in the item.
- # If the selection is not in the item, this form returns an error.
- &test_no_eval ("refering to sel.first in a text item without selection",
- $log_level, "insert", 'text', 'sel.first', "string");
- # sel.last Refers to the last character of the selection in the item.
- # If the selection is not in the item, this form returns an error.
- &test_no_eval ("refering to sel.last in a text item without selection",
- $log_level, "insert", 'text', 'sel.last', "string");
-
- # If no item is named by tagOrId or if the item doesn t support anchors,
- # an error is raised.
- &test_no_eval ("refering no item by tagOrId with anchorxy",
- $log_level, "anchorxy", 'bad_tag', 'rectangle');
-
- # If the item doesn't support anchors, an error is raised.
- &test_no_eval ("refering item that does not support anchors",
- $log_level, "anchorxy", 'rectangle', 'ne');
-
- # If the item doesn't support anchors, an error is raised.
- &test_no_eval ("refering a bad anchor name",
- $log_level, "anchorxy", 'text', 'not_an_anchor');
-
-# If the command parameter is omitted, bind returns the command associated
-# with tagOrId and sequence or an error is raised if there is no such binding.
- &test_no_eval ("refering a non-existing bindind with bind",
- $log_level, "bind", 'text', 'badseq');
-
-# $zinc->contour(tagOrId, operatorAndFlag, coordListOrTagOrId);
- # An error is generated if items are not of a correct type or if the
- # coordinate list is malformed.
- # tested in &test_contour_and_coords
-
-# If no items are named by tagOrId, an error is raised.
- &test_no_eval ("refering a non-existing item with hasanchors",
- $log_level, "hasanchors", 'badtag');
-
-# If no items are named by tagOrId, an error is raised.
- &test_no_eval ("refering a non-existing item with hasfields",
- $log_level, "hasfields", 'badtag');
-
- # If no items are named by tagOrId, an error is raised.
- &test_no_eval ("refering a non-existing item with hastag",
- $log_level, "hastag", 'badtag', 'atag');
-
- # If field is given, it must be a valid field index for the item or
- # an error will be reported.
- &test_no_eval ("accessing a non existing track field",
- $log_level, "itemcget", 'track', 111, -text);
-
- # If the attribute is not available for the field or item type,
- # an error is reported.
- &test_no_eval ("accessing a non existing curve attribute",
- $log_level, "itemcget", 'curve', -bad_attribute);
- &test_no_eval ("accessing a non existing attribute of a track field",
- $log_level, "itemcget", 'track', 1, -bad_attribute);
-
- # If field is given, it must be a valid field index for the item or an
- # error will be reported.
- &test_no_eval ("modifying a non existing track field",
- $log_level, "itemconfigure", 'track', 111, -text => "foo");
- # If an attribute does not belong to the item or field, an error is reported:
- &test_no_eval ("modifying a non existing curve attribute",
- $log_level, "itemconfigure", 'curve', -bad_attribute => "foo");
- &test_no_eval ("modifying a non existing attribute of a track field",
- $log_level, "itemconfigure", 'track', 1, -bad_attribute => "foo");
-
-# If tagOrId doesn t name an item, an error is raised.
- &test_no_eval ("lowering a non-existing item with lower",
- $log_level, "lower", 'badtag', 'track');
-# If belowThis doesn t name an item, an error is raised.
- &test_no_eval ("lowering an existing below an non-existing item with lower",
- $log_level, "lower", 'track', 'badtag');
-
-# If no items are named by tagOrId, an error is raised.
- &test_no_eval ("refering a non-existing item with numparts",
- $log_level, "numparts", 'badtag');
-
-# If tagOrId describes neither a named transform nor an item, an error is raised.
- &test_no_eval ("refering a non-existing item with rotate",
- $log_level, "rotate", 'badtag', 180);
-# If tagOrId describes neither a named transform nor an item, an error is raised.
- &test_no_eval ("refering a non-existing item with scale",
- $log_level, "scale", 'badtag', 2,2);
-# If tagOrId describes neither a named transform nor an item, an error is raised.
- &test_no_eval ("refering a non-existing item with translate",
- $log_level, "translate", 'badtag', 200,200);
-
- # If the given name is not found among the named transforms, an error is raised.
- &test_no_eval ("refering a non-existing named transform item with tdelete",
- $log_level, "tdelete", 'badNamedTransform');
-
-# ->transform ??
-
- # If tagOrId describes neither a named transform nor an item, an error is raised.
- &test_no_eval ("refering a non-existing named transform or item with treset",
- $log_level, "treset", 'badNamedTransform');
-
- # If tagOrId doesn t describe any item or if the transform named tName
- # doesn't exist, an error is raised.
- &test_eval ($log_level, "tsave", "text", "namedTransfrom");
- &test_no_eval ("refering a non-existing item with trestore",
- $log_level, "trestore", 'badTag', 'namedTransform');
- &test_no_eval ("refering a non-existing named transform with trestore",
- $log_level, "trestore", 'track', 'badNamedTransform');
-
- # If tagOrId doesn t describe any item, an error is raised.
- &test_no_eval ("refering a non-existing item with tsave",
- $log_level, "tsave", 'badTag', 'otherNamedTransform');
-
- # If no items are named by tagOrId, an error is raised.
- &test_no_eval ("refering a non-existing item with type",
- $log_level, "type", 'badTag');
-
- &log (0, "#---- End of test_errors -----\n");
-} # end of test_errors
-
-sub creating_items {
- # first removing all remaining items
- foreach my $tag qw(group track waypoint tabular text icon reticle map
- rectangle arc curve triangles window) {
- $zinc->remove($tag);
- }
- # and then creating items
- $zinc->add('group', 1, -tags => ['group']);
- $zinc->add('track', 1, 5, -position => [100,200], -tags => ['track']);
- $zinc->add('waypoint', 1, 5, -position => [200,100], -tags => ['waypoint']);
- $zinc->add('tabular', 1, 5, -position => [100,20], -tags => ['tabular']);
- $zinc->add('text',1, -tags => ['text']);
- $zinc->add('icon', 1, -tags => ['icon']);
- $zinc->add('reticle', 1, -tags => ['reticle']);
- $zinc->add('map', 1, -tags => ['map']);
- $zinc->add('rectangle', 1, [400,400 , 450,220], -tags => ['rectangle']);
- $zinc->add('arc', 1, [10,10 , 50,50], -tags => ['arc']);
- $zinc->add('curve', 1, [30,0 , 150,10, 100,110, 10,100, 50,140], -tags => ['curve']);
- $zinc->add('triangles', 1, [200,200 , 300,200 , 300,300, 200,300],
- -colors => ["blue;50", "red;20", "green;80"], -tags => ['triangles']);
- $zinc->add('window', 1, -tags => ['window']);
- foreach my $tag qw(group track waypoint tabular text icon reticle map
- rectangle arc curve triangles window) {
-# my $contour = $zinc->contour($tag);
-# print "$tag := $contour\n";
- }
-
-} # end creating_items
-
-
-sub verify_coords_of_contour {
- my ($predicat, $id1, $id2, $contour) = @_;
- my @contour1 = $zinc->coords($id1,$contour);
- my @contour2 = $zinc->coords($id2,$contour);
-# print "contour1: ", &printableArray (@contour1), "\n";
-# print "contour2: ", &printableArray (@contour2), "\n";
- my $res = &nequal_cplx_arrays (\@contour1, \@contour2);
-# print "res=$res\n";
- if ($predicat eq 'eq') {
- if ($res) {
- &log(-100, "coords of $id1($contour) and $id2($contour) are not equal:\n\t".
- &printableArray(@contour1)."\n\t".&printableArray(@contour2)."\n");
- } else {
- &log(1, " # coords of $id1($contour) and $id2($contour) are OK ($predicat)\n");
- }
- } elsif ($predicat eq 'ne') {
- if (!$res) {
- &log(-10, "coords of $id1($contour) and $id2($contour) should not be equal\n");
- } else {
- &log(1, " # coords of $id1($contour) and $id2($contour) are OK ($predicat)\n");
- }
- } else {
- &log(-100, "unknown predicat: $predicat\n");
- }
-} # end of verify_coords_of_contour;
-
-
-sub verify_coords_of_contour_points {
- my ($predicat, $id1, $id2, $contour) = @_;
- my @contour1 = $zinc->coords($id1,$contour);
-
- my $nequal=0;
- for (my $i = 0; $i < $#contour1; $i++) {
- my @coords1 = $zinc->coords($id1,0,$i);
- my @coords2 = $zinc->coords($id2,0,$i);
- my $res = &equal_flat_arrays ( \@coords1, \@coords2 );
- if ($predicat eq 'eq') {
- if (!$res) {
- &log(-100, "coords of $id1($contour,$i) and $id2($contour,$i) are not equal:\n\t$res");
- }
- } elsif ($predicat eq 'ne') {
- if (!$res) {
- $nequal=$res;
- last;
- }
- } else {
- &log(-100, "unknown predicat: $predicat\n");
- }
- }
- if ($predicat eq 'neq' and !$nequal) {
- &log(-100, "coords of $id1($contour,i) and $id2($contour,i) should not be all equal\n");
- } else {
- &log(1, " # coords of $id1($contour,i) and $id2($contour,i) are OK ($predicat)\n");
- }
-} # end of verify_coords_of_contour_points;
-
-
-sub parseTestsOpt {
- my ($opt) = @_;
- my @tests;
- if ($opt eq '') {
- print "Availables tests are:\n";
- while (@testsList) {
- my $i = shift @testsList;
- my $comment = shift @testsList;
- print "\t$i => $comment\n";
- }
- exit;
- } elsif ( $opt eq 'all' ) { ## default!
- &log (0, " # all tests will be passed through\n");
- @tests = sort keys %testsHash;
- } elsif ( $opt =~ /^\d+(,\d+)*$/ ) {
- @tests = split (/,/ , $opt);
- my $testnumb = (scalar @testsList) / 2;
- foreach my $test (@tests) {
- die "tests num must not exceed $testnumb" if $test > $testnumb;
- }
- &log(0, "Test to be done:\n");
- foreach my $test (@tests) {
- &log(0, "\t # $test => " . $testsHash{$test} . "\n");
- }
- } else {
- print "bad -tests value. Must be a list of integer separated by ,\n";
- &usage;
- }
- return @tests;
-} # end of parseTestsOpt
-
-# ---------- TEST ------------------
-# the following code must be coherent with the tests list described
-# on the very beginning of this file (see @testsList definition)
-
-if ($tests{1}) {
- &test_contour_and_coords ();
-}
-
-if ($tests{2}) {
- &test_forbidden_operations_on_root_group ();
-}
-
-if ($tests{3}) {
- &test_errors;
-}
-
-if ($tests{4}) {
- &test_bboxes;
-}
-
-if ($tests{5}) {
- &test_gradient_coding;
-}
-
-### we should also test multicontour curves
-if ($tests{5}) {
-# &test_coords;
-}
-
-# #### &test_fonts; ## and specially big fonts with render = 1;
-# #### &test_path_tags;
-# #### &test_illegal_tags;
-
-# #### &test_illegal_call
-# for example:
-# calling a methode for an non-existing item
-# getting coords, contours, fields, etc... of non-existing index
-#
-# cloning, deleting topgroup
-#
-
-&log (0, "#---- End of test_method ----\n");
-
-#MainLoop();
diff --git a/Perl/t/test-no-crash.pl b/Perl/t/test-no-crash.pl
deleted file mode 100644
index f1e22a6..0000000
--- a/Perl/t/test-no-crash.pl
+++ /dev/null
@@ -1,880 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This non-regression / memory leak test has been developped by Christophe Mertz <mertz@intuilab.com>
-
-use Tk;
-use Tk::Zinc;
-use Getopt::Long;
-use TestLog;
-
-use strict;
-
-use constant ERROR => '--an error--';
-
-
-# the following list be coherent with the treatments done in the TEST section.
-my @testsList = (
- 1 => 'test_mapitems (quick)',
- 2 => 'test_every_field_attributes (long)',
- 3 => 'test_attributes (medium)',
- 4 => 'test_cloning (quick)',
- 5 => 'test_coords (quick)',
- );
-my %testsHash;
-{ my @tests = @testsList;
- while (@tests) {
- my $num = shift (@tests);
- my $comment = shift (@tests);
- $testsHash{ $num } = $comment;
- }
-}
-
-# les variables positionnées en fonction des options de la ligne de commande
-my $opt_log = 0;
-my $opt_trace = "";
-my $opt_render = -1;
-my $opt_type = 0;
-my $outfile;
-my $opt_tests = "all";
-my $opt_memoryleak = 0;
-
-# on récupère les options
-Getopt::Long::Configure('pass_through');
-my $optstatus = GetOptions('log=i' => \$opt_log,
- 'out=s' => \$outfile,
- 'trace=s' => \$opt_trace,
- 'render:s' => \$opt_render,
- 'type=s' => \$opt_type,
- 'help' => \&usage,
- 'memoryleak' => \$opt_memoryleak,
- 'tests:s' => \$opt_tests,
- );
-
-# on teste la validité de l'option -render!
-if ($opt_render eq '') {
- print "-render option have no value!\n";
- &usage;
-}
-$opt_render = 1 if $opt_render == -1;
-unless ($opt_render==0 or $opt_render==1 or $opt_render==2) {
- print "-render option value must be 0, 1 or 2!\n";
- &usage;
-}
-
-
-$outfile = "no-crash-$Tk::Zinc::VERSION.log" if (!defined $outfile);
-
-## in case of memoryleak test, logs are not written in a file
-## and logs are limited to high level logs on the standard output
-## (only those with a loglevel <= -1000 will be written on stdout)
-my $nolog_file = 0;
-if ($opt_memoryleak) {
- $opt_log = -1000;
- my $nolog_file = 1;
-}
-
-
-
-
-&openLog($outfile, $opt_log, $nolog_file);
-
-sub usage {
- my ($text) = @_;
- print $text,"\n" if (defined $text);
- print "test-no-crash [options]\n";
- print " A non-regression test suite for zinc.\n";
- print " Some exhaustive test of zinc. Of course everything is not tested yet\n";
- print " options are:\n";
- print " -help to print this short help\n";
- print " -log <n> trace level, defaulted to 0; higher level trace more infos\n";
- print " -out filename the log filename. defaulted to no-crash.log\n";
- print " NB: the previous log file is always renamed with a .prev suffix\n";
- print " -memoryleak to try to detect some memoryleak between first iteration of the test \n";
- print " and the following iteration. This test NEVER finish automatically\n";
- print " it is up to the tester to stop the memoryleak test after\n";
- print " a significative number of iterations\n";
- print " -render 0|1|2 to select the render option of zinc (defaulted to 1)\n";
- print " -trace <an_item_option> to better trace usage of an option\n";
- print " -type <a_zinc_item_type> to limits tests to this item type.\n";
- print " -tests to get the list of available tests.\n";
- print " -tests i,j,k... to define the list of tests to pass.\n";
- exit;
-}
-
-my $mw = MainWindow->new();
-
-&log (-1000, "#testing Zinc-perl Version=" . $Tk::Zinc::VERSION . " - ", $mw->zinc(), "\n");
-
-## must be done after the LOG file is open:
-
-my @tests = &parseTestsOpt($opt_tests);
-my %tests;
-foreach my $t (@tests) {$tests{$t} = $t }
-
-
-# The explanation displayed when running this demo
-my $label=$mw->Label(-text => "This is a non-regression test, testing that
-zinc is not core-dumping! It can also be used for detecting memory leaks",
- -justify => 'left')->pack(-padx => 10, -pady => 10);
-
-
-# Creating the zinc widget
-my $zinc = $mw->Zinc(-width => 500, -height => 500,
- -trackmanagedhistorysize => 10,
- -font => "10x20", # usually fonts are sets in resources
- # but for this example it is set in the code!
- -borderwidth => 0, -relief => 'sunken',
- -render => $opt_render,
- )->pack;
-
-&setZincLog($zinc);
-
-
-my %itemtypes;
-my @itemtypes = qw(arc tabular track waypoint
- curve rectangle triangles
- group icon map reticle text window
- );
-
-if ($opt_type) { @itemtypes = ($opt_type); }
-
-foreach my $type (@itemtypes) { $itemtypes{$type}=1 }
-
-#### some global variables needed as attributes values
-my ($text1, $text2, $text3, $text4);
-my ($image1, $image2, $image3, $image4);
-
-&creating_items ("unused");
-&verifying_item_completion;
-
-sub creating_items {
- # first removing all remaining items
- foreach my $item (&test_eval (1, 'find', 'withtag', 'all')) {
- &test_eval (1, "remove", $item);
- }
-
-
- my $labelformat = "x82x60+0+0 x60a0^0^0 x32a0^0>1 a0a0>2>1 x32a0>3>1";
- # and then creating items
- &test_eval (1, "add", 'group', 1);
- &test_eval (1, "add", 'group', 1);
- &test_eval (1, "add", 'icon', 1);
- &test_eval (1, "add", 'map', 1);
- &test_eval (1, "add", 'map', 1);
- &test_eval (1, "add", 'reticle', 1);
- $text1 = &test_eval (1, "add", 'text', 1, -position => [300,120], -text => "hello world1");
- $text2 = &test_eval (1, "add", 'text', 1, -position => [350,170], -text => "hello world2");
- $text3 = &test_eval (1, "add", 'text', 1, -position => [400,220], -text => "hello world3");
- &test_eval (1, "add", 'window', 1);
-# &test_eval (1, "add", 'track', 1, 5, -position => [100,200]);
- &test_eval (1, "add", 'track', 1, 5, -position => [100,200], -labelformat => $labelformat);
- &test_eval (1, "add", 'waypoint', 1, 5, -position => [200,100], -labelformat => $labelformat);
- &test_eval (1, "add", 'tabular', 1, 5, -position => [100,20], -labelformat => $labelformat);
- &test_eval (1, "add", 'group', 1);
-
- &test_eval (1, "mapinfo", 'mapinfo1', 'create');
- &test_eval (1, "mapinfo", 'mapinfo2', 'create');
- &test_eval (1, "mapinfo", 'mapinfo3', 'create');
-
-#$zinc->itemconfigure ('tabular', -labelformat => "200x10");
-#$zinc->update;
-
-
-
- &test_eval (1, "add", 'arc', 1, [10,10 , 50,50]);
- &test_eval (1, "add", 'curve', 1, [30,0 , 150,10, 100,110, 10,100, 50,140]);
- &test_eval (1, "add", 'rectangle', 1, [400,400 , 450,220]);
- &test_eval (1, "add", 'triangles', 1, [200,200 , 300,200 , 300,300, 200,300],
- -colors => ["blue;50", "red;20", "green;80"]);
-
- # images are initialised ONLY ONCE! (to avoid memoryleaks)
- $image1 = $zinc->Photo(-file => Tk::findINC("Tk/icon.gif") ) unless $image1;
- $image2 = $zinc->Photo(-file => Tk::findINC("Tk/Xcamel.gif") ) unless $image2;
- $image3 = $zinc->Photo(-file => Tk::findINC("Tk/tranicon.gif") ) unless $image3;
- $image4 = $zinc->Photo(-file => Tk::findINC("Tk/anim.gif") ) unless $image4;
-
- &creating_datas; # some of the data are using items!
-} # end creating_items
-
-# verifies that we create an item of every existing type
-sub verifying_item_completion {
- my @all_types = $zinc->add(); ## this use of add is not documented yet XXX!
- my @all_items = $zinc->find ('withtag', 'all');
- my %created_item_types;
- foreach my $item (@all_items) {
- $created_item_types{$zinc->type($item)} = 1;
- }
- foreach my $type (@all_types) {
- if (defined $created_item_types{$type}) {
- delete $created_item_types{$type};
- }
- else {
- &log(-100, "item type \"type\" which exist in Zinc is not tested!\n");
- }
- }
- foreach my $type (sort keys %created_item_types) {
- &log(-100, "This tested item type \"$type\" is supposed not to exist in Zinc!\n");
- }
-}
-
-
-my %options;
-my %types;
-
-
-foreach my $itemType (@itemtypes) {
- my ($anItem) = $zinc->find('withtype', $itemType);
- if (!defined $anItem) { &log (-10, "no item $itemType\n"); next;};
- my @options = $zinc->itemconfigure($anItem);
- foreach my $elem (@options) {
- my ($optionName, $optionType, $readOnly, $empty, $optionValue) = @$elem;
- $options{$itemType}{$optionName} = [$optionType, $readOnly, $empty, $optionValue];
- $types{$optionType} = 1;
- }
-}
-
-my %fieldOptions;
-
-{
-my ($aTrack) = $zinc->find('withtype', 'track');
-if (!defined $aTrack) { &log (-10, "no item track\n") }
-else {
- my @fieldOptions = $zinc->itemconfigure($aTrack, 0);
- for my $elem (@fieldOptions) {
- my ($optionName, $optionType, $readOnly, $empty, $optionValue) = @$elem;
- $fieldOptions{$optionName} = [$optionType, $readOnly, $empty, $optionValue];
- $types{$optionType} = 1;
- }
-}
-}
-
-foreach my $type (sort keys %types) {
-# print "$type\n";
-}
-
-# a hash giving samples of valid data for attributes types
-my %typesValues;
-
-# the following hash associated to types valid value that should be all different from
-# default value and from value initiated when creating items (see up...)
-my %typesNonStandardValues;
-
-# a hash giving samples of NOT valid data for attributes types
-my %typesIllegalValues;
-
-sub creating_datas {
- return if defined $typesValues{'alignment'};
- %typesValues =
- ('alignment' => ['left', 'right', 'center'],
- 'alpha' => [0, 50, 100, 23],
- 'anchor' => ['n', 's', 'e', 'w', 'nw', 'ne', 'sw', 'se', 'center'],
- 'angle' => [0, 90, 180, 270, 360, 12, 93, 178, 272, 359],
- 'autoalignment' => ['lll', 'llr', 'llc', 'lrl', 'lrr', 'lrc', 'lcl', 'lcr', 'lcc',
- 'rll', 'rlr', 'rlc', 'rrl', 'rrr', 'rrc', 'rcl', 'rcr', 'rcc',
- 'cll', 'clr', 'clc', 'crl', 'crr', 'crc', 'ccl', 'ccr', 'ccc',
- '-',],
- 'boolean' => [0..1],
- 'bitmap' => ['AlphaStipple0', 'AlphaStipple3', 'AlphaStipple14', 'AlphaStipple11', 'AlphaStipple7'], ####?!
- 'bitmaplist' => [['AlphaStipple0', 'AlphaStipple3', 'AlphaStipple14', 'AlphaStipple11', 'AlphaStipple7'], ['AlphaStipple0']], ##TBC
- 'capstyle' => ['butt', 'projecting', 'round'],
- 'gradient' => ['green', 'LemonChiffon', '#c84', '#4488cc', '#888ccc444', 'red'], ## TBC
- 'gradientlist' => [['green'], ['LemonChiffon'], ['#c84'], ['#4488cc'], ['#888ccc444'],
- ['red', 'green'], ['red', 'green', 'blue'],
- ['red;50', 'green;50', 'blue;50'],
- ['blue;0', 'green;50', 'red;90'],
- ], ## TBC
- 'dimension' => [0..5, 10, 50, 100, 0.0, 5.5, 100.5, 4.5], ## and floats ?!
- 'edgelist' => ['left', 'right', 'top', 'bottom', 'contour', 'oblique', 'counteroblique'], ## +combinations!
- 'filerule', => ['odd', 'negative','positive', 'abs_ge_eq2'],
- 'font' => ['10x20', '6x10', '6x12', '6x13'],
- 'image' => [$image1, $image2, $image3], ## TBC
- 'integer' => [-10000, -100, -1, 0, 1, 10, 10000], ## pour quoi?
- 'item' => [$text1, $text2],
- 'joinstyle' => ['bevel', 'miter', 'round'],
- 'labelformat' => ["200x10", ## BUG BUG
-# "200x100 x100x20+0+0 x100x20+0+20 x200x40+100+20"
- ],
- 'leaderanchors' => ["%10x30", "|0|0", "%40x20", "|1|1", "|100|100", "%67x21" ], ## TBC! non exchaustif!! BUG non conforme à la doc
- # illegal et fait planter: "%50"
- 'lineend' => [ [10,10,10], [10,100,10], [100,10,10], [10,10,100], [100,10,100] ],
- 'lineshape' => ['straight', 'rightlightning', 'leftlightning', 'rightcorner', 'leftcorner', 'doublerightcorner', 'doubleleftcorner'],
- 'linestyle' => ['dotted', 'simple', 'dashed', 'mixed', 'dotted'],
- 'mapinfo' => ['mapinfo1','mapinfo2','mapinfo3'], ## TBC
-# 'number' => [2.3, 1.0, 5.6, 2.1],
- 'point' => [ [0,0] , [10,10], [20,20], [30,30], [20,20], [0,0] , [10,10] ],
- 'priority' => [ 1, 10, 50, 1000, 10000 ], # positif ou nul
- 'relief' => ['flat', 'groove', 'raised', 'ridge', 'sunken',
- 'roundraised', 'roundsunken', 'roundgroove',
- 'roundridge', 'sunkenrule', 'raisedrule'],
- 'string' => ['teststring', 'short', 'veryverylongstring'],
- 'taglist' => [ [1], [1..2], ['a','b'], ['tag1','tag2','tag3']],
- 'unsignedint' => [ 0..5 , 10, 20, 30, 100 ],
- 'window' => [], ## TBC
- );
-
-# the following valid value associated to types should be all different from
-# default value and from value initiated when creating items (see up...)
- %typesNonStandardValues =
- ('alignment' => 'right',
- 'alpha' => 50,
- 'anchor' => 'w',
- 'angle' => 45,
- 'autoalignment' => 'llc',
- 'bitmap' => 'AlphaStipple14',
- 'bitmaplist' => ['AlphaStipple0', 'AlphaStipple3', 'AlphaStipple14', 'AlphaStipple11', 'AlphaStipple7'],
- 'capstyle' => 'butt',
- 'gradient' => 'LemonChiffon',
- 'gradientlist' => ['red;50', 'green;50', 'blue;50'],
- 'dimension' => 45,
- 'edgelist' => 'contour',
- 'font' => '6x10',
- 'fillrule' => 'nonzero',
- 'image' => $image4,
- 'integer' => 7,
- 'item' => $text3,
- 'joinstyle' => 'miter',
- 'labelformat' => "200x30", ## BUG BUG
- 'leaderanchors' => "%10x45", ## BUG BUG
- 'lineend' => [13,7,20],
- 'lineshape' => 'rightlightning',
- 'linestyle' => 'dotted',
- 'mapinfo' => 'mapinfo2', ## TBC
- 'number' => 7.6,
- 'point' => [100,100],
- 'priority' => 50,
- 'relief' => 'groove',
- 'string' => 'notsoshort',
- 'taglist' => ['tag1','tag11','tag111'],
- 'unsignedint' => 7, # 22, # 22 is to high for -visiblehistorysize and 5 is, the default value for reticle -period
- 'window' => undef, ### TBC
- );
-
- %typesIllegalValues =
- ('alpha' => [0..100],
- 'anchor' => ['n', 's', 'e', 'w'], ##TBC
- 'angle' => [0..360],
- 'boolean' => [0..1],
- 'capstyle' => [],
- 'dimension' => [0..100],
- 'font' => ['10x20', '6x10', '6x12', '6x13'],
- 'leaderanchors' => ["%50" ], ## TBC! non exchaustif!! BUG non
- 'relief' => ['flat', 'groove', 'raised', 'ridge', 'sunken',
- 'roundraised', 'roundsunken', 'roundgroove',
- 'roundridge', 'sunkenrule', 'raisedrule'],
- );
-}
-
-$mw->Button(-text => "Exit",
- -command => sub { exit },
- )->pack(-pady => 4);
-
-sub test_attributes {
- &log (-1000, "#---- Start of test_attributes ----\n");
- foreach my $type (@itemtypes) {
- my @items = $zinc->find('withtype', $type);
- &log (0, "#--------- Testing ", (1+$#items), " ",$type," attributes ----------------\n");
- if ($#items == -1) {
- &log (-100, "No such item: $type\n");
- next;
- }
- &log(0,"no such type '$type'\n"), next unless defined $options{$type};
-# print $options{$type}, "\t\t", %{$options{$type}}, "\n";
- my %theoptions = %{$options{$type}};
- foreach my $item (@items) {
- ## il faudrait tester les options selon un ordre défini à l'avance
- ## en passant par plusieurs occurences pour les options et en forçant
- ## certaines valeurs, par exemple les valeurs booléennees... (visible/sensible/filled)
- my @boolean_attributes;
- my %boolean_attributes;
- foreach my $option (sort keys %theoptions) {
- my ($optionType, $readOnly, $empty, $optionValue) = @{$theoptions{$option}};
- if ($optionType eq 'boolean') {
- next if $option eq -composerotation;
- next if $option eq -composescale;
- next if $option =~ /-\w+sensitive/ ; # to get rid of many track options!
- next if $option =~ /-filled\w+/ ; # to get rid of many track options!
- next if $option =~ /-speed\w+/ ; # to get rid of many track options!
- next if $option =~ /-\w+history/ ; # to get rid of many track options!
- push @boolean_attributes, $option;
- $boolean_attributes{$option}=1;
- }
- }
- &log (0, "# $type (id $item) : ", ((2**(1+$#boolean_attributes)) , " Combinations (", join (', ' , @boolean_attributes),")\n"));
- foreach my $i (0 .. (2**(1+$#boolean_attributes) -1) ) {
- my $format = "%0" . ($#{boolean_attributes} +1) . "b";
- my $binary = sprintf ($format,$i);
- &log (0, "# $i/", (2**(1+$#boolean_attributes)), " $binary\n");
- my @binary = split (//,$binary);
- foreach my $j (0 .. $#boolean_attributes) {
- &test_eval (0, "itemconfigure", $item, $boolean_attributes[$j] => $binary[$j] );
-# &log (0, "setting $type ($item) ", $boolean_attributes[$j], " to ", $binary[$j], "\n");
- }
- foreach my $option (sort keys %theoptions) {
- next if ($option eq -numfields); # BUG? makes the appli stop
- next if ($option eq "-clip" and $type = "group"); # BUG? This test cannot be random clipping item must belong to the group
- next if ($boolean_attributes{$option}); # skipping boolean attributes which are exhaustively tested
-
- my ($optionType, $readOnly, $empty, $optionValue) = @{$theoptions{$option}};
- my $typeValues = $typesValues{$optionType};
- if (!defined $typeValues) {&log (-100, "No values for type $optionType (option $option)\n");next;}
- my @values = @{$typeValues};
-
- if (!@values) {&log (-100, "No values for type $optionType (option $option)\n");next;}
-
-
- my $valueRef = ref ($values[0]);
- my $previous_val;
- my @previous_val;
-
- if ($valueRef eq '') {
- $previous_val = $zinc->itemcget($item, $option);
- }
- else {
- @previous_val = $zinc->itemcget($item, $option);
- }
- &log (1, "#** itemconfigure of $item ($type), $option => ",&printableList (@values),"\n");
- my $log_lev = ($opt_trace eq $option || $opt_trace eq $optionType ) ? 0 : 2 ;
- foreach my $value (@values) {
- &test_eval ($log_lev, "itemconfigure", $item, $option => $value);
- $zinc->update;
- $zinc->after(10);
- }
-
- if ($valueRef eq '') {
- &test_eval ($log_lev, "itemconfigure", $item, $option => $previous_val);
- }
- else {
- &test_eval ($log_lev, "itemconfigure", $item, $option => \@previous_val);
- }
-
- }
- }
- }
- }
- &log (0, "#---- End of test_attributes ----\n");
-} # end test_attributes
-
-
-# test2: configurer les fields des track / waypoint / tabular
-# jouer avec les labelformats
-
-# test3: tester toutes les fonctions aléatoirement selon les signatures
-
-
-# test4: tester qu'en clonant on obtient bien une copie de tous les attributs
-
-sub test_cloning {
- &log (-1000, "#---- Start of test_cloning ----\n");
- &creating_items;
- foreach my $type (@itemtypes) {
- my ($item) = $zinc->find('withtype', $type);
- &log (0, "#--------- Cloning and testing item ",$type," $item ----------------\n");
- if (!defined $item) { &log (-10, "No such item: $type\n"); next;};
- my $clone = &test_eval(1, "clone", $item);
-
- &log (0, "#---- Modifying the clone $clone\n");
- &test_a_clone ($type, $item, $clone);
- &test_enclosed_overlapping_closest($type, 'original', $item, $zinc->bbox ($item));
- &test_enclosed_overlapping_closest($type, 'clone', $clone, $zinc->bbox ($clone));
- &log (0, "#---- Modifying the original\n");
- &test_a_clone ($type, $clone, $item);
- &test_enclosed_overlapping_closest($type, 'original', $item, $zinc->bbox ($item));
- &test_enclosed_overlapping_closest($type, 'clone', $clone, $zinc->bbox ($clone));
- &log (0, "#---- Deleting the original\n");
- &test_eval (1, "remove", $item);
- &test_every_attributes_once($type,$clone);
- &log (0, "#---- Deleting the clone\n");
- &test_eval (1, "remove", $clone);
- }
- # tester le find enclosed / overlapping avec un rectangle un peu plus grand que la bbox
- # tester le closest avec le centre de la bbox
-
- # faire la même chose que juste avant, mais en interchangeant clone et original
- # tester le find enclosed / overlapping avec un rectangle un peu plus grand que la bbox
- # tester le closest avec le centre de la bbox
-
- # supprimer l'item original
-
- # tester le find enclosed / overlapping avec un rectangle un peu plus grand que la bbox
- # tester le closest avec le centre de la bbox
-
- # modifier tous les attributs du clone
- # supprimer le clone
-
- # tester le find enclosed / overlapping avec un rectangle un peu plus grand que la bbox
- # tester le closest avec le centre de la bbox
-
- &log (0, "#---- End of test_cloning ----\n");
-} # end test_cloning
-
-## teste le find enclosed / overlapping avec un rectangle un peu plus grand
-# que la bbox donnée en paramètre.
-# si $item est différent de '', vérifie que l'item est enclosed/overlapping
-## Vérifie aussi le fonctionnement ud closest pour le centre de la bbox
-sub test_enclosed_overlapping_closest {
- my ($type, $clone_or_original, $item, @bbox) = @_;
- if ($#bbox == -1) {
- &log(-100, "Undef bbox of a $type ($clone_or_original)\n");
- }
- else {
- @bbox = ( $bbox[0]-10, $bbox[1]-10, $bbox[2]+10, $bbox[3]+10 );
- my @items = &test_eval (1, "find", 'enclosed', @bbox);
- goto TESTOVERLAPPING if ($item eq '');
- foreach my $i (@items) {
- goto TESTOVERLAPPING if ($i eq $item); # the item is included!
- }
- &log(-100, "The $type ($clone_or_original) is not enclosed in its bbox!\n");
- TESTOVERLAPPING:
-# @items = $zinc->find ('overlapping', @bbox);
- @items = &test_eval (1, "find", 'overlapping', @bbox);
- goto TESTCLOSEST if ($item eq '');
- foreach my $i (@items) {
- goto TESTCLOSEST if ($i eq $item);
- }
- &log(-100, "The $type ($clone_or_original) is not overlapping its bbox!\n");
- TESTCLOSEST:
- my $x = ($bbox[0] + $bbox[2] )/2;
- my $y = ($bbox[1] + $bbox[3] )/2;
-# my $closest = $zinc->find ('closest', $x,$y);
- my $closest = &test_eval (1, "find", 'closest', $x,$y);
- }
-} # end test_enclosed_overlapping_closest
-
-sub test_a_clone {
- my ($type, $original, $clone) = @_;
- my %theoptions = %{$options{$type}};
- foreach my $option (sort keys %theoptions) {
- next if ($option eq -numfields); # BUG? makes the appli stop
- next if ($option eq "-clip" and $type = "group"); # BUG? This test cannot be random. Clipping item must belong to the group
- next if ($option eq '-connecteditem'); ## XXX this test should be corrected implemented,
- my ($optionType, $readOnly, $empty, $optionValue) = @{$theoptions{$option}};
- my $value = $typesNonStandardValues{$optionType};
- if ($optionType ne 'boolean' && !defined $value) {
- &log (-100, "No value for type $optionType (option $option)\n");
- next;
- }
-
- my $valueRef = ref ($value);
- my $previous_val;
- my @previous_val;
-
- # memoryzing previous value of the clone
- if ($valueRef eq '') {
- $previous_val = &test_eval (2, "itemcget", $clone, $option);
- }
- else {
- @previous_val = &test_eval (2, "itemcget", $clone, $option);
- }
-
- # in the case of boolean, we must always take the not value:
- if ($optionType eq 'boolean') { $value = !$previous_val }
-
- my $log_lev = ($opt_trace eq $option || $opt_trace eq $optionType) ? 0 : 2 ;
- &test_eval ($log_lev, "itemconfigure", $clone, $option => $value);
- $zinc->update;
-
- if ($valueRef eq 'ARRAY') { # the value is a list
- my @original_value = &test_eval (2, "itemcget", $original, $option);
- my @clone_value = &test_eval (1, "itemcget", $clone, $option);
- if ( &equal_flat_arrays (\@original_value, \@clone_value) ) {
- &log (-100, "Modified cloned $type gets the same value for $option (type $optionType) ". &printableArray(@original_value) . "\n");
- }
- }
- else { # the value is either a scalar or a class instance
- my $original_value = &test_eval (2, "itemcget", $original, $option);
- my $clone_value = &test_eval (2, "itemcget", $clone, $option);
- if (defined $original_value && $original_value eq $clone_value) {
-# print "ORIGIN = ",$original_value, " $original_value CLONE = ",$clone_value,"\n";
- &log (-100, "Modified cloned $type gets the same value for $option (type $optionType) " .
- "(original=cloned: " . &printableItem($original_value) .
- "?=" . &printableItem($previous_val) .
- " :previous)\n");
- }
- }
-
- # setting back the previous value
- if ($valueRef eq '') {
- &test_eval (1, "itemconfigure", $clone, $option => $previous_val);
- }
- else {
- &test_eval (1, "itemconfigure", $clone, $option => \@previous_val);
- }
-
- }
-} # end test_a_clone
-
-sub test_every_attributes_once {
- my ($type, $item) = @_;
- my %theoptions = %{$options{$type}};
- foreach my $option (sort keys %theoptions) {
- next if ($option eq -numfields); # BUG? makes the appli stop
- next if ($option eq "-clip" and $type = "group"); # BUG? This test cannot be random. Clipping item must belong to the group
- next if ($option eq '-connecteditem'); ## XXX this test should be corrected implemented,
- my ($optionType, $readOnly, $empty, $optionValue) = @{$theoptions{$option}};
- my $value = $typesNonStandardValues{$optionType};
- if ($optionType ne 'boolean' && !defined $value) {
- &log (-100, "No value for type $optionType (option $option)\n");
- next;
- }
- # in the case of boolean, we must always take the not value:
- if ($optionType eq 'boolean') { $value = !$zinc->itemcget($item, $option) }
-
- my $log_lev = ($opt_trace eq $option || $opt_trace eq $optionType) ? 0 : 2 ;
- &test_eval ($log_lev, "itemconfigure", $item, $option => $value);
- $zinc->update;
- }
-} # end test_every_attributes_once
-
-
-sub test_every_field_attributes {
- &log (-1000, "#---- Start of test_every_field_attributes ----\n");
- foreach my $type qw(waypoint track tabular) {
- next unless $itemtypes{$type};
- my %theoptions = %fieldOptions;
- my @items = $zinc->find('withtype', $type);
- &log (0, "#--------- Testing field attributes of ", (1+$#items), " ",$type,"(s) ----------------\n");
- if ($#items == -1) {
- &log (-100, "No such item: $type\n");
- next;
- }
- foreach my $item (@items) {
- ## il faudrait tester les options selon un ordre défini à l'avance
- ## en passant par plusieurs occurences pour les options et en forçant
- ## certaines valeurs, par exemple les valeurs booléennees... (visible/sensible/filled)
- my @boolean_attributes;
- my %boolean_attributes;
- foreach my $option (sort keys %theoptions) {
- my ($optionType, $readOnly, $empty, $optionValue) = @{$theoptions{$option}};
- if ($optionType eq 'boolean') {
-# next if $option =~ /-\w+sensitive/ ; # to get rid of many track options!
-# next if $option =~ /-filled\w+/ ; # to get rid of many track options!
-# next if $option =~ /-speed\w+/ ; # to get rid of many track options!
-# next if $option =~ /-\w+history/ ; # to get rid of many track options!
- push @boolean_attributes, $option;
- $boolean_attributes{$option}=1;
- }
- }
- &log (0, "# $type (id $item) : ", ((2**(1+$#boolean_attributes)) , " Combinations (", join (', ' , @boolean_attributes),")\n"));
- foreach my $i (0 .. (2**(1+$#boolean_attributes) -1) ) {
- my $format = "%0" . ($#{boolean_attributes} +1) . "b";
- my $binary = sprintf ($format,$i);
- &log (0, "# $i/", (2**(1+$#boolean_attributes)), " $binary\n");
- my @binary = split (//,$binary);
- foreach my $j (0 .. $#boolean_attributes) {
- &log (0, "# setting $type ($item) field 0..",$zinc->itemcget($item, -numfields)-1, " ", $boolean_attributes[$j], " to ", $binary[$j], "\n");
- foreach my $field (0 .. $zinc->itemcget($item, -numfields)-1 ) {
- &test_eval (1, "itemconfigure", $item, $field, $boolean_attributes[$j] => $binary[$j] );
- }
- }
- foreach my $field (0 .. $zinc->itemcget($item, -numfields)-1 ) {
- foreach my $option (sort keys %theoptions) {
- next if ($boolean_attributes{$option}); # skipping boolean attributes which are exhaustively tested
-
- my ($optionType, $readOnly, $empty, $optionValue) = @{$theoptions{$option}};
-
- my $typeValues = $typesValues{$optionType};
- if (!defined $typeValues) {&log (-100, "No values for type $optionType (option $option)\n");next;}
- my @values = @{$typeValues};
-
- if (!@values) {&log (-100, "No values for type $optionType (option $option)\n");next;}
-
-
- my $valueRef = ref ($values[0]);
- my $previous_val;
- my @previous_val;
-
- if ($valueRef eq '') {
- $previous_val = &test_eval (1, "itemcget", $item, $field, $option);
- }
- else {
- @previous_val = &test_eval (1, "itemcget", $item, $field, $option);
- }
- &log (1, "#** itemconfigure ($item ($type), $field, $option => ",&printableList (@values),"\n");
- foreach my $value (@values) {
- my $log_lev = ($opt_trace eq $option || $opt_trace eq $optionType) ? 0 : 2 ;
- &test_eval ($log_lev, "itemconfigure", $item, $field, $option => $value);
- $zinc->update;
- $zinc->after(10);
- }
-
- if ($valueRef ne 'ARRAY') {
- &test_eval (1, "itemconfigure", $item, $field, $option => $previous_val);
- }
- else {
- &test_eval (1, "itemconfigure", $item, $field, $option => \@previous_val);
- }
-
- }}
- }
- }
- }
- &log (0, "#---- End of test_every_field_attributes ----\n");
-} # end test_every_field_attributes
-
-
-sub createMapInfo {
- my ($name, $N,$deltaN, $radius, $centerX,$centerY) = @_;
- &test_eval (1, "mapinfo", $name, 'create');
-
- my @lineTypes=(qw/simple dashed dotted mixed marked/),
- my $deltaAngle=6.283/$N;
- for (my $i = 0; $i < $N; $i++) {
- my $x1 = $centerX + $radius * sin($i * $deltaAngle);
- my $y1 = $centerY + $radius * cos($i * $deltaAngle);
- my $x2 = $centerX+ $radius * sin( ($i + $deltaN) * $deltaAngle);
- my $y2 = $centerY + $radius * cos( ($i + $deltaN)* $deltaAngle);
- my $linetype = $lineTypes[$i%5];
- $mw->mapinfo($name, 'add', 'line', $linetype, 1+$i%3, +$x1,$y1,$x2,$y2);
- }
-} # end of createMapInfo
-
-sub test_mapitems {
- my @mapinfoNames = @_;
- &log (-1000, "#---- Start of test_mapitems ----\n");
- my @maps = $zinc->find('withtype', 'map');
- my $counter=0;
- foreach my $map (@maps) {
- &test_eval (1, "itemconfigure", $map, -mapinfo => $mapinfoNames[$counter]);
- if ($counter == $#maps) { $counter=0 }
- $counter++;
- }
- &log (0, "#---- End of test_mapitems ----\n");
-} # end test_mapitems
-
-## testing the returned value of coords
-sub test_coords {
- &log (-1000, "#---- Start of test_coords ----\n");
- foreach my $it ($zinc->find('withtag','*')) {
- $zinc->remove($it);
- }
- ## creationg again items
- &creating_items;
- foreach my $type ($zinc->add()) {
- next if $type eq 'map'; ## map item does not support coords method
- my ($it) = $zinc->find('withtype',$type);
- my @coordsAll= &test_eval (1, "coords", $it);
- my $coordsAll = &printableArray(@coordsAll);
- &log (1, "=> $coordsAll\n");
- my @coordsContour= &test_eval (1, "coords", $it,0); # all items have 1 contour
- my $coordsContour = &printableArray(@coordsContour);
- &log (1,"=> $coordsContour\n");
- my @coordsPoint= &test_eval (1, "coords", $it,0,0); # all items have 1 contour with at least one point
- my $coordsPoint = &printableArray(@coordsPoint);
- &log (1,"=> $coordsPoint\n");
- }
- &log (0, "#---- End of test_coords ----\n");
-}
-
-sub parseTestsOpt {
- my ($opt) = @_;
- my @tests;
- if ($opt eq '') {
- print "Availables tests are:\n";
- while (@testsList) {
- my $i = shift @testsList;
- my $comment = shift @testsList;
- print "\t$i => $comment\n";
- }
- exit;
- } elsif ( $opt eq 'all' ) { ## default!
- &log (0, "# all tests will be passed through\n");
- @tests = sort keys %testsHash;
- } elsif ( $opt =~ /^\d+(,\d+)*$/ ) {
- @tests = split (/,/ , $opt);
- my $testnumb = (scalar @testsList) / 2;
- foreach my $test (@tests) {
- die "tests num must not exceed $testnumb" if $test > $testnumb;
- }
- &log(0, "# Tests to be done:\n");
- foreach my $test (@tests) {
- &log(0, "\t# $test => " . $testsHash{$test} . "\n");
- }
- } else {
- print "bad -tests value. Must be a list of integer separated by ,\n";
- &usage;
- }
- return @tests;
-} # end of parseTestsOpt
-
-
-
-# ---------- TEST ------------------
-# the following code must be coherent with the tests list described
-# on the very beginning of this file (see @testsList definition)
-
-&createMapInfo ('firstmap', 50, 20, 200, 200, 300);
-&createMapInfo ('secondmap', 12, 3, 200, 300, 50);
-
-sub theTest {
- if ($tests{1}) {
- &test_mapitems ('firstmap', 'secondmap'); # should be done before really testing map items attributes
- }
- # #### &test_labelcontent; # should be done before really testing track/waypoint/tabular items attributes
-
- if ($tests{2}) {
- &test_every_field_attributes;
- }
-
- if ($tests{3}) {
- &test_attributes; # on peut configurer tous les attributs
- }
-
- ### we SHOULD test that setting a bad type value ofr an option does not core dump zinc!
-
- if ($tests{4}) {
- &test_cloning; # we test that cloning items and modifiyng/removing them does not core dump
- }
-
- ### we should also test multicontour curves
- if ($tests{5}) {
- &test_coords;
- }
-
-# #### &test_fonts; ## and specially big fonts with render = 1;
-# #### &test_path_tags;
-# #### &test_illegal_tags;
-
-# #### &test_illegal_call
-# for example:
-# calling a method for an non-existing item
-# getting coords, contours, fields, etc... of non-existing index
-#
-# cloning, deleting topgroup
-#
-}
-
-sub getMemoryUsage {
- open (PROC, "/proc/$$/status");
- my ($totalMemory,$dataMemory);
- while (<PROC>) {
- if (/^VmSize:\s+(\d+)/) {
- $totalMemory = $1;
- }
- elsif (/^VmData:\s+(\d+)/) {
- $dataMemory = $1;
- last;
- }
- }
- close PROC;
- return ($totalMemory,$dataMemory);
-}
-
-
-
-if ($opt_memoryleak) {
- my $iteration = 0;
- while (1) {
- my ($total,$data) = &getMemoryUsage;
- ## get here the current memory state
- &log(-1000, "#---- MemoryState iteration=$iteration totalMemory=$total dataMemory=$data ----\n");
- $iteration++;
- &theTest;
- }
-} else {
- &theTest;
-}
-
-
-&log (0, "#---- End of test_no_crash ----\n");
-
-MainLoop();
diff --git a/Perl/t/testdoc.pl b/Perl/t/testdoc.pl
deleted file mode 100644
index 590774f..0000000
--- a/Perl/t/testdoc.pl
+++ /dev/null
@@ -1,274 +0,0 @@
-#!/usr/bin/perl -w
-# $Id$
-# This script verifies the conformity of the reference manual with
-# some types informations available inside ZincTk
-# It has been developped by C. Mertz <mertz@cena.fr>
-
-# limitations: this script makes some very strong assumptions
-# on the latex Zinc reference manual formating!
-# However if the formating changes, it should be
-# simple to modify the &scanDoc function!
-#
-# What this script currently does:
-# - verifies that all Zinc options are documented
-# - verifies that all items attributes (and their type) are documented
-# - verifies that all field attributes options (and their type) are documented
-# - verifies that all documented options and attributes really exists
-# - verifies that all documented types are refered to in the doc
-# It also checks that options, attributes and types are documented in alphabetical order
-# It is heavily based on meta information available directly from zinc
-#
-# How to use it:
-# testdoc.pl path_to_refman.tex
-
-use Tk;
-use Tk::Zinc;
-
-use strict;
-
-print "------- Testing conformity of refman.tex and meta-information from zinc Version $Tk::Zinc::VERSION\n";
-
-my $mw = MainWindow->new();
-
-# Creating the zinc widget
-# NB: this widget will not be displayed! It is only used for creating items
-# and getting some internal information about attributes/options and types.
-
-my $zinc = $mw->Zinc(-width => 1, -height => 1,);
-
-# 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, 1);
-}
-
-# 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]);
-}
-
-
-my %zinc2doc; # a hash recording every discrepency between attribute/option
- # type between the doc and TkZinc
-my %documentedOptions;
-my %itemAttributeDoc;
-my %documentedTypes;
-my %usedTypes; # hash recording all refered types in the doc
-
-die "missing refman.tex path_name as unique argument to this script" unless defined $ARGV[0];
-
-
-&scanDoc ($ARGV[0]);
-
-sub scanDoc {
- my ($filename) = @_;
- open (DOC, $filename) or die "unable to open " . $filename . "\n";
- my $current_item = 0;
- my $prev_attribute = 0;
- my $prev_type = 0;
-
- while (<DOC>) {
- if ( /^\\attribute\{(\w+)\}\{(\w+)\}\{(\w+)\}/ ) {
- my $item = $1;
- my $attribute = $2;
- my $type = $3;
- $itemAttributeDoc{$item}{-$attribute} = $type;
- if ($item eq $current_item) {
- if ($attribute lt $prev_attribute) {
- print "W: attributes $prev_attribute and $attribute are not in alphabetical order for $item\n";
- }
- }
- else {
- $current_item = $item;
- $prev_attribute = $attribute;
- }
- }
- elsif ( /^\\option\{(\w+)\}\{(\w+)\}\{(\w+)\}/ ) {
- my $optionName = $1;
- my $databaseName = $2;
- my $databaseClass = $3;
- $documentedOptions{-$optionName} = $databaseClass;
- }
- elsif ( /^\\attrtype\{(\w+)\}/ ) {
- my $type = $1;
- $documentedTypes{$type} = $type;
- if ($type lt $prev_type) {
- print "W: type $prev_type and $type are not in alphabetical order\n";
- }
- $prev_type = $type;
- }
- }
-}
-
-sub testAllOptions {
- my @options = $zinc->configure();
- my %options;
- # we use this hashtable to check that all documented options
- # are matching all existing options in TkZinc
-
- for my $elem (@options) {
- my ($optionName, $optionDatabaseName, $optionClass, $default, $optionValue) = @$elem;
- $options{$optionName} = [$optionClass, $default, "", $optionValue];
- }
-
- foreach my $optionName (sort keys %options) {
- my ($optionType, $readOnly, $empty, $optionValue) = @{$options{$optionName}};
- # $empty is for provision by Zinc
-
- if (!defined $documentedOptions{$optionName}) {
- print "E: $optionName ($optionType) of Zinc IS NOT DOCUMENTED!\n";
- $options{$optionName} = undef;
- next;
- }
- if ($documentedOptions{$optionName} ne $optionType) {
- print "W: $optionName has type $optionType inside ZincTk and type $documentedOptions{$optionName} inside Doc\n";
- $zinc2doc{$optionType}=$documentedOptions{$optionName};
- }
-# $attributes{$attributeName} = undef;
- $documentedOptions{$optionName} = undef;
- }
-
- foreach my $unexistingDocOpt (sort keys %documentedOptions) {
- if (defined $documentedOptions{$unexistingDocOpt}) {
- print "E: The Documented Option \"$unexistingDocOpt\" DOES NOT EXIST!\n";
- }
- }
-}
-
-sub testAllAttributes {
- my ($item) = @_;
-
- my %documentedAttributes = %{$itemAttributeDoc{$item}};
- my @attributes = $zinc->itemconfigure($itemtypes{$item});
-
- my %attributes;
- # we use this hashtable to check that all documented attributes
- # are matching all existing attributes in TkZinc
-
- # verifying that all referenced types are defined
- # and storing used types
- foreach my $attribute (sort keys %documentedAttributes) {
- my $type = $documentedAttributes{$attribute};
- $usedTypes{$type} = 1;
- print "E: type $type ($attribute of $item) is not documented\n" unless $documentedTypes{$type};
- }
-
- foreach my $elem (@attributes) {
- my ($attributeName, $attributeType, $readOnly, $empty, $attributeValue) = @$elem;
- $attributes{$attributeName} = [$attributeType, $readOnly, $empty, $attributeValue];
- }
-
- foreach my $attributeName (keys %attributes) {
- my ($attributeType, $readOnly, $empty, $attributeValue) = @{$attributes{$attributeName}};
- # $empty is for provision by Zinc
-
- if (!defined $documentedAttributes{$attributeName}) {
- print "E: $attributeName ($attributeType) of item $item IS NOT DOCUMENTED!\n";
- $attributes{$attributeName} = undef;
- next;
- }
-
- if ($documentedAttributes{$attributeName} ne $attributeType) {
- print "W: $attributeName has type $attributeType inside ZincTk and type $documentedAttributes{$attributeName} inside Doc\n";
- $zinc2doc{$attributeType}=$documentedAttributes{$attributeName};
- }
-# $attributes{$attributeName} = undef;
- $documentedAttributes{$attributeName} = undef;
- }
-
- foreach my $unexistingDocAttr (sort keys %documentedAttributes) {
- if (defined $documentedAttributes{$unexistingDocAttr}) {
- print "E: The Documented Attribute \"$unexistingDocAttr\" DOES NOT EXIST!\n";
- }
- }
-}
-
-
-sub testFieldAttributes {
- my %documentedAttributes = %{$itemAttributeDoc{"field"}};
- my @attributes = $zinc->itemconfigure($itemtypes{track},0);
-
- my %attributes;
- # we use this hashtable to check that all documented fields attributes
- # are matching all existing fields attributes in TkZinc
-
- # verifying that all referenced types are defined
- # and storing used types
- foreach my $attribute (sort keys %documentedAttributes) {
- my $type = $documentedAttributes{$attribute};
- $usedTypes{$type} = 1;
- print "E: type $type ($attribute of 'field') is not documented\n" unless $documentedTypes{$type};
- }
-
-
- foreach my $elem (@attributes) {
- my ($attributeName, $attributeType, $readOnly, $empty, $attributeValue) = @$elem;
- $attributes{$attributeName} = [$attributeType, $readOnly, $empty, $attributeValue];
- }
-
- foreach my $attributeName (keys %attributes) {
- my ($attributeType, $readOnly, $empty, $attributeValue) = @{$attributes{$attributeName}};
- # $empty is for provision by Zinc
-
- if (!defined $documentedAttributes{$attributeName}) {
- print "E: $attributeName ($attributeType) of field IS NOT DOCUMENTED!\n";
- $attributes{$attributeName} = undef;
- next;
- }
-
- if ($documentedAttributes{$attributeName} ne $attributeType) {
- print "W: $attributeName of field has type $attributeType inside ZincTk and type $documentedAttributes{$attributeName} inside Doc\n";
- $zinc2doc{$attributeType}=$documentedAttributes{$attributeName};
- }
- $documentedAttributes{$attributeName} = undef;
- }
-
- foreach my $unexistingDocAttr (sort keys %documentedAttributes) {
- if (defined $documentedAttributes{$unexistingDocAttr}) {
- print "E: The Documented Field Attribute \"$unexistingDocAttr\" DOES NOT EXIST!\n";
- }
- }
-}
-
-sub verifyingAllDefinedTypesAreUsed {
- foreach my $type (sort keys %documentedTypes) {
- print "W: documented type $type is never refered to in the doc\n" unless $usedTypes{$type};
- }
-}
-
-print "--- TkZinc Options -----------------------------------------\n";
-&testAllOptions;
-print "--- Field Attributes ---------------------------------------\n";
-
-&testFieldAttributes;
-
-foreach my $type (sort keys %itemtypes) {
- print "--- Item $type -------------------------------------------------\n";
- &testAllAttributes($type);
-}
-
-&verifyingAllDefinedTypesAreUsed;
-
-print "------- Summary of type discrepencies between Doc and Zinc --------\n";
-printf "%15s |%15s\n", "zinctype","doctype";
-foreach my $typezinc (sort keys %zinc2doc) {
- printf "%15s |%15s\n", $typezinc,$zinc2doc{$typezinc};
-}
-
-
-# MainLoop();
-
-
-1;
diff --git a/Perl/t/text.t b/Perl/t/text.t
deleted file mode 100644
index b8893db..0000000
--- a/Perl/t/text.t
+++ /dev/null
@@ -1,161 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: text.t,v 1.6 2004-05-07 13:53:00 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing text item
-
-# this script can be used with an optionnal argument, an integer giving
-# the delay in seconds during which the graphic updates will be displayed
-# this is usefull for visual inspection!
-
-my $mw;
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 69;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc;
- 1;
- }) {
- print "unable to load Tk::Zinc";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- $mw = MainWindow->new();
- 1;
- }) {
- print "# tests only work properly when it is possible to create a mainwindow in your env\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-use strict;
-
-my $zinc = $mw->Zinc(-render => 1,
- -width => 400, -height => 1200)->pack;
-
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc has been created");
-
-
-my $g1 = $zinc->add('group',1, -tags => "gr1");
-
-
-my $TEXT = "";
-
-my @families = $mw->fontFamilies;
-#print "families=@families\n";
-
-my $family="";
-if ( grep /^verdana$/i , @families) {
- $family = "verdana";
-# $family = "helvetica";
-} elsif ( grep /^helvetica$/i , @families) {
- $family = "helvetica";
-} elsif ( grep /^arial$/i , @families) {
- $family = "arial";
-}
-#print "family=$family\n";
-
-my $topLevel = $mw->Toplevel();
-$topLevel->title("testing all ascii glyphs of $family");
-
-my $zinc0 = $topLevel->Zinc(-render => 1,
- -width => 300,
- -height => 400,)->pack;
-like ($zinc, qr/^Tk::Zinc=HASH/ , "zinc0 has been created");
-
-$zinc0->fontCreate("fonta", -family => $family, -size => -20, -weight => 'normal');
-
-
-foreach my $row (2..15) {
- my $string = "";
- foreach my $col (0..15) {
- $string .= chr($row*16+$col);
- }
- $zinc0->add('text', 1, -position => [10,$row*20-40],
- -text => $string, -font => 'fonta');
- $zinc0->update;
- &pass("adding text item n°$row with a $family font of size 20 and normal weight");
-}
-
-
-### creating text items with many different fonts:
-
-my $size = 8;
-my $y = 10 ;
-
-$zinc->fontCreate("font$size", -family => $family, -size => -$size, -weight => 'normal');
-
-
-### creating text items with many different fonts:
-$zinc->add('text', $g1, -position => [10,$y], -tags => ["txt$size"], -font => "font$size",
- -text => "$size pixels $family");
-$zinc->remove('txt8');
-$zinc->fontDelete("font$size");
-$zinc->fontCreate("font$size", -family => $family, -size => -$size, -weight => 'normal');
-$zinc->add('text', $g1, -position => [10,$y], -tags => ["txt$size"], -font => "font$size",
- -text => "$size pixels $family");
-
-
-
-
-
-foreach my $size (9..60) {
- $zinc->fontCreate("font$size", -family => $family, -size => -$size, -weight => 'normal');
- $zinc->add('text', $g1, -position => [10,$y], -tags => ["txt$size"], -font => "font$size",
- -text => "$size pixels $family");
- $zinc->update;
-
- # deleting both the font and the text item and recreating it 10 times
- foreach my $count (1..10) {
- $zinc->fontDelete("font$size");
- $zinc->remove('txt8');
- $zinc->fontCreate("font$size", -family => $family, -size => -$size, -weight => 'normal');
- $zinc->add('text', $g1, -position => [10,$y], -tags => ["txt$size"], -font => "font$size",
- -text => "$size pixels $family");
- $zinc->update;
- }
- &pass("creating and deleting 10 times a text item with a $family font of size $size");
- $y += $size;
-}
-
-
-&wait;
-
-## we should certainly test much much other things!
-
-
-
-sub wait {
- $zinc->update;
- ok (1, $_[0]);
-
- my $delay = $ARGV[0];
- if (defined $delay) {
- $zinc->update;
- if ($delay =~ /^\d+$/) {
- sleep $delay;
- } else {
- sleep 1;
- }
- }
-
-}
-
-
-
-diag("############## end of text test");
diff --git a/Perl/t/traceutils.t b/Perl/t/traceutils.t
deleted file mode 100644
index 0636037..0000000
--- a/Perl/t/traceutils.t
+++ /dev/null
@@ -1,89 +0,0 @@
-#!/usr/bin/perl -w
-
-#
-# $Id: traceutils.t,v 1.2 2004-05-07 16:53:43 mertz Exp $
-# Author: Christophe Mertz
-#
-
-# testing Tk::Zinc::TraceUtils utilities
-
-#use Tk::Zinc::TraceUtils;
-use strict;
-
-BEGIN {
- if (!eval q{
-# use Test::More qw(no_plan);
- use Test::More tests => 14;
- 1;
- }) {
- print "# tests only work properly with installed Test::More module\n";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
- if (!eval q{
- use Tk::Zinc::TraceUtils;
- 1;
- }) {
- print "unable to load Tk::Zinc::TraceUtils";
- print "1..1\n";
- print "ok 1\n";
- exit;
- }
-}
-
-
-
-#### creating different images, bitmaps and pixmaps...
-
-my $arg;
-
-$arg = "1";
-is (&Item ($arg), $arg, "testing " . $arg);
-
-SKIP: {
- my $mw;
- skip "not able to create a MainWindow", 3 if !eval q{$mw = MainWindow->new()} ;
- require Tk::Font;
- my $font = $mw->fontCreate("testfont", -family => "Helvetica");
-
- like ($font, qr/^testfont/, "font creation");
- is (&Item ($font), "'testfont'", "testing " . "testfont"); # not so sure about this result!
- is (&List (-font => $font), "(-font => 'testfont')", "(-font => afont)");
-}
-
-$arg = "()";
-is (&List (eval $arg), $arg, "empty list: ". $arg);
-
-$arg = "(-option_without_value)";
-is (&List (eval $arg), $arg, $arg);
-
-$arg = "(1, 2, 3, 4)";
-is (&List (eval $arg), $arg, $arg);
-
-$arg = "(-1, -2, -3, -4)";
-is (&List (eval $arg), $arg, $arg);
-
-$arg = "(1.2, -2, .01, -1.2e+22, 1.02e+34)";
-
-is (&List (eval $arg), ($arg =~ s/\.01/0.01/ , $arg ), $arg);
-
-$arg = "('-1aa' => -2, '-a b', -1.2)";
-is (&List (eval $arg), $arg, $arg);
-
-$arg = "(-option => -2, -option2 => -1.2, -option3)";
-is (&List (eval $arg), $arg, $arg);
-
-$arg = "('icon', 1, -priority => 210, -visible => 1)";
-is (&List (eval $arg), $arg, $arg);
-
-$arg = "('text', 1, -font => '-adobe-helvetica-bold-r-normal-*-120-*-*-*-*-*-*')";
-is (&List (eval $arg), $arg, $arg);
-
-
-$arg = "-option, -2, -option2, -1.2, -option3";
-is (&Array (eval "(".$arg.")"), "[".$arg."]", "[".$arg."]");
-
-
-
-diag("############## Tk::Zinc::TraceUtils test");
diff --git a/Python/library/Zinc.py.in b/Python/library/Zinc.py.in
deleted file mode 100644
index f26af6a..0000000
--- a/Python/library/Zinc.py.in
+++ /dev/null
@@ -1,452 +0,0 @@
-#
-# Zinc.py -- Python interface to the tkzinc widget.
-#
-# Authors : Frederic Lepied, Patrick Lecoanet
-# Created Date : Thu Jul 22 09:36:04 1999
-#
-# $Id$
-#
-#
-# Copyright (c) 1999 CENA --
-#
-# This code is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Library General Public
-# License as published by the Free Software Foundation; either
-# version 2 of the License, or (at your option) any later version.
-#
-# This code is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Library General Public License for more details.
-#
-# You should have received a copy of the GNU Library General Public
-# License along with this code; if not, write to the Free
-# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#
-#
-
-__version__ = "$Revision$"
-
-import string, types
-from Tkinter import *
-from Tkinter import _cnfmerge, _flatten
-import traceback
-
-ZINC_NO_PART=-1
-ZINC_CURRENT_POSITION=-2
-ZINC_SPEED_VECTOR=-3
-ZINC_LEADER=-4
-ZINC_CONNECTION=-5
-
-# current part dictionnary
-ZINC_DPART = { 'position' : ZINC_CURRENT_POSITION,
- 'speedvector' : ZINC_SPEED_VECTOR ,
- 'leader' : ZINC_LEADER,
- 'connection' : ZINC_CONNECTION}
-# notes : 'field' will be return when currentpart is a field
-
-def havetkzinc(window):
- '''load Zinc dynamic sharable object library , test if everything is ok
-if ok :return zinc version
-if nok : return 0 '''
- try:
- window.tk.call('load', '@Tkzinc_LIB_FILE@')
- # Call a function from the package to autoload it
- # and verify that all is OK.
- sversion = window.tk.call('zinc') + " Zinc.py %s" % __version__
- except TclError:
- traceback.print_exc()
- return 0
- return sversion
-
-class Zinc(Widget):
- def __str__(self):
- return("Zinc instance")
- def __init__(self, master=None, cnf={}, **kw):
- Widget.__init__(self, master, 'zinc', cnf, kw)
- self.items = {}
-
- def add(self, itemType, *args, **kw):
-# if len(args) != 0:
-# cnf = args[-1]
-# else:
-# cnf={}
-# if type(cnf) in (DictionaryType, TupleType):
-# args = args[:-1]
-# else:
-# cnf = {}
- #args = _flatten(args)
- args=list(args)
- args=args+list(self._options(kw))
- return self.tk.getint(
- self.tk.call(self._w, 'add', itemType,*args))
-
- def addtag(self, *args):
- self._do('addtag', args)
-
- def addtag_above(self, newtag, tagOrId):
- self.addtag(newtag, 'above', tagOrId)
-
- def addtag_all(self, newtag):
- self.addtag(newtag, 'all')
-
- def addtag_atpoint(self, newtag, x, y, halo=None, start=None):
- self.addtag(newtag, 'atpoint', x, y, halo, start)
-
- def addtag_atpriority(self, newtag, pri):
- self.addtag(newtag, 'atpriority', pri)
-
- def addtag_below(self, newtag, tagOrId):
- self.addtag(newtag, 'below', tagOrId)
-
- def addtag_enclosed(self, newtag, x1, y1, x2, y2):
- self.addtag(newtag, 'enclosed', x1, y1, x2, y2)
-
- def addtag_overlapping(self, newtag, x1, y1, x2, y2):
- self.addtag(newtag, 'overlapping', x1, y1, x2, y2)
-
- def addtag_withtag(self, newtag, tagOrId):
- self.addtag(newtag, 'withtag', tagOrId)
-
- def addtag_withtype(self, newtag, type):
- self.addtag(newtag, 'withtype', type)
-
- def anchorxy(self, *args):
- self._do('anchorxy', args)
-
- def bbox(self, *args):
- self._do('bbox', args)
-
- def becomes(self, *args):
- self._do('becomes', args)
-
-# def bind(self):
-# pass
-
- def bind_tag(self, tagOrId, sequence=None, func=None, add=None):
- '''return a funcid which can be usefull for unbinding'''
- return self._bind((self._w, 'bind', tagOrId),
- sequence, func, add)
-
-# def cget(self):
-# pass
-
- def chggroup(self, *args):
- self._do('chggroup', args)
-
- def clone(self, *args):
- self._do('clone', args)
-
-# def configure(self):
-# pass
-
- def coords(self, *args):
- self._do('coords', args)
-
- def currentpart(self):
- '''return a string (result from zinc current part function) and an
-integer representing either the number of the field either the number of the
-item part either ZINC_NO_PART'''
- scurrentp = self._do('currentpart')
- if scurrentp == "":
- rvalue = ZINC_NO_PART
- else:
- try:
- rvalue = string.atoi(scurrentp)
- except:
- try:
- rvalue = ZINC_DPART[scurrentp]
- except:
- rvalue = ZINC_NO_PART
- else:
- # string to integer succeeded
- scurrentp = "field"
- return(scurrentp,rvalue)
-
- def dtag(self, *args):
- self._do('dtag', args)
-
- def find(self, *args):
- return self._getints(self._do('find', args)) or ()
-
- def find_above(self, tagOrId):
- return self.find('above', tagOrId)
-
- def find_all(self):
- return self.find('all')
-
- def find_atpoint(self, x, y, halo=None, start=None):
- return self.find('atpoint', x, y, halo, start)
-
- def find_atpriority(self, pri):
- return self.find('atpriority', pri)
-
- def find_below(self, tagOrId):
- return self.find('below', tagOrId)
-
- def find_enclosed(self, x1, y1, x2, y2):
- return self.find('enclosed', x1, y1, x2, y2)
-
- def find_overlapping(self, x1, y1, x2, y2):
- return self.find('overlapping', x1, y1, x2, y2)
-
- def find_withtag(self, tagOrId):
- return self.find('withtag', tagOrId)
-
- def find_withtype(self, type):
- return self.find('withtag', type)
-
- def gettags(self, *args):
- return self.tk.splitlist(self._do('gettags', args))
-
- def group(self, *args):
- self._do('group', args)
-
- def hasanchors(self, *args):
- self._do('hasanchors', args)
-
- def hasfields(self, *args):
- self._do('hasanchors', args)
-
- def hasparts(self, *args):
- self._do('hasanchors', args)
-
-# def hastag(self):
-# pass
-
- def itemcget(self, tagOrId, option):
- return self._do('itemcget', (tagOrId, '-'+option))
-
- def itemfieldcget(self, tagOrId, field, option):
- return self._do('itemcget', (tagOrId, field, '-'+option))
-
- def itemconfigure(self, tagOrId, field=None, **kw):
- '''either get the dictionnary of possible attributes (if kw is None)
-either allow to set Items attributes or Field attributes '''
- if not kw:
- cnf = {}
- for x in self.tk.split(
- field != None and self._do('itemconfigure', (tagOrId, field)) or
- self._do('itemconfigure', (tagOrId,))):
- cnf[x[0][1:]] = (x[0][1:],) + x[1:]
- return cnf
- if field != None:
- self._do('itemconfigure', (tagOrId, str(field),)
- + self._options({}, kw))
- else:
- self._do('itemconfigure', (tagOrId,) + self._options({},kw))
-
- # _dp voir si cette instruction est a execute ici
- # permet de creer un synonyme de itemconfigure
- itemconfig = itemconfigure
-
- def loweritem(self, *args):
- self._do('lower', args)
-
- def monitor(self, *args):
- self._do('monitor', args)
-
- def raiseitem(self, *args):
- self._do('raise', args)
-
- def remove(self, *args):
- self._do('remove', args)
-
- def rotate(self, *args):
- self._do('rotate', args)
-
- def scale(self, xFactor=None, yFactor=None, tagOrId=None):
- if yFactor == None:
- return self.tk.getdouble(self._do('scale'))
- else:
- if tagOrId == None:
- self._do('scale', (xFactor, yFactor))
- else:
- self._do('scale', (tagOrId, xFactor, yFactor))
-
- def tdelete(self, *args):
- self._do('tdelete', args)
-
- def transform(self, *args):
- # self._getints(self._do('transform', args))
- return self._getdoubles(self._do('transform', args))
-
- def translate(self, dx=None, dy=None, tagOrId=None):
- if dx == None:
- return self._getints(self._do('translate'))
- else:
- if tagOrId == None:
- self._do('translate', (dx, dy))
- else:
- self._do('translate', (tagOrId, dx, dy))
-
- def treset(self, *args):
- self._do('treset', args)
-
- def trestore(self, *args):
- self._do('trestore', args)
-
- def tsave(self, *args):
- self._do('tsave', args)
-
- def type(self, tagOrId):
- return self._do('type', (tagOrId,))
-
-
-class ZincItem:
- def __init__(self, zinc, itemType, *args, **kw):
- self.zinc = zinc
- self.id = zinc.add(itemType, *args, **kw)
- zinc.items[self.id] = self
-
- def __str__(self):
- return str(self.id)
-
- def __repr__(self):
- return str(self.id)
-
- def delete(self):
- del self.zinc.items[self.id]
- try:
- self.zinc.remove(self.id)
- except:
- pass
- def __getitem__(self, key):
- '''allow to get attribute by self["key"] '''
- if ( key == "coords" ):
- return self.zinc.coords()
- return self.zinc.itemcget(self.id, key)
-
- def __setitem__(self, key, value):
- '''allow to set item attrbutes, eg. for a track position attributes
-just writing :
-a = ZincItem(myzinc, ...)
-a["position"] = (x,y)
-Notes : when setting multiple attributes using itemconfigure is more efficient '''
- if ( key is "coords" ):
- self.zinc.coords(self.id,value)
- else:
- self.zinc.itemconfigure(self.id, **{key:value})
-
- def keys(self):
- if not hasattr(self, '_keys'):
- self._keys = {}
- config=self.zinc.itemconfig(self.id)
- for x in config.keys():
- self._keys[x] = config[x][1]
- return self._keys
-
- def has_key(self, key):
- return key in self.keys()
-
- def bind(self, sequence=None, command=None, add=None):
- '''return a funcid which can be used to unbind
-notes: unbinding can be done by bind("<seq>","") or using native tkinter
-unbind method '''
- return(self.zinc.bind_tag(self.id, sequence, command, add))
-
- def cget(self, attr):
- return self.zinc.itemcget(self.id, attr)
-
- def fieldcget(self, field, attr):
- return self.zinc.itemfieldcget(self.id, field, attr)
-
- def itemconfigure(self, field=None, **kw):
- self.zinc.itemconfigure(self, field,**kw)
-
- def rotate(self, factor):
- return self.zinc.rotate(factor,self.id)
-
- def scale(self, xFactor=None, yFactor=None):
- return self.zinc.scale(xFactor, yFactor,self.id)
-
- def translate(self, dx=None, dy=None):
- self.zinc.translate(self.id,dx,dy)
-
-class Arc(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'arc', *args, **kw)
-
-class Group(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'group', *args, **kw)
-
-class Icon(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'icon', *args, **kw)
-
-class Map(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'map', *args, **kw)
-
-class Curve(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'curve', *args, **kw)
-
-class Rectangle(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'rectangle', *args, **kw)
-
-class Reticle(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'reticle', *args, **kw)
-
-class Tabular(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'tabular', *args, **kw)
-
-class Text(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'text', *args, **kw)
-
-class Track(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'track', *args, **kw)
-
-class WayPoint(ZincItem):
- def __init__(self, zinc, *args, **kw):
- ZincItem.__init__(self, zinc, 'waypoint', *args, **kw)
-
-
-# Class to hold mapinfos used by the Map Item class
-class Mapinfo:
- def __init__(self, interp, *args):
- self.interp=interp.tk
- apply(self.interp.call, ('mapinfo', self, 'create'))
-
- def __repr__(self):
- return `id(self)`
-
- def add_text(self, text_style, line_style, x, y, text):
- self.interp.call('mapinfo', self, 'add', 'text', text_style,
- line_style, x, y, text)
-
- def add_line(self, line_style, width, x1, y1, x2, y2):
- self.interp.call('mapinfo', self, 'add', 'line', line_style,
- width, x1, y1, x2, y2)
-
- def add_arc(self, line_style, width, cx, cy, radius, start, extent):
- self.interp.call('mapinfo', self, 'add', 'arc', line_style,
- width, cx, cy, radius, start, extent)
-
- def scale(self, factor):
- self.interp.call('mapinfo', self, 'scale', factor)
-
- def translate(self, xAmount, yAmount):
- self.interp.call('mapinfo', self, 'translate', xAmount, yAmount)
-
-class Videomap (Mapinfo):
- def __init__(self, tk, *args):
- self.tk=tk.tk
- args=args + (self,)
- self.tk.call('videomap', 'load', *args )
-
-# ---- self-test ----------------------------------------------------------
-if __name__ == '__main__':
- from Tkinter import *
- tk = Tk()
- zincversion = havetkzinc(tk)
- if zincversion :
- print "Zinc version [%s] seems ok." % zincversion
-
-# Zinc.py ends here
diff --git a/README b/README
deleted file mode 100644
index b88892a..0000000
--- a/README
+++ /dev/null
@@ -1,294 +0,0 @@
-$Id$
-
-
-
-
- *===========================================*
- The TkZinc widget version 3.3
- *===========================================*
-
-
-WHAT IS THIS?
-
- TkZinc is a canvas like widget extension to Tcl/Tk. It adds
-support for ATC displays, provides structured assembly of
-items, transformations, clipping, and openGL based rendering
-features such as gradients and alpha blending.
-
- It is currently available on Unices (tested on Linux),
-Windows and Mac OSX (with X11 and fink).
-
-
-WHERE DOES IT COME FROM?
-
- The newest version is found at: http://www.tkzinc.org/
- It should be at least available in source form in a file
- named Tkzinc<version>.tgz.
- Distribution specific packages may also be available for
- Debian/Mandrake/Red Hat distributions, most likely for stable
- versions.
-
- For Tcl/Tk users, TkZinc is also available as a multi-plateforme
- (linux/windows) starkit on http://www.tkzinc.org/
- For Perl/Tk users, TkZinc is available on the CPAN, see for example
- on http://search.cpan.org/search?query=TkZinc&mode=all
-
- As a convenience the documentation (pdf+html) is made available
- on the web site as a separate package.
-
-
-BUILDING AND INSTALLATION FOR TCL/TK
-
-
-0. You need a working Tcl/Tk distribution (version >= 8.4). You can either grab
- it using your regular package manager, or build it and install it from scratch.
-
- On a Linux system, you need tcl tcl-dev tk tk-dev packages.
-
- On MacOSX you need:
- - fink with tcltk and tcltk-dev package (http://fink.sf.net)
- - tcl/tk sources, though you are _not_ required to compile and install them.
- tcl/tk sources are needed because some required files are missing in the packages (tclInt.h and tkInt.h,
- if you know how to get those files with fink, submit a suggestion to the maintainers).
- I couldn't install them using fink, d/l them instead:
- http://prdownloads.sourceforge.net/fink/direct_download/source
- - X11 et X11 sdk from Apple (http://www.apple.com/macosx/x11/)
-
- From sources or on Windows, get, build and _install_ the Tcl/Tk distribution.
- On Windows there is currently an incompatibility when using a TkZinc compiled under mingw32 with
- a core Tcl/Tk compiled with visual C++. You need to grab a Tcl/Tk
- compiled with the same environment as TkZinc.
-
-
-1. Unpack the distribution
-
- On Unix/Linux/MacOSX:
-
- tar zxf Tkzinc<version>.tgz
-
- On Windows:
-
- Use WinZip or something similar to unpack
-
- This creates a directory Tkzinc<version> with all the
- needed files. This directory should be in the same
- directory as the Tcl/Tk sources.
-
-
-2. Configure
-
- On Unix/Linux:
-
- cd Tkzinc<version>
- ./configure <option>*
-
- This will configure the package for your platform. It
- will install it in /usr/local. If you want it elsewhere
- you can use the --prefix and --exec-prefix options of
- configure to assign another location.
-
- On MacOSX:
-
- say we have unpacked tlc/tk sources in $HOME/src. The configure
- line is as follows:
- env "CPPFLAGS=-I/sw/include -I$HOME/src/tcl8.4.1/generic -I$HOME/src/tk8.4.1/generic" ./configure --with-tcl=/sw/lib --with-tk=/sw/lib --enable-gl=damage
-
- On Windows:
-
- TkZinc has been built using the msys/mingw32 environment.
- It is known to work with Tcl/Tk 8.4.2 compiled using the
- same environment. CAUTION: It doesn't work with Tcl/Tk 8.4.1
- using mingw32.
- The steps for building under mingw32 are the same as on Unices.
- Currently there is no support for building with visual C++.
-
- On all platforms:
-
- It is possible to customize TkZinc through configure options:
-
- --enable-gl=[yes|no|damage]
- --disable-gl
-
- This is turned off by default. Building with --enable-gl=damage
- is the recommanded way for openGL support.
-
- --enable-om=[yes|no]
- --disable-om
-
- This is turned on by default. It controls the inclusion of
- code for avoid overlap between track labels in radar images.
-
- --enable-shape=[yes|no]
- --disable-shape
-
- This is turned on by default except on Windows where support
- code is not currently available (it may become available).
- It allows for non rectangular TkZinc windows optionally including
- the top level window.
-
- And the Tcl standards:
-
- --enable-threads=[yes|no]
- --disable-threads
-
- Compile a thread aware/thread safe version (not tested in multi
- threaded environment). Needed if Tcl/Tk has been compiled with
- the same configure option.
-
- --enable-symbols=[yes|no|mem|all]
- --disable-symbols
-
- Turn on debugging symbols. If the form --enable-symbols=mem is
- used, turn on memory debugging as well.
-
-
-3. Make and Install
-
- For use with Tcl on Unix/Linux and Windows using mingw32:
-
- make
- make install-tcl
-
- It is recommended to do a make distclean before actual building if you
- have done a previous build.
-
- The warnings while compiling libtess are harmless (or so I believe ;-).
- libtess is a tesselation library extracted from GLU/Mesa. I trust it as
- robust unless proven wrong. I do not want to modify the code just to
- shut up some warnings.
-
-
- For use with Tcl on Windows using Visual C++:
-
- nmake /F win/makefile.vc
-
- There is no install target. You are left with the dlls and the start of
- pkgIndex.tcl (it lacks the entries for the Tcl modules in library).
- It is needed to compile with Visual C++ if TkZinc is to be used with a
- Tcl/Tk compiled with Visual C++.
-
- P.S: If a pkgIndex.tcl for Tkzinc exists in the autoload path before
- installing, it will interfere with the generation of the new pkgIndex.tcl.
- It should be removed or renamed. echo 'puts $auto_path' | tclsh will
- tell the current load path.
-
- WATCH OUT! On Linux it is quite frequent to have both Mesa and proprietary
- openGL libraries installed. This may lead to big problems at
- runtime if the linker picks the wrong library. It is often the
- case between the static (libGL.a) Mesa library and the dynamic
- (libGL.so) NVidia library. It is very important to assert that
- the link is done with the library matching the openGL driver
- loaded in the X server.
-
-4. Run the demos
-
- In the Tkzinc<version> directory run:
-
- wish8.4 demos/zinc-widget
-
- Under windows do:
-
- wish84 demos/zinc-widget
-
- It should start a Tk like 'widget' demo showing TkZinc
- features. You can also run the demo with: demos/zinc-widget
- if you have in the PATH a wish that is greater or equal to
- 8.4.2.
-
-
-BUILDING AND INSTALLATION FOR PERL/TK
-
-TkZinc for Perl/Tk is available for Linux, Windows (Perl/Tk 804)
-and MacOSX. Also remember that the easiest way could be to use
-the CPAN. However new releases are usually first available on
-www.tkzinc.org/
-
-
-0. You need a working Perl (>= 5.6) and Perl/Tk distribution (800 or 804). You can either grab
- it using your regular package manager, or build it and install it from scratch.
-
- On a Linux system, you need perl and perl-tk packages.
-
- On MacOSX you need:
- - fink with tk-pm package and its dependencies (http://fink.sf.net)
- tk-pm is available in unstable. You can add this binary unstable tree to you /sw/etc/apt/sources.list:
- deb http://fink.opendarwin.org/bbraun 10.3/unstable main crypto
- deb http://fink.opendarwin.org/bbraun 10.3/stable main crypto
- - X11 et X11 sdk from Apple (http://www.apple.com/macosx/x11/)
-
- On WinXP you need:
- - perl and perl-tk 804,
- - Visual C++ or the Free Visual C++ Command Line Tools
-
-1. Unpack the distribution
-
- tar zxf Tkzinc<version>.tgz
- cd Tkzinc<version>/Perl
- ./export2cpan
- cd ../export2cpan/Tkzinc<version>
-
-2. Make and install
-
- This done is the usual way
-
- perl Makefile.PL
- make
- make test
-
- # to run the demo without/before installing:
- perl -Mblib demos/zinc-demos
-
- make install
-
- WATCH OUT! On Linux it is quite frequent to have both Mesa and proprietary
- openGL libraries installed. This may lead to big problems at
- runtime if the linker picks the wrong library. It is often the
- case between the static (libGL.a) Mesa library and the dynamic
- (libGL.so) NVidia library. It is very important to assert that
- the link is done with the library matching the openGL driver
- loaded in the X server.
-
-3. Run the demo
-
- You can choose in the 35 available demos with the
- following perl script:
-
- zinc-demos
-
-
-MAKE AND READ THE DOCUMENTATION
-
-
- It is available in pdf and html forms.
- To make the pdf doc you need pdflatex installed. Then do:
-
- cd Tkzinc<version>
- make pdf
-
- This should create a refman.pdf in the doc directory.
-
- To make the html doc you need latex and latex2html. Then do:
-
- cd Tkzinc<version>
- make html
-
- This should create a refman directory in the doc directory
- with all the html pages and images. The entry point is
- index.html.
-
- You can also download the doc on TkZinc website:
- http://www.tkzinc.org/index.php/Main/Download
-
-
-
-REPORT BUGS AND WISHES
-
-
- Please report bugs and suggestions to the TkZinc mailing list
- at zinc@tls.cena.fr.
-
- When reporting bugs try to be as specific as possible.
- Include, if possible, the output from the program. Compile
- TkZinc with debugging symbols and include a backtrace of the
- debugger. Send a small Tcl (or Perl) script reproducing the problem.
- The availability of a correction may dependent on these infos.
diff --git a/aclocal.m4 b/aclocal.m4
deleted file mode 100644
index 2cc42b6..0000000
--- a/aclocal.m4
+++ /dev/null
@@ -1,171 +0,0 @@
-# generated automatically by aclocal 1.7.4 -*- Autoconf -*-
-
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002
-# Free Software Foundation, Inc.
-# This file is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-#
-# Include the TEA standard macro set
-#
-
-builtin(include,tclconfig/tcl.m4)
-
-#
-# Zinc specific macros below.
-#
-#
-# ALL the new macros here need to be modified to
-# detect the various packages needed and to get their paths.
-# Right now all this is statically defined in the macros.
-#
-#------------------------------------------------------------------------
-# ZINC_ENABLE_GL --
-#
-# Specify if openGL support should be used.
-# Code for managing a damage area can also be enabled.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-gl=[yes,no,damage]
-#
-# Defines the following vars:
-# GL_INCLUDES OpenGL include files path
-# GL_LIBS additional libraries needed for GL
-# LIBS Modified to reflect the need of new
-# libraries
-# GL Defined if GL support is enabled
-# GL_DAMAGE Defined if damage support has been
-# requested
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(ZINC_ENABLE_GL, [
- if test x"${TEA_INITED}" = x ; then
- AC_MSG_ERROR([Must call TEA INIT before ENABLE_GL])
- fi
-
- AC_MSG_CHECKING([for build with GL])
- AC_ARG_ENABLE(gl,
- [ --enable-gl build with openGL support (yes,no,damage) [[no]]],
- [tcl_ok=$enableval], [tcl_ok=no])
-
- if test "$tcl_ok" = "no"; then
- GL_LIBS=
- GL_INCLUDES=
- AC_MSG_RESULT([no])
- else
- if test "${TEA_PLATFORM}" = "windows" ; then
- GL_LIBS=-lopengl32
- else
- GL_LIBS="-lGL"
- GL_INCLUDES='-I/usr/include'
- fi
-
- AC_DEFINE(GL)
- if test "$tcl_ok" = "damage"; then
- AC_DEFINE(GL_DAMAGE)
- fi
-
- LIBS="$LIBS $GL_LIBS"
-
- if test "$tcl_ok" = "yes"; then
- AC_MSG_RESULT([yes (standard)])
- else
- AC_MSG_RESULT([yes (with damage support)])
- fi
- fi
-
- AC_SUBST(GL_LIBS)
- AC_SUBST(GL_INCLUDES)
-])
-
-#------------------------------------------------------------------------
-# ZINC_ENABLE_ATC --
-#
-# Specify if the Atc code should be included.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-atc=[yes,no]
-#
-# Defines the following vars:
-# ATC Defined if ATC support is enabled
-#
-#------------------------------------------------------------------------
-
- AC_DEFUN(ZINC_ENABLE_ATC, [
- if test x"${TEA_INITED}" = x ; then
- AC_MSG_ERROR([Must call TEA INIT before ENABLE_ATC])
- fi
-
- AC_MSG_CHECKING([for build with the ATC extensions])
- AC_ARG_ENABLE(atc,
- [ --enable-atc build with ATC extensions [[yes]]],
- [tcl_ok=$enableval], [tcl_ok=yes])
- if test "$tcl_ok" = "no"; then
- Atc_SOURCES=
- AC_MSG_RESULT([no])
- else
- AC_DEFINE(ATC)
- Atc_SOURCES="OverlapMan.c Track.c Reticle.c Map.c MapInfo.c"
- AC_MSG_RESULT([yes])
- fi
- AC_SUBST(Atc_SOURCES)
-])
-
-#------------------------------------------------------------------------
-# ZINC_ENABLE_SHAPE --
-#
-# Specify if the X shape extension support should be included.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-shape=[yes,no]
-#
-# Defines the following vars:
-# SHAPE Defined if shape support is enabled
-#
-# Adjust LIBS to include the X extension library
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(ZINC_ENABLE_SHAPE, [
- if test x"${TEA_INITED}" = x ; then
- AC_MSG_ERROR([Must call TEA INIT before ENABLE_SHAPE])
- fi
- AC_MSG_CHECKING([for build with X shape support])
- AC_ARG_ENABLE(shape,
- [ --enable-shape build with X shape support (if applicable) [[yes]]],
- [tcl_ok=$enableval], [tcl_ok=yes])
- if test "$tcl_ok" = "no"; then
- AC_MSG_RESULT([no])
- else
- if test "${TEA_PLATFORM}" = "windows" ; then
- AC_MSG_RESULT([no (not available on windows)])
- else
- AC_DEFINE(SHAPE)
- AC_MSG_RESULT([yes])
- LIBS="${LIBS} -lXext"
- fi
- fi
-])
-
diff --git a/bootstrap b/bootstrap
deleted file mode 100644
index 1ac0018..0000000
--- a/bootstrap
+++ /dev/null
@@ -1,3 +0,0 @@
-aclocal -I .
-libtoolize --force
-autoconf
diff --git a/buildperl.tcl b/buildperl.tcl
deleted file mode 100644
index 3b01864..0000000
--- a/buildperl.tcl
+++ /dev/null
@@ -1,40 +0,0 @@
-#
-# This script is intended to be run in the top directory
-# with: tclsh84 buildperl.tcl
-#
-
-#
-# Create a perl build directory and copy the relevant
-# files in it.
-#
-set wd [pwd]
-set files {t Zinc.xs Zinc.pm Makefile.PL demos README Zinc}
-set buildDir buildperl
-
-puts "Creating temporary build structure for Tkzinc perl variant"
-
-if { [file exists $buildDir] } {
- file delete -force $buildDir
-}
-file mkdir $buildDir
-foreach f $files {
- file copy -force Perl/$f $buildDir
-}
-foreach f [glob -nocomplain libtess/*.c libtess/*.h generic/*.c generic/*.h win/*.c debian/changelog debian/copyright] {
- file copy -force $f $buildDir
-}
-
-puts "Compiling the perl variant"
-
-set make make
-if { [lindex $tcl_platform(os) 0] eq "Windows" } {
- set make nmake
-}
-
-cd buildperl
-catch {exec perl Makefile.PL} result
-puts $result
-catch {exec $make} result
-puts $result
-
-cd $wd
diff --git a/configure b/configure
deleted file mode 100755
index 549b138..0000000
--- a/configure
+++ /dev/null
@@ -1,4656 +0,0 @@
-#! /bin/sh
-
-# Guess values for system-dependent variables and create Makefiles.
-# Generated automatically using autoconf version 2.13
-# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-
-# Defaults:
-ac_help=
-ac_default_prefix=/usr/local
-# Any additions from configure.in:
-ac_help="$ac_help
- --with-tcl directory containing tcl configuration (tclConfig.sh)"
-ac_help="$ac_help
- --with-tk directory containing tk configuration (tkConfig.sh)"
-ac_help="$ac_help
- --enable-threads build with threads [[no]]"
-ac_help="$ac_help
- --enable-shared build and link with shared libraries [[yes]]"
-ac_help="$ac_help
- --enable-64bit enable 64bit support (where applicable) [[no]]"
-ac_help="$ac_help
- --enable-64bit-vis enable 64bit Sparc VIS support [[no]]"
-ac_help="$ac_help
- --disable-load disallow dynamic loading and "load" command"
-ac_help="$ac_help
- --enable-symbols build with debugging symbols (yes,no,mem,all) [[no]]"
-ac_help="$ac_help
- --with-x use the X Window System"
-ac_help="$ac_help
- --enable-shape build with X shape support (if applicable) [[yes]]"
-ac_help="$ac_help
- --enable-gl build with openGL support (yes,no,damage) [[no]]"
-ac_help="$ac_help
- --enable-atc build with ATC extensions [[yes]]"
-
-# Initialize some variables set by options.
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-build=NONE
-cache_file=./config.cache
-exec_prefix=NONE
-host=NONE
-no_create=
-nonopt=NONE
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-target=NONE
-verbose=
-x_includes=NONE
-x_libraries=NONE
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datadir='${prefix}/share'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-libdir='${exec_prefix}/lib'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-infodir='${prefix}/info'
-mandir='${prefix}/man'
-
-# Initialize some other variables.
-subdirs=
-MFLAGS= MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-# Maximum number of lines to put in a shell here document.
-ac_max_here_lines=12
-
-ac_prev=
-for ac_option
-do
-
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval "$ac_prev=\$ac_option"
- ac_prev=
- continue
- fi
-
- case "$ac_option" in
- -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
- *) ac_optarg= ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case "$ac_option" in
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir="$ac_optarg" ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build="$ac_optarg" ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file="$ac_optarg" ;;
-
- -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
- | --da=*)
- datadir="$ac_optarg" ;;
-
- -disable-* | --disable-*)
- ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
- { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
- fi
- ac_feature=`echo $ac_feature| sed 's/-/_/g'`
- eval "enable_${ac_feature}=no" ;;
-
- -enable-* | --enable-*)
- ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
- { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
- fi
- ac_feature=`echo $ac_feature| sed 's/-/_/g'`
- case "$ac_option" in
- *=*) ;;
- *) ac_optarg=yes ;;
- esac
- eval "enable_${ac_feature}='$ac_optarg'" ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix="$ac_optarg" ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he)
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat << EOF
-Usage: configure [options] [host]
-Options: [defaults in brackets after descriptions]
-Configuration:
- --cache-file=FILE cache test results in FILE
- --help print this message
- --no-create do not create output files
- --quiet, --silent do not print \`checking...' messages
- --version print the version of autoconf that created configure
-Directory and file names:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [same as prefix]
- --bindir=DIR user executables in DIR [EPREFIX/bin]
- --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
- --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
- --datadir=DIR read-only architecture-independent data in DIR
- [PREFIX/share]
- --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data in DIR
- [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
- --libdir=DIR object code libraries in DIR [EPREFIX/lib]
- --includedir=DIR C header files in DIR [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
- --infodir=DIR info documentation in DIR [PREFIX/info]
- --mandir=DIR man documentation in DIR [PREFIX/man]
- --srcdir=DIR find the sources in DIR [configure dir or ..]
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM
- run sed PROGRAM on installed program names
-EOF
- cat << EOF
-Host type:
- --build=BUILD configure for building on BUILD [BUILD=HOST]
- --host=HOST configure for HOST [guessed]
- --target=TARGET configure for TARGET [TARGET=HOST]
-Features and packages:
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --x-includes=DIR X include files are in DIR
- --x-libraries=DIR X library files are in DIR
-EOF
- if test -n "$ac_help"; then
- echo "--enable and --with options recognized:$ac_help"
- fi
- exit 0 ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host="$ac_optarg" ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir="$ac_optarg" ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir="$ac_optarg" ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir="$ac_optarg" ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir="$ac_optarg" ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst \
- | --locals | --local | --loca | --loc | --lo)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* \
- | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
- localstatedir="$ac_optarg" ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir="$ac_optarg" ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir="$ac_optarg" ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix="$ac_optarg" ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix="$ac_optarg" ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix="$ac_optarg" ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name="$ac_optarg" ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir="$ac_optarg" ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir="$ac_optarg" ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site="$ac_optarg" ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir="$ac_optarg" ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir="$ac_optarg" ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target="$ac_optarg" ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers)
- echo "configure generated by autoconf version 2.13"
- exit 0 ;;
-
- -with-* | --with-*)
- ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
- { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
- fi
- ac_package=`echo $ac_package| sed 's/-/_/g'`
- case "$ac_option" in
- *=*) ;;
- *) ac_optarg=yes ;;
- esac
- eval "with_${ac_package}='$ac_optarg'" ;;
-
- -without-* | --without-*)
- ac_package=`echo $ac_option|sed -e 's/-*without-//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
- { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
- fi
- ac_package=`echo $ac_package| sed 's/-/_/g'`
- eval "with_${ac_package}=no" ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes="$ac_optarg" ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries="$ac_optarg" ;;
-
- -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
- ;;
-
- *)
- if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
- echo "configure: warning: $ac_option: invalid host type" 1>&2
- fi
- if test "x$nonopt" != xNONE; then
- { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
- fi
- nonopt="$ac_option"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
-fi
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-# File descriptor usage:
-# 0 standard input
-# 1 file creation
-# 2 errors and warnings
-# 3 some systems may open it to /dev/tty
-# 4 used on the Kubota Titan
-# 6 checking for... messages and results
-# 5 compiler messages saved in config.log
-if test "$silent" = yes; then
- exec 6>/dev/null
-else
- exec 6>&1
-fi
-exec 5>./config.log
-
-echo "\
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-" 1>&5
-
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Also quote any args containing shell metacharacters.
-ac_configure_args=
-for ac_arg
-do
- case "$ac_arg" in
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c) ;;
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
- *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
- ac_configure_args="$ac_configure_args '$ac_arg'" ;;
- *) ac_configure_args="$ac_configure_args $ac_arg" ;;
- esac
-done
-
-# NLS nuisances.
-# Only set these to C if already set. These must not be set unconditionally
-# because not all systems understand e.g. LANG=C (notably SCO).
-# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
-# Non-C LC_CTYPE values break the ctype check.
-if test "${LANG+set}" = set; then LANG=C; export LANG; fi
-if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
-if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
-if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo > confdefs.h
-
-# A filename unique to this package, relative to the directory that
-# configure is in, which we can look for to find out if srcdir is correct.
-ac_unique_file=
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then its parent.
- ac_prog=$0
- ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
- test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
- srcdir=$ac_confdir
- if test ! -r $srcdir/$ac_unique_file; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r $srcdir/$ac_unique_file; then
- if test "$ac_srcdir_defaulted" = yes; then
- { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
- else
- { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
- fi
-fi
-srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
-
-# Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
- fi
-fi
-for ac_site_file in $CONFIG_SITE; do
- if test -r "$ac_site_file"; then
- echo "loading site script $ac_site_file"
- . "$ac_site_file"
- fi
-done
-
-if test -r "$cache_file"; then
- echo "loading cache $cache_file"
- . $cache_file
-else
- echo "creating cache $cache_file"
- > $cache_file
-fi
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-ac_exeext=
-ac_objext=o
-if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
- # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
- if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
- ac_n= ac_c='
-' ac_t=' '
- else
- ac_n=-n ac_c= ac_t=
- fi
-else
- ac_n= ac_c='\c' ac_t=
-fi
-
-
-
-#-----------------------------------------------------------------------
-# Setup the CONFIGDIR to the path of the directory containing the
-# configuration files
-#-----------------------------------------------------------------------
-ac_aux_dir=
-for ac_dir in tclconfig $srcdir/tclconfig; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in tclconfig $srcdir/tclconfig" 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
-CONFIGDIR=${srcdir}/tclconfig
-
-
-#-----------------------------------------------------------------------
-# Define the PACKAGE variable
-#--------------------------------------------------------------------
-PACKAGE=Tkzinc
-
-#--------------------------------------------------------------------
-# Call TEA_INIT as the first TEA_ macro to set up initial vars.
-# This will define a ${TEA_PLATFORM} variable == "unix" or "windows".
-#
-# Keep it here we will need ${TEA_PLATFORM} soon.
-#--------------------------------------------------------------------
-
- echo $ac_n "checking for correct TEA configuration""... $ac_c" 1>&6
-echo "configure:589: checking for correct TEA configuration" >&5
- if test x"${PACKAGE}" = x ; then
- { echo "configure: error:
-The PACKAGE variable must be defined by your TEA configure.in" 1>&2; exit 1; }
- fi
- echo "$ac_t""ok" 1>&6
- TEA_INITED=ok
- case "`uname -s`" in
- *win32*|*WIN32*|*CYGWIN_NT*|*CYGWIN_9*|*CYGWIN_ME*|*MINGW32_*)
- # Extract the first word of "cygpath", so it can be a program name with args.
-set dummy cygpath; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:601: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CYGPATH'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CYGPATH"; then
- ac_cv_prog_CYGPATH="$CYGPATH" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CYGPATH="cygpath -w"
- break
- fi
- done
- IFS="$ac_save_ifs"
- test -z "$ac_cv_prog_CYGPATH" && ac_cv_prog_CYGPATH="echo"
-fi
-fi
-CYGPATH="$ac_cv_prog_CYGPATH"
-if test -n "$CYGPATH"; then
- echo "$ac_t""$CYGPATH" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
- EXEEXT=".exe"
- TEA_PLATFORM="windows"
- ;;
- *)
- CYGPATH=echo
- EXEEXT=""
- TEA_PLATFORM="unix"
- ;;
- esac
-
-
-
-
-
-#-----------------------------------------------------------------------
-# Define the VERSION variable
-#
-# VERSION is constructed from MAJOR_VERSION, MINOR_VERSION and
-# PATCHLEVEL. The windows variant does not containt a dot.
-#-----------------------------------------------------------------------
-MAJOR_VERSION=3
-MINOR_VERSION=3
-PATCHLEVEL=0
-
-VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${PATCHLEVEL}
-
-
-
-
-
-
-
-
-
-
-#--------------------------------------------------------------------
-# This define a preprocessor macro -DVERSION=3.2.6i to include
-# the package version in the sources.
-#--------------------------------------------------------------------
-eval cat >> confdefs.h <<EOF
-#define VERSION "${VERSION}"
-EOF
-
-
-#--------------------------------------------------------------------
-# Load the tclConfig.sh file
-#--------------------------------------------------------------------
-
- if test x"${TEA_INITED}" = x ; then
- # Can't refer to exact macro name or it will be substituted
- { echo "configure: error: Must call TEA INIT before PATH_TCLCONFIG" 1>&2; exit 1; }
- fi
- #
- # Ok, lets find the tcl configuration
- # First, look for one uninstalled.
- # the alternative search directory is invoked by --with-tcl
- #
-
- if test x"${no_tcl}" = x ; then
- # we reset no_tcl in case something fails here
- no_tcl=true
- # Check whether --with-tcl or --without-tcl was given.
-if test "${with_tcl+set}" = set; then
- withval="$with_tcl"
- with_tclconfig=${withval}
-fi
-
- echo $ac_n "checking for Tcl configuration""... $ac_c" 1>&6
-echo "configure:696: checking for Tcl configuration" >&5
- if eval "test \"`echo '$''{'ac_cv_c_tclconfig'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
-
-
- # First check to see if --with-tcl was specified.
- if test x"${with_tclconfig}" != x ; then
- if test -f "${with_tclconfig}/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
- else
- { echo "configure: error: ${with_tclconfig} directory doesn't contain tclConfig.sh" 1>&2; exit 1; }
- fi
- fi
-
- # then check for a private Tcl installation
- if test x"${ac_cv_c_tclconfig}" = x ; then
- for i in \
- ../tcl \
- `ls -dr ../tcl[8-9].[0-9]* 2>/dev/null` \
- ../../tcl \
- `ls -dr ../../tcl[8-9].[0-9]* 2>/dev/null` \
- ../../../tcl \
- `ls -dr ../../../tcl[8-9].[0-9]* 2>/dev/null` ; do
- if test -f "$i/unix/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
-
- # check in a few common install locations
- if test x"${ac_cv_c_tclconfig}" = x ; then
- for i in `ls -d ${exec_prefix}/lib 2>/dev/null` \
- `ls -d /usr/local/lib 2>/dev/null` \
- `ls -d /usr/contrib/lib 2>/dev/null` \
- `ls -d /usr/lib 2>/dev/null` \
- ; do
- if test -f "$i/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd $i; pwd)`
- break
- fi
- done
- fi
-
- # check in a few other private locations
- if test x"${ac_cv_c_tclconfig}" = x ; then
- for i in \
- ${srcdir}/../tcl \
- `ls -dr ${srcdir}/../tcl[8-9].[0-9]* 2>/dev/null` ; do
- if test -f "$i/unix/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
-
-fi
-
-
- if test x"${ac_cv_c_tclconfig}" = x ; then
- TCL_BIN_DIR="# no Tcl configs found"
- echo "configure: warning: "Cannot find Tcl configuration definitions"" 1>&2
- exit 0
- else
- no_tcl=
- TCL_BIN_DIR=${ac_cv_c_tclconfig}
- echo "$ac_t""found $TCL_BIN_DIR/tclConfig.sh" 1>&6
- fi
- fi
-
-
- echo $ac_n "checking for existence of $TCL_BIN_DIR/tclConfig.sh""... $ac_c" 1>&6
-echo "configure:769: checking for existence of $TCL_BIN_DIR/tclConfig.sh" >&5
-
- if test -f "$TCL_BIN_DIR/tclConfig.sh" ; then
- echo "$ac_t""loading" 1>&6
- . $TCL_BIN_DIR/tclConfig.sh
- else
- echo "$ac_t""file not found" 1>&6
- fi
-
- #
- # If the TCL_BIN_DIR is the build directory (not the install directory),
- # then set the common variable name to the value of the build variables.
- # For example, the variable TCL_LIB_SPEC will be set to the value
- # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
- # instead of TCL_BUILD_LIB_SPEC since it will work with both an
- # installed and uninstalled version of Tcl.
- #
-
- if test -f $TCL_BIN_DIR/Makefile ; then
- TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
- TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
- TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
- fi
-
- #
- # eval is required to do the TCL_DBGX substitution
- #
-
- eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
- eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
- eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
-
- eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
- eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
- eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
-
-
-
-
-
-
-
-
-
-
-
-
-
- #AC_SUBST(TCL_DBGX)
-
-
-
-
-
- #AC_SUBST(TCL_BUILD_LIB_SPEC)
- #AC_SUBST(TCL_BUILD_STUB_LIB_SPEC)
-
-
-#--------------------------------------------------------------------
-# Load the tkConfig.sh file
-#--------------------------------------------------------------------
-
- #
- # Ok, lets find the tk configuration
- # First, look for one uninstalled.
- # the alternative search directory is invoked by --with-tk
- #
-
- if test x"${no_tk}" = x ; then
- # we reset no_tk in case something fails here
- no_tk=true
- # Check whether --with-tk or --without-tk was given.
-if test "${with_tk+set}" = set; then
- withval="$with_tk"
- with_tkconfig=${withval}
-fi
-
- echo $ac_n "checking for Tk configuration""... $ac_c" 1>&6
-echo "configure:847: checking for Tk configuration" >&5
- if eval "test \"`echo '$''{'ac_cv_c_tkconfig'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
-
-
- # First check to see if --with-tkconfig was specified.
- if test x"${with_tkconfig}" != x ; then
- if test -f "${with_tkconfig}/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
- else
- { echo "configure: error: ${with_tkconfig} directory doesn't contain tkConfig.sh" 1>&2; exit 1; }
- fi
- fi
-
- # then check for a private Tk library
- if test x"${ac_cv_c_tkconfig}" = x ; then
- for i in \
- ../tk \
- `ls -dr ../tk[8-9].[0-9]* 2>/dev/null` \
- ../../tk \
- `ls -dr ../../tk[8-9].[0-9]* 2>/dev/null` \
- ../../../tk \
- `ls -dr ../../../tk[8-9].[0-9]* 2>/dev/null` ; do
- if test -f "$i/unix/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
- # check in a few common install locations
- if test x"${ac_cv_c_tkconfig}" = x ; then
- for i in `ls -d ${exec_prefix}/lib 2>/dev/null` \
- `ls -d /usr/local/lib 2>/dev/null` \
- `ls -d /usr/contrib/lib 2>/dev/null` \
- `ls -d /usr/lib 2>/dev/null` \
- ; do
- if test -f "$i/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd $i; pwd)`
- break
- fi
- done
- fi
- # check in a few other private locations
- if test x"${ac_cv_c_tkconfig}" = x ; then
- for i in \
- ${srcdir}/../tk \
- `ls -dr ${srcdir}/../tk[8-9].[0-9]* 2>/dev/null` ; do
- if test -f "$i/unix/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
-
-fi
-
- if test x"${ac_cv_c_tkconfig}" = x ; then
- TK_BIN_DIR="# no Tk configs found"
- echo "configure: warning: "Cannot find Tk configuration definitions"" 1>&2
- exit 0
- else
- no_tk=
- TK_BIN_DIR=${ac_cv_c_tkconfig}
- echo "$ac_t""found $TK_BIN_DIR/tkConfig.sh" 1>&6
- fi
- fi
-
-
-
- echo $ac_n "checking for existence of ${TK_BIN_DIR}/tkConfig.sh""... $ac_c" 1>&6
-echo "configure:918: checking for existence of ${TK_BIN_DIR}/tkConfig.sh" >&5
-
- if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
- echo "$ac_t""loading" 1>&6
- . $TK_BIN_DIR/tkConfig.sh
- else
- echo "$ac_t""could not find ${TK_BIN_DIR}/tkConfig.sh" 1>&6
- fi
-
- #
- # If the TK_BIN_DIR is the build directory (not the install directory),
- # then set the common variable name to the value of the build variables.
- # For example, the variable TK_LIB_SPEC will be set to the value
- # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
- # instead of TK_BUILD_LIB_SPEC since it will work with both an
- # installed and uninstalled version of Tcl.
- #
-
- if test -f $TK_BIN_DIR/Makefile ; then
- TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
- TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
- TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
- fi
-
- #
- # eval is required to do the TK_DBGX substitution
- #
-
- eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
- eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
- eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
-
- eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
- eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
- eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#-----------------------------------------------------------------------
-# Handle the --prefix=... option by defaulting to what Tcl gave.
-# Must be called after TEA_LOAD_TCLCONFIG and before TEA_SETUP_COMPILER.
-#-----------------------------------------------------------------------
-
- # Should be AC_MSG_NOTICE, but that requires autoconf 2.50
- if test "${prefix}" = "NONE"; then
- prefix_default=yes
- if test x"${TCL_PREFIX}" != x; then
- echo "configure: warning: --prefix defaulting to TCL_PREFIX ${TCL_PREFIX}" 1>&2
- prefix=${TCL_PREFIX}
- else
- prefix=/usr/local
- fi
- fi
- if test "${exec_prefix}" = "NONE" -a x"${prefix_default}" = x"yes" ; then
- if test x"${TCL_EXEC_PREFIX}" != x; then
- echo "configure: warning: --exec-prefix defaulting to TCL_EXEC_PREFIX ${TCL_EXEC_PREFIX}" 1>&2
- exec_prefix=${TCL_EXEC_PREFIX}
- else
- exec_prefix=$prefix
- fi
- fi
-
-
-#-----------------------------------------------------------------------
-# Standard compiler checks.
-# This sets up CC by using the CC env var, or looks for gcc otherwise.
-# This also calls AC_PROG_CC, AC_PROG_INSTALL and a few others to create
-# the basic setup necessary to compile executables.
-#-----------------------------------------------------------------------
-echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:1002: checking for Cygwin environment" >&5
-if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1007 "configure"
-#include "confdefs.h"
-
-int main() {
-
-#ifndef __CYGWIN__
-#define __CYGWIN__ __CYGWIN32__
-#endif
-return __CYGWIN__;
-; return 0; }
-EOF
-if { (eval echo configure:1018: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- ac_cv_cygwin=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- ac_cv_cygwin=no
-fi
-rm -f conftest*
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_cygwin" 1>&6
-CYGWIN=
-test "$ac_cv_cygwin" = yes && CYGWIN=yes
-echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:1035: checking for mingw32 environment" >&5
-if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1040 "configure"
-#include "confdefs.h"
-
-int main() {
-return __MINGW32__;
-; return 0; }
-EOF
-if { (eval echo configure:1047: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- ac_cv_mingw32=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- ac_cv_mingw32=no
-fi
-rm -f conftest*
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_mingw32" 1>&6
-MINGW32=
-test "$ac_cv_mingw32" = yes && MINGW32=yes
-
- # If the user did not set CFLAGS, set it now to keep
- # the AC_PROG_CC macro from adding "-g -O2".
- if test "${CFLAGS+set}" != "set" ; then
- CFLAGS=""
- fi
-
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1073: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="gcc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1103: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_prog_rejected=no
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# -gt 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- set dummy "$ac_dir/$ac_word" "$@"
- shift
- ac_cv_prog_CC="$@"
- fi
-fi
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
- if test -z "$CC"; then
- case "`uname -s`" in
- *win32* | *WIN32*)
- # Extract the first word of "cl", so it can be a program name with args.
-set dummy cl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1154: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="cl"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
- ;;
- esac
- fi
- test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1186: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-cat > conftest.$ac_ext << EOF
-
-#line 1197 "configure"
-#include "confdefs.h"
-
-main(){return(0);}
-EOF
-if { (eval echo configure:1202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- ac_cv_prog_cc_works=yes
- # If we can't run a trivial program, we are probably using a cross compiler.
- if (./conftest; exit) 2>/dev/null; then
- ac_cv_prog_cc_cross=no
- else
- ac_cv_prog_cc_cross=yes
- fi
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- ac_cv_prog_cc_works=no
-fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
-fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1228: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1233: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.c <<EOF
-#ifdef __GNUC__
- yes;
-#endif
-EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1242: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
- ac_cv_prog_gcc=yes
-else
- ac_cv_prog_gcc=no
-fi
-fi
-
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
-
-if test $ac_cv_prog_gcc = yes; then
- GCC=yes
-else
- GCC=
-fi
-
-ac_test_CFLAGS="${CFLAGS+set}"
-ac_save_CFLAGS="$CFLAGS"
-CFLAGS=
-echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1261: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
- ac_cv_prog_cc_g=yes
-else
- ac_cv_prog_cc_g=no
-fi
-rm -f conftest*
-
-fi
-
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS="$ac_save_CFLAGS"
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-
-
- #------------------------------------------------------------------------
- # If we're using GCC, see if the compiler understands -pipe. If so, use it.
- # It makes compiling go faster. (This is only a performance feature.)
- #------------------------------------------------------------------------
-
- if test -z "$no_pipe" -a -n "$GCC"; then
- echo $ac_n "checking if the compiler understands -pipe""... $ac_c" 1>&6
-echo "configure:1300: checking if the compiler understands -pipe" >&5
- OLDCC="$CC"
- CC="$CC -pipe"
- cat > conftest.$ac_ext <<EOF
-#line 1304 "configure"
-#include "confdefs.h"
-
-int main() {
-
-; return 0; }
-EOF
-if { (eval echo configure:1311: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- echo "$ac_t""yes" 1>&6
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CC="$OLDCC"
- echo "$ac_t""no" 1>&6
-fi
-rm -f conftest*
- fi
-
- # Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# ./install, which can be erroneously created by make from ./install.sh.
-echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:1336: checking for a BSD compatible install" >&5
-if test -z "$INSTALL"; then
-if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
- for ac_dir in $PATH; do
- # Account for people who put trailing slashes in PATH elements.
- case "$ac_dir/" in
- /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- if test -f $ac_dir/$ac_prog; then
- if test $ac_prog = install &&
- grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- else
- ac_cv_path_install="$ac_dir/$ac_prog -c"
- break 2
- fi
- fi
- done
- ;;
- esac
- done
- IFS="$ac_save_IFS"
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL="$ac_cv_path_install"
- else
- # As a last resort, use the slow shell script. We don't cache a
- # path for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the path is relative.
- INSTALL="$ac_install_sh"
- fi
-fi
-echo "$ac_t""$INSTALL" 1>&6
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-
- #--------------------------------------------------------------------
- # Checks to see if the make program sets the $MAKE variable.
- #--------------------------------------------------------------------
-
- echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1394: checking whether ${MAKE-make} sets \${MAKE}" >&5
-set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftestmake <<\EOF
-all:
- @echo 'ac_maketemp="${MAKE}"'
-EOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
-if test -n "$ac_maketemp"; then
- eval ac_cv_prog_make_${ac_make}_set=yes
-else
- eval ac_cv_prog_make_${ac_make}_set=no
-fi
-rm -f conftestmake
-fi
-if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- SET_MAKE=
-else
- echo "$ac_t""no" 1>&6
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-
- #--------------------------------------------------------------------
- # Find ranlib
- #--------------------------------------------------------------------
-
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1428: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_RANLIB="ranlib"
- break
- fi
- done
- IFS="$ac_save_ifs"
- test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
-fi
-fi
-RANLIB="$ac_cv_prog_RANLIB"
-if test -n "$RANLIB"; then
- echo "$ac_t""$RANLIB" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-
- #--------------------------------------------------------------------
- # Determines the correct binary file extension (.o, .obj, .exe etc.)
- #--------------------------------------------------------------------
-
- echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:1461: checking for object suffix" >&5
-if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- rm -f conftest*
-echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:1467: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- for ac_file in conftest.*; do
- case $ac_file in
- *.c) ;;
- *) ac_cv_objext=`echo $ac_file | sed -e s/conftest.//` ;;
- esac
- done
-else
- { echo "configure: error: installation or configuration problem; compiler does not work" 1>&2; exit 1; }
-fi
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_objext" 1>&6
-OBJEXT=$ac_cv_objext
-ac_objext=$ac_cv_objext
-
-
-
-echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1487: checking for executable suffix" >&5
-if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
- ac_cv_exeext=.exe
-else
- rm -f conftest*
- echo 'int main () { return 0; }' > conftest.$ac_ext
- ac_cv_exeext=
- if { (eval echo configure:1497: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
- for file in conftest.*; do
- case $file in
- *.c | *.o | *.obj) ;;
- *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
- esac
- done
- else
- { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
- fi
- rm -f conftest*
- test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
-fi
-fi
-
-EXEEXT=""
-test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
-echo "$ac_t""${ac_cv_exeext}" 1>&6
-ac_exeext=$EXEEXT
-
-
-echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:1519: checking for Cygwin environment" >&5
-if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1524 "configure"
-#include "confdefs.h"
-
-int main() {
-
-#ifndef __CYGWIN__
-#define __CYGWIN__ __CYGWIN32__
-#endif
-return __CYGWIN__;
-; return 0; }
-EOF
-if { (eval echo configure:1535: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- ac_cv_cygwin=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- ac_cv_cygwin=no
-fi
-rm -f conftest*
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_cygwin" 1>&6
-CYGWIN=
-test "$ac_cv_cygwin" = yes && CYGWIN=yes
-echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:1552: checking for mingw32 environment" >&5
-if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1557 "configure"
-#include "confdefs.h"
-
-int main() {
-return __MINGW32__;
-; return 0; }
-EOF
-if { (eval echo configure:1564: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- ac_cv_mingw32=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- ac_cv_mingw32=no
-fi
-rm -f conftest*
-rm -f conftest*
-fi
-
-echo "$ac_t""$ac_cv_mingw32" 1>&6
-MINGW32=
-test "$ac_cv_mingw32" = yes && MINGW32=yes
-
-#--------------------------------------------------------------------
-# Choose which headers you need. Extension authors should try very
-# hard to only rely on the Tcl public header files. Internal headers
-# contain private data structures and are subject to change without
-# notice.
-# This MUST be called after TEA_LOAD_TCLCONFIG / TEA_LOAD_TKCONFIG
-#
-# Sorry but zinc needs the internal functionality provided by Tk
-# even if this is less convenient and secure.
-#--------------------------------------------------------------------
-
- echo $ac_n "checking for Tcl private include files""... $ac_c" 1>&6
-echo "configure:1593: checking for Tcl private include files" >&5
-
- if test "${TEA_PLATFORM}" = "windows"; then
- TCL_TOP_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}`\"
- TCL_GENERIC_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/generic`\"
- TCL_UNIX_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/unix`\"
- TCL_WIN_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/win`\"
- TCL_BMAP_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/bitmaps`\"
- TCL_TOOL_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/tools`\"
- TCL_COMPAT_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/compat`\"
- TCL_PLATFORM_DIR_NATIVE=${TCL_WIN_DIR_NATIVE}
- else
- TCL_TOP_DIR_NATIVE='$(TCL_SRC_DIR)'
- TCL_GENERIC_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/generic'
- TCL_UNIX_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/unix'
- TCL_WIN_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/win'
- TCL_BMAP_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/bitmaps'
- TCL_TOOL_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/tools'
- TCL_COMPAT_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/compat'
- TCL_PLATFORM_DIR_NATIVE=${TCL_UNIX_DIR_NATIVE}
- fi
-
-
-
-
-
-
-
-
-
- TCL_INCLUDES="-I${TCL_GENERIC_DIR_NATIVE} -I${TCL_PLATFORM_DIR_NATIVE}"
-
- echo "$ac_t""Using srcdir found in tclConfig.sh: ${TCL_SRC_DIR}" 1>&6
-
-
- echo $ac_n "checking for Tk private include files""... $ac_c" 1>&6
-echo "configure:1629: checking for Tk private include files" >&5
-
- if test "${TEA_PLATFORM}" = "windows"; then
- TK_TOP_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}`\"
- TK_UNIX_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/unix`\"
- TK_WIN_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/win`\"
- TK_GENERIC_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/generic`\"
- TK_XLIB_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/xlib`\"
- TK_PLATFORM_DIR_NATIVE=${TK_WIN_DIR_NATIVE}
-
- TK_INCLUDES="-I${TK_GENERIC_DIR_NATIVE} -I${TK_PLATFORM_DIR_NATIVE} -I${TK_XLIB_DIR_NATIVE}"
- else
- TK_TOP_DIR_NATIVE='$(TK_SRC_DIR)'
- TK_GENERIC_DIR_NATIVE='$(TK_TOP_DIR_NATIVE)/generic'
- TK_UNIX_DIR_NATIVE='$(TK_TOP_DIR_NATIVE)/unix'
- TK_WIN_DIR_NATIVE='$(TK_TOP_DIR_NATIVE)/win'
- TK_PLATFORM_DIR_NATIVE=${TK_UNIX_DIR_NATIVE}
-
- TK_INCLUDES="-I${TK_GENERIC_DIR_NATIVE} -I${TK_PLATFORM_DIR_NATIVE}"
- fi
-
-
-
-
-
-
-
-
-
- echo "$ac_t""Using srcdir found in tkConfig.sh: ${TK_SRC_DIR}" 1>&6
-
-
-#--------------------------------------------------------------------
-# A few miscellaneous platform-specific items:
-#
-# Define the special symbol BUILD_Tkzinc for Windows so
-# that we create the export library with the dll.
-#
-# Windows creates a few extra files that need to be cleaned up.
-#
-# Define any extra compiler flags in the PACKAGE_CFLAGS variable.
-# These will be appended to the current set of compiler flags for
-# your system.
-#--------------------------------------------------------------------
-if test "${TEA_PLATFORM}" = "windows" ; then
- cat >> confdefs.h <<\EOF
-#define BUILD_Tkzinc 1
-EOF
-
- CLEANFILES="pkgIndex.tcl *.lib *.dll *.exp *.ilk *.pdb vc*.pch"
- EXTRA_SOURCES='$(WIN_SOURCES)'
-else
- CLEANFILES="pkgIndex.tcl"
- EXTRA_SOURCES='$(UNIX_SOURCES)'
-fi
-CLEANFILES="${CLEANFILES} doc/*.dvi doc/*.aux doc/*.idx doc/*.ilg doc/*.ind"
-CLEANFILES="${CLEANFILES} doc/*.lof doc/*.log doc/*.out doc/*.toc doc/*.tpt"
-CLEANFILES="${CLEANFILES} doc/refman doc/refman.pdf"
-CLEANFILES="${CLEANFILES} Python/Zinc.py"
-
-
-
-
-#--------------------------------------------------------------------
-# Check whether --enable-threads or --disable-threads was given.
-# This call disable threading support as a default.
-#--------------------------------------------------------------------
-
- # Check whether --enable-threads or --disable-threads was given.
-if test "${enable_threads+set}" = set; then
- enableval="$enable_threads"
- tcl_ok=$enableval
-else
- tcl_ok=no
-fi
-
-
- if test "$tcl_ok" = "yes"; then
- TCL_THREADS=1
-
- if test "${TEA_PLATFORM}" != "windows" ; then
- # We are always OK on Windows, so check what this platform wants.
- cat >> confdefs.h <<\EOF
-#define USE_THREAD_ALLOC 1
-EOF
-
- cat >> confdefs.h <<\EOF
-#define _REENTRANT 1
-EOF
-
- cat >> confdefs.h <<\EOF
-#define _THREAD_SAFE 1
-EOF
-
- echo $ac_n "checking for pthread_mutex_init in -lpthread""... $ac_c" 1>&6
-echo "configure:1724: checking for pthread_mutex_init in -lpthread" >&5
-ac_lib_var=`echo pthread'_'pthread_mutex_init | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lpthread $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 1732 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char pthread_mutex_init();
-
-int main() {
-pthread_mutex_init()
-; return 0; }
-EOF
-if { (eval echo configure:1743: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- tcl_ok=yes
-else
- echo "$ac_t""no" 1>&6
-tcl_ok=no
-fi
-
- if test "$tcl_ok" = "no"; then
- # Check a little harder for __pthread_mutex_init in the
- # same library, as some systems hide it there until
- # pthread.h is defined. We could alternatively do an
- # AC_TRY_COMPILE with pthread.h, but that will work with
- # libpthread really doesn't exist, like AIX 4.2.
- # [Bug: 4359]
- echo $ac_n "checking for __pthread_mutex_init in -lpthread""... $ac_c" 1>&6
-echo "configure:1772: checking for __pthread_mutex_init in -lpthread" >&5
-ac_lib_var=`echo pthread'_'__pthread_mutex_init | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lpthread $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 1780 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char __pthread_mutex_init();
-
-int main() {
-__pthread_mutex_init()
-; return 0; }
-EOF
-if { (eval echo configure:1791: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- tcl_ok=yes
-else
- echo "$ac_t""no" 1>&6
-tcl_ok=no
-fi
-
- fi
-
- if test "$tcl_ok" = "yes"; then
- # The space is needed
- THREADS_LIBS=" -lpthread"
- else
- echo $ac_n "checking for pthread_mutex_init in -lpthreads""... $ac_c" 1>&6
-echo "configure:1819: checking for pthread_mutex_init in -lpthreads" >&5
-ac_lib_var=`echo pthreads'_'pthread_mutex_init | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lpthreads $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 1827 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char pthread_mutex_init();
-
-int main() {
-pthread_mutex_init()
-; return 0; }
-EOF
-if { (eval echo configure:1838: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- tcl_ok=yes
-else
- echo "$ac_t""no" 1>&6
-tcl_ok=no
-fi
-
- if test "$tcl_ok" = "yes"; then
- # The space is needed
- THREADS_LIBS=" -lpthreads"
- else
- echo $ac_n "checking for pthread_mutex_init in -lc""... $ac_c" 1>&6
-echo "configure:1864: checking for pthread_mutex_init in -lc" >&5
-ac_lib_var=`echo c'_'pthread_mutex_init | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lc $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 1872 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char pthread_mutex_init();
-
-int main() {
-pthread_mutex_init()
-; return 0; }
-EOF
-if { (eval echo configure:1883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- tcl_ok=yes
-else
- echo "$ac_t""no" 1>&6
-tcl_ok=no
-fi
-
- if test "$tcl_ok" = "no"; then
- echo $ac_n "checking for pthread_mutex_init in -lc_r""... $ac_c" 1>&6
-echo "configure:1906: checking for pthread_mutex_init in -lc_r" >&5
-ac_lib_var=`echo c_r'_'pthread_mutex_init | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lc_r $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 1914 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char pthread_mutex_init();
-
-int main() {
-pthread_mutex_init()
-; return 0; }
-EOF
-if { (eval echo configure:1925: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- tcl_ok=yes
-else
- echo "$ac_t""no" 1>&6
-tcl_ok=no
-fi
-
- if test "$tcl_ok" = "yes"; then
- # The space is needed
- THREADS_LIBS=" -pthread"
- else
- TCL_THREADS=0
- echo "configure: warning: "Don t know how to find pthread lib on your system - thread support disabled"" 1>&2
- fi
- fi
- fi
- fi
-
- # Does the pthread-implementation provide
- # 'pthread_attr_setstacksize' ?
- for ac_func in pthread_attr_setstacksize
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1962: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1967 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-
-int main() {
-
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:1990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-done
-
- fi
- else
- TCL_THREADS=0
- fi
- # Do checking message here to not mess up interleaved configure output
- echo $ac_n "checking for building with threads""... $ac_c" 1>&6
-echo "configure:2020: checking for building with threads" >&5
- if test "${TCL_THREADS}" = "1"; then
- cat >> confdefs.h <<\EOF
-#define TCL_THREADS 1
-EOF
-
- echo "$ac_t""yes" 1>&6
- else
- echo "$ac_t""no (default)" 1>&6
- fi
- # TCL_THREADS sanity checking. See if our request for building with
- # threads is the same as the way Tcl was built. If not, warn the user.
- case ${TCL_DEFS} in
- *THREADS=1*)
- if test "${TCL_THREADS}" = "0"; then
- echo "configure: warning:
- Building ${PACKAGE} without threads enabled, but building against a Tcl
- that IS thread-enabled." 1>&2
- fi
- ;;
- *)
- if test "${TCL_THREADS}" = "1"; then
- echo "configure: warning:
- --enable-threads requested, but attempting building against a Tcl
- that is NOT thread-enabled." 1>&2
- fi
- ;;
- esac
-
-
-
-#--------------------------------------------------------------------
-# The statement below defines a collection of symbols related to
-# building as a shared library instead of a static library.
-#--------------------------------------------------------------------
-
- echo $ac_n "checking how to build libraries""... $ac_c" 1>&6
-echo "configure:2057: checking how to build libraries" >&5
- # Check whether --enable-shared or --disable-shared was given.
-if test "${enable_shared+set}" = set; then
- enableval="$enable_shared"
- tcl_ok=$enableval
-else
- tcl_ok=yes
-fi
-
-
- if test "${enable_shared+set}" = set; then
- enableval="$enable_shared"
- tcl_ok=$enableval
- else
- tcl_ok=yes
- fi
-
- if test "$tcl_ok" = "yes" ; then
- echo "$ac_t""shared" 1>&6
- SHARED_BUILD=1
- else
- echo "$ac_t""static" 1>&6
- SHARED_BUILD=0
- cat >> confdefs.h <<\EOF
-#define STATIC_BUILD 1
-EOF
-
- fi
-
-
-
-#--------------------------------------------------------------------
-# This macro figures out what flags to use with the compiler/linker
-# when building shared/static debug/optimized objects. This information
-# can be taken from the tclConfig.sh file, but this figures it all out.
-#--------------------------------------------------------------------
-echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2094: checking how to run the C preprocessor" >&5
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
-if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- # This must be in double quotes, not single quotes, because CPP may get
- # substituted into the Makefile and "${CC-cc}" will confuse make.
- CPP="${CC-cc} -E"
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp.
- cat > conftest.$ac_ext <<EOF
-#line 2109 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2115: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CPP="${CC-cc} -E -traditional-cpp"
- cat > conftest.$ac_ext <<EOF
-#line 2126 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2132: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CPP="${CC-cc} -nologo -E"
- cat > conftest.$ac_ext <<EOF
-#line 2143 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2149: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CPP=/lib/cpp
-fi
-rm -f conftest*
-fi
-rm -f conftest*
-fi
-rm -f conftest*
- ac_cv_prog_CPP="$CPP"
-fi
- CPP="$ac_cv_prog_CPP"
-else
- ac_cv_prog_CPP="$CPP"
-fi
-echo "$ac_t""$CPP" 1>&6
-
-
- if test x"${TEA_INITED}" = x ; then
- # Can't refer to exact macro name or it will be substituted
- { echo "configure: error: Must call TEA INIT before CONFIG_CFLAGS" 1>&2; exit 1; }
- fi
-
- # Step 0: Enable 64 bit support?
-
- echo $ac_n "checking if 64bit support is enabled""... $ac_c" 1>&6
-echo "configure:2182: checking if 64bit support is enabled" >&5
- # Check whether --enable-64bit or --disable-64bit was given.
-if test "${enable_64bit+set}" = set; then
- enableval="$enable_64bit"
- do64bit=$enableval
-else
- do64bit=no
-fi
-
- echo "$ac_t""$do64bit" 1>&6
-
- # Step 0.b: Enable Solaris 64 bit VIS support?
-
- echo $ac_n "checking if 64bit Sparc VIS support is requested""... $ac_c" 1>&6
-echo "configure:2196: checking if 64bit Sparc VIS support is requested" >&5
- # Check whether --enable-64bit-vis or --disable-64bit-vis was given.
-if test "${enable_64bit_vis+set}" = set; then
- enableval="$enable_64bit_vis"
- do64bitVIS=$enableval
-else
- do64bitVIS=no
-fi
-
- echo "$ac_t""$do64bitVIS" 1>&6
-
- if test "$do64bitVIS" = "yes"; then
- # Force 64bit on with VIS
- do64bit=yes
- fi
-
- # Step 1: set the variable "system" to hold the name and version number
- # for the system. This can usually be done via the "uname" command, but
- # there are a few systems, like Next, where this doesn't work.
-
- echo $ac_n "checking system version (for dynamic loading)""... $ac_c" 1>&6
-echo "configure:2217: checking system version (for dynamic loading)" >&5
- if test -f /usr/lib/NextStep/software_version; then
- system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
- else
- system=`uname -s`-`uname -r`
- if test "$?" -ne 0 ; then
- echo "$ac_t""unknown (can't find uname command)" 1>&6
- system=unknown
- else
- # Special check for weird MP-RAS system (uname returns weird
- # results, and the version is kept in special file).
-
- if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
- system=MP-RAS-`awk '{print }' /etc/.relid'`
- fi
- if test "`uname -s`" = "AIX" ; then
- system=AIX-`uname -v`.`uname -r`
- fi
- if test "${TEA_PLATFORM}" = "windows" ; then
- system=windows
- fi
- echo "$ac_t""$system" 1>&6
- fi
- fi
-
- # Step 2: check for existence of -ldl library. This is needed because
- # Linux can use either -ldl or -ldld for dynamic loading.
-
- echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:2246: checking for dlopen in -ldl" >&5
-ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-ldl $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 2254 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char dlopen();
-
-int main() {
-dlopen()
-; return 0; }
-EOF
-if { (eval echo configure:2265: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- have_dl=yes
-else
- echo "$ac_t""no" 1>&6
-have_dl=no
-fi
-
-
- # Step 3: set configuration options based on system name and version.
-
- do64bit_ok=no
- EXTRA_CFLAGS=""
- TCL_EXPORT_FILE_SUFFIX=""
- UNSHARED_LIB_SUFFIX=""
- TCL_TRIM_DOTS='`echo ${VERSION} | tr -d .`'
- ECHO_VERSION='`echo ${VERSION}`'
- TCL_LIB_VERSIONS_OK=ok
- CFLAGS_DEBUG=-g
- CFLAGS_OPTIMIZE=-O
- if test "$GCC" = "yes" ; then
-#
-# no-implicit-int is already included in all.
-# -Wconversion generate some pretty useless warnings
-# among more useful ones. To be used once in a while.
-# Added -W which _is_ useful, it detects comparisons
-# between unsigned and signed, empty blocks, unused
-# parameters/vars....
-# CFLAGS_WARNING="-Wall -Wconversion -Wno-implicit-int"
- CFLAGS_WARNING="-Wall -W"
- else
- CFLAGS_WARNING=""
- fi
- TCL_NEEDS_EXP_FILE=0
- TCL_BUILD_EXP_FILE=""
- TCL_EXP_FILE=""
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2317: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_AR="ar"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-AR="$ac_cv_prog_AR"
-if test -n "$AR"; then
- echo "$ac_t""$AR" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
- STLIB_LD='${AR} cr'
- case $system in
- windows)
- # This is a 2-stage check to make sure we have the 64-bit SDK
- # We have to know where the SDK is installed.
- if test "$do64bit" = "yes" ; then
- if test "x${MSSDK}x" = "xx" ; then
- MSSDK="C:/Progra~1/Microsoft SDK"
- fi
- # In order to work in the tortured autoconf environment,
- # we need to ensure that this path has no spaces
- MSSDK=`cygpath -w -s "$MSSDK" | sed -e 's!\\\!/!g'`
- if test ! -d "${MSSDK}/bin/win64" ; then
- echo "configure: warning: "could not find 64-bit SDK to enable 64bit mode"" 1>&2
- do64bit="no"
- else
- do64bit_ok="yes"
- fi
- fi
-
- if test "${SHARED_BUILD}" = "0" ; then
- runtime=-MT
- else
- runtime=-MD
- fi
-
- if test "$do64bit" = "yes" ; then
- # All this magic is necessary for the Win64 SDK RC1 - hobbs
- export CC="${MSSDK}/Bin/Win64/cl.exe \
- -I${MSSDK}/Include/prerelease -I${MSSDK}/Include/Win64/crt \
- -I${MSSDK}/Include"
- export RC="${MSSDK}/bin/rc.exe"
- export lflags="-MACHINE:IA64 -LIBPATH:${MSSDK}/Lib/IA64 \
- -LIBPATH:${MSSDK}/Lib/Prerelease/IA64"
- export STLIB_LD="${MSSDK}/bin/win64/lib.exe -nologo ${lflags}"
- export LINKBIN="${MSSDK}/bin/win64/link.exe ${lflags}"
- CFLAGS_DEBUG="-nologo -Zi -Od -W3 ${runtime}d"
- CFLAGS_OPTIMIZE="-nologo -O2 -Gs -W2 ${runtime}"
- else
- RC="rc"
- STLIB_LD="lib -nologo"
- LINKBIN="link -link50compat"
- CFLAGS_DEBUG="-nologo -Z7 -Od -W3 -WX ${runtime}d"
- CFLAGS_OPTIMIZE="-nologo -O2 -Gs -GD -W2 ${runtime}"
- fi
-
- if test "$MINGW32" = "yes"; then
- # mingw gcc mode
- CFLAGS_DEBUG="-g"
- CFLAGS_OPTIMIZE="-O2"
- SHLIB_LD="gcc -shared"
- STLIB_LD='${AR} cr'
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- LDFLAGS_CONSOLE="-wl,--subsystem,console ${lflags}"
- LDFLAGS_WINDOW="-wl,--subsystem,windows ${lflags}"
- else
- SHLIB_LD="${LINKBIN} -dll -nologo"
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.lib'
- EXTRA_CFLAGS="-YX"
- # For information on what debugtype is most useful, see:
- # http://msdn.microsoft.com/library/en-us/dnvc60/html/gendepdebug.asp
- # This essentially turns it all on.
- LDFLAGS_DEBUG="-debug:full -debugtype:both -warn:2"
- LDFLAGS_OPTIMIZE="-release"
- LDFLAGS_CONSOLE="-link -subsystem:console ${lflags}"
- LDFLAGS_WINDOW="-link -subsystem:windows ${lflags}"
- PATHTYPE=-w
- fi
-
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".dll"
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.dll'
-
- TCL_LIB_VERSIONS_OK=nodots
- # Bogus to avoid getting this turned off
- DL_OBJS="tclLoadNone.obj"
- ;;
- AIX-*)
- if test "${TCL_THREADS}" = "1" -a "$GCC" != "yes" ; then
- # AIX requires the _r compiler when gcc isn't being used
- if test "${CC}" != "cc_r" ; then
- CC=${CC}_r
- fi
- echo "$ac_t""Using $CC for compiling with threads" 1>&6
- fi
- LIBS="$LIBS -lc"
- SHLIB_CFLAGS=""
- SHLIB_SUFFIX=".so"
- SHLIB_LD_LIBS='${LIBS}'
- if test "`uname -m`" = "ia64" ; then
- # AIX-5 uses ELF style dynamic libraries on IA-64, but not PPC
- SHLIB_LD="/usr/ccs/bin/ld -G -z text"
- # AIX-5 has dl* in libc.so
- DL_LIBS=""
- if test "$GCC" = "yes" ; then
- LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
- else
- LD_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
- fi
- else
- SHLIB_LD="${TCL_SRC_DIR}/unix/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
- DL_LIBS="-ldl"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- TCL_NEEDS_EXP_FILE=1
- TCL_EXPORT_FILE_SUFFIX='${VERSION}\$\{DBGX\}.exp'
- fi
- DL_OBJS="tclLoadDl.o"
- LDFLAGS=""
-
- # AIX v<=4.1 has some different flags than 4.2+
- if test "$system" = "AIX-4.1" -o "`uname -v`" -lt "4" ; then
- LIBOBJS="$LIBOBJS tclLoadAix.o"
- DL_LIBS="-lld"
- fi
-
- # On AIX <=v4 systems, libbsd.a has to be linked in to support
- # non-blocking file IO. This library has to be linked in after
- # the MATH_LIBS or it breaks the pow() function. The way to
- # insure proper sequencing, is to add it to the tail of MATH_LIBS.
- # This library also supplies gettimeofday.
- #
- # AIX does not have a timezone field in struct tm. When the AIX
- # bsd library is used, the timezone global and the gettimeofday
- # methods are to be avoided for timezone deduction instead, we
- # deduce the timezone by comparing the localtime result on a
- # known GMT value.
-
- echo $ac_n "checking for gettimeofday in -lbsd""... $ac_c" 1>&6
-echo "configure:2471: checking for gettimeofday in -lbsd" >&5
-ac_lib_var=`echo bsd'_'gettimeofday | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lbsd $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 2479 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char gettimeofday();
-
-int main() {
-gettimeofday()
-; return 0; }
-EOF
-if { (eval echo configure:2490: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- libbsd=yes
-else
- echo "$ac_t""no" 1>&6
-libbsd=no
-fi
-
- if test $libbsd = yes; then
- MATH_LIBS="$MATH_LIBS -lbsd"
- cat >> confdefs.h <<\EOF
-#define USE_DELTA_FOR_TZ 1
-EOF
-
- fi
-
- # Check to enable 64-bit flags for compiler/linker on AIX 4+
- if test "$do64bit" = "yes" -a "`uname -v`" -gt "3" ; then
- if test "$GCC" = "yes" ; then
- echo "configure: warning: "64bit mode not supported with GCC on $system"" 1>&2
- else
- do64bit_ok=yes
- EXTRA_CFLAGS="-q64"
- LDFLAGS="-q64"
- RANLIB="${RANLIB} -X64"
- AR="${AR} -X64"
- SHLIB_LDFLAGS="-b64"
- fi
- fi
- ;;
- BSD/OS-2.1*|BSD/OS-3*)
- SHLIB_CFLAGS=""
- SHLIB_LD="shlicc -r"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- BSD/OS-4.*)
- SHLIB_CFLAGS="-export-dynamic -fPIC"
- SHLIB_LD="cc -shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS="-export-dynamic"
- LD_SEARCH_FLAGS=""
- ;;
- dgux*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- HP-UX-*.11.*)
- # Use updated header definitions where possible
- cat >> confdefs.h <<\EOF
-#define _XOPEN_SOURCE_EXTENDED 1
-EOF
-
-
- SHLIB_SUFFIX=".sl"
- echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
-echo "configure:2572: checking for shl_load in -ldld" >&5
-ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-ldld $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 2580 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char shl_load();
-
-int main() {
-shl_load()
-; return 0; }
-EOF
-if { (eval echo configure:2591: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- tcl_ok=yes
-else
- echo "$ac_t""no" 1>&6
-tcl_ok=no
-fi
-
- if test "$tcl_ok" = yes; then
- SHLIB_CFLAGS="+z"
- SHLIB_LD="ld -b"
- SHLIB_LD_LIBS='${LIBS}'
- DL_OBJS="tclLoadShl.o"
- DL_LIBS="-ldld"
- LDFLAGS="-Wl,-E"
- LD_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
- fi
-
- # Users may want PA-RISC 1.1/2.0 portable code - needs HP cc
- #EXTRA_CFLAGS="+DAportable"
-
- # Check to enable 64-bit flags for compiler/linker
- if test "$do64bit" = "yes" ; then
- if test "$GCC" = "yes" ; then
- hpux_arch=`gcc -dumpmachine`
- case $hpux_arch in
- hppa64*)
- # 64-bit gcc in use. Fix flags for GNU ld.
- do64bit_ok=yes
- SHLIB_LD="gcc -shared"
- SHLIB_LD_LIBS=""
- LD_SEARCH_FLAGS=''
- ;;
- *)
- echo "configure: warning: "64bit mode not supported with GCC on $system"" 1>&2
- ;;
- esac
- else
- do64bit_ok=yes
- EXTRA_CFLAGS="+DA2.0W"
- LDFLAGS="+DA2.0W $LDFLAGS"
- fi
- fi
- ;;
- HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*)
- SHLIB_SUFFIX=".sl"
- echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
-echo "configure:2651: checking for shl_load in -ldld" >&5
-ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-ldld $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 2659 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char shl_load();
-
-int main() {
-shl_load()
-; return 0; }
-EOF
-if { (eval echo configure:2670: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- tcl_ok=yes
-else
- echo "$ac_t""no" 1>&6
-tcl_ok=no
-fi
-
- if test "$tcl_ok" = yes; then
- SHLIB_CFLAGS="+z"
- SHLIB_LD="ld -b"
- SHLIB_LD_LIBS=""
- DL_OBJS="tclLoadShl.o"
- DL_LIBS="-ldld"
- LDFLAGS="-Wl,-E"
- LD_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
- fi
- ;;
- IRIX-4.*)
- SHLIB_CFLAGS="-G 0"
- SHLIB_SUFFIX=".a"
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
- SHLIB_LD_LIBS='${LIBS}'
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS="-Wl,-D,08000000"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a'
- ;;
- IRIX-5.*)
- SHLIB_CFLAGS=""
- SHLIB_LD="ld -shared -rdata_shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- EXTRA_CFLAGS=""
- LDFLAGS=""
- ;;
- IRIX-6.*|IRIX64-6.5*)
- SHLIB_CFLAGS=""
- SHLIB_LD="ld -n32 -shared -rdata_shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- if test "$GCC" = "yes" ; then
- EXTRA_CFLAGS="-mabi=n32"
- LDFLAGS="-mabi=n32"
- else
- case $system in
- IRIX-6.3)
- # Use to build 6.2 compatible binaries on 6.3.
- EXTRA_CFLAGS="-n32 -D_OLD_TERMIOS"
- ;;
- *)
- EXTRA_CFLAGS="-n32"
- ;;
- esac
- LDFLAGS="-n32"
- fi
- ;;
- IRIX64-6.*)
- SHLIB_CFLAGS=""
- SHLIB_LD="ld -n32 -shared -rdata_shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-
- # Check to enable 64-bit flags for compiler/linker
-
- if test "$do64bit" = "yes" ; then
- if test "$GCC" = "yes" ; then
- echo "configure: warning: 64bit mode not supported by gcc" 1>&2
- else
- do64bit_ok=yes
- SHLIB_LD="ld -64 -shared -rdata_shared"
- EXTRA_CFLAGS="-64"
- LDFLAGS="-64"
- fi
- fi
- ;;
- Linux*)
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
-
- # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings
- # when you inline the string and math operations. Turn this off to
- # get rid of the warnings.
-
- CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
-
- if test "$have_dl" = yes; then
- SHLIB_LD="${CC} -shared"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS="-rdynamic"
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- else
- ac_safe=`echo "dld.h" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for dld.h""... $ac_c" 1>&6
-echo "configure:2790: checking for dld.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2795 "configure"
-#include "confdefs.h"
-#include <dld.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2800: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=yes"
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
- echo "$ac_t""yes" 1>&6
-
- SHLIB_LD="ld -shared"
- DL_OBJS="tclLoadDld.o"
- DL_LIBS="-ldld"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
-else
- echo "$ac_t""no" 1>&6
-fi
-
- fi
- if test "`uname -m`" = "alpha" ; then
- EXTRA_CFLAGS="-mieee"
- fi
-
- # The combo of gcc + glibc has a bug related
- # to inlining of functions like strtod(). The
- # -fno-builtin flag should address this problem
- # but it does not work. The -fno-inline flag
- # is kind of overkill but it works.
- # Disable inlining only when one of the
- # files in compat/*.c is being linked in.
- if test x"${LIBOBJS}" != x ; then
- EXTRA_CFLAGS="${EXTRA_CFLAGS} -fno-inline"
- fi
-
- ;;
- GNU*)
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
-
- if test "$have_dl" = yes; then
- SHLIB_LD="${CC} -shared"
- DL_OBJS=""
- DL_LIBS="-ldl"
- LDFLAGS="-rdynamic"
- LD_SEARCH_FLAGS=""
- else
- ac_safe=`echo "dld.h" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for dld.h""... $ac_c" 1>&6
-echo "configure:2857: checking for dld.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2862 "configure"
-#include "confdefs.h"
-#include <dld.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2867: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=yes"
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
- echo "$ac_t""yes" 1>&6
-
- SHLIB_LD="ld -shared"
- DL_OBJS=""
- DL_LIBS="-ldld"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
-else
- echo "$ac_t""no" 1>&6
-fi
-
- fi
- if test "`uname -m`" = "alpha" ; then
- EXTRA_CFLAGS="-mieee"
- fi
- ;;
- MP-RAS-02*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- MP-RAS-*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS="-Wl,-Bexport"
- LD_SEARCH_FLAGS=""
- ;;
- NetBSD-*|FreeBSD-[1-2].*|OpenBSD-*)
- # Not available on all versions: check for include file.
- ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6
-echo "configure:2922: checking for dlfcn.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2927 "configure"
-#include "confdefs.h"
-#include <dlfcn.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2932: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=yes"
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
- echo "$ac_t""yes" 1>&6
-
- # NetBSD/SPARC needs -fPIC, -fpic will not do.
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD="ld -Bshareable -x"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- echo $ac_n "checking for ELF""... $ac_c" 1>&6
-echo "configure:2959: checking for ELF" >&5
- cat > conftest.$ac_ext <<EOF
-#line 2961 "configure"
-#include "confdefs.h"
-
-#ifdef __ELF__
- yes
-#endif
-
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "yes" >/dev/null 2>&1; then
- rm -rf conftest*
- echo "$ac_t""yes" 1>&6
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
-else
- rm -rf conftest*
- echo "$ac_t""no" 1>&6
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
-
-fi
-rm -f conftest*
-
-
-else
- echo "$ac_t""no" 1>&6
-
- SHLIB_CFLAGS=""
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".a"
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
-
-fi
-
-
- # FreeBSD doesn't handle version numbers with dots.
-
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- TCL_LIB_VERSIONS_OK=nodots
- ;;
- FreeBSD-*)
- # FreeBSD 3.* and greater have ELF.
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD="ld -Bshareable -x"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS="-export-dynamic"
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- if test "${TCL_THREADS}" = "1" ; then
- # The -pthread needs to go in the CFLAGS, not LIBS
- LIBS=`echo $LIBS | sed s/-pthread//`
- EXTRA_CFLAGS="-pthread"
- LDFLAGS="$LDFLAGS -pthread"
- fi
- case $system in
- FreeBSD-3.*)
- # FreeBSD-3 doesn't handle version numbers with dots.
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
- TCL_LIB_VERSIONS_OK=nodots
- ;;
- esac
- ;;
- Rhapsody-*|Darwin-*)
- SHLIB_CFLAGS="-fno-common"
- SHLIB_LD="cc -dynamiclib \${LDFLAGS}"
- TCL_SHLIB_LD_EXTRAS="-compatibility_version ${TCL_MAJOR_VERSION} -current_version \${VERSION} -install_name \${LIB_RUNTIME_DIR}/\${TCL_LIB_FILE} -prebind -seg1addr 0xa000000"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".dylib"
- DL_OBJS="tclLoadDyld.o"
- DL_LIBS=""
- LDFLAGS="-prebind"
- LD_SEARCH_FLAGS=""
- CFLAGS_OPTIMIZE="-O3"
- EXTRA_CFLAGS="-arch ppc -pipe"
- ;;
- NEXTSTEP-*)
- SHLIB_CFLAGS=""
- SHLIB_LD="cc -nostdlib -r"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadNext.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- OS/390-*)
- CFLAGS_OPTIMIZE="" # Optimizer is buggy
- cat >> confdefs.h <<\EOF
-#define _OE_SOCKETS 1
-EOF
- # needed in sys/socket.h
- ;;
- OSF1-1.0|OSF1-1.1|OSF1-1.2)
- # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1
- SHLIB_CFLAGS=""
- # Hack: make package name same as library name
- SHLIB_LD='ld -R -export :'
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadOSF.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- OSF1-1.*)
- # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2
- SHLIB_CFLAGS="-fPIC"
- if test "$SHARED_BUILD" = "1" ; then
- SHLIB_LD="ld -shared"
- else
- SHLIB_LD="ld -non_shared"
- fi
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- OSF1-V*)
- # Digital OSF/1
- SHLIB_CFLAGS=""
- if test "$SHARED_BUILD" = "1" ; then
- SHLIB_LD='ld -shared -expect_unresolved "*"'
- else
- SHLIB_LD='ld -non_shared -expect_unresolved "*"'
- fi
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
- if test "$GCC" != "yes" ; then
- EXTRA_CFLAGS="-DHAVE_TZSET -std1"
- fi
- # see pthread_intro(3) for pthread support on osf1, k.furukawa
- if test "${TCL_THREADS}" = "1" ; then
- EXTRA_CFLAGS="${EXTRA_CFLAGS} -DHAVE_PTHREAD_ATTR_SETSTACKSIZE"
- EXTRA_CFLAGS="${EXTRA_CFLAGS} -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
- LIBS=`echo $LIBS | sed s/-lpthreads//`
- if test "$GCC" = "yes" ; then
- LIBS="$LIBS -lpthread -lmach -lexc"
- else
- EXTRA_CFLAGS="${EXTRA_CFLAGS} -pthread"
- LDFLAGS="-pthread"
- fi
- fi
-
- ;;
- QNX-6*)
- # QNX RTP
- # This may work for all QNX, but it was only reported for v6.
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD="ld -Bshareable -x"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- # dlopen is in -lc on QNX
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- RISCos-*)
- SHLIB_CFLAGS="-G 0"
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".a"
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS="-Wl,-D,08000000"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- ;;
- SCO_SV-3.2*)
- # Note, dlopen is available only on SCO 3.2.5 and greater. However,
- # this test works, since "uname -s" was non-standard in 3.2.4 and
- # below.
- if test "$GCC" = "yes" ; then
- SHLIB_CFLAGS="-fPIC -melf"
- LDFLAGS="-melf -Wl,-Bexport"
- else
- SHLIB_CFLAGS="-Kpic -belf"
- LDFLAGS="-belf -Wl,-Bexport"
- fi
- SHLIB_LD="ld -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LD_SEARCH_FLAGS=""
- ;;
- SINIX*5.4*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- SunOS-4*)
- SHLIB_CFLAGS="-PIC"
- SHLIB_LD="ld"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
-
- # SunOS can't handle version numbers with dots in them in library
- # specs, like -ltcl7.5, so use -ltcl75 instead. Also, it
- # requires an extra version number at the end of .so file names.
- # So, the library has to have a name like libtcl75.so.1.0
-
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- TCL_LIB_VERSIONS_OK=nodots
- ;;
- SunOS-5.[0-6]*)
-
- # Note: If _REENTRANT isn't defined, then Solaris
- # won't define thread-safe library routines.
-
- cat >> confdefs.h <<\EOF
-#define _REENTRANT 1
-EOF
-
- cat >> confdefs.h <<\EOF
-#define _POSIX_PTHREAD_SEMANTICS 1
-EOF
-
-
- SHLIB_CFLAGS="-KPIC"
-
- # Note: need the LIBS below, otherwise Tk won't find Tcl's
- # symbols when dynamically loaded into tclsh.
-
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- if test "$GCC" = "yes" ; then
- SHLIB_LD="$CC -shared"
- LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
- else
- SHLIB_LD="/usr/ccs/bin/ld -G -z text"
- LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
- fi
- ;;
- SunOS-5*)
-
- # Note: If _REENTRANT isn't defined, then Solaris
- # won't define thread-safe library routines.
-
- cat >> confdefs.h <<\EOF
-#define _REENTRANT 1
-EOF
-
- cat >> confdefs.h <<\EOF
-#define _POSIX_PTHREAD_SEMANTICS 1
-EOF
-
-
- SHLIB_CFLAGS="-KPIC"
- LDFLAGS=""
-
- # Check to enable 64-bit flags for compiler/linker
- if test "$do64bit" = "yes" ; then
- arch=`isainfo`
- if test "$arch" = "sparcv9 sparc" ; then
- if test "$GCC" = "yes" ; then
- echo "configure: warning: "64bit mode not supported with GCC on $system"" 1>&2
- else
- do64bit_ok=yes
- if test "$do64bitVIS" = "yes" ; then
- EXTRA_CFLAGS="-xarch=v9a"
- LDFLAGS="-xarch=v9a"
- else
- EXTRA_CFLAGS="-xarch=v9"
- LDFLAGS="-xarch=v9"
- fi
- fi
- else
- echo "configure: warning: "64bit mode only supported sparcv9 system"" 1>&2
- fi
- fi
-
- # Note: need the LIBS below, otherwise Tk won't find Tcl's
- # symbols when dynamically loaded into tclsh.
-
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- if test "$GCC" = "yes" ; then
- SHLIB_LD="$CC -shared"
- LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
- else
- SHLIB_LD="/usr/ccs/bin/ld -G -z text"
- LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
- fi
- ;;
- ULTRIX-4.*)
- SHLIB_CFLAGS="-G 0"
- SHLIB_SUFFIX=".a"
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
- SHLIB_LD_LIBS='${LIBS}'
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS="-Wl,-D,08000000"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- if test "$GCC" != "yes" ; then
- EXTRA_CFLAGS="-DHAVE_TZSET -std1"
- fi
- ;;
- UNIX_SV* | UnixWare-5*)
- SHLIB_CFLAGS="-KPIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
- # that don't grok the -Bexport option. Test that it does.
- hold_ldflags=$LDFLAGS
- echo $ac_n "checking for ld accepts -Bexport flag""... $ac_c" 1>&6
-echo "configure:3296: checking for ld accepts -Bexport flag" >&5
- LDFLAGS="${LDFLAGS} -Wl,-Bexport"
- cat > conftest.$ac_ext <<EOF
-#line 3299 "configure"
-#include "confdefs.h"
-
-int main() {
-int i;
-; return 0; }
-EOF
-if { (eval echo configure:3306: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- found=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- found=no
-fi
-rm -f conftest*
- LDFLAGS=$hold_ldflags
- echo "$ac_t""$found" 1>&6
- if test $found = yes; then
- LDFLAGS="-Wl,-Bexport"
- else
- LDFLAGS=""
- fi
- LD_SEARCH_FLAGS=""
- ;;
- esac
-
- if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then
- echo "configure: warning: "64bit support being disabled -- don\'t know magic for this platform"" 1>&2
- fi
-
- # Step 4: If pseudo-static linking is in use (see K. B. Kenny, "Dynamic
- # Loading for Tcl -- What Became of It?". Proc. 2nd Tcl/Tk Workshop,
- # New Orleans, LA, Computerized Processes Unlimited, 1994), then we need
- # to determine which of several header files defines the a.out file
- # format (a.out.h, sys/exec.h, or sys/exec_aout.h). At present, we
- # support only a file format that is more or less version-7-compatible.
- # In particular,
- # - a.out files must begin with `struct exec'.
- # - the N_TXTOFF on the `struct exec' must compute the seek address
- # of the text segment
- # - The `struct exec' must contain a_magic, a_text, a_data, a_bss
- # and a_entry fields.
- # The following compilation should succeed if and only if either sys/exec.h
- # or a.out.h is usable for the purpose.
- #
- # Note that the modified COFF format used on MIPS Ultrix 4.x is usable; the
- # `struct exec' includes a second header that contains information that
- # duplicates the v7 fields that are needed.
-
- if test "x$DL_OBJS" = "xtclLoadAout.o" ; then
- echo $ac_n "checking sys/exec.h""... $ac_c" 1>&6
-echo "configure:3352: checking sys/exec.h" >&5
- cat > conftest.$ac_ext <<EOF
-#line 3354 "configure"
-#include "confdefs.h"
-#include <sys/exec.h>
-int main() {
-
- struct exec foo;
- unsigned long seek;
- int flag;
-#if defined(__mips) || defined(mips)
- seek = N_TXTOFF (foo.ex_f, foo.ex_o);
-#else
- seek = N_TXTOFF (foo);
-#endif
- flag = (foo.a_magic == OMAGIC);
- return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
-
-; return 0; }
-EOF
-if { (eval echo configure:3372: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- tcl_ok=usable
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- tcl_ok=unusable
-fi
-rm -f conftest*
- echo "$ac_t""$tcl_ok" 1>&6
- if test $tcl_ok = usable; then
- cat >> confdefs.h <<\EOF
-#define USE_SYS_EXEC_H 1
-EOF
-
- else
- echo $ac_n "checking a.out.h""... $ac_c" 1>&6
-echo "configure:3390: checking a.out.h" >&5
- cat > conftest.$ac_ext <<EOF
-#line 3392 "configure"
-#include "confdefs.h"
-#include <a.out.h>
-int main() {
-
- struct exec foo;
- unsigned long seek;
- int flag;
-#if defined(__mips) || defined(mips)
- seek = N_TXTOFF (foo.ex_f, foo.ex_o);
-#else
- seek = N_TXTOFF (foo);
-#endif
- flag = (foo.a_magic == OMAGIC);
- return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
-
-; return 0; }
-EOF
-if { (eval echo configure:3410: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- tcl_ok=usable
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- tcl_ok=unusable
-fi
-rm -f conftest*
- echo "$ac_t""$tcl_ok" 1>&6
- if test $tcl_ok = usable; then
- cat >> confdefs.h <<\EOF
-#define USE_A_OUT_H 1
-EOF
-
- else
- echo $ac_n "checking sys/exec_aout.h""... $ac_c" 1>&6
-echo "configure:3428: checking sys/exec_aout.h" >&5
- cat > conftest.$ac_ext <<EOF
-#line 3430 "configure"
-#include "confdefs.h"
-#include <sys/exec_aout.h>
-int main() {
-
- struct exec foo;
- unsigned long seek;
- int flag;
-#if defined(__mips) || defined(mips)
- seek = N_TXTOFF (foo.ex_f, foo.ex_o);
-#else
- seek = N_TXTOFF (foo);
-#endif
- flag = (foo.a_midmag == OMAGIC);
- return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
-
-; return 0; }
-EOF
-if { (eval echo configure:3448: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- tcl_ok=usable
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- tcl_ok=unusable
-fi
-rm -f conftest*
- echo "$ac_t""$tcl_ok" 1>&6
- if test $tcl_ok = usable; then
- cat >> confdefs.h <<\EOF
-#define USE_SYS_EXEC_AOUT_H 1
-EOF
-
- else
- DL_OBJS=""
- fi
- fi
- fi
- fi
-
- # Step 5: disable dynamic loading if requested via a command-line switch.
-
- # Check whether --enable-load or --disable-load was given.
-if test "${enable_load+set}" = set; then
- enableval="$enable_load"
- tcl_ok=$enableval
-else
- tcl_ok=yes
-fi
-
- if test "$tcl_ok" = "no"; then
- DL_OBJS=""
- fi
-
- if test "x$DL_OBJS" != "x" ; then
- BUILD_DLTEST="\$(DLTEST_TARGETS)"
- else
- echo "Can't figure out how to do dynamic loading or shared libraries"
- echo "on this system."
- SHLIB_CFLAGS=""
- SHLIB_LD=""
- SHLIB_SUFFIX=""
- DL_OBJS="tclLoadNone.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- BUILD_DLTEST=""
- fi
-
- # If we're running gcc, then change the C flags for compiling shared
- # libraries to the right flags for gcc, instead of those for the
- # standard manufacturer compiler.
-
- if test "$DL_OBJS" != "tclLoadNone.o" ; then
- if test "$GCC" = "yes" ; then
- case $system in
- AIX-*)
- ;;
- BSD/OS*)
- ;;
- IRIX*)
- ;;
- NetBSD-*|FreeBSD-*|OpenBSD-*)
- ;;
- Rhapsody-*|Darwin-*)
- ;;
- RISCos-*)
- ;;
- SCO_SV-3.2*)
- ;;
- ULTRIX-4.*)
- ;;
- windows)
- if test "$MINGW32" != "yes"; then
- SHLIB_CFLAGS="-fPIC"
- fi
- ;;
- *)
- SHLIB_CFLAGS="-fPIC"
- ;;
- esac
- fi
- fi
-
- if test "$SHARED_LIB_SUFFIX" = "" ; then
- SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}${SHLIB_SUFFIX}'
- fi
- if test "$UNSHARED_LIB_SUFFIX" = "" ; then
- UNSHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a'
- fi
-
-
-
-
-
-
-
- SHLIB_LDFLAGS='$(LDFLAGS_DEFAULT)'
-
-
-
-
-
-
-
-
-
-#--------------------------------------------------------------------
-# Set the default compiler switches based on the --enable-symbols option.
-#--------------------------------------------------------------------
-
- if test x"${TEA_INITED}" = x ; then
- # Can't refer to exact macro name or it will be substituted
- { echo "configure: error: Must call TEA INIT before ENABLE_SYMBOLS" 1>&2; exit 1; }
- fi
-
- if test "${TEA_PLATFORM}" = "windows" ; then
- tcl_dbgx=d
- else
- tcl_dbgx=g
- fi
-
- echo $ac_n "checking for build with symbols""... $ac_c" 1>&6
-echo "configure:3574: checking for build with symbols" >&5
- # Check whether --enable-symbols or --disable-symbols was given.
-if test "${enable_symbols+set}" = set; then
- enableval="$enable_symbols"
- tcl_ok=$enableval
-else
- tcl_ok=no
-fi
-
- if test "$tcl_ok" = "no"; then
- CFLAGS_DEFAULT='$(CFLAGS_OPTIMIZE)'
- LDFLAGS_DEFAULT='$(LDFLAGS_OPTIMIZE)'
- DBGX=""
- TCL_DBGX=""
- echo "$ac_t""no" 1>&6
- else
- CFLAGS_DEFAULT='$(CFLAGS_DEBUG)'
- LDFLAGS_DEFAULT='$(LDFLAGS_DEBUG)'
- DBGX=${tcl_dbgx}
- TCL_DBGX=${tcl_dbgx}
- if test "$tcl_ok" = "yes"; then
- echo "$ac_t""yes (standard debugging)" 1>&6
- fi
- fi
-
-
-
-
-
- if test "$tcl_ok" = "mem" -o "$tcl_ok" = "all"; then
- cat >> confdefs.h <<\EOF
-#define TCL_MEM_DEBUG 1
-EOF
-
- fi
-
- if test "$tcl_ok" != "yes" -a "$tcl_ok" != "no"; then
- if test "$tcl_ok" = "all"; then
- echo "$ac_t""enabled symbols mem debugging" 1>&6
- else
- echo "$ac_t""enabled $tcl_ok debugging" 1>&6
- fi
- fi
-
-
-#--------------------------------------------------------------------
-# For Unix/Tk builds, make sure that the X libraries/headers are found.
-# This must be called after TEA_CONFIG_CFLAGS as it adjusts LIBS.
-#--------------------------------------------------------------------
-
- if test "${TEA_PLATFORM}" = "unix" ; then
-
- # If we find X, set shell vars x_includes and x_libraries to the
-# paths, otherwise set no_x=yes.
-# Uses ac_ vars as temps to allow command line to override cache and checks.
-# --without-x overrides everything else, but does not touch the cache.
-echo $ac_n "checking for X""... $ac_c" 1>&6
-echo "configure:3631: checking for X" >&5
-
-# Check whether --with-x or --without-x was given.
-if test "${with_x+set}" = set; then
- withval="$with_x"
- :
-fi
-
-# $have_x is `yes', `no', `disabled', or empty when we do not yet know.
-if test "x$with_x" = xno; then
- # The user explicitly disabled X.
- have_x=disabled
-else
- if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
- # Both variables are already set.
- have_x=yes
- else
-if eval "test \"`echo '$''{'ac_cv_have_x'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- # One or both of the vars are not set, and there is no cached value.
-ac_x_includes=NO ac_x_libraries=NO
-rm -fr conftestdir
-if mkdir conftestdir; then
- cd conftestdir
- # Make sure to not put "make" in the Imakefile rules, since we grep it out.
- cat > Imakefile <<'EOF'
-acfindx:
- @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
-EOF
- if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
- # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
- eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
- # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
- for ac_extension in a so sl; do
- if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
- test -f $ac_im_libdir/libX11.$ac_extension; then
- ac_im_usrlibdir=$ac_im_libdir; break
- fi
- done
- # Screen out bogus values from the imake configuration. They are
- # bogus both because they are the default anyway, and because
- # using them would break gcc on systems where it needs fixed includes.
- case "$ac_im_incroot" in
- /usr/include) ;;
- *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
- esac
- case "$ac_im_usrlibdir" in
- /usr/lib | /lib) ;;
- *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
- esac
- fi
- cd ..
- rm -fr conftestdir
-fi
-
-if test "$ac_x_includes" = NO; then
- # Guess where to find include files, by looking for this one X11 .h file.
- test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
-
- # First, try using that file with no special directory specified.
-cat > conftest.$ac_ext <<EOF
-#line 3693 "configure"
-#include "confdefs.h"
-#include <$x_direct_test_include>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3698: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- rm -rf conftest*
- # We can compile using X headers with no special include directory.
-ac_x_includes=
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- # Look for the header file in a standard set of common directories.
-# Check X11 before X11Rn because it is often a symlink to the current release.
- for ac_dir in \
- /usr/X11/include \
- /usr/X11R6/include \
- /usr/X11R5/include \
- /usr/X11R4/include \
- \
- /usr/include/X11 \
- /usr/include/X11R6 \
- /usr/include/X11R5 \
- /usr/include/X11R4 \
- \
- /usr/local/X11/include \
- /usr/local/X11R6/include \
- /usr/local/X11R5/include \
- /usr/local/X11R4/include \
- \
- /usr/local/include/X11 \
- /usr/local/include/X11R6 \
- /usr/local/include/X11R5 \
- /usr/local/include/X11R4 \
- \
- /usr/X386/include \
- /usr/x386/include \
- /usr/XFree86/include/X11 \
- \
- /usr/include \
- /usr/local/include \
- /usr/unsupported/include \
- /usr/athena/include \
- /usr/local/x11r5/include \
- /usr/lpp/Xamples/include \
- \
- /usr/openwin/include \
- /usr/openwin/share/include \
- ; \
- do
- if test -r "$ac_dir/$x_direct_test_include"; then
- ac_x_includes=$ac_dir
- break
- fi
- done
-fi
-rm -f conftest*
-fi # $ac_x_includes = NO
-
-if test "$ac_x_libraries" = NO; then
- # Check for the libraries.
-
- test -z "$x_direct_test_library" && x_direct_test_library=Xt
- test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
-
- # See if we find them without any special options.
- # Don't add to $LIBS permanently.
- ac_save_LIBS="$LIBS"
- LIBS="-l$x_direct_test_library $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 3767 "configure"
-#include "confdefs.h"
-
-int main() {
-${x_direct_test_function}()
-; return 0; }
-EOF
-if { (eval echo configure:3774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- LIBS="$ac_save_LIBS"
-# We can link X programs with no special library path.
-ac_x_libraries=
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- LIBS="$ac_save_LIBS"
-# First see if replacing the include by lib works.
-# Check X11 before X11Rn because it is often a symlink to the current release.
-for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
- /usr/X11/lib \
- /usr/X11R6/lib \
- /usr/X11R5/lib \
- /usr/X11R4/lib \
- \
- /usr/lib/X11 \
- /usr/lib/X11R6 \
- /usr/lib/X11R5 \
- /usr/lib/X11R4 \
- \
- /usr/local/X11/lib \
- /usr/local/X11R6/lib \
- /usr/local/X11R5/lib \
- /usr/local/X11R4/lib \
- \
- /usr/local/lib/X11 \
- /usr/local/lib/X11R6 \
- /usr/local/lib/X11R5 \
- /usr/local/lib/X11R4 \
- \
- /usr/X386/lib \
- /usr/x386/lib \
- /usr/XFree86/lib/X11 \
- \
- /usr/lib \
- /usr/local/lib \
- /usr/unsupported/lib \
- /usr/athena/lib \
- /usr/local/x11r5/lib \
- /usr/lpp/Xamples/lib \
- /lib/usr/lib/X11 \
- \
- /usr/openwin/lib \
- /usr/openwin/share/lib \
- ; \
-do
- for ac_extension in a so sl; do
- if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
- ac_x_libraries=$ac_dir
- break 2
- fi
- done
-done
-fi
-rm -f conftest*
-fi # $ac_x_libraries = NO
-
-if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
- # Didn't find X anywhere. Cache the known absence of X.
- ac_cv_have_x="have_x=no"
-else
- # Record where we found X for the cache.
- ac_cv_have_x="have_x=yes \
- ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
-fi
-fi
- fi
- eval "$ac_cv_have_x"
-fi # $with_x != no
-
-if test "$have_x" != yes; then
- echo "$ac_t""$have_x" 1>&6
- no_x=yes
-else
- # If each of the values was on the command line, it overrides each guess.
- test "x$x_includes" = xNONE && x_includes=$ac_x_includes
- test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
- # Update the cache value to reflect the command line values.
- ac_cv_have_x="have_x=yes \
- ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
- echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
-fi
-
- not_really_there=""
- if test "$no_x" = ""; then
- if test "$x_includes" = ""; then
- cat > conftest.$ac_ext <<EOF
-#line 3864 "configure"
-#include "confdefs.h"
-#include <X11/XIntrinsic.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3869: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- not_really_there="yes"
-fi
-rm -f conftest*
- else
- if test ! -r $x_includes/X11/Intrinsic.h; then
- not_really_there="yes"
- fi
- fi
- fi
- if test "$no_x" = "yes" -o "$not_really_there" = "yes"; then
- echo $ac_n "checking for X11 header files""... $ac_c" 1>&6
-echo "configure:3889: checking for X11 header files" >&5
- XINCLUDES="# no special path needed"
- cat > conftest.$ac_ext <<EOF
-#line 3892 "configure"
-#include "confdefs.h"
-#include <X11/Intrinsic.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3897: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- XINCLUDES="nope"
-fi
-rm -f conftest*
- if test "$XINCLUDES" = nope; then
- dirs="/usr/unsupported/include /usr/local/include /usr/X386/include /usr/X11R6/include /usr/X11R5/include /usr/include/X11R5 /usr/include/X11R4 /usr/openwin/include /usr/X11/include /usr/sww/include"
- for i in $dirs ; do
- if test -r $i/X11/Intrinsic.h; then
- echo "$ac_t""$i" 1>&6
- XINCLUDES=" -I$i"
- break
- fi
- done
- fi
- else
- if test "$x_includes" != ""; then
- XINCLUDES=-I$x_includes
- else
- XINCLUDES="# no special path needed"
- fi
- fi
- if test "$XINCLUDES" = nope; then
- echo "$ac_t""could not find any!" 1>&6
- XINCLUDES="# no include files found"
- fi
-
- if test "$no_x" = yes; then
- echo $ac_n "checking for X11 libraries""... $ac_c" 1>&6
-echo "configure:3933: checking for X11 libraries" >&5
- XLIBSW=nope
- dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib"
- for i in $dirs ; do
- if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then
- echo "$ac_t""$i" 1>&6
- XLIBSW="-L$i -lX11"
- x_libraries="$i"
- break
- fi
- done
- else
- if test "$x_libraries" = ""; then
- XLIBSW=-lX11
- else
- XLIBSW="-L$x_libraries -lX11"
- fi
- fi
- if test "$XLIBSW" = nope ; then
- echo $ac_n "checking for XCreateWindow in -lXwindow""... $ac_c" 1>&6
-echo "configure:3953: checking for XCreateWindow in -lXwindow" >&5
-ac_lib_var=`echo Xwindow'_'XCreateWindow | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lXwindow $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 3961 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char XCreateWindow();
-
-int main() {
-XCreateWindow()
-; return 0; }
-EOF
-if { (eval echo configure:3972: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- XLIBSW=-lXwindow
-else
- echo "$ac_t""no" 1>&6
-fi
-
- fi
- if test "$XLIBSW" = nope ; then
- echo "$ac_t""could not find any! Using -lX11." 1>&6
- XLIBSW=-lX11
- fi
- if test x"${XLIBSW}" != x ; then
- LIBS="${LIBS} ${XLIBSW}"
- fi
-
- fi
-
-
-#--------------------------------------------------------------------
-# This sets the tesselation library name and adjust LIBS to
-# include this library.
-#--------------------------------------------------------------------
-if test "${TEA_PLATFORM}" = "windows" ; then
- Tess_LIB_FILE=tess.lib
-else
- Tess_LIB_FILE=libtess.a
-fi
-LIBS="${LIBS} -L. -ltess"
-
-
-#--------------------------------------------------------------------
-# Tkzinc is always linked against the tcl and tk stubs libraries
-#--------------------------------------------------------------------
-cat >> confdefs.h <<\EOF
-#define USE_TCL_STUBS 1
-EOF
-
-cat >> confdefs.h <<\EOF
-#define USE_TK_STUBS 1
-EOF
-
-
-#--------------------------------------------------------------------
-# This macro generates a line to use when building a library. It
-# depends on values set by the TEA_ENABLE_SHARED, TEA_ENABLE_SYMBOLS,
-# and TEA_LOAD_TCLCONFIG macros above.
-#--------------------------------------------------------------------
-
- if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes"; then
- MAKE_STATIC_LIB="\${STLIB_LD} -out:\$@ \$(\$(PACKAGE)_OBJECTS)"
- MAKE_SHARED_LIB="\${SHLIB_LD} \${SHLIB_LDFLAGS} \${SHLIB_LD_LIBS} \$(LDFLAGS) -out:\$@ \$(\$(PACKAGE)_OBJECTS)"
- MAKE_STUB_LIB="\${STLIB_LD} -out:\$@ \$(\$(PACKAGE)stub_OBJECTS)"
- else
- MAKE_STATIC_LIB="\${STLIB_LD} \$@ \$(\$(PACKAGE)_OBJECTS)"
- MAKE_SHARED_LIB="\${SHLIB_LD} -o \$@ \$(\$(PACKAGE)_OBJECTS) \${SHLIB_LDFLAGS} \${SHLIB_LD_LIBS}"
- MAKE_STUB_LIB="\${STLIB_LD} \$@ \$(\$(PACKAGE)stub_OBJECTS)"
- fi
-
- if test "${SHARED_BUILD}" = "1" ; then
- MAKE_LIB="${MAKE_SHARED_LIB} "
- else
- MAKE_LIB="${MAKE_STATIC_LIB} "
- fi
-
- #--------------------------------------------------------------------
- # Shared libraries and static libraries have different names.
- # Use the double eval to make sure the ${DBGX} in the suffix is
- # substituted.
- #--------------------------------------------------------------------
-
- if test "${TEA_PLATFORM}" = "windows" ; then
- if test "${SHARED_BUILD}" = "1" ; then
- # We force the unresolved linking of symbols that are really in
- # the private libraries of Tcl and Tk.
- SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}`\""
- if test x"${TK_BIN_DIR}" != x ; then
- SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TK_BIN_DIR}/${TK_STUB_LIB_FILE}`\""
- fi
- eval eval "${PACKAGE}_LIB_FILE=${PACKAGE}${SHARED_LIB_SUFFIX}"
- RANLIB=:
- else
- eval eval "${PACKAGE}_LIB_FILE=${PACKAGE}${UNSHARED_LIB_SUFFIX}"
- fi
- # Some packages build there own stubs libraries
- eval eval "${PACKAGE}stub_LIB_FILE=${PACKAGE}stub${UNSHARED_LIB_SUFFIX}"
- else
- if test "${SHARED_BUILD}" = "1" ; then
- SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TCL_STUB_LIB_SPEC}"
- if test x"${TK_BIN_DIR}" != x ; then
- SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TK_STUB_LIB_SPEC}"
- fi
- eval eval "${PACKAGE}_LIB_FILE=lib${PACKAGE}${SHARED_LIB_SUFFIX}"
- #RANLIB=:
- else
- eval eval "${PACKAGE}_LIB_FILE=lib${PACKAGE}${UNSHARED_LIB_SUFFIX}"
- fi
- # Some packages build there own stubs libraries
- eval eval "${PACKAGE}stub_LIB_FILE=lib${PACKAGE}stub${UNSHARED_LIB_SUFFIX}"
- fi
-
- # These are escaped so that only CFLAGS is picked up at configure time.
- # The other values will be substituted at make time.
- CFLAGS="${CFLAGS} \${CFLAGS_DEFAULT} \${CFLAGS_WARNING}"
- if test "${SHARED_BUILD}" = "1" ; then
- CFLAGS="${CFLAGS} \${SHLIB_CFLAGS}"
- fi
-
-
-
-
-
-
-
-#--------------------------------------------------------------------
-# Add platform libs to LIBS or SHLIB_LD_LIBS as necessary.
-#--------------------------------------------------------------------
-if test "${TEA_PLATFORM}" = "windows" ; then
- LIBS="${LIBS} -lgdi32 -luser32 -lwsock32"
-fi
-#SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -lxxxx"
-
-#--------------------------------------------------------------------
-# Find tclsh so that we can run pkg_mkIndex to generate the pkgIndex.tcl
-# file during the install process. Don't run the TCLSH_PROG through
-# ${CYGPATH} because it's being used directly by make.
-# Require that we use a tclsh shell version 8.2 or later since earlier
-# versions have bugs in the pkg_mkIndex routine.
-# Add WISH as well since Tkzinc is a Tk extension.
-#--------------------------------------------------------------------
-
- echo $ac_n "checking for tclsh""... $ac_c" 1>&6
-echo "configure:4117: checking for tclsh" >&5
-
- if eval "test \"`echo '$''{'ac_cv_path_tclsh'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
-
- search_path=`echo ${TCL_BIN_DIR}:${TCL_BIN_DIR}/../bin:${exec_prefix}/bin:${prefix}/bin:${PATH} | sed -e 's/:/ /g'`
- for dir in $search_path ; do
- for j in `ls -r $dir/tclsh[8-9]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/tclsh*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_tclsh" = x ; then
- if test -f "$j" ; then
- ac_cv_path_tclsh=$j
- break
- fi
- fi
- done
- done
-
-fi
-
-
- if test -f "$ac_cv_path_tclsh" ; then
- TCLSH_PROG=$ac_cv_path_tclsh
- echo "$ac_t""$TCLSH_PROG" 1>&6
- else
- { echo "configure: error: No tclsh found in PATH: $search_path" 1>&2; exit 1; }
- fi
-
-
-
- echo $ac_n "checking for wish""... $ac_c" 1>&6
-echo "configure:4149: checking for wish" >&5
-
- if eval "test \"`echo '$''{'ac_cv_path_wish'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
-
- search_path=`echo ${TK_BIN_DIR}:${TK_BIN_DIR}/../bin:${TCL_BIN_DIR}:${TCL_BIN_DIR}/../bin:${exec_prefix}/bin:${prefix}/bin:${PATH} | sed -e 's/:/ /g'`
- for dir in $search_path ; do
- for j in `ls -r $dir/wish[8-9]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/wish*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_wish" = x ; then
- if test -f "$j" ; then
- ac_cv_path_wish=$j
- break
- fi
- fi
- done
- done
-
-fi
-
-
- if test -f "$ac_cv_path_wish" ; then
- WISH_PROG=$ac_cv_path_wish
- echo "$ac_t""$WISH_PROG" 1>&6
- else
- { echo "configure: error: No wish found in PATH: $search_path" 1>&2; exit 1; }
- fi
-
-
-
-#--------------------------------------------------------------------
-# Define the SHAPE symbol to control the X shape extension support.
-# This must be called after TEA_CONFIG_CFLAGS as it adjusts LIBS.
-#--------------------------------------------------------------------
-
- if test x"${TEA_INITED}" = x ; then
- { echo "configure: error: Must call TEA INIT before ENABLE_SHAPE" 1>&2; exit 1; }
- fi
- echo $ac_n "checking for build with X shape support""... $ac_c" 1>&6
-echo "configure:4189: checking for build with X shape support" >&5
- # Check whether --enable-shape or --disable-shape was given.
-if test "${enable_shape+set}" = set; then
- enableval="$enable_shape"
- tcl_ok=$enableval
-else
- tcl_ok=yes
-fi
-
- if test "$tcl_ok" = "no"; then
- echo "$ac_t""no" 1>&6
- else
- if test "${TEA_PLATFORM}" = "windows" ; then
- echo "$ac_t""no (not available on windows)" 1>&6
- else
- cat >> confdefs.h <<\EOF
-#define SHAPE 1
-EOF
-
- echo "$ac_t""yes" 1>&6
- LIBS="${LIBS} -lXext"
- fi
- fi
-
-
-#--------------------------------------------------------------------
-# Adjust the library set based on --enable-gl option. Define also
-# the GL and GL_DAMAGE symbols to configure the code.
-# This must be called after TEA_CONFIG_CFLAGS as it adjusts LIBS.
-#--------------------------------------------------------------------
-
- if test x"${TEA_INITED}" = x ; then
- { echo "configure: error: Must call TEA INIT before ENABLE_GL" 1>&2; exit 1; }
- fi
-
- echo $ac_n "checking for build with GL""... $ac_c" 1>&6
-echo "configure:4225: checking for build with GL" >&5
- # Check whether --enable-gl or --disable-gl was given.
-if test "${enable_gl+set}" = set; then
- enableval="$enable_gl"
- tcl_ok=$enableval
-else
- tcl_ok=no
-fi
-
-
- if test "$tcl_ok" = "no"; then
- GL_LIBS=
- GL_INCLUDES=
- echo "$ac_t""no" 1>&6
- else
- if test "${TEA_PLATFORM}" = "windows" ; then
- GL_LIBS=-lopengl32
- else
- GL_LIBS="-lGL"
- GL_INCLUDES='-I/usr/include'
- fi
-
- cat >> confdefs.h <<\EOF
-#define GL 1
-EOF
-
- if test "$tcl_ok" = "damage"; then
- cat >> confdefs.h <<\EOF
-#define GL_DAMAGE 1
-EOF
-
- fi
-
- LIBS="$LIBS $GL_LIBS"
-
- if test "$tcl_ok" = "yes"; then
- echo "$ac_t""yes (standard)" 1>&6
- else
- echo "$ac_t""yes (with damage support)" 1>&6
- fi
- fi
-
-
-
-
-
-#--------------------------------------------------------------------
-# Define the ATC symbol to control inclusion of the ATC specific code.
-#--------------------------------------------------------------------
-
- if test x"${TEA_INITED}" = x ; then
- { echo "configure: error: Must call TEA INIT before ENABLE_ATC" 1>&2; exit 1; }
- fi
-
- echo $ac_n "checking for build with the ATC extensions""... $ac_c" 1>&6
-echo "configure:4280: checking for build with the ATC extensions" >&5
- # Check whether --enable-atc or --disable-atc was given.
-if test "${enable_atc+set}" = set; then
- enableval="$enable_atc"
- tcl_ok=$enableval
-else
- tcl_ok=yes
-fi
-
- if test "$tcl_ok" = "no"; then
- Atc_SOURCES=
- echo "$ac_t""no" 1>&6
- else
- cat >> confdefs.h <<\EOF
-#define ATC 1
-EOF
-
- Atc_SOURCES="OverlapMan.c Track.c Reticle.c Map.c MapInfo.c"
- echo "$ac_t""yes" 1>&6
- fi
-
-
-
-#--------------------------------------------------------------------
-# Finally, substitute all of the various values into the Makefile.
-# Add other files needing substitution after Makefile.
-#--------------------------------------------------------------------
-
-
-
-trap '' 1 2 15
-cat > confcache <<\EOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs. It is not useful on other systems.
-# If it contains results you don't want to keep, you may remove or edit it.
-#
-# By default, configure uses ./config.cache as the cache file,
-# creating it if it does not exist already. You can give configure
-# the --cache-file=FILE option to use a different cache file; that is
-# what configure does when it calls configure scripts in
-# subdirectories, so they share the cache.
-# Giving --cache-file=/dev/null disables caching, for debugging configure.
-# config.status only pays attention to the cache file if you give it the
-# --recheck option to rerun configure.
-#
-EOF
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, don't put newlines in cache variables' values.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(set) 2>&1 |
- case `(ac_space=' '; set | grep ac_space) 2>&1` in
- *ac_space=\ *)
- # `set' does not quote correctly, so add quotes (double-quote substitution
- # turns \\\\ into \\, and sed turns \\ into \).
- sed -n \
- -e "s/'/'\\\\''/g" \
- -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
- ;;
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
- ;;
- esac >> confcache
-if cmp -s $cache_file confcache; then
- :
-else
- if test -w $cache_file; then
- echo "updating cache $cache_file"
- cat confcache > $cache_file
- else
- echo "not updating unwritable cache $cache_file"
- fi
-fi
-rm -f confcache
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# Any assignment to VPATH causes Sun make to only execute
-# the first set of double-colon rules, so remove it if not needed.
-# If there is a colon in the path, we need to keep it.
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
-fi
-
-trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
-
-# Transform confdefs.h into DEFS.
-# Protect against shell expansion while executing Makefile rules.
-# Protect against Makefile macro expansion.
-cat > conftest.defs <<\EOF
-s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
-s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
-s%\[%\\&%g
-s%\]%\\&%g
-s%\$%$$%g
-EOF
-DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
-rm -f conftest.defs
-
-
-# Without the "./", some shells look in PATH for config.status.
-: ${CONFIG_STATUS=./config.status}
-
-echo creating $CONFIG_STATUS
-rm -f $CONFIG_STATUS
-cat > $CONFIG_STATUS <<EOF
-#! /bin/sh
-# Generated automatically by configure.
-# Run this file to recreate the current configuration.
-# This directory was configured as follows,
-# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-#
-# $0 $ac_configure_args
-#
-# Compiler output produced by configure, useful for debugging
-# configure, is in ./config.log if it exists.
-
-ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
-for ac_option
-do
- case "\$ac_option" in
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
- exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
- -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
- echo "$CONFIG_STATUS generated by autoconf version 2.13"
- exit 0 ;;
- -help | --help | --hel | --he | --h)
- echo "\$ac_cs_usage"; exit 0 ;;
- *) echo "\$ac_cs_usage"; exit 1 ;;
- esac
-done
-
-ac_given_srcdir=$srcdir
-ac_given_INSTALL="$INSTALL"
-
-trap 'rm -fr `echo "Makefile starkit.tcl Perl/Makefile.PL Perl/Zinc.pm Python/Zinc.py win/makefile.vc win/Tkzinc.aip win/Tkzincperl.aip" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
-EOF
-cat >> $CONFIG_STATUS <<EOF
-
-# Protect against being on the right side of a sed subst in config.status.
-sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
- s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
-$ac_vpsub
-$extrasub
-s%@SHELL@%$SHELL%g
-s%@CFLAGS@%$CFLAGS%g
-s%@CPPFLAGS@%$CPPFLAGS%g
-s%@CXXFLAGS@%$CXXFLAGS%g
-s%@FFLAGS@%$FFLAGS%g
-s%@DEFS@%$DEFS%g
-s%@LDFLAGS@%$LDFLAGS%g
-s%@LIBS@%$LIBS%g
-s%@exec_prefix@%$exec_prefix%g
-s%@prefix@%$prefix%g
-s%@program_transform_name@%$program_transform_name%g
-s%@bindir@%$bindir%g
-s%@sbindir@%$sbindir%g
-s%@libexecdir@%$libexecdir%g
-s%@datadir@%$datadir%g
-s%@sysconfdir@%$sysconfdir%g
-s%@sharedstatedir@%$sharedstatedir%g
-s%@localstatedir@%$localstatedir%g
-s%@libdir@%$libdir%g
-s%@includedir@%$includedir%g
-s%@oldincludedir@%$oldincludedir%g
-s%@infodir@%$infodir%g
-s%@mandir@%$mandir%g
-s%@CONFIGDIR@%$CONFIGDIR%g
-s%@CYGPATH@%$CYGPATH%g
-s%@EXEEXT@%$EXEEXT%g
-s%@MAJOR_VERSION@%$MAJOR_VERSION%g
-s%@MINOR_VERSION@%$MINOR_VERSION%g
-s%@PATCHLEVEL@%$PATCHLEVEL%g
-s%@VERSION@%$VERSION%g
-s%@WIN_VERSION@%$WIN_VERSION%g
-s%@PACKAGE@%$PACKAGE%g
-s%@Tkzinc_LIB_FILE@%$Tkzinc_LIB_FILE%g
-s%@Tkzincstub_LIB_FILE@%$Tkzincstub_LIB_FILE%g
-s%@TCL_VERSION@%$TCL_VERSION%g
-s%@TCL_BIN_DIR@%$TCL_BIN_DIR%g
-s%@TCL_SRC_DIR@%$TCL_SRC_DIR%g
-s%@TCL_LIB_FILE@%$TCL_LIB_FILE%g
-s%@TCL_LIB_FLAG@%$TCL_LIB_FLAG%g
-s%@TCL_LIB_SPEC@%$TCL_LIB_SPEC%g
-s%@TCL_STUB_LIB_FILE@%$TCL_STUB_LIB_FILE%g
-s%@TCL_STUB_LIB_FLAG@%$TCL_STUB_LIB_FLAG%g
-s%@TCL_STUB_LIB_SPEC@%$TCL_STUB_LIB_SPEC%g
-s%@TCL_LIBS@%$TCL_LIBS%g
-s%@TCL_DEFS@%$TCL_DEFS%g
-s%@TCL_EXTRA_CFLAGS@%$TCL_EXTRA_CFLAGS%g
-s%@TCL_LD_FLAGS@%$TCL_LD_FLAGS%g
-s%@TCL_SHLIB_LD_LIBS@%$TCL_SHLIB_LD_LIBS%g
-s%@TK_VERSION@%$TK_VERSION%g
-s%@TK_BIN_DIR@%$TK_BIN_DIR%g
-s%@TK_SRC_DIR@%$TK_SRC_DIR%g
-s%@TK_LIB_FILE@%$TK_LIB_FILE%g
-s%@TK_LIB_FLAG@%$TK_LIB_FLAG%g
-s%@TK_LIB_SPEC@%$TK_LIB_SPEC%g
-s%@TK_STUB_LIB_FILE@%$TK_STUB_LIB_FILE%g
-s%@TK_STUB_LIB_FLAG@%$TK_STUB_LIB_FLAG%g
-s%@TK_STUB_LIB_SPEC@%$TK_STUB_LIB_SPEC%g
-s%@TK_LIBS@%$TK_LIBS%g
-s%@TK_XINCLUDES@%$TK_XINCLUDES%g
-s%@CC@%$CC%g
-s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
-s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
-s%@INSTALL_DATA@%$INSTALL_DATA%g
-s%@SET_MAKE@%$SET_MAKE%g
-s%@RANLIB@%$RANLIB%g
-s%@OBJEXT@%$OBJEXT%g
-s%@TCL_TOP_DIR_NATIVE@%$TCL_TOP_DIR_NATIVE%g
-s%@TCL_GENERIC_DIR_NATIVE@%$TCL_GENERIC_DIR_NATIVE%g
-s%@TCL_UNIX_DIR_NATIVE@%$TCL_UNIX_DIR_NATIVE%g
-s%@TCL_WIN_DIR_NATIVE@%$TCL_WIN_DIR_NATIVE%g
-s%@TCL_BMAP_DIR_NATIVE@%$TCL_BMAP_DIR_NATIVE%g
-s%@TCL_TOOL_DIR_NATIVE@%$TCL_TOOL_DIR_NATIVE%g
-s%@TCL_PLATFORM_DIR_NATIVE@%$TCL_PLATFORM_DIR_NATIVE%g
-s%@TCL_INCLUDES@%$TCL_INCLUDES%g
-s%@TK_TOP_DIR_NATIVE@%$TK_TOP_DIR_NATIVE%g
-s%@TK_UNIX_DIR_NATIVE@%$TK_UNIX_DIR_NATIVE%g
-s%@TK_WIN_DIR_NATIVE@%$TK_WIN_DIR_NATIVE%g
-s%@TK_GENERIC_DIR_NATIVE@%$TK_GENERIC_DIR_NATIVE%g
-s%@TK_XLIB_DIR_NATIVE@%$TK_XLIB_DIR_NATIVE%g
-s%@TK_PLATFORM_DIR_NATIVE@%$TK_PLATFORM_DIR_NATIVE%g
-s%@TK_INCLUDES@%$TK_INCLUDES%g
-s%@CLEANFILES@%$CLEANFILES%g
-s%@EXTRA_SOURCES@%$EXTRA_SOURCES%g
-s%@TCL_THREADS@%$TCL_THREADS%g
-s%@SHARED_BUILD@%$SHARED_BUILD%g
-s%@AR@%$AR%g
-s%@CPP@%$CPP%g
-s%@DL_LIBS@%$DL_LIBS%g
-s%@CFLAGS_DEBUG@%$CFLAGS_DEBUG%g
-s%@CFLAGS_OPTIMIZE@%$CFLAGS_OPTIMIZE%g
-s%@CFLAGS_WARNING@%$CFLAGS_WARNING%g
-s%@EXTRA_CFLAGS@%$EXTRA_CFLAGS%g
-s%@STLIB_LD@%$STLIB_LD%g
-s%@SHLIB_LD@%$SHLIB_LD%g
-s%@SHLIB_CFLAGS@%$SHLIB_CFLAGS%g
-s%@SHLIB_LDFLAGS@%$SHLIB_LDFLAGS%g
-s%@SHLIB_LD_LIBS@%$SHLIB_LD_LIBS%g
-s%@LDFLAGS_DEBUG@%$LDFLAGS_DEBUG%g
-s%@LDFLAGS_OPTIMIZE@%$LDFLAGS_OPTIMIZE%g
-s%@TCL_DBGX@%$TCL_DBGX%g
-s%@CFLAGS_DEFAULT@%$CFLAGS_DEFAULT%g
-s%@LDFLAGS_DEFAULT@%$LDFLAGS_DEFAULT%g
-s%@Tess_LIB_FILE@%$Tess_LIB_FILE%g
-s%@MAKE_LIB@%$MAKE_LIB%g
-s%@MAKE_SHARED_LIB@%$MAKE_SHARED_LIB%g
-s%@MAKE_STATIC_LIB@%$MAKE_STATIC_LIB%g
-s%@MAKE_STUB_LIB@%$MAKE_STUB_LIB%g
-s%@TCLSH_PROG@%$TCLSH_PROG%g
-s%@WISH_PROG@%$WISH_PROG%g
-s%@GL_LIBS@%$GL_LIBS%g
-s%@GL_INCLUDES@%$GL_INCLUDES%g
-s%@Atc_SOURCES@%$Atc_SOURCES%g
-s%@aux_BINARIES@%$aux_BINARIES%g
-s%@bin_BINARIES@%$bin_BINARIES%g
-
-CEOF
-EOF
-
-cat >> $CONFIG_STATUS <<\EOF
-
-# Split the substitutions into bite-sized pieces for seds with
-# small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
-ac_file=1 # Number of current file.
-ac_beg=1 # First line for current file.
-ac_end=$ac_max_sed_cmds # Line after last line for current file.
-ac_more_lines=:
-ac_sed_cmds=""
-while $ac_more_lines; do
- if test $ac_beg -gt 1; then
- sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
- else
- sed "${ac_end}q" conftest.subs > conftest.s$ac_file
- fi
- if test ! -s conftest.s$ac_file; then
- ac_more_lines=false
- rm -f conftest.s$ac_file
- else
- if test -z "$ac_sed_cmds"; then
- ac_sed_cmds="sed -f conftest.s$ac_file"
- else
- ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
- fi
- ac_file=`expr $ac_file + 1`
- ac_beg=$ac_end
- ac_end=`expr $ac_end + $ac_max_sed_cmds`
- fi
-done
-if test -z "$ac_sed_cmds"; then
- ac_sed_cmds=cat
-fi
-EOF
-
-cat >> $CONFIG_STATUS <<EOF
-
-CONFIG_FILES=\${CONFIG_FILES-"Makefile starkit.tcl Perl/Makefile.PL Perl/Zinc.pm Python/Zinc.py win/makefile.vc win/Tkzinc.aip win/Tkzincperl.aip"}
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
- # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case "$ac_file" in
- *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
- ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- *) ac_file_in="${ac_file}.in" ;;
- esac
-
- # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
-
- # Remove last slash and all that follows it. Not all systems have dirname.
- ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
- if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
- # The file is in a subdirectory.
- test ! -d "$ac_dir" && mkdir "$ac_dir"
- ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
- # A "../" for each directory in $ac_dir_suffix.
- ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
- else
- ac_dir_suffix= ac_dots=
- fi
-
- case "$ac_given_srcdir" in
- .) srcdir=.
- if test -z "$ac_dots"; then top_srcdir=.
- else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
- /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
- *) # Relative path.
- srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
- top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
-
- case "$ac_given_INSTALL" in
- [/$]*) INSTALL="$ac_given_INSTALL" ;;
- *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
- esac
-
- echo creating "$ac_file"
- rm -f "$ac_file"
- configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
- case "$ac_file" in
- *Makefile*) ac_comsub="1i\\
-# $configure_input" ;;
- *) ac_comsub= ;;
- esac
-
- ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
- sed -e "$ac_comsub
-s%@configure_input@%$configure_input%g
-s%@srcdir@%$srcdir%g
-s%@top_srcdir@%$top_srcdir%g
-s%@INSTALL@%$INSTALL%g
-" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
-fi; done
-rm -f conftest.s*
-
-EOF
-cat >> $CONFIG_STATUS <<EOF
-
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-
-exit 0
-EOF
-chmod +x $CONFIG_STATUS
-rm -fr confdefs* $ac_clean_files
-test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
-
diff --git a/configure.in b/configure.in
deleted file mode 100644
index 91236cf..0000000
--- a/configure.in
+++ /dev/null
@@ -1,236 +0,0 @@
-dnl
-dnl Process this file with autoconf to produce a configure script.
-dnl autoconf 2.13 should work fine. However autoconf >= 2.53 and
-dnl perhaps versions in between (2.50 and 2.52) are not directly usuable.
-dnl
-dnl
-dnl This configure.in is derived from the Sample TEA template which is:
-dnl
-dnl Copyright (c) 1999 Scriptics Corporation.
-dnl Copyright (c) 2002 ActiveState SRL.
-dnl
-dnl
-dnl $Id$
-
-#-----------------------------------------------------------------------
-# Check the source path of the package
-#-----------------------------------------------------------------------
-AC_INIT
-
-#-----------------------------------------------------------------------
-# Setup the CONFIGDIR to the path of the directory containing the
-# configuration files
-#-----------------------------------------------------------------------
-AC_CONFIG_AUX_DIR(tclconfig)
-CONFIGDIR=${srcdir}/tclconfig
-AC_SUBST(CONFIGDIR)
-
-#-----------------------------------------------------------------------
-# Define the PACKAGE variable
-#--------------------------------------------------------------------
-PACKAGE=Tkzinc
-
-#--------------------------------------------------------------------
-# Call TEA_INIT as the first TEA_ macro to set up initial vars.
-# This will define a ${TEA_PLATFORM} variable == "unix" or "windows".
-#
-# Keep it here we will need ${TEA_PLATFORM} soon.
-#--------------------------------------------------------------------
-TEA_INIT
-
-#-----------------------------------------------------------------------
-# Define the VERSION variable
-#
-# VERSION is constructed from MAJOR_VERSION, MINOR_VERSION and
-# PATCHLEVEL. The windows variant does not containt a dot.
-#-----------------------------------------------------------------------
-MAJOR_VERSION=3
-MINOR_VERSION=3
-PATCHLEVEL=0
-
-VERSION=${MAJOR_VERSION}.${MINOR_VERSION}.${PATCHLEVEL}
-
-AC_SUBST(MAJOR_VERSION)
-AC_SUBST(MINOR_VERSION)
-AC_SUBST(PATCHLEVEL)
-AC_SUBST(VERSION)
-AC_SUBST(WIN_VERSION)
-AC_SUBST(PACKAGE)
-AC_SUBST(Tkzinc_LIB_FILE)
-AC_SUBST(Tkzincstub_LIB_FILE)
-
-#--------------------------------------------------------------------
-# This define a preprocessor macro -DVERSION=3.2.6i to include
-# the package version in the sources.
-#--------------------------------------------------------------------
-eval AC_DEFINE_UNQUOTED(VERSION, "${VERSION}")
-
-#--------------------------------------------------------------------
-# Load the tclConfig.sh file
-#--------------------------------------------------------------------
-TEA_PATH_TCLCONFIG
-TEA_LOAD_TCLCONFIG
-
-#--------------------------------------------------------------------
-# Load the tkConfig.sh file
-#--------------------------------------------------------------------
-TEA_PATH_TKCONFIG
-TEA_LOAD_TKCONFIG
-
-#-----------------------------------------------------------------------
-# Handle the --prefix=... option by defaulting to what Tcl gave.
-# Must be called after TEA_LOAD_TCLCONFIG and before TEA_SETUP_COMPILER.
-#-----------------------------------------------------------------------
-TEA_PREFIX
-
-#-----------------------------------------------------------------------
-# Standard compiler checks.
-# This sets up CC by using the CC env var, or looks for gcc otherwise.
-# This also calls AC_PROG_CC, AC_PROG_INSTALL and a few others to create
-# the basic setup necessary to compile executables.
-#-----------------------------------------------------------------------
-TEA_SETUP_COMPILER
-AC_CYGWIN
-AC_MINGW32
-
-#--------------------------------------------------------------------
-# Choose which headers you need. Extension authors should try very
-# hard to only rely on the Tcl public header files. Internal headers
-# contain private data structures and are subject to change without
-# notice.
-# This MUST be called after TEA_LOAD_TCLCONFIG / TEA_LOAD_TKCONFIG
-#
-# Sorry but zinc needs the internal functionality provided by Tk
-# even if this is less convenient and secure.
-#--------------------------------------------------------------------
-TEA_PRIVATE_TCL_HEADERS
-TEA_PRIVATE_TK_HEADERS
-
-#--------------------------------------------------------------------
-# A few miscellaneous platform-specific items:
-#
-# Define the special symbol BUILD_Tkzinc for Windows so
-# that we create the export library with the dll.
-#
-# Windows creates a few extra files that need to be cleaned up.
-#
-# Define any extra compiler flags in the PACKAGE_CFLAGS variable.
-# These will be appended to the current set of compiler flags for
-# your system.
-#--------------------------------------------------------------------
-if test "${TEA_PLATFORM}" = "windows" ; then
- AC_DEFINE(BUILD_Tkzinc)
- CLEANFILES="pkgIndex.tcl *.lib *.dll *.exp *.ilk *.pdb vc*.pch"
- EXTRA_SOURCES='$(WIN_SOURCES)'
-else
- CLEANFILES="pkgIndex.tcl"
- EXTRA_SOURCES='$(UNIX_SOURCES)'
-fi
-CLEANFILES="${CLEANFILES} doc/*.dvi doc/*.aux doc/*.idx doc/*.ilg doc/*.ind"
-CLEANFILES="${CLEANFILES} doc/*.lof doc/*.log doc/*.out doc/*.toc doc/*.tpt"
-CLEANFILES="${CLEANFILES} doc/refman doc/refman.pdf"
-CLEANFILES="${CLEANFILES} Python/Zinc.py"
-
-AC_SUBST(CLEANFILES)
-AC_SUBST(EXTRA_SOURCES)
-
-#--------------------------------------------------------------------
-# Check whether --enable-threads or --disable-threads was given.
-# This call disable threading support as a default.
-#--------------------------------------------------------------------
-TEA_ENABLE_THREADS(no)
-
-#--------------------------------------------------------------------
-# The statement below defines a collection of symbols related to
-# building as a shared library instead of a static library.
-#--------------------------------------------------------------------
-TEA_ENABLE_SHARED
-
-#--------------------------------------------------------------------
-# This macro figures out what flags to use with the compiler/linker
-# when building shared/static debug/optimized objects. This information
-# can be taken from the tclConfig.sh file, but this figures it all out.
-#--------------------------------------------------------------------
-TEA_CONFIG_CFLAGS
-
-#--------------------------------------------------------------------
-# Set the default compiler switches based on the --enable-symbols option.
-#--------------------------------------------------------------------
-TEA_ENABLE_SYMBOLS
-
-#--------------------------------------------------------------------
-# For Unix/Tk builds, make sure that the X libraries/headers are found.
-# This must be called after TEA_CONFIG_CFLAGS as it adjusts LIBS.
-#--------------------------------------------------------------------
-TEA_PATH_X
-
-#--------------------------------------------------------------------
-# This sets the tesselation library name and adjust LIBS to
-# include this library.
-#--------------------------------------------------------------------
-if test "${TEA_PLATFORM}" = "windows" ; then
- Tess_LIB_FILE=tess.lib
-else
- Tess_LIB_FILE=libtess.a
-fi
-LIBS="${LIBS} -L. -ltess"
-AC_SUBST(Tess_LIB_FILE)
-
-#--------------------------------------------------------------------
-# Tkzinc is always linked against the tcl and tk stubs libraries
-#--------------------------------------------------------------------
-AC_DEFINE(USE_TCL_STUBS)
-AC_DEFINE(USE_TK_STUBS)
-
-#--------------------------------------------------------------------
-# This macro generates a line to use when building a library. It
-# depends on values set by the TEA_ENABLE_SHARED, TEA_ENABLE_SYMBOLS,
-# and TEA_LOAD_TCLCONFIG macros above.
-#--------------------------------------------------------------------
-TEA_MAKE_LIB
-
-#--------------------------------------------------------------------
-# Add platform libs to LIBS or SHLIB_LD_LIBS as necessary.
-#--------------------------------------------------------------------
-if test "${TEA_PLATFORM}" = "windows" ; then
- LIBS="${LIBS} -lgdi32 -luser32 -lwsock32"
-fi
-#SHLIB_LD_LIBS="${SHLIB_LD_LIBS} -lxxxx"
-
-#--------------------------------------------------------------------
-# Find tclsh so that we can run pkg_mkIndex to generate the pkgIndex.tcl
-# file during the install process. Don't run the TCLSH_PROG through
-# ${CYGPATH} because it's being used directly by make.
-# Require that we use a tclsh shell version 8.2 or later since earlier
-# versions have bugs in the pkg_mkIndex routine.
-# Add WISH as well since Tkzinc is a Tk extension.
-#--------------------------------------------------------------------
-TEA_PROG_TCLSH
-TEA_PROG_WISH
-
-#--------------------------------------------------------------------
-# Define the SHAPE symbol to control the X shape extension support.
-# This must be called after TEA_CONFIG_CFLAGS as it adjusts LIBS.
-#--------------------------------------------------------------------
-ZINC_ENABLE_SHAPE
-
-#--------------------------------------------------------------------
-# Adjust the library set based on --enable-gl option. Define also
-# the GL and GL_DAMAGE symbols to configure the code.
-# This must be called after TEA_CONFIG_CFLAGS as it adjusts LIBS.
-#--------------------------------------------------------------------
-ZINC_ENABLE_GL
-
-#--------------------------------------------------------------------
-# Define the ATC symbol to control inclusion of the ATC specific code.
-#--------------------------------------------------------------------
-ZINC_ENABLE_ATC
-
-#--------------------------------------------------------------------
-# Finally, substitute all of the various values into the Makefile.
-# Add other files needing substitution after Makefile.
-#--------------------------------------------------------------------
-AC_SUBST(aux_BINARIES)
-AC_SUBST(bin_BINARIES)
-
-AC_OUTPUT([Makefile starkit.tcl Perl/Makefile.PL Perl/Zinc.pm Python/Zinc.py win/makefile.vc win/Tkzinc.aip win/Tkzincperl.aip])
diff --git a/debian/.cvsignore b/debian/.cvsignore
deleted file mode 100644
index 86a8cdb..0000000
--- a/debian/.cvsignore
+++ /dev/null
@@ -1,8 +0,0 @@
-tmp
-zinc-doc
-zinc-perl
-zinc-python
-substvars
-zinc-perl.substvars
-files
-*.debhelper \ No newline at end of file
diff --git a/debian/README.debian b/debian/README.debian
deleted file mode 100644
index 9d9dbc1..0000000
--- a/debian/README.debian
+++ /dev/null
@@ -1,6 +0,0 @@
-zinc for DEBIAN
-----------------------
-
-No comments ;-)
-
-Patrick Lecoanet <lecoanet@ath.cena.fr>, Wed, 25 Feb 1998 14:11:43 +0100
diff --git a/debian/changelog b/debian/changelog
deleted file mode 100644
index a8ae2bb..0000000
--- a/debian/changelog
+++ /dev/null
@@ -1,1374 +0,0 @@
-zinc-tk (3.3.01) unstable; urgency=low
-
- * All the ATC specific code in now optional. To remove it add
- --enable-atc=no to the configure invocation. In Perl you have
- to say perl Makefile.PL with-atc=no.
- * Changed the method used to position the label wrt the track
- position. Now regarless of its shape and its angular position,
- the label is maintained at the requested distance.
- * Corrected a nasty memory leak in the Curve geometry management.
- It affected only the simple curves, convex with only one contour.
- This bug might be the source of some performance problems observed
- lately.
- * Debug.pm (D.Etienne)
- - built code correctly manages transformations.
- - the transformation matrix can be displayed.
- - transformation primitives parameters can be displayed and changed.
- - added a new entry in the control bar to display the X cursor device
- coordinates.
- - added the -expandTagsField option to configure the tags display in
- the attributes window.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 11 Nov 2004 17:10:07 +0200
-
-zinc-tk (3.3.0) unstable; urgency=low
-
- * Reworked the X11 arc handling code in order to fix bugs
- and improve coherence between X11 and openGL.
- * Reworked once more the GL init code to cope with Windows.
- * Many various bug fixes.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 5 Oct 2004 17:10:07 +0200
-
-zinc-tk (3.2.100) unstable; urgency=low
-
- * Fixed a problem in GL init code which prevented zinc from
- working with Mesa.
- * A (hopefully) more useful warning is emitted when openGL
- rendering is not good enough (most often 24 bits buffer
- or stencil not available).
- * Tweaking and bending the openGL init code to make it
- work better.
- * Changed the group picking code to enable correct picking with a
- complex clipping shape.
- * Fixed the font loading code when compiling for perl 800.
- The error prevented the correct encoding of codes > 127.
- * Fixed processing of extended gradient syntax (vector based
- specification) which was completly wrong for axial gradients.
- * Fixed some other minor bugs in gradient structure initialisation
- which led to gradient fill extending outside the item boundary.
- * Improved the two README to clarify how to compile
- the two possible distributions (cpan or full distrib).
- * Fixed the Perl compilation for MacOS.
- * Fixed the crash when closing a TkZinc on MacOS OpenGL.
- * Fixed the coredump due to a bug in the field text handling.
- * Updated the doc.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 25 May 2004 17:10:07 +0200
-
-zinc-tk (3.2.98) unstable; urgency=low
-
- * Suppressed the fieldbbox command. It is available when calling
- the bbox command with the -field and -label options.
- * Fixed a nasty openGL/Windows redraw bug when opening a window.
- * GL contexts are destoyed when no longer needed.
- * Fixed Enter/leave emission to match the Canvas (and better).
- * Slightly rearranged the init sequence for openGL. This will
- ensure that render will be reset has soon has possible if
- GL is not there. It will _stay_ set if we discover later that
- GL is not available. This will fix a rather bewildering situation
- when using images: The image is created for GL, then all of a sudden
- accessed in an X11 context.
- * Bug fixes. These should have boosted the stability a lot.
- * A new Tcl_Obj type "attribute" is used to cache the attribute
- lookup from one command invocation to the other. This can
- speed up the code slightly (or more). Available only for
- Tcl.
- * Text rendering in text items should be better quality.
- * Fixed the scrollbar protocol to work with all versions
- of Perl/Tk and Tcl.
- * The "new" tk option configuration mecanism is used where
- possible (not with Perl/TK 800).
- * Only one tesselator is allocated regardless of how many
- TkZinc widgets an application use. This potentially can
- bring resource savings for applications using many
- TkZincs with OpenGL.
- * TkZinc perl works under Windows (Perl/Tk 804 only).
- * Font loading under GL has been rewritten it is now as fast
- as before and still utf8 based.
- * coords has (yet) been modified (fixed) so that items which
- exhibit only one meaningful coordinate will return this
- coordinate as a flat list instead of as a list of lists.
- * Redisplaying after a move or a resize even when clipped
- by the display border is now rock stable. This has been
- achieved by a full redisplay when moving/resizing.
- * An msi package Tcl/Tk and Perl/Tk on Windows.
- * makefile for building for Tcl with vc++ has been updated.
- * Several fixes in Makefile.PL (pthreads, INC augmented,
- Windows port)
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 3 May 2004 17:10:07 +0200
-
-zinc-tk (3.2.97) unstable; urgency=low
-
- * Added a tget command. If called with a transform or an
- item as parameter, it returns the transform factors as
- a list (compatible with tset). An optional second parameter
- can be given, either 'all' meaning decompose the transform
- in translation, scale, rotation, skew and return the list
- in this order, or 'translation', 'scale', 'rotation', 'skew'
- which means return the corresponding value.
- * Added an optional boolean parameter abs to the translate
- command. If true it means that the translation should be
- interpreted as absolute. If absent or false the usual
- behavior is preserved.
- * Under OpenGL, a single graphic context is used for all
- zincs on a single display. Textures are put in common
- for the display. This should greatly reduce the resource
- consumption with GL.
- * Potential memory bugs have been fixed thanks to valgrind.
- * The code can be compiled either for perl/Tk 800 (define
- PTK and PTK_800) or perl/Tk 804 (define PTK alone).
- * The coords command returns a flat point instead of a list
- of one point for all items with a -position attribute.
- * The transformation of items with a -position has been slightly
- modified. The point described by -position is no longer considered
- in the coordinate space of the item but in the coordinate space
- of its parent group. The item is always located in 0,0 of its
- own coordinate space. This is so to make use of -composescale and
- -composerotation a lot more useful (and compatible).
- * The default value of -composescale and -composerotation on texts
- and icons is now false. This is coherent with the default behavior
- of these items (being rigids). The impact of this change is
- greatly minored by the new processing of the -position attribute.
- * Modified the command bindings for the transform
- testbed demo. Added a new delete item command.
- * Added two new Tcl demos ported from perl, testGraphics
- and magicLens.
- * Ported the Graphics package by JL Vinot to Tcl as
- zincGraphics.
- * Modified the behavior of options and arguments controlling
- the display of track history. The -trackmanagehistory is
- gone, a -trackvisiblehistorysize option has appeared, it
- describe the length of the history for ALL tracks in a zinc
- instance. In the Track class -visiblehistorysize has been
- removed and replaced by a boolean attribute -historyvisible
- that can be used to switch off the history for the concerned
- track instance. !!! INCOMPATIBLE CHANGE !!!
- * Fixed several problems with respect to UTF8 strings
- rendering. It should be possible for the text item
- to render OpenGL strings in all configurations.
- * Fixed a bug in indexing a Text item with utf8 characters
- (above 127).
- * Re-ported the pathtag demo from Perl to Tcl.
- * Fixed some bugs in the transform code (core dumps)
- * The scale method takes an optional center
- * The angle in the rotate method can be specified in
- degrees, a flag has been added to tell if the angle
- is given in degrees or radians.
- * The find and addtag method can do spacial searches
- (overlapping, enclosed, closest) in atomic
- groups overriding the atomic specification. The
- recursive flag takes the new value 'override' to do
- so.
- * a new command fieldbbox has been added. It returns the bounding
- box of the given field for the specified item or the item's label
- bounding box.
- * The bounding box reported for groups with clip areas
- takes into account the clipping. This was a long
- standing bug.
- * The enter leave processing as been sped somewhat by
- correcting an omission in the detection code.
- * The bind method now handles virtual events (an omission).
- * The bind method accept an alternative syntax for specifying
- bindings on fields instead of saying:
- .z bind $id:3 <1> "script"
- it is possible to say:
- .z bind $id 3 <1> "script"
- This is coherent with the syntax used by the other methods.
- * Icons are fully transformable in X. The same behavior is
- achieved in both graphical environments.
- * The anchors positions have been fixed for rotated icons.
- * The text items are fully transformable in both environments.
- * The insertion cursor wasn't displayed on the last text line
- if empty. Fixed.
- * The last character of a text selection was never displayed
- as part of the selection (but correctly reported). Fixed.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 26 Jan 2004 13:37:48 +0200
-
-zinc-tk (3.2.96) unstable; urgency=low
-
- * Fixed a bad redraw of maps (traces) and adapted for floating
- point MapInfos.
- * MapInfo coordinates converted to floating point. This should
- greatly improve map usefullness in Zinc.
- * Fixed an erroneous clipping shape when specified with
- an unaligned rectangle or an icon.
- * Fixed a core dump in curve when -closed 1 under X.
- * Added tcompose, tset, skew transformation commands.
- * The transform command now accept the reserved tag 'device' as
- source and destination. This specifies the device coordinate
- space. A named transform can be given as source and destination.
- * The tsave command accept the reserved tag 'identity' as source.
- It can also take a named transform as source.
- * Zinc is now able to use all font glyphs above 0x20 in a
- 256 glyph font.
- * The smooth method reports a list of line segment vertices
- instead of the incorrect list of bezier segment vertices.
- * Added a -followpointer widget option to optimize pointer
- motion processing (suppress enter/leave processing).
- * The coords method correctly updates the control flags when
- replacing the whole vertex list.
- * Fixed a problem a the invalidation code which prevented
- item with a transform update pending from being correctly
- processed. All item specific invalidation flags were
- ignored after a transform operation on the item.
- * The -lastasfirst attribute of tracks failed to work causing
- a mis-coloring of the history when -lastasfirst was turned on.
- * Corrected a potential problem in the processing of end of lines
- in multi-lines texts.
- * Update of the refman, tanks C. Mertz.
- * Fixed the Makefile.in to build a correct pkgIndex.tcl when
- installing, it lacked an entry for loading the Tkzinc
- library itself.
- * Debug.pm : A control bar and zoom/translate new functionalities
- have been added. finditems(), tree(), snapshot() functions become
- deprecated. Initialisation is done using the new init() function.
- (D. Etienne).
- * zinc-demo (perl variant) : the pathtag demo has been corrected.
- Should be more explict now (C. Mertz)
- * A first contribution by zentara : TripleRotatingWheel.
- * New tests (perl variant) : find method with 'overlaped', 'enclosing',
- 'withtype', pathtags. More images tests. Tests for text items.
- Tests for openGL fonts with multiple sizes (C. Mertz).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 28 Nov 2003 13:37:48 +0200
-
-zinc-tk (3.2.95) unstable; urgency=low
-
- * Configuration of image and bitmap valued attibutes is now
- optimized against reconfiguration with the same value (image).
- This has the side benefit of fixing a core dump ;-).
- * Fixed the return type of the ZnPointInRegion prototype to return
- a ZnBool (A. Lemort).
- * Stephane Conversy has contributed diffs to compile the tcl
- version on MacOs X Fink.
- * ZincDebug: Contours of curves can be displayed and explored
- (D. Etienne).
- * ZincDebug: Fixed a bug in device coordinates when a non group
- item has a transformation (D. Etienne).
- * a new debian package has been created to install the doc
- files (pdf and html) separately.
- * Integrated the export script and Makefile contributed for
- Perl by Somanos Sar. Merged the CPAN features written by
- C. Mertz.
- * The scrollbar protocol should now work with perl as well as
- with tcl.
- * libom is no more. It will be made into a loadable module
- as soon as Tkzinc will have stubs and a tcl binding will be
- written for the overlap manager api.
- * No more perl building/configure code in the main trunk. All
- perl related build and configuring tools are in Perl.
- * Fixed a font texture allocation problem with large fonts.
- The texture sizing has been changed with better results.
- * Added a -tracksymbol option to act as the default value
- for the -symbol attributes of tracks.
- * The track default symbol for current positon is now correctly
- read from the -tracksymbol option and not statically fixed.
- * Changed the parameters of the new conical gradient.
- If only one value is given, it is taken to be the gradient
- starting angle, the center being 0,0. If two values are given,
- they are taken as the gradient center, the starting angle being 0.
- If three values are given, it's the gradient center followed by
- the gradient starting angle. If four values are given, they are
- two points defining the center and the angle/extent of the gradient
- (vector based definition).
- * Corrected a bug when tiling aligned rectangles under GL.
- The rectangular form was not correctly clipped so that
- it showed outside its area.
- * Shaped icons should be rendered correctly under all environments
- and for all image formats.
- In fact the image/bitmap code has been reworked and integrated.
- For the internals there is no difference now between images,
- image supported bitmaps and old style bitmaps obtained by
- Tk_DefineBitmap.
- * The image update mecanism is now fully functional. It will
- work for tiles, icon, symbols and even patterns if they are
- made with image bitmaps.
- * Icon item picking should be ok in all cases and all environments.
- It used to be limited for rotated shaped images.
- * Change in the font texture allocation to guarantee that it
- will not fail. This is now postponed until first use for
- drawing.
- * Videomap loading is done through the Tcl_Channel api enabling
- the use of Tkzinc and all of its datas in a starkit.
- * no more dependencies between zinc-perl and zinc-tk
- * a new perl module for building complex graphic objects:
- Tk::Zinc::Graphics.pm
- * Perl module Text is renamed Tk::Zinc::Text (beware: slight incompatible change!)
- * Perl module Logo is renamed Tk::Zinc::Logo
- * PerlModules ZincTrace, ZincTraceErrors and ZincDebug are renamed
- Tk::Zinc::[Trace|TraceErrors|Debug]
- * new demos :
- - color-path-and-conic.pl to demonstrate conical and path gradient
- - testGraphics.pl to demonstrate the power of Graphics.pm
- - Magiclens.pl
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 5 Sep 2003 13:37:48 +0200
-
-zinc-tk (3.2.94) unstable; urgency=low
-
- * Added an optimization for aligned/textured rectangles in openGL.
- This can really boost the performances of some apps.
- * Fixed a core dump when destroying zinc after an error occured
- during the first Configure.
- * Fixed the picking of multi-contours curves. They should be
- correctly detected now.
- * Fixed a bug in the compilation of libtess around the inclusion
- of glu.h
- * Added a new vector based method to describe gradient geometry.
- The vector is specified by two points (4 floats).
- It is available for axial, radial and the new conical gradients.
- * Added a new gradient type: conical, defined by an angle,
- a center and an angle or a vector.
- * (ZincDebug) A partir de l'arbre des items, possibilité de générer
- du code perl correspondant à une branche (Daniel Etienne).
- * Ajout d'un module ZincTraceError (perl) qui trappe les erreurs
- Zinc et affiche pour chaque erreur l'instruction et le message
- d'erreur (Daniel Etienne).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 21 May 2003 09:22:18 +0200
-
-zinc-tk (3.2.93) unstable; urgency=low
-
- * Fixed a bug preventing the loading and display of accented letters
- in openGL.
- * In zincText.tcl fixed a problem preventing insertion of accented
- letters
- * Added the documentation in the tk debian package
- * Shaped images can be used both in perl/tk and in Tcl/Tk under
- GL. Alpha channel is also supported in perl/tk (for image formats
- that support the feature).
- * Fixed a gradient filling bug on some (many usual) multi-contours
- curves.
- * Fixed a X Pixmap error problem (in GL) with some fonts reporting
- a zero width on critical characters.
- * Text item: Modified the processing of the white space/tab causing
- a line break when a -width limiting atribute is in effect. The extra
- space used to be located at the beginning of the new line. Now it is
- suppressed. Other white spaces are still displayed at the begining
- of the line. The new behavior seems more natural.
- * Fixed a typo in zincText.tcl preventing the insertion of a new line.
- * Fixed a core dump when destroying a map item due to
- the freeing of an unallocated pattern in the symbols
- list
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 12 May 2003 13:51:10 +0200
-
-zinc-tk (3.2.92) unstable; urgency=low
-
- * Perl compilation ok even if no package installed
- * Perl demo runable without installation. Idem for
- tests (but there is no tests yet ;-).
- * Fixed Enter/Leave bugs during grabs and in fields.
- * Fixed stipple filling in openGL.
- * Fixed several core dumps.
- * Fixed several bugs in relation with contour manipulation
- (adding, orientation evaluation, memory allocation, gradients).
- * Fixed text cursor visibility if no text to display (text
- item & fields).
- * Fixed problems with some demos in Tcl.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 9 May 2003 17:12:14 +0200
-
-zinc-tk (3.2.91) unstable; urgency=low
-
- * Corrected the scollbar/view bug under Windows.
- * Polished quite a bit the install process.
- * Added a makefile.vc to be used with Visual C++ on Windows.
- * Small fixes on several demo scripts.
- * Corrected a very touchy bug related to font texture
- loading on Windows. The symptom is a blank window,
- if it contains text and the mouse is in the window
- when it is mapped.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 25 Apr 2003 11:50:38 +0200
-
-zinc-tk (3.2.90) unstable; urgency=low
-
- * Portage Windows
- * Changement du symbole de compilation openGL de GLX en GL.
- * Tentative de préfixage exhaustif de tous les symboles externes
- (fonctions, macros, variables, types) par Zn.
- * Modification du code de traitement des images pour 1/ assurer
- le portage sous Windows, 2/ Obtenir le rendu transparent pour
- les images le supportant (PNG), 3/ Rétablir dans un deuxième
- temps le mécanisme de mise à jour de Tk lors de la modif de
- l'objet image. Le prix à payer est l'impossibilité temporaire
- d'avoir des images détourées en perl/Tk **PROBLEME POTENTIEL**.
- * Compilation avec tous les warnings réalistes et correction des
- types de variables + casts explicites pour faire disparaitre
- les warnings.
- * Suppression de l'utilisation de strcasecmp pour la conversion
- des valeurs certains attributs. Il faudra désormais les spécifier
- obligatoirement en minuscules. **PROBLEME POTENTIEL**.
- * Utilisation du code de gestion des couleurs de Tk plutôt que
- celui qui avait été importé depuis Tk dans zinc.
- * Gros remaniement du code de chargement des glyphes de fontes
- sous forme de textures en openGL afin d'assurer le portage
- Windows.
- * Dans l'item Text -spacing et -width sont des entiers au lieu de
- floats.
- * Les priorités par défaut ont été modifiées et valent 0 pour Map
- et Reticle et 1 pour tous les autres items. **PROBLEME POTENTIEL**.
- * Grosse réorganisation des headers afin de regrouper par module
- logique. Cela a permit de dégonfler Types.h.
- * Déplacement des fonctions de parsing d'attributs de Item.c vers
- Attrs.c comme de logique.
- * Nouvelle chaine de configuration/Makefile basée sur TEA.
- * Restructuration des fichiers afin d'être plus proche de l'architecture
- TEA.
- * Portage des démos en Tcl (J.P Imbert).
- * Début de squelette pour des tests en Tcl.
- * Le Makefile.PL est généré par configure. C'est également le cas
- de Zinc.py. Cela permet une meileure configuration selon les
- plateformes et les versions.
- * Changement de module dans le repository CVS. Le module s'appelle
- désormais Tkzinc. L'ancien module reste actif au cas où.
- * Des corrections de bugs nécessités/découverts par le portage
- Windows.v
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 24 Apr 2003 11:59:09 +0200
-
-zinc-tk (3.2.6i) unstable; urgency=low
-
- * Les couleurs du relief de la fenêtre ne sont allouées que si
- et lorsque le relief est différent de flat. Cela permet de
- ménager les colormaps.
- * zinc verifie que l'on ne demande pas à chggroup de placer un
- ancestre dans un de ses descendants.
- * Les infos GL au démarrage sont conditionnées à la présence de
- la variable d'environnement ZINC_GLX_INFO.
- * Les flags -composerotation et -composescale de Icon sont
- positionnés à vrai par défaut. C'est un pis-aller, il faudra
- repenser le traitement des icones et du texte dans un contexte
- de transformation totale (rotation, echelle).
- * Correction d'un bug de précision conduisant à la fameuse bande
- non rafaichie à droite en 1600x1200 sous GL.
- * Le paquet zinc debian devrait mieux se comporter quand aux
- dépendances sur les autres paquets tant à la compil qu'au
- runtime. La dépendance à openGL est supportée au travers
- de mesa.
- * Le répertoire test est renommé sandbox. IL FAUT RE-EXTRAIRE
- une copie fraiche des sources depuis la base CVS ou tripoter
- les fichiers dans les répertoires CVS de zinc et de sandbox
- pour refléter la modif.
- * Changement du format des gradients pour être compatible avec
- les formats de nom de couleur normalisés. MODIF INCOMPATIBLE.
- * Début d'architecure TEA pour la version Tcl. Le module Zinc
- utilise désormais les stubs de tcl/tk plutot que le linker
- dynamique pour résoudre les références sur tcl/tk. Il en
- résulte une meilleure indépendance par rapport aux versions
- de tcl/tk.
- * Incorporation de libtess, ce qui permet de se passer de GLU/GL
- dans des versions sans openGL.
- * Améliorations et corrections de bugs dans ZincDebug (Daniel Etienne):
- Gestion de plusieurs instances de Zinc.
- Paramétrage de ZincDebug sur la ligne de commande:
- perl -MZincDebug monappli.pl <-options_monappli> <-options_zincdebug>
- Ajout d'un bouton treset permettant de savoir si un item a subi des
- transformations.
- Correction de bug d'affichage :
- des coordonnées d'un item curve.
- de la bounding box de groupes vides.
- * Incorporation d'un module python mis à jour (uillaume Vidon)
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 10 Mar 2003 17:42:53 +0100
-
-zinc-tk (3.2.6h) unstable; urgency=low
-
- * Correction d'un bug provoquant la suppression d'un blanc
- en début de lignes sur l'item text
- * Correction d'un problème de spécialisation des images sous
- X. Il fallait spécialiser par Screen et non par Display.
- * Correction d'une erreur lors de la requête de bindings
- sur un item/séquence.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 20 Jan 2003 13:53:19 +0100
-
-zinc-tk (3.2.6g) unstable; urgency=low
-
- * Edition des attributs dans ZincDebug: la plupart des champs attributs
- sont maintenant éditables (un <Control-z> dans un champ permet de
- restaurer la valeur initiale)
- * Possibilite de visualiser la bounding box d'un item dans ZincDebug.
- * Ajout d'un module permettant de tracer les appels de commande
- zinc pour faciliter sensiblement le debugging d'une appli. Faire
- perl -MZincTrace myscript.pl (Christophe/Daniel).
- * Correction d'un bug d'analyse des listes de points d'ancienne forme.
- * Correction d'un core dump lors d'une tentative de clonage du top
- group.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 20 Jan 2003 10:53:40 +0100
-
-zinc-tk (3.2.6f) unstable; urgency=low
-
- * Adaptation des méthodes fit, smooth, transform, coords, contour
- pour obtenir un tout cohérent dans la nouvelle logique de gestion
- des points et des contours.
- * Correction d'un bug de gradient introduit par le debug.
- * Ajout d'un attribut -fillrule à l'item curve (en liaison avec le
- premier point.
- * L'item curve ne détruit plus un contour vidé par la méthode coords.
- Il n'en ajoute pas non plus (cas d'un item vide).
- * Correction d'un bug d'affichage de texte en GL avec plusieurs
- fenêtres (cycle de création/destruction).
- * Corrections de bugs en relation avec le premier point.
- * La limitation qui obligeait à déclarer comme globale l'instance de zinc
- lorsque ZincDebug était chargé au runtime (perl -MZincDebug script.pl)
- n'est plus.
- * Correction de bug (ZincDebug): la selection du groupe 1 dans l'arbre des
- items provoquait un segmentation fault.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Tue, 14 Jan 2003 12:14:38 +0100
-
-zinc-tk (3.2.6e) unstable; urgency=low
-
- * Corrections de bugs
- * Ajout du support UTF8 pour Tcl/Tk
- * Possibilité d'invoquer ZincDebug sans modifier le code,
- de la maniere suivante: perl -MZincDebug script.pl
- (cf man ZincDebug). Ajout de D.Etienne.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 20 Dec 2002 14:56:42 +0100
-
-zinc-tk (3.2.6d) unstable; urgency=low
-
- * Adaptations (mineures) pour TCL/TK 8.4.
- * Corrections de bugs dans les méthodes Coords et Contour.
- * Changement incompatible du code des gradients.
- * Fin de réalisation des nouveaux contours utilisant le tesselateur GLU.
- * Le tesselateur est disponible même si on utilise une version compilée sans GL.
- * Fin de réalisation des paths dans Curve.
- * Utilisation des display lists GL pour Arc, Curve, Rectangle, Text.
- L'optimisation n'est effective que si l'item n'est pas modifié (ce qui est
- souvent le cas quand même).
- * Encore des corrections de bugs.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Tue, 10 Dec 2002 11:09:08 +0100
-
-zinc-tk (3.2.6c) unstable; urgency=low
-
- * Correction d'un bug empéchant Zinc de s'initialiser (ZnBezier a disparu).
- * Mise à jour de ZincDebug par Daniel Etienne:
- Modification concernant la fonction tree() :
- Possibilité d'afficher, pour chaque item de l'arbre, la valeur d'un ou
- de plusieurs de ses attributs; utiliser les options -optionsToDisplay et
- -optionsFormat.
- Mécanisme de recherche de chaine de caractères.
- Feedback pour signaler qu'un item sélectionné dans l'arbre n'est pas
- visible car en dehors de la fenêtre.
- * Suppression de la fabrication du paquet zinc python qui de toute manière
- n'était plus maintenu et ne fonctionnait pas sous Woody.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 6 Nov 2002 09:59:13 +0100
-
-zinc-tk (3.2.6b) unstable; urgency=low
-
- * Correction d'un bug empechant la mise à jour des bitmaps/images modifiées.
- * Suppression du clippeur GPC et remplacement par le tesselateur de GLU.
- Zinc est maintenant entièrement Open Source ;-).
- * Les commandes contour ont entièrement changé: exit les union, xor, inter, diff
- maintenant on peut faire des add, addhole et remove. Les contours ainsi manipulés
- gardent leur position relative les uns par rapport aux autres.
- * L'item Bezier n'existe plus, il est remplacé par un traitement plus général dans
- Curve qui accepte maintenant la specification de controles sur les points. Il est
- ainsi possible de décrire des chemins mélangeant segments de droites et de cubiques
- de Bezier.
- * Correction d'un oubli dans Zinc.pm qui empêchait l'usage de vertexat.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Tue, 5 Nov 2002 11:13:12 +0100
-
-zinc-tk (3.2.6a) unstable; urgency=low
-
- * Correction du bug de rendu des lignes (hachures) sur GeForce 3/4
- * Correction d'un bug de rendu de lignes avec alpha dans certaines
- circonstances (modulation de la couluer).
- * Adaptation du Makefile pour compil avec les derniers drivers NVidia.
- * Correction du bug de mise à jour de la bbox d'un gruope suite à
- l'ajout/suppression d'un item (Daniel Etiienne, Nathalie Banoun).
- * Correction d'un bug sur l'épaisseur des lignes de 0.5 pixels en GL.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 26 Sep 2002 12:10:58 +0200
-
-zinc-tk (3.2.6) unstable; urgency=low
-
- * Correction d'un bug lors de l'utilisation simultanée par
- une appli d'un environnement X et GL (Bug détecté par A. Marion).
-
- * Corrections dans le Makefile.in.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 18 Sep 2002 15:07:37 +0200
-
-zinc-tk (3.2.5i) unstable; urgency=low
-
- * Encore des corrections de bugs
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 9 Sep 2002 14:48:46 +0200
-
-zinc-tk (3.2.5h) unstable; urgency=low
-
- * Corrections de bugs.
- * la commande contour retourne le nombre de contours d'un item.
- * Changements dans ZincDebug (Daniel Etienne), la liste suit :
- * meilleure gestion des groupes atomiques : ils sont maintenant scannés
- comme les autres.
- * la mise en evidence des items selectionnés est modulable. Par defaut,
- l'item est mis en avant-plan et encadré (click gauche), mais pour
- faciliter sa distinction on peut egalement cacher les autres items de
- son groupe (click milieu), voire ceux du groupe parent (click droit).
- * il est possible de rechercher des items en specifiant un tagOrId dans
- un champs de saisie (ouvert sur un Control-f)
- * séparation des traitements : 2 fonctions sont maintenant exportées,
- finditems() qui cree les bindings necessaires a la recherche d'items
- et snapshot() qui cree ceux necessaires a la capture d'image. (action
- sur Control-s)
- * mise a jour du man ZincDebug
- * Possibilite d'afficher l'arbre des items d'une application
- (Control-t)
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 2 Sep 2002 14:36:04 +0200
-
-zinc-tk (3.2.5g) unstable; urgency=low
-
- * Ajout de la commande find ancestors qui permet de retrouver, avec
- un éventuel filtrage sur tag, l'ensemble des ancêtres d'un item.
- * Corrections de bugs sur le curseur d'insertion : text et fields.
- * Correction d'un bug dans find overlapping/enclosed qui retournait
- des résultats aléatoires selon le groupe de départ.
- * Correction du calcul des ancres pour les items icons.
- * Nouveaux programmes de démos et amélioration de la doc (C. Mertz)
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 5 Jul 2002 17:08:12 +0200
-
-zinc-tk (3.2.5f) unstable; urgency=low
-
- * Correction d'un bug génant (les items se déplacent suite à un
- problème dans la méthode ToArea de group) introduit en 3.2.5d
- et révélé en 3.2.5e.
- * Ajustement de la doc pour find/addtag.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Tue, 25 Jun 2002 11:38:36 +0200
-
-zinc-tk (3.2.5e) unstable; urgency=low
-
- * Corrections de qq bugs.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 24 Jun 2002 11:19:02 +0200
-
-zinc-tk (3.2.5d) unstable; urgency=low
-
- * la commande de création de zinc rapporte le numéro de version
- et énumère mes différentes têtes graphiques possibles (X11, GL).
- * Les fonctions tsave et gsave permettent de savoir si un nom est déjà
- utilisé.
- * L'item Icon peut tourner et être redimensionné.
- * QQ bug squashes.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 10 Jun 2002 15:33:46 +0200
-
-zinc-tk (3.2.5c) unstable; urgency=low
-
- * Correction du calcul de l'angle du guideur (passage entre
- antirec et Zinc + une erreur dans la fonction PointPolarToCartesian.
- * Le rho n'était plus passé à l'antirec second problème expliquant
- les perfos pitoyables de l'antirec.
- * Correction d'un bug de specification d'angle créant un problème dans
- les items arcs si on specifiait un extent de 360.
- * Correction d'un core dump lors de la deallocation des fontes (cas
- où plusieurs Zincs sont créés).
- * Correction d'une boucle infinie lors de l'allocation d'une fonte
- (cas où plusieurs Zincs sont créés).
- * Correction d'un core dump se produisant dans certains cas lors de
- l'utilisation d'un Curve en clipping.
- * Correction d'un core dump lorsque l'on tentait d'éditer un texte
- dans un champ.
- * Les ressources Zinc de type images/bitmaps (-tile, -mapdistancesymbol,
- etc), ne pouvaient pas être remises à "". Une consultation de la valeur
- de ces ressources provoquait un core dump si la ressource valait "".
- * L'item Icon ne possède plus qu'un attribut -image/-mask. Cependant il
- est toujours possible de positionner cet attribut soit par -image soit
- par -mask. La reconnaissance bitmap/image est automatique.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 27 May 2002 17:07:19 +0200
-
-zinc-tk (3.2.5b) unstable; urgency=low
-
- * Les tags peuvent désormais comporter un chemin permettant de
- préciser dans quelle partie de l'arborescence les items doivent
- être recherchés. Le chemin consiste en une suite de tags séparés
- par des . ou des *. Chaque tag désigne le groupe possédant ce tag
- à un niveau donné de la hierarchie. Le caractère * premet de demander
- la recherche en profondeur en sautant éventuellement des degrés dans
- la hierarchie. LES CARACTERES . et * sont donc INTERDITS dans les tags.
- Cette fonctionalité est particulièrement importante lors de l'utilisation
- de la commande clone (création et paramétrage d'après un modèle,
- programmation par prototype). Elle est sensée être à peu près transparente
- pour ceux que cela n'interesse pas.
- * Les sous commandes de find/addtag ont été remaniées pour tenir compte
- du point précédent. En particulier 'find all' a disparu. Les
- paramètres optionnels 'inGroup' et 'recursive' ont disparu des commandes
- above, below, withtag. Ils sont remplacé par un simple tag optionnel
- pour les commandes withtype et atpriority. Par contre les commandes
- overlapping et enclosed gagnent ces mêmes paramètres optionnels
- 'inGroup' et 'recursive'. La commande closest gagne le paramètre optionnel
- 'recursive' et le paramètre start voie son sens modifié : si 'start' est
- un groupe non ATOMIC, la recherche démarre au premier item de ce groupe
- sinon le sens précédent est conservé, la recherche démarre à l'item suivant
- 'start'
- * Un tag chaine vide (ou un chemin sans tag final) est équivalent au
- tag 'all'.
- * Meilleure prise en compte de la présence de l'extension GLX. Son
- absence ne devrait plus générer de core dump.
- * La commande clone ne clone plus tous les items désignés par le tagOrId
- mais seulement le premier dans l'ordre de la display list et elle
- retourne l'id de ce nouvel item.
- * Correction d'une erreur dans itemconfigure qui retournait une info
- incorrecte quand on lui demandait la liste des attributs d'un field.
- * Redesign complet de la gestion des images/bitmaps et fontes afin 1/
- de gérer correctement les ressources sous GL avec plusieurs fenêtres
- et 2/ de LIBERER les ressources automatiquement lorsqu'elles ne sont plus
- utilisées (textures et mémoire process X et GL). Une conséquence est
- que le nouveau code ne peut plus gérer le changement du contenu d'une
- image Tk, il faut détruire l'image et la recréer.
- * Correction d'un bug provoquant un core dump en 3.2.5a suite à la modification
- du code de réparation de l'image. Un redisplay était planifié lors de la
- destruction d'un widget et lorsqu'il était effectivement déclenché le
- widget n'existait plus, bien sûr.... No comments
- * Les bordures de champs n'étaient pas dessinées en GL, l'alpha n'étant
- pas composé correctement et l'épaisseur de trait à été portée à 1.5.
- * Correction du code de dessin des images dans les fields sous X. Elles ne
- pouvaient pas être clippée correctement si elles avaient un masque.
- * Correction d'un bug de clonage des fields, on tentait de dupliquer
- un label format sur un groupe de champs vide.
- * Mise en cohérence des types d'attributs entre le code et la doc, certains
- type ont été modifiés dans le code : tags/taglist, justify/alignment,
- autojustify/autoalignment, border/edgelist, gradients/gradientlist,
- text/string, patterns/bitmaplist, pattern/bitmap.
- * Retablissement du controle de la validité des attributs dans
- itemconfigure même lorsqu'un tag est utilisé.
- * Correction dans les lineshapes des types lineleftcorner et
- linedoubleleftcorner qui étaient confondus avec leur analogues
- droits.
- * Sortie d'un message d'erreur lorsqu'un item n'est pas trouvé comme
- valeur d'attribut.
- * Correction du traitement des angles startangle et extent dans Arc, les
- extents négatifs étaient erronés et si startangle était nul on obtenait
- systématiquement un arc de 360 degrés.
- * Ajout d'un attribut -composealpha à tous les items. Il agit de la même
- manière que -composescale et -composerotate mais pour l'alpha des
- couleurs de l'item.
- * Correction d'un bug rendant inctif le paramètre de tension dans les gradients.
- * Incorporation des corrections de Christophe dans la doc.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 3 May 2002 13:44:17 +0200
-
-zinc-tk (3.2.5a) unstable; urgency=low
-
- * Correction d'un core dump lors de la destruction d'un
- item text cloné dont on a modifié le texte.
- * Le changement de fonte d'un texte (Text et Field) n'était
- pas suivi d'effet en openGL, maintenant ça devrait aller
- mieux.
- * Tous les items peuvent avoir le focus, donc on peut utiliser
- des bindings sur des evènements clavier sur tout item. C'est
- également vrai pour les fields (extension de la commande focus).
- * La selection et le curseur sont affiché en GL pour l'item Text
- * La selection et le curseur sont affiché pour le texte dans les
- fields (X et GL).
- * L'édition de texte, la selection, et le curseur sont supportés
- pour les fields.
- * Restructuration du module Item, création du module Field et
- suppression de l'ingérance de Item dans Group. Le code devrait
- être plus clair et plus facile à maintenir (il reste à préfixer
- toutes les fonctions externes par Zn).
- * L'option -render n'est plus un booléen, elle peut prendre les
- valeurs 0: rendu X, 1: rendu GL direct, 2: rendu GL indirect.
- * Amélioration de ZincText.pm: correction de bugs, évolution des
- bindings pour mieux gérer la sélection, intégration de l'édition
- des textes dans les fields, possibilité d'aller en fin/début de
- ligne, de monter/descendre d'une ligne (item text).
- * Des nouveaux indices sont disponibles dans les items indexables:
- bol, eol, bow, eow, up, down.
- * Correction d'un core dans DeleteChars de Text (pointeur non
- déréférencé).
- * La commande currentpart prend un paramètre booléen optionnel
- qui spécifie si elle doit reporter les parties privées de l'item
- ou seulement les fields (elle retourne "" si le pointeur est
- sur une partie privée).
- * Toutes les commandes acceptant un paramètre field optionnel
- comprennent un field index "" comme étant une absence de paramètre:
- aucune erreur n'est générée et tout se passe comme si le paramètre
- n'avait pas été spécifié.
- * Les commandes 'focus' et 'select item' retournent une liste
- (item, field) ou "" si pas d'item. La présence de field est
- garantie (liste de longueur 2) mais peut être "", se qui veut
- dire pas de field. On peut directement utiliser le résultat
- de ces commandes comme paramètres pour les commandes prennant
- un couple item, field.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 12 Apr 2002 13:02:05 +0200
-
-zinc-tk (3.2.4) unstable; urgency=low
-
- * Correction de -lastasfirst, le bug était dû à un
- débordement du champs de bits traitant les flags.
- Il a été porté à 16 bits pour tous les flags d'item
- (header et privé).
- * Correction d'un core dump lors de clonage de rectangle,
- arc, curve, bezier. La réallocation des structures
- géométrique doit se faire tout de suite dans clone.
- * Correction du bug faisant apparaitre un petit carré en
- fin de ligne dans Text.
- * Les coins supérieurs des bordures des rectangles n'étaient
- pas fermés (visible sur les bordures épaisses).
- * Zinc openGL marche un peu mieux sous Mesa (attention aux
- -linewidth supérieurs à 3 et inférieurs à 11).
- * Module perl ZincText.pm qui permet d'éditer les items textes
- pour peu que ceux ci possèdent le tag 'text'. Il faut faire:
- use ZincText; new ZincText($zinc);
- * L'option -tile de Zinc n'avait pas subit le traitement destiné
- à l'immuniser contre les images sans contenu. Il en resultait
- l'infame XCreatePixmap error. C'est corrigé.
- * itemconfigure a été (encore) modifié pour accepter les attributs
- inconnus. Il est préferrable de na pas reporter d'erreur que
- de bloquer un itemconfigure sur tag.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 29 Mar 2002 16:19:40 +0100
-
-zinc-tk (3.2.3g) unstable; urgency=low
-
- * Correction d'un core d'un lors de la creation répétée
- d'un label format erroné. L'entrée de cache n'était pas
- détruite bien qu'invalide.
- * Correction d'un bug très génant de redessin en openGL du
- à un problème de calcul de la damaged area et révélé par
- la modification du traitement de la zone de dessin du
- widget (inset). Un contournement en 3.2.3f et de mettre
- -borderwidth et highlightthickness à 0.
- * Dans le code de reparation le scissor n'était pas réactivé
- aprés le dessin de la bordure.
- * Correction de la commande itemconfigure qui reportait à tort
- une erreur attribut invalide sur un tag. L'erreur doit être
- reportée que pour un id.
- * Rectangle correction d'un core dump dû à une variable couleur
- non initialisée (si -linewith != 0).
- * Le code de redessin sur changement de focus nécessaire pour
- corriger certains problèmes liés au redessin avec scissor n'était
- pas compilé conditionnellement.
- * Un pas de plus vers une doc potable.
- * Ajout d'une démo sur les transformations.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Tue, 26 Mar 2002 10:42:27 +0100
-
-zinc-tk (3.2.3f) unstable; urgency=low
-
- * Remplacement de la doc PostScript par une doc pdf.
- Celle ci exploite les références hyper texte et la table
- des matières latérale.
- * Un grand pas en avant sur le contenu de la doc. Pas mal
- d'explications supplémentaires et des chapitres vides qui
- commencent doucement à se remplir. Mise à jour pour les
- nouvelles fonctionalités (pas toutes encore). Index,
- figures, etc Contribution de Christophe Mertz.
- * Une suite de démos qui fonctionne et qui commence à être
- sympa est apparue. Merci là aussi Christophe Mertz, et qq
- autres. Qui?
- * Réalisation de reliefs pour les courbes exploitant
- les possibilités de dégradés de GL. L'item curve
- possède un attribut -smoothrelief qui permet de décider
- si on veut traiter le relief comme pour un arc (en douceur)
- ou par facettes.
- * Les reliefs peuvent être bombés au lieu d'être simplement
- biseautés (plusieurs variations).
- * La couleur des reliefs est calculée sur le -linecolor et
- non plus sur le -fillcolor. INCOMPATIBILITE.
- * Portage de l'item Bezier en GL. Il peut se dessiner et servir
- de clipping.
- * Correction d'un bug dans LeaderAnchor qui empéchait le
- paramétrage. Il n'y a pas beaucoup de monde qui a essayé
- de s'en servir, apparement.
- * Suppression du inset autour de la fenetre. L'origine des
- coordonnées device est partout et pour toutes les commandes
- le 0,0 de la fenetre.
- * Amélioration de la détection des images bugées. Désormais
- si une image est malencontreusement créée vide (nom de fichier
- ""), zinc détecte l'anomalie et sort une erreur.
- * Correction d'un bug qui affectait chggroup lorsqu'elle était
- utilisée sur un groupe et sans ajustement : les fils du groupe
- n'étaient pas replacés correctement.
- * Rétablissement de l'option -lastasfirst de l'item track qui
- était en panne du à un débordement de capacité des flags
- privés.
- * Correction de deux bugs dans le tracé des cercles. Un empéchait
- le tracé correct d'un cercle complet dans arc (sous certaines
- conditions). L'autre créait une petite facette sous certains
- angles pour un arc non complet.
- * Toutes les options couleurs de zinc sont exprimables sous forme
- de gradient et donc possèdent un alpha. C'est appréciable sachant
- par example que -forecolor sert de valeur par défaut à la plupart
- des couleurs d'item.
- * L'option de relief bénéficie également d'un traitement spécial
- permettant toutes les valeurs de relief (pas seulement celles
- acceptées par Tk).
- * Makefile.in tricky enhancement for installing zinc-demos and its
- components (H. Damiano)
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 15 Mar 2002 16:15:06 +0100
-
-zinc-tk (3.2.3e) unstable; urgency=low
-
- * Intégration des modifs des Didier Pavet concernant l'antirec.
- * Petite mise à jour de l'interface Python (D.Pavet).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 20 Feb 2002 14:02:59 +0100
-
-zinc-tk (3.2.3d) unstable; urgency=low
-
- * Suppression des attributs alpha. Toutes les couleurs
- sont des gradients et comportent un alpha. Les gradients
- ont été totalement purgés du code développé pour le
- rendu sous X (shades).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 18 Feb 2002 17:03:05 +0100
-
-zinc-tk (3.2.3c) unstable; urgency=low
-
- * Correction d'un bug de recalcul de la géométrie des
- labels lors d'une modif d'un champ.
- * Correction du dessin des arcs lorsqu'ils ne sont pas
- complets (arc partiel). Meilleure prise en compte
- des angles en utilisant le modulo plutôt que le bornage.
- * Les attributs de type dimension comme les linewidth et autres
- tailles, n'acceptent plus une spécification à la Tk avec
- possibilité de décrire en point en millimètres etc. En
- revanche ils sont promus valeur flottante et donc peuvent
- être utilisé en GL pour spécifier des tailles fractionnaires.
- * Correction d'un bug de clipping qui empéchait la remise à
- jour de la scène après la suppression du clipping dans un
- groupe.
- * Correction du clonage et de la destruction d'un item Triangles.
- Les couleurs n'étaient pas correctement dupliquées/libérées.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 15 Feb 2002 10:29:55 +0100
-
-zinc-tk (3.2.3b) unstable; urgency=low
-
- * Ajout de démos de Christophe dans le répertoire
- examples.
- * Correction des bugs de dessin des polylines qui affectaient
- gravement twinkle (entre autre).
- * Correction de code de Daniel.
- * Correction de tsave et trestore, les noms ne fonctionnaient
- pas.
- * Ajout du module PerlDebug et de quelques examples
- contribués par Daniel Etienne.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 28 Jan 2002 14:57:57 +0100
-
-zinc-tk (3.2.3a) unstable; urgency=low
-
- * Ajout d'attributs dans Track sur vecteur vitesse.
- * Ajout de RenderPolyline qui débarasse de libgle et qui fournit
- les flêches.
- * Ajout de l'item Triangles.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 3 Dec 2001 15:29:13 +0100
-
-zinc-tk (3.2.2) unstable; urgency=low
-
- * Ajout du clipping non rectangulaire.
- * Gradient PATH
- * Correction d'un bug de binding Enter/Leave dans item.
- * Intégration de la gestion sélective du redessin.
- * Réalisation de la bordure relief et du highlight de focus
- directement en X ou en GL pour éviter les clignotements
- (en GL).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 26 Nov 2001 11:29:08 +0100
-
-zinc-tk (3.2.1) unstable; urgency=low
-
- * Correction d'un core dump dans clonage de curve.
- * Correction d'un break oublié dans mapinfo add symbol.
- * Travail sur les gradients et les reliefs.
- * Corrections de bugs dans la version OpenGL.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 7 Nov 2001 10:31:22 +0100
-
-zinc-tk (3.2.0) unstable; urgency=low
-
- * Version avec OpenGL actif.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 24 Oct 2001 15:25:10 +0200
-
-zinc-tk (3.1.28) unstable; urgency=low
-
- * Correction du core dump dans la fonction currentpart si
- pas de current item.
-
- * Recompilation avec la dernière version de perl woody.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 12 Oct 2001 09:50:39 +0200
-
-zinc-tk (3.1.27) unstable; urgency=low
-
- * Correction d'un bug de sensibilité sur tabular et track
-
- * Modification de la syntaxe des gradients (-fillcolor) et
- réécriture des gradients.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 25 Jun 2001 13:27:40 +0200
-
-zinc-tk (3.1.26) unstable; urgency=low
-
- * Correction de itemcget et itemconfigure afin qu'ils retournent
- des tableaux perl et non des refs sur des tableaux.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 30 Mar 2001 14:19:54 +0200
-
-zinc-tk (3.1.25) unstable; urgency=low
-
- * Retour arrière sur le traitement du grab lors d'un buttonpress.
-
- * Correction du bug bloquant l'appel des callbacks d'enter lors du
- dans l'item de grab (buttonpress actif).
-
- * Correction de doc.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Tue, 20 Mar 2001 10:49:46 +0100
-
-zinc-tk (3.1.24) unstable; urgency=low
-
- * Un début de scripts de démo en Perl.
-
- * Des adaptations pour Redhat/Mandrake et Solaris au niveau
- de la compilation (configure, Makefiles).
-
- * Debut d'intégration d'un rendu à base de GLX.
-
- * Corrections de bugs de rendu (rectangle, track), et de
- clipping (champs). Le relief des curves est géré dans
- le bon sens (il était inversé).
-
- * Correction du bug des curves -closed (corre dump).
-
- * Correction du core dump lors de la destruction d'un dépendant,
- par example waypoint attachées.
-
- * Correction de la fonction contour, il est désormais possible
- de fournir un contour sous forme de point. Correction d'un
- core dump lié à la libération intempestive de mémoire.
-
- * Correction de coords, il est possible d'ajouter/modifier des
- points à un curve sans contours (curve vide à la construction).
-
- * Modification du traitment des évènements/bindings pour
- les champs/parties. Maintenant les enter/leaves d'items
- sont controlés exclusivement par la sensibilité de l'item
- et les enter/leaves de champs par la sensibilité du champ
- et celle de l'item.
-
- * Suppression du grab sur bouton gauche appuyé, les enter/leave
- sont toujours générés.
-
- * Tentative d'homogénéiser la valeur de retour des fonctions
- retournant une liste. Désormais ce sera un tableau en Perl.
- Les fonctions touchées : bbox, monitor, find, mapinfo get.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 9 Feb 2001 11:22:22 +0100
-
-zinc-tk (3.1.23) unstable; urgency=low
-
- * -curve est à false par défaut (conforme à l'ancien
- usage).
- * Une curve ouverte garde ses deux points extrèmes même
- s'ils sont identiques.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 12 Jan 2001 17:39:42 +0100
-
-zinc-tk (3.1.22) unstable; urgency=low
-
- * Ajout de sections de compilation conditionnelle pour libart.
- Renommage de l'option -localrender en -render pour préparer
- l'avenir (openGL ou extension Render de Xfree86).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 4 Jan 2001 11:41:11 +0100
-
-zinc-tk (3.1.21) unstable; urgency=low
-
- * Ajouté une dep sur libart. Corrige des bugs sur l'appel de l'antirec.
- Corrge un bug de spec sur l'affichage de la derniere pos d'une piste
- en surbrillance.
- Implementation de la méthode Render sur plus d'items.
- Le vecteur vitesse est codé en flottant et il est possible de modifier
- sa largeur.
- Blocage de la version Tk à 8.0 pour etre compatible perltk et tk :
- Tk 8.2 implémente UTF8 et unicode.
- Correction de plusieurs bugs sur l'appel de l'antirec (essentiellement
- situés dans Track.c).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 16 Nov 2000 16:27:20 +0100
-
-zinc-tk (3.1.20) unstable; urgency=low
-
- * Début d'ajout du rendu local. Modif de l'appel
- de l'antirec (il était appelé trop fréquement).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 13 Nov 2000 11:23:18 +0100
-
-zinc-tk (3.1.19) unstable; urgency=low
-
- * Plus de doc.
-
- * Ajout de deux attributs à l'item Track afin de permettre une colorisation
- différenciée des positions passée et de la position courante.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 27 Sep 2000 10:58:01 +0200
-
-zinc-tk (3.1.18) unstable; urgency=low
-
- * Correction de bugs: fuite de mémoire, segmentation au démarrage
- alors que le pointeur est dans la fenêtre.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 29 Jun 2000 14:55:44 +0200
-
-zinc-tk (3.1.17) unstable; urgency=low
-
- * MODIFICATIONS INCOMPATIBLES: find atpoint est remplacée par
- find closest qui a la même sémantique que le find closest du
- canvas. LEs parties privées (connexions, vecteurs vitesse, etc)
- ne sont plus spécifiée par des nombres négatifs mais par des
- symboles (connection, position, speedvector, leader).
-
- * Tous les bindings associés à un item sont libérés lors de la
- destruction de l'item y compris ceux associés aux champs et
- aux parties privées.
-
- * La nouvelle commande verticeat retourne le sommet d'un curve ou
- bezier le plus près d'un point donné.
-
- * Le système de tags à été entièrement revu et s'appuie maintenant
- sur un seul jeuy de fonctions (plus de table de tag). Les items sont
- désormais toujours énumérés par ordre de priorité d'affichage.
- Il est désormais possible d'utiliser des connecteurs booléens là
- où un tag est attendu (&& || () ! ^ sont reconnus).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 21 Jun 2000 13:07:11 +0200
-
-zinc-tk (3.1.16) unstable; urgency=low
-
- * Passage en Tcl_Objs.
-
- * La compilation de GPC est optionnelle et la
- commande contour n'est oérationnelle que si
- GPC est inclu.
-
- * Ajout du copyright de GPC dans le fichier copyright.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 5 Jun 2000 13:56:59 +0200
-
-zinc-tk (3.1.15) unstable; urgency=low
-
- * Ajout de l'item Window
-
- * Ajout du focus, de la selection et des commandes et
- méthodes nécessaires à la saisie de texte.
-
- * Ajout d'une spec de dimensionnement de field permettant
- de specifier toute la hauteur et/ou toute la largeur
- du label.
-
- * Corrections de bugs sur Curve, Coords, Recherche de
- tags, etc.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 26 May 2000 10:41:38 +0200
-
-zinc-tk (3.1.14) unstable; urgency=low
-
- * Ajout des polygones multi-contours (fonction contour),
- de l'item Bezier, des fonctions fit et smooth (Bezier).
- * Correction d'un bug sur l'antirec interdisant l'antirec
- ailleurs que dans le top group.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 11 May 2000 16:09:30 +0200
-
-zinc-tk (3.1.13) unstable; urgency=low
-
- * Fix de bugs. Réalisation des dégradés. Clipping par un arc.
- find withtag ne sort plus en erreur si le tag/id n'est pas
- trouvé
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 23 Mar 2000 15:27:32 +0100
-
-zinc-tk (3.1.12) unstable; urgency=low
-
- * Fix de bugs et du paquetage. Amélioration des reliefs.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Tue, 7 Mar 2000 16:00:09 +0100
-
-zinc-tk (3.1.11) unstable; urgency=low
-
- *
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 25 Feb 2000 11:19:53 +0100
-
-zinc-tk (3.1.10) unstable; urgency=low
-
- * Modifications pour une meilleure configuration de la compil
- et du test en Perl.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 4 Feb 2000 15:42:11 +0100
-
-zinc-tk (3.1.9) unstable; urgency=low
-
- * Passage du nom radar au nom zinc.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 31 Jan 2000 14:27:56 +0100
-
-xradar3-tk (3.1.8) unstable; urgency=low
-
- * Fin de réalisation de ToArea pour Curve.
- * Mise à dispo de l'item Arc complet (sauf relief).
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 26 Jan 2000 14:39:05 +0100
-
-xradar3-tk (3.1.7) unstable; urgency=low
-
- * Ajout des commandes clone, group, monitor,
- * extension de fonctionalité de coords,
- * changement de nom de multipoint en curve,
- * amélioration des commandes find et addtag,
- * gestion des dégradés/couleurs en interne,
- * Gestion des flêches dans track et curve.
- * Gestion des bouts de lignes et des joints dans
- curve.
- * curve permet d'interpreter ses points comme des
- controles de Bezier (en plus de la méthode smooth).
- * Correction de bugs nombreuses.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 13 Jan 2000 11:12:35 +0100
-
-xradar3-tk (3.1.6) unstable; urgency=low
-
- * Correction dans debian pour assurer la mise en paquet suite à
- l'ajout de la bib dynamique ptkradar et om.
- * Correction de bugs, ajout de la commande chggroup.
- * Les reliefs ne sont plus fonctionnels.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 16 Dec 1999 11:30:43 +0100
-
-xradar3-tk (3.1.5) unstable; urgency=low
-
- * Ajout du clip, du tuilage. Séparation de l'antirec dans une lib.
- Mise à jour Perl, génération possible d'une bib debug pour perl.
- Génération d'une bib dynamique pour perl. Correction de bug.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 9 Dec 1999 14:28:44 +0100
-
-xradar3-tk (3.1.4) unstable; urgency=low
-
- * Remplacement de l'algo d'antirec par l'ancienne version de LAOM
- qui peut être distribuée sous LGPL. Corrections de bugs en particulier
- autour des transformations et du label format. Mise à jour partielle
- de la doc, etc. Suppression des phidiasseries.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 2 Dec 1999 15:47:18 +0100
-
-xradar3-tk (3.1.3) unstable; urgency=low
-
- * Grosses modifs autour des étiquettes, labelformats, guideurs
- et ancres/attachements.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 29 Nov 1999 11:36:23 +0100
-
-xradar3-tk (3.1.2) unstable; urgency=low
-
- * Ajout de l'item Rectangle. Correction de problèmes de binding.
- et plein d'autres choses.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 4 Nov 1999 16:51:06 +0100
-
-xradar3-tk (3.1.1) unstable; urgency=low
-
- * Première version de la branche instable 3.1. Comporte l'ajout des
- transformations et des groupes et les items Icon et Text.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 29 Oct 1999 17:14:20 +0200
-
-xradar3-tk (3.0.12) unstable; urgency=low
-
- * Quatrième version distribuée. Correction d'un bug bloquant sur itemcget
- dans l'incarnation perl. Début de passage en RadarBBox.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 4 Jun 1999 13:30:02 +0200
-
-xradar3-tk (3.0.11) unstable; urgency=low
-
- * Troisieme version distribuée. La XToolkit n'existe plus. Le paquetage
- de base est désormais xradar3-tk. Corrections de bugs dans le widget.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 4 Jun 1999 13:30:02 +0200
-
-xradar (3.0.10) unstable; urgency=low
-
- * Seconde version distribuée. Le schema de nommage debian incorpore
- desormais le patch level en troisieme partie. De plus la numérotation
- est celle d'un paquetage debian natif.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 21 May 1999 13:20:02 +0200
-
-xradar (3.0-2) unstable; urgency=low
-
- * Premiere version distribuée. Elle correspond à la ALPHA_10.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 21 May 1999 11:20:02 +0200
-
-xradar (3.0-1) unstable; urgency=low
-
- * Suppression de la dependance xbase. Cration des paquetages xradar-tk et
- xradar-perl.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Fri, 28 May 1999 14:26:02 +0200
-
-xradar (2.5-3) unstable; urgency=low
-
- * Ajout des dépendances et du soname sur la bibliothèque dynamique.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 9 Dec 1998 11:05:27 +0100
-
-xradar (2.5-2) unstable; urgency=low
-
- * Eclatement en trois paquetages. Un pour le runtime, un pour
- le développement et un pour les fontes.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 24 Aug 1998 13:40:50 +0200
-
-xradar (2.5-1) unstable; urgency=low
-
- * Passage en xradar 2.5.0 (beta de la 3.0)
- * Installation sous /usr/X11R6
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Mon, 4 May 1998 15:29:50 +0200
-
-xradar (2.4-3) unstable; urgency=low
-
- * Separation de la fonte curseur des autres fontes. Elle n'est plus
- fabriquée automatiquement et elle n'est plus installée.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Thu, 2 Apr 1998 10:13:50 +0200
-
-xradar (2.4-2) unstable; urgency=low
-
- * Ajout des fontes phidias.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Tue, 10 Mar 1998 11:04:38 +0100
-
-xradar (2.4-1) unstable; urgency=low
-
- * Initial Release.
-
- -- Patrick Lecoanet <lecoanet@ath.cena.fr> Wed, 25 Feb 1998 14:11:43 +0100
-
-
diff --git a/debian/control b/debian/control
deleted file mode 100644
index 81b0f7b..0000000
--- a/debian/control
+++ /dev/null
@@ -1,39 +0,0 @@
-Source: zinc-tk
-Section: devel
-Priority: extra
-Maintainer: Patrick Lecoanet <lecoanet@ath.cena.fr>
-Build-Depends: xlibs-dev, xlibmesa-dev, tk8.4-dev, tcl8.4-dev, perl-base, python (>= 2.1), debhelper (>> 3.0.0), tetex-extra (>= 1.0.2+20011202-2), gcc(>= 2.95.4-14), perl (>= 5.6.1-8.2), latex2html
-Standards-Version: 2.3.0.0
-
-Package: zinc-tk
-Architecture: i386
-#Depends: xlibmesa3
-Depends: tk8.4 (>= 8.4.3), xlibmesa3
-Conflicts: xradar3-tk
-Description: The Tk zinc widget.
- Tkzinc is a canvas like widget for the Tk toolkit. Its has been
- designed to provide a structured organization of its graphical
- components. It provides also advanced geometrical and graphical
- capabilities such as geometric construction (boolean ops),
- transformations, non rectangular clipping gradient fills, smart
- reliefs, etc.
- For more information, http://www.tkzinc.org
-
-Package: zinc-perl
-Architecture: i386
-Depends: perl-tk (>= 800.024)
-Conflicts: xradar3-perl
-Description: perl-tk variant of the Tk zinc widget.
- perl-tk variant of the Tk zinc widget.
-
-Package: zinc-python
-Architecture: all
-Depends: python, python-tk, zinc-tk (= ${Source-Version})
-Conflicts: python-xradar3
-Description: python interface to the Tk zinc widget.
- python interface to the Tk zinc widget.
-
-Package: zinc-doc
-Architecture: all
-Description: Documentation files for the Tk zinc widget
- Documentation files for the Tk zinc widget in html and pdf formats
diff --git a/debian/copyright b/debian/copyright
deleted file mode 100644
index 9c50fa6..0000000
--- a/debian/copyright
+++ /dev/null
@@ -1,22 +0,0 @@
-This package was debianized by Patrick Lecoanet lecoanet@ath.cena.fr on
-Wed, 25 Feb 1998 14:11:43 +0100.
-
-Copyright:
-
- Copyright (c) 1993 - 2002 CENA, Patrick Lecoanet --
-
- This code is free software; you can redistribute it and/or
- modify it under the terms of the GNU Library General Public
- License as published by the Free Software Foundation; either
- version 2 of the License, or (at your option) any later version.
-
- This code is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Library General Public License for more details.
-
- You should have received a copy of the GNU Library General Public
- License along with this code; if not, write to the Free
- Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
- MA 02111-1307, USA.
-
diff --git a/debian/rules b/debian/rules
deleted file mode 100755
index ff60d70..0000000
--- a/debian/rules
+++ /dev/null
@@ -1,125 +0,0 @@
-#!/usr/bin/make -f
-# Sample debian/rules that uses debhelper.
-# This file is public domain software, originally written by Joey Hess.
-#
-# This version is for a hypothetical package that builds an
-# architecture-dependant package, as well as an architecture-independent
-# package.
-
-# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
-
-TMP=`pwd`/debian/tmp
-TMP_DOC=`pwd`/debian/zinc-doc
-TMP_PERL=`pwd`/debian/zinc-perl
-TMP_PYTHON=`pwd`/debian/zinc-python
-
-
-DEFAULT_VERSION_PYTHON=$(shell echo `dpkg -p python| grep -e "^Version:" |cut -d" " -f2|cut -d"." -f1-2`)
-
-build: build-stamp
-
-build-stamp:
- dh_testdir
-
- touch build-stamp
-
-clean:
- dh_testdir
- dh_testroot
- -rm -f build-stamp
- -rm -f config.cache
- -$(MAKE) clean
-
- dh_clean
-
-install: build
- dh_testdir
- dh_testroot
- dh_clean -k
- dh_installdirs
-
-#
-# Configuring/compiling/installing for Tcl.
- ./configure --prefix=/usr --enable-gl=damage
- make binaries
- make install prefix=$(TMP)/usr
-#
-# Making/installing the documentation
- make pdf html
- -mkdir -p $(TMP_DOC)/usr/share/doc/zinc-doc/refman
- -install -m644 doc/refman.pdf $(TMP_DOC)/usr/share/doc/zinc-doc
- -install -m644 doc/refman/*.html doc/refman/*.css doc/refman/*.png $(TMP_DOC)/usr/share/doc/zinc-doc/refman
-
-#
-# Configuring/compiling/installing for Python.
- -mkdir -p $(TMP_PYTHON)/usr/lib/python$(DEFAULT_VERSION_PYTHON)/site-packages
- -install -m644 Python/Zinc.py $(TMP_PYTHON)/usr/lib/python$(DEFAULT_VERSION_PYTHON)/site-packages
-#
-# Configuring/compiling/installing for perl/Tk.
- -mkdir -p $(TMP_PERL)
- (cd Perl; ./export2cpan)
- (cd export2cpan/tk-zinc; perl Makefile.PL; make; make pure_install prefix=`pwd`/../../debian/zinc-perl/usr INSTALLDIRS=vendor PREFIX=`pwd`/../../debian/zinc-perl/usr)
-
- find $(TMP_PERL)/usr/lib/perl5 -type f -name .packlist | xargs rm -f
-
-# Build architecture-independent files here.
-binary-indep: build install
- dh_testdir -i
- dh_testroot -i
- dh_installchangelogs -i
- dh_installdocs -i BUGS
- dh_installexamples -i
-# dh_install --sourcedir=debian/tmp
-# dh_installmenu -i
-# dh_installdebconf -i
-# dh_installlogrotate -i
-# dh_installemacsen -i
-# dh_installpam -i
-# dh_installmime -i
-# dh_installinit -i
-# dh_installcron -i
-# dh_installinfo -i
-# dh_undocumented -i
- dh_installman -i
- dh_link -i
- dh_compress -i --exclude=.pdf
- dh_fixperms -i
- dh_installdeb -i
-# dh_perl -i
- dh_gencontrol -i
- dh_md5sums -i
- dh_builddeb -i
-
-# Build architecture-dependent files here.
-binary-arch: build install
- dh_testdir -a
- dh_testroot -a
- dh_installchangelogs -a
- dh_installdocs -a
- dh_installexamples -a
- dh_installmenu -a
-# dh_installdebconf -a
-# dh_installlogrotate -a
-# dh_installemacsen -a
-# dh_installpam -a
-# dh_installmime -a
-# dh_installinit -a
-# dh_installcron -a
-# dh_installinfo -a
-# dh_undocumented -a
- dh_installman -a
- dh_strip -a
- dh_link -a
- dh_compress -a --exclude=.pdf
- dh_fixperms -a
-# dh_makeshlibs -a
- dh_installdeb -a
-# dh_perl -a
- dh_shlibdeps -a
- dh_gencontrol -a
- dh_md5sums -a
- dh_builddeb -a
-
-binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary install
diff --git a/debian/zinc-python.postinst b/debian/zinc-python.postinst
deleted file mode 100644
index 0f85b0a..0000000
--- a/debian/zinc-python.postinst
+++ /dev/null
@@ -1,23 +0,0 @@
-#! /bin/bash -e
-#
-# Debian postinst script for Python hierarchical modules
-# Written by Gregor Hoffleit <flight@debian.org>
-#
-
-NAME=zinc-python
-DEFAULT_VERSION_PYTHON=`dpkg -p python| grep -e "^Version:" |cut -d" " -f2|cut -d"." -f1-2`
-DIRLIST="/usr/lib/python${DEFAULT_VERSION_PYTHON}/site-packages"
-
-case "$1" in
- configure|abort-upgrade|abort-remove|abort-deconfigure)
- for i in $DIRLIST ; do
- python -O /usr/lib/python${DEFAULT_VERSION_PYTHON}/compileall.py -q $i
- python /usr/lib/python${DEFAULT_VERSION_PYTHON}/compileall.py -q $i
- done
- ;;
-
- *)
- echo "postinst called with unknown argument \`$1'" >&2
- exit 1
- ;;
-esac
diff --git a/debian/zinc-python.prerm b/debian/zinc-python.prerm
deleted file mode 100644
index 6c9295a..0000000
--- a/debian/zinc-python.prerm
+++ /dev/null
@@ -1,11 +0,0 @@
-#! /bin/bash -e
-#
-# Debian prerm script for Python hierarchical modules
-# Written by Gregor Hoffleit <flight@debian.org>
-#
-
-NAME=zinc-python
-
-dpkg --listfiles $NAME |
- awk '$0~/\.py$/ {print $0"c\n" $0"o"}' |
- xargs rm -f >&2
diff --git a/demos/allOptions.tcl b/demos/allOptions.tcl
deleted file mode 100644
index 46b60c6..0000000
--- a/demos/allOptions.tcl
+++ /dev/null
@@ -1,121 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval allOptions {
- variable w .allOptions
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc All Option Demonstration"
- wm iconname $w "All options"
-
- frame $w.buttons
- pack $w.buttons -side bottom -fill x -pady 2m
- button $w.buttons.dismiss -text Dismiss -command "destroy $w"
- button $w.buttons.code -text "See Code" -command "showCode $w"
- pack $w.buttons.dismiss $w.buttons.code -side left -expand 1
-
- # The explanation displayed when running this demo
- label $w.label -justify left -text {Click on one of the following
- buttons to get a list of Item
- attributes (or zinc options)
- with their types.}
-
- pack $w.label -padx 10 -pady 10
-
-
- # Creating the zinc widget
- zinc $w.zinc -width 1 -height 1 -borderwidth 0 -relief sunken
- pack $w.zinc
-
- # Creating an instance of every item type
-
- variable itemTypes
- # These Items have fields! So the number of fields must be given at creation time
- foreach type {tabular track waypoint} {
- set itemTypes($type) [$w.zinc add $type 1 0]
- }
-
- # These items needs no specific initial values
- foreach type {group icon map reticle text window} {
- set itemTypes($type) [$w.zinc add $type 1]
- }
-
- # These items needs some coordinates at creation time
- # However curves usually needs more than 2 points.
- foreach type {arc curve rectangle} {
- set itemTypes($type) [$w.zinc add $type 1 {0 0 1 1}]
- }
-
- # Triangles item needs at least 3 points for the coordinates
- foreach type {triangles} {
- set itemTypes($type) [$w.zinc add $type 1 {0 0 1 1 2 2}]
- }
-
- proc showAllOptions { w type} {
- variable itemTypes
-
- if [winfo exists .tl] {destroy .tl}
- toplevel .tl
- if {[string compare $type zinc]==0} {
- set options [$w.zinc configure]
- set typeopt optionClass
- set readopt defaultValue
- set readoff 3
- set title {All options of zinc widget}
- } else {
- set options [$w.zinc itemconfigure $itemTypes($type)];
- set title "All attributes of an $type item"
- set typeopt Type
- set readopt ReadOnly
- set readoff 2
- }
-
- wm title .tl $title
-
- frame .tl.f1
- set bgcolor ivory
-
- label .tl.f1.opt -text Option -background $bgcolor -relief ridge -width 20
- label .tl.f1.typ -text $typeopt -background $bgcolor -relief ridge -width 20
- label .tl.f1.rd -text $readopt -background $bgcolor -relief ridge -width 21
-
- pack .tl.f1.opt .tl.f1.typ .tl.f1.rd -side left
- set nbelem [llength $options]
- frame .tl.f2
- listbox .tl.f2.l1 -width 20 -height $nbelem
- listbox .tl.f2.l2 -width 20 -height $nbelem
- listbox .tl.f2.l3 -width 20 -height $nbelem
- pack .tl.f2.l1 .tl.f2.l2 .tl.f2.l3 -side left
- pack .tl.f1 .tl.f2 -side top -anchor nw
-
- # Remplissage des list box
- foreach elem $options {
- .tl.f2.l1 insert end [lindex $elem 0]
- .tl.f2.l2 insert end [lindex $elem 1]
- .tl.f2.l3 insert end [lindex $elem $readoff]
- }
- }
-
- pack [frame $w.col]
-
- variable width 0
- foreach type [lsort [array names itemTypes]] {
- if {[string length $type] > $width} {
- set width [string length $type]
- }
- }
-
- foreach type [lsort [array names itemTypes]] {
- button $w.col.$type -text "$type" -width $width -command "::allOptions::showAllOptions $w $type"
- pack $w.col.$type -pady 4
-
- }
-
- button $w.col.b -text "zinc widget options" -command "::allOptions::showAllOptions $w zinc"
- pack $w.col.b -pady 4
-}
-
diff --git a/demos/atomicGroups.tcl b/demos/atomicGroups.tcl
deleted file mode 100644
index 2bf782b..0000000
--- a/demos/atomicGroups.tcl
+++ /dev/null
@@ -1,184 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval atomicGroups {
- variable w .atomicGroups
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Atomicity Demonstration"
- wm iconname $w "Atomic"
-
- variable defaultfont [font create -family Helvetica -size 14 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 6 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 6 -column 1 -pady 10
-
- grid [zinc $w.zinc -width 500 -height 350 -font $defaultfont -borderwidth 0] \
- -row 0 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 0 -weight 2
-
- variable groupsGroupAtomicity 0
- variable redGroupAtomicity 0
- variable greenGroupAtomicity 0
-
- $w.zinc add "text" 1 -font $defaultfont -text "- There are 3 groups: a red group containing 2 redish objects\na green group containing 2 greenish objects,\nand groupsGroup containing both previous groups.\n- You can make some groups atomic or not by depressing \nthe 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 ###############################
- variable groupsGroup [$w.zinc add group 1 -visible 1 -atomic $groupsGroupAtomicity -tags groupsGroup]
-
- # the following callbacks will be called only if "groupsGroup" IS atomic
- $w.zinc bind $groupsGroup <1> ::atomicGroups::modifyBitmapBg
- $w.zinc bind $groupsGroup <ButtonRelease-1> ::atomicGroups::modifyBitmapBg
-
- ############### creating the redGroup, with its binding and its content ################
- # the redGroup may be atomic, that is is makes all children as a single object
- # and sensitive to redGroup callbacks
- variable redGroup [$w.zinc add group $groupsGroup -visible 1 -atomic $redGroupAtomicity -sensitive 1 -tags redGroup]
-
- # the following callbacks will be called only if "groupsGroup" IS NOT-atomic
- # and if "redGroup" IS atomic
- $w.zinc bind $redGroup <1> "::atomicGroups::modifyItemLines $redGroup"
- $w.zinc bind $redGroup <ButtonRelease-1> "::atomicGroups::modifyItemLines $redGroup"
-
-
- variable rc [$w.zinc add arc $redGroup {100 200 140 240} -filled 1 -fillcolor red2 -linewidth 3 -linecolor white -tags redCircle]
- variable rr [$w.zinc add rectangle $redGroup {300 200 400 250} -filled 1 -fillcolor red2 -linewidth 3 -linecolor white -tags redRectangle]
-
- # the following callbacks will be called only if "groupsGroup" IS NOT atomic
- # and if "redGroup" IS NOT atomic
- $w.zinc bind $rc <1> ::atomicGroups::toggleColor
- $w.zinc bind $rc <ButtonRelease-1> ::atomicGroups::toggleColor
- $w.zinc bind $rr <1> ::atomicGroups::toggleColor
- $w.zinc bind $rr <ButtonRelease-1> ::atomicGroups::toggleColor
-
- ############### creating the greenGroup, with its binding and its content ################
- # the greenGroup may be atomic, that is is makes all children as a single object
- # and sensitive to greenGroup callbacks
- variable greenGroup [$w.zinc add group $groupsGroup -visible 1 -atomic $greenGroupAtomicity -sensitive 1 -tags greenGroup]
-
- # the following callbacks will be called only if "groupsGroup" IS NOT atomic
- # and if "greenGroup" IS atomic
- $w.zinc bind $greenGroup <1> "::atomicGroups::modifyItemLines $greenGroup"
- $w.zinc bind $greenGroup <ButtonRelease-1> "::atomicGroups::modifyItemLines $greenGroup"
-
- variable gc [$w.zinc add arc $greenGroup {100 270 140 310} -filled 1 -fillcolor green2 -linewidth 3 -linecolor white -tags greenCircle]
-
- variable gr [$w.zinc add rectangle $greenGroup {300 270 400 320} -filled 1 -fillcolor green2 -linewidth 3 -linecolor white -tags greenRectangle]
- # the following callbacks will be called only if "groupsGroup" IS NOT atomic
- # and if "greenGroup" IS NOT atomic
- $w.zinc bind $gc <1> ::atomicGroups::toggleColor
- $w.zinc bind $gc <ButtonRelease-1> ::atomicGroups::toggleColor
- $w.zinc bind $gr <1> ::atomicGroups::toggleColor
- $w.zinc bind $gr <ButtonRelease-1> ::atomicGroups::toggleColor
-
-
- variable currentBg ""
- ###################### groupsGroup callback ##############
-
- proc modifyBitmapBg {} {
- variable currentBg
- variable rc
- variable rr
- variable gc
- variable gr
- variable w
- if {$currentBg=="AlphaStipple2"} {
- set currentBg {}
- } else {
- set currentBg AlphaStipple2
- }
- foreach item "$rc $rr $gc $gr" {
- $w.zinc itemconfigure $item -fillpattern $currentBg
- }
- }
-
- #################### red/greenGroup callback ##############
- proc modifyItemLines {gr} {
- variable w
-
- set children [$w.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
-
- set currentLineWidth [$w.zinc itemcget [lindex $children 0] -linewidth]
-
- if {$currentLineWidth == 3} {
- set currentLineWidth 0
- } else {
- set currentLineWidth 3
- }
- foreach item $children {
- $w.zinc itemconfigure $item -linewidth $currentLineWidth
- }
-
- }
-
-
- ##################### items callback ######################
- proc toggleColor {} {
- variable w
- set item [$w.zinc find withtag current]
- set fillcolor [$w.zinc itemcget $item -fillcolor]
- regexp {([a-z]+)(\d)} $fillcolor "" color num
-
- #my ($color $num) = $fillcolor =~ /("a-z"+)(\d)/
- if {$num == 2} {
- set val 1
- set num 4
- } else {
- set num 2
- }
- $w.zinc itemconfigure $item -fillcolor "$color$num"
- }
-
- proc atomicOrNot {gr} {
- variable w
- set val [lindex [$w.zinc itemconfigure $gr -atomic] 4]
- if {$val==1} {
- $w.zinc itemconfigure $gr -atomic 0
- } else {
- $w.zinc itemconfigure $gr -atomic 1
- }
- updateFoundItems
- }
-
-
- ###################### toggle buttons at the bottom ####
-
- grid [checkbutton $w.cb -text "groupsGroup is atomic" -variable ::atomicGroups::groupsGroupAtomicity \
- -command "::atomicGroups::atomicOrNot $groupsGroup"] -row 1 -column 0 -sticky w
- grid [checkbutton $w.cb2 -text "red group is atomic" -foreground red4 \
- -variable ::atomicGroups::redGroupAtomicity \
- -command "::atomicGroups::atomicOrNot $redGroup"] -row 2 -column 0 -sticky w
- grid [checkbutton $w.cb3 -text "green group is atomic" -foreground green4 \
- -variable ::atomicGroups::greenGroupAtomicity \
- -command "::atomicGroups::atomicOrNot $greenGroup"] -row 3 -column 0 -sticky w
-
- grid [label $w.lb2 -text "Following command '$w.zinc find overlapping 0 200 500 400', returns:"] \
- -row 4 -column 0 -columnspan 2 -pady 10
- grid [label $w.label -text ""] \
- -row 5 -column 0 -columnspan 2
-
-
- ##### to update the list of enclosed items
- proc updateFoundItems {} {
- variable w
- set found [$w.zinc find overlapping 0 200 500 400]
- set str ""
- foreach item $found {
- set tags [$w.zinc itemcget $item -tags]
- set str "$str $tags"
- }
- $w.label configure -text $str
- }
-
- # to init the list of enclosed items
- updateFoundItems
-}
diff --git a/demos/clipping.tcl b/demos/clipping.tcl
deleted file mode 100644
index 4d0fa28..0000000
--- a/demos/clipping.tcl
+++ /dev/null
@@ -1,123 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval clippingDemo {
- variable w .clipping
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Clipping Demonstration"
- wm iconname $w "Clipping"
-
- variable defaultfont [font create -family Helvetica -size 14 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- grid [zinc $w.zinc -width 700 -height 600 -font $defaultfont -borderwidth 3 \
- -relief sunken] -row 0 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 0 -weight 2
-
- variable displayClippingItemBackground 0
- variable clip 1
-
- $w.zinc add text 1 -font $defaultfont -text "You can drag and drop the objects.\nThere are two groups of objects a tan group and a blue group\nTry to move them and discover the clipping area which is a curve.\nwith two contours" -anchor nw -position {10 10}
-
-
- variable clippedGroup [$w.zinc add group 1 -visible 1]
-
- variable clippingItem [$w.zinc add curve $clippedGroup {10 100 690 100 690 590 520 350 350 590 180 350 10 590} -closed 1 -priority 1 -fillcolor tan2 -linewidth 0 -filled $displayClippingItemBackground]
- $w.zinc contour $clippingItem add +1 {200 200 500 200 500 250 200 250}
-
- ############### creating the tanGroup objects ################
- # the tanGroup is atomic that is is makes all children as a single object
- # and sensitive to tanGroup callbacks
- variable tanGroup [$w.zinc add group $clippedGroup -visible 1 -atomic 1 -sensitive 1]
-
-
- $w.zinc add arc $tanGroup {200 220 280 300} -filled 1 -linewidth 1 -startangle 45 -extent 270 -pieslice 1 -closed 1 -fillcolor tan
-
-
- $w.zinc add curve $tanGroup {400 400 440 450 400 500 500 500 460 450 500 400} -filled 1 -fillcolor tan -linecolor tan
-
-
- ############### creating the blueGroup objects ################
- # the blueGroup is atomic too that is is makes all children as a single object
- # and sensitive to blueGroup callbacks
- variable blueGroup [$w.zinc add group $clippedGroup -visible 1 -atomic 1 -sensitive 1]
-
- $w.zinc add rectangle $blueGroup {570 180 470 280} -filled 1 -linewidth 1 -fillcolor blue2
-
- $w.zinc add curve $blueGroup {200 400 200 500 300 500 300 400 300 300} -filled 1 -fillcolor blue -linewidth 0
-
-
- $w.zinc itemconfigure $clippedGroup -clip $clippingItem
-
-
- ###################### drag and drop callbacks ############
- # for both tanGroup and blueGroup
-
- $w.zinc bind $tanGroup <1> "::clippingDemo::itemStartDrag $tanGroup %x %y"
- $w.zinc bind $tanGroup <B1-Motion> "::clippingDemo::itemDrag $tanGroup %x %y"
- $w.zinc bind $blueGroup <1> "::clippingDemo::itemStartDrag $blueGroup %x %y"
- $w.zinc bind $blueGroup <B1-Motion> "::clippingDemo::itemDrag $blueGroup %x %y"
-
-
-
- # callback for starting a drag
- variable xOrig ""
- variable yOrig ""
-
- proc itemStartDrag {item x y} {
- variable xOrig
- variable yOrig
- set xOrig $x
- set yOrig $y
- }
-
- # Callback for moving an item
- proc itemDrag {item x y} {
- variable xOrig
- variable yOrig
- variable w
- $w.zinc translate $item [expr $x-$xOrig] [expr $y-$yOrig];
- set xOrig $x;
- set yOrig $y;
- }
-
-
-
- ###################### toggle buttons at the bottom #######
- grid [frame $w.row] -row 1 -column 0 -columnspan 2
- checkbutton $w.row.show -text "Show clipping item" \
- -variable ::clippingDemo::displayClippingItemBackground \
- -command "::clippingDemo::displayClippingArea"
- checkbutton $w.row.clip -text Clip -variable ::clippingDemo::clip \
- -command "::clippingDemo::clipCommand"
- pack $w.row.show $w.row.clip -side left
-
- proc displayClippingArea {} {
- variable clippingItem
- variable w
- variable displayClippingItemBackground
- $w.zinc itemconfigure $clippingItem -filled $displayClippingItemBackground
- }
-
- proc clipCommand {} {
- variable clip
- variable clippedGroup
- variable clippingItem
- variable w
-
- if {$clip} {
- $w.zinc itemconfigure $clippedGroup -clip $clippingItem
- } else {
- $w.zinc itemconfigure $clippedGroup -clip ""
- }
- }
-}
diff --git a/demos/colorCircular.tcl b/demos/colorCircular.tcl
deleted file mode 100644
index e829fd8..0000000
--- a/demos/colorCircular.tcl
+++ /dev/null
@@ -1,63 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval colorCircular {
- variable w .colorCircular
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Color Circular Demonstration"
- wm iconname $w "Color Circular"
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- variable defaultfont [font create -family Helvetica -size 14 -weight normal]
-
- grid [zinc $w.zinc -width 700 -height 600 -borderwidth 3 -relief sunken -render 1] \
- -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- $w.zinc add rectangle 1 {10 10 80 80} -fillcolor {=radial 50 50|red|blue} -filled 1
- $w.zinc add text 1 -font $defaultfont -text {Radial variation from non-transparent red to non-transparent blue in a square.
-The gradient starts in the lower right corner.} -anchor nw -position {120 20}
-
- $w.zinc add arc 1 {10 110 90 190} -fillcolor {=radial 0 25|red;40|blue;40} -filled 1
-
- $w.zinc add text 1 -font $defaultfont -text {Radial variation from 40% transparent red to 40% transparent blue in a disc.
-The gradient starts mid way between the center and the bottom.} \
- -anchor nw -position {120 120}
-
- $w.zinc add arc 1 {10 210 90 290} -fillcolor {=radial 0 0|red;40|green;40 50|blue;40} -filled 1
-
- $w.zinc add text 1 -font $defaultfont -text {A variation from 40% transparent red to 40% transparent blue
-through 40% green in the middle of the disc. The gradient is centered.} \
- -anchor nw -position {120 220}
-
- $w.zinc add text 1 -font $defaultfont -anchor w -position {20 320} \
- -text {Two overlapping items filled by a transparent radial gradient on a white background.
-On the right three gradient filled ovals, note the warped gradients following the ovals.}
-
- $w.zinc add rectangle 1 {10 340 690 590} -fillcolor white -filled 1
-
- $w.zinc add rectangle 1 {20 365 220 565} -fillcolor {=radial 0 0|red;40|green;40 50|blue;40} -filled 1
-
- $w.zinc add arc 1 {150 365 350 565} -fillcolor {=radial 0 0|yellow;40|black;40 50|cyan;40} -filled 1
-
- $w.zinc add arc 1 {280 365 480 565} -fillcolor {=radial 0 0|black;100|black;100 20|mistyrose;40} -filled 1 -linewidth 0
-
- variable warc [$w.zinc add arc 1 {-50 -50 50 50} \
- -fillcolor {=radial -10 16|black;80|blue;20 90 100} -filled 1]
- $w.zinc scale $warc 1.5 1
- $w.zinc translate $warc 500 432
-
- variable warc [$w.zinc add arc 1 {-50 -50 50 50} \
- -fillcolor {=radial 0 20|black;70|green;20} -filled 1]
- $w.zinc scale $warc 1 1.5
- $w.zinc translate $warc 630 432
-}
diff --git a/demos/colorX.tcl b/demos/colorX.tcl
deleted file mode 100644
index 2a4d8a3..0000000
--- a/demos/colorX.tcl
+++ /dev/null
@@ -1,48 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval colorX {
- variable w .colorX
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Color-x Demonstration"
- wm iconname $w "Color X"
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- variable defaultfont [font create -family Helvetica -size 14 -weight normal]
-
- grid [zinc $w.zinc -width 700 -height 600 -borderwidth 3 -relief sunken -render 1] \
- -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- $w.zinc add rectangle 1 {10 10 690 100} -fillcolor {red|blue} -filled 1
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {20 20} \
- -text "A variation from non transparent red to non transparent blue.\n"
-
- $w.zinc add rectangle 1 {10 110 690 200} -fillcolor {red;40|blue;40} -filled 1
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {20 120} \
- -text "A variation from 40%transparent red to 40% transparent blue."
-
- $w.zinc add rectangle 1 {10 210 690 300} -fillcolor {red;40|green;40 50|blue;40} -filled 1
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {20 220} \
- -text "A variation from 40%transparent red to 40% transparent blue.\nthrough a 40%green on the middle"
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {20 320} \
- -text "Two overlaping transparently colored rectangles on a white background"
-
- $w.zinc add rectangle 1 {10 340 690 590} -fillcolor white -filled 1
- $w.zinc add rectangle 1 {200 350 500 580} -fillcolor {red;40|green;40 50|blue;40} -filled 1
-
- $w.zinc add rectangle 1 {10 400 690 500} -fillcolor {yellow;40|black;40 50|cyan;40} -filled 1
-}
diff --git a/demos/colorY.tcl b/demos/colorY.tcl
deleted file mode 100644
index e1b1f38..0000000
--- a/demos/colorY.tcl
+++ /dev/null
@@ -1,48 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval colorY {
- variable w .colorY
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Color-y Demonstration"
- wm iconname $w "Color y"
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- variable defaultfont [font create -family Helvetica -size 14 -weight normal]
-
- grid [zinc $w.zinc -width 700 -height 600 -borderwidth 3 -relief sunken -render 1] \
- -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- $w.zinc add rectangle 1 {10 10 690 100} -fillcolor {=axial 90|red|blue} -filled 1
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {20 20} \
- -text "A variation from non transparent red to non transparent blue.\n"
-
- $w.zinc add rectangle 1 {10 110 690 200} -fillcolor {=axial 90|red;40|blue;40} -filled 1
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {20 120} \
- -text "A variation from 40%transparent red to 40% transparent blue."
-
- $w.zinc add rectangle 1 {10 210 690 300} -fillcolor {=axial 90|red;40|green;40 50|blue;40} -filled 1
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {20 220} \
- -text "A variation from 40%transparent red to 40% transparent blue.\nthrough a 40%green on the middle"
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {20 320} \
- -text "Two overlaping transparently colored rectangles on a white background"
-
- $w.zinc add rectangle 1 {10 340 690 590} -fillcolor white -filled 1
- $w.zinc add rectangle 1 {200 350 500 580} -fillcolor {=axial 90|red;40|green;40 50|blue;40} -filled 1
-
- $w.zinc add rectangle 1 {10 400 690 500} -fillcolor {=axial 90|yellow;40|black;40 50|cyan;40} -filled 1
-}
diff --git a/demos/contours.tcl b/demos/contours.tcl
deleted file mode 100644
index 4f08fca..0000000
--- a/demos/contours.tcl
+++ /dev/null
@@ -1,202 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval contoursDemo {
- variable w .contours
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Curve contours Demonstration"
- wm iconname $w Curve
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- # The explanation displayed when running this demo
- grid [text $w.text -relief sunken -borderwidth 2 -setgrid true -height 9] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end "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
- grid [zinc $w.zinc -width 600 -height 500 -borderwidth 3 \
- -relief sunken] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- variable top 1
-
- # 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
-
- variable curve0 [$w.zinc add curve $top {
- {300 0} {400 100 c} {300 200} {200 300 c} {100 200} {0 100 c} {100 0}
- } -closed 1 -visible 0 -filled 1]
- variable cercle100 [$w.zinc add arc 1 {130 30 280 180} -visible 0]
-
-
- # cloning curve0 as curve1 and moving it
- variable curve1 [$w.zinc clone $curve0 -visible 1 -fillcolor firebrick1]
- # adding a 'difference' contour to the curve1
- $w.zinc contour $curve1 add 1 $cercle100
-
-
- # cloning curve0 as curve2 and moving it
- # creating a curve without contour to control contour clockwise/counterclockwise
- variable curve2 [$w.zinc add curve $top {} -closed 1 -filled 1 \
- -fillcolor lightblue2 -fillrule positive]
- $w.zinc contour $curve2 add +1 $curve0
- $w.zinc translate $curve2 100 90
-
- # adding the left ear of mickey mouse!
- $w.zinc contour $curve2 add +1 $cercle100
- $w.zinc translate $curve2 -200 0
-
- # adding the right ear of mickey mouse!
- $w.zinc contour $curve2 add +1 $cercle100
-
- # ... translate to make it more visible
- $w.zinc translate $curve2 320 20
-
- # cloning curve0 as curve3 and moving it
- variable curve3 [$w.zinc clone $curve0 -visible 1 -fillcolor yellow3]
- $w.zinc translate $curve3 0 290
-
- # adding an nion' contour to the curve3
- $w.zinc contour $curve3 add +1 $cercle100
- # ... translate to make it more visible
- $w.zinc translate $curve3 -130 0
-
-
-
-
- # cloning curve0 as curve4 and moving it slightly
- variable curve4 [$w.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
-
-
- variable index 2; ## index of the vertex associated to the handle
- variable coord [$w.zinc coords $curve4 0 $index]
- variable x [lindex $coord 0]
- variable y [lindex $coord 1]
- variable handle [$w.zinc add rectangle $top "[expr $x-5] [expr $y-5] [expr $x+5] [expr $y+5]" \
- -fillcolor black -filled 1 -tags {grouped}]
-
-
- # adding a 'difference' contour to the curve4
- $w.zinc contour $curve4 add +1 $cercle100
- $w.zinc translate grouped 110 0
- $w.zinc contour $curve4 add +1 $cercle100
- $w.zinc translate grouped -220 0
- $w.zinc contour $curve4 add +1 $cercle100
- $w.zinc translate grouped 10 80
- $w.zinc contour $curve4 add -1 $cercle100
- $w.zinc translate grouped 0 -10
- $w.zinc contour $curve4 add +1 $cercle100
-
- $w.zinc translate grouped 200 80
- $w.zinc contour $curve4 add +1 $cercle100
- $w.zinc translate grouped -350 0
- $w.zinc contour $curve4 add +1 $cercle100
-
- $w.zinc translate grouped 350 250
- #$zinc->lower(grouped);
-
- # Deleting no more usefull items: curve0 and cercle10:
- $w.zinc remove $curve0 $cercle100
-
- $w.zinc raise $curve1
-
- # adding drag and drop callback to each visible curve!
- foreach item "$curve1 $curve2 $curve3 $curve4" {
- # Some bindings for dragging the items
- $w.zinc bind $item <ButtonPress-1> "::contoursDemo::press $item motion %x %y"
- $w.zinc bind $item <ButtonRelease-1> ::contoursDemo::release
- }
-
- # adding drag and drop on curve4 which also moves handle
- $w.zinc bind $curve4 <ButtonPress-1> "::contoursDemo::press $curve4 motionWithHandle %x %y"
- $w.zinc bind $curve4, <ButtonRelease-1> ::contoursDemo::release
-
- # adding drag and drop on handle which also modify curve4
- $w.zinc bind $handle <ButtonPress-1> "::contoursDemo::press $handle moveHandle %x %y"
- $w.zinc bind $handle <ButtonRelease-1> ::contoursDemo::release
-
- # callback for starting a drag
- variable xOrig 0
- variable yOrig 0
-
- proc press {item action x y} {
- variable w
- variable xOrig
- variable yOrig
-
- set xOrig $x
- set yOrig $y
- bind $w.zinc <Motion> "::contoursDemo::$action $item %x %y"
- }
-
- # Callback for moving an item
- proc motion {item x y} {
- variable w
- variable xOrig
- variable yOrig
-
- $w.zinc translate $item [expr $x - $xOrig] [expr $y - $yOrig]
- set xOrig $x
- set yOrig $y
- }
-
- # Callback for moving an item and its handle
- proc motionWithHandle {item x y} {
- variable w
- variable xOrig
- variable yOrig
-
- set tag [lindex [$w.zinc itemcget $item -tags] 0]
- $w.zinc translate $tag [expr $x-$xOrig] [expr $y-$yOrig]
- set xOrig $x;
- set yOrig $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!
- proc moveHandle {handle x y} {
- variable w
- variable xOrig
- variable yOrig
- variable curve4
- variable index
-
- $w.zinc translate $handle [expr $x - $xOrig] [expr $y - $yOrig];
-
- foreach {vertxX vertxY} [$w.zinc coords $curve4 0 $index] break
- $w.zinc coords $curve4 0 $index "[expr $vertxX+($x-$xOrig)] [expr $vertxY+($y-$yOrig)]"
- set xOrig $x
- set yOrig $y
- }
-
-
- proc release {} {
- variable w
-
- bind $w.zinc <Motion> {}
- }
-}
diff --git a/demos/curveBezier.tcl b/demos/curveBezier.tcl
deleted file mode 100644
index ed1622e..0000000
--- a/demos/curveBezier.tcl
+++ /dev/null
@@ -1,265 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-
-namespace eval curveBezier {
- variable w .curveBezier
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Curve Bezier Demonstration"
- wm iconname $w Curve
-
- variable defaultfont [font create -family Helvetica -size 14 -weight normal]
- #variable imagePath [file join $zinc_library demos images]
- #variable texture [image create photo -file [file join $imagePath paper-grey1.gif]]
- variable splineColor \#AA0000
- variable handleColor grey70
- variable barColor grey30
- variable textColor grey20
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- grid [text $w.text -relief sunken -borderwidth 2 -setgrid true -height 3] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.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
- }
-
- grid [zinc $w.zinc -width 700 -height 650 -font $defaultfont -borderwidth 0 \
- -backcolor \#898A8F] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- variable group [$w.zinc add group 1]
-
- $w.zinc add text $group -position {50 20} -anchor w -color $textColor \
- -text {Examples of curve items using cubic bezier control points}
-
- ## Please note: much of the items below could be computed
- $w.zinc add text $group -anchor w -position {25 270} -tags bezier1 -color $textColor -width 270
- $w.zinc add curve $group {100 200 100 100} -tags {line1 l1-2} \
- -linecolor $barColor -filled 0 -linewidth 2
- $w.zinc add curve $group {400 100 400 200} -tags {line1 l3-4} \
- -linecolor $barColor -filled 0 -linewidth 2
- $w.zinc add curve $group {{100 200} {100 100 c} {400 100 c} {400 200}} \
- -tags bezier1 -closed 0 -linecolor $splineColor -linewidth 5
- $w.zinc add arc $group {90 190 110 210} -tags {handle1 p1} -filled 1 \
- -fillcolor \#BBBBBB
- $w.zinc add arc $group {90 90 110 110} -tags {handle1 p2} -filled 1 \
- -linewidth 0 -fillcolor $handleColor -filled 1
- $w.zinc add arc $group {390 90 410 110} -tags {handle1 p3} -filled 1 \
- -linewidth 0 -fillcolor $handleColor -filled 1
- $w.zinc add arc $group {390 190 410 210} -tags {handle1 p4} -filled 1 \
- -fillcolor \#BBBBBB
-
- $w.zinc add text $group -anchor w -position {570 270} -tags bezier2 -color $textColor -width 270
- $w.zinc add curve $group {600 200 675 100} -tags {line2 l1-2} \
- -linecolor $barColor -linewidth 2
- $w.zinc add curve $group {975 100 900 200} -tags {line2 l3-4} \
- -linecolor $barColor -linewidth 2
- $w.zinc add curve $group {{600 200} {675 100 c} {975 100 c} {900 200}} \
- -tags bezier2 -closed 0 -linecolor $splineColor -linewidth 5
- $w.zinc add arc $group {590 190 610 210} -tags {handle2 p1} -filled 1 \
- -fillcolor $handleColor
- $w.zinc add arc $group {665 90 685 110} -tags {handle2 p2} -filled 1 \
- -linewidth 0 -fillcolor $handleColor
- $w.zinc add arc $group {965 90 985 110} -tags {handle2 p3} -filled 1 \
- -linewidth 0 -fillcolor $handleColor
- $w.zinc add arc $group {890 190 910 210} -tags {handle2 p4} -filled 1 \
- -fillcolor $handleColor
-
- $w.zinc add text $group -anchor w -position {25 570} -tags bezier3 -color $textColor -width 270
- $w.zinc add curve $group {100 500 25 400} -tags {line3 l1-2} \
- -linecolor $barColor -linewidth 2
- $w.zinc add curve $group {475 400 400 500} -tags {line3 l3-4} \
- -linecolor $barColor -linewidth 2
- $w.zinc add curve $group {{100 500} {25 400 c} {475 400 c} {400 500}} \
- -tags {bezier3} -closed 0 -linecolor $splineColor -linewidth 5
- $w.zinc add arc $group {90 490 110 510} -tags {handle3 p1} -filled 1 \
- -fillcolor $handleColor
- $w.zinc add arc $group {15 390 35 410} -tags {handle3 p2} -filled 1 \
- -linewidth 0 -fillcolor $handleColor
- $w.zinc add arc $group {465 390 485 410} -tags {handle3 p3} -filled 1 \
- -linewidth 0 -fillcolor $handleColor
- $w.zinc add arc $group {390 490 410 510} -tags {handle3 p4} -filled 1 \
- -fillcolor $handleColor
-
- $w.zinc add text $group -anchor w -position {570 570} -tags bezier4 -color $textColor -width 270
- $w.zinc add curve $group {600 500 600 350} -tags {line4 l1-2} \
- -linecolor $barColor -linewidth 2
- $w.zinc add curve $group {900 650 900 500} -tags {line4 l3-4} \
- -linecolor $barColor -linewidth 2
- $w.zinc add curve $group {{600 500} {600 350 c} {900 650 c} {900 500}} \
- -tags {bezier4} -closed 0 -linecolor $splineColor -linewidth 5
- $w.zinc add arc $group {590 490 610 510} -tags {handle4 p1} -filled 1 \
- -fillcolor $handleColor
- $w.zinc add arc $group {590 340 610 360} -tags {handle4 p2} -filled 1 \
- -linewidth 0 -fillcolor $handleColor
- $w.zinc add arc $group {890 640 910 660} -tags {handle4 p3} -filled 1 \
- -linewidth 0 -fillcolor $handleColor
- $w.zinc add arc $group {890 490 910 510} -tags {handle4 p4} -filled 1 \
- -fillcolor $handleColor
-
- $w.zinc add text $group -anchor w -position {25 870} -tags bezier5 -color $textColor -width 270
- $w.zinc add curve $group {100 800 175 700} -tags {line5 l1-2} \
- -linecolor $barColor -filled 0 -linewidth 2
- $w.zinc add curve $group {325 700 400 800} -tags {line5 l3-4} \
- -linecolor $barColor -filled 0 -linewidth 2
- $w.zinc add curve $group {{100 800} {175 700 c} {325 700 c} {400 800}} \
- -tags {bezier5} -closed 0 -linecolor $splineColor -linewidth 5
- $w.zinc add arc $group {90 790 110 810} -tags {handle5 p1} -filled 1 \
- -fillcolor $handleColor
- $w.zinc add arc $group {165 690 185 710} -tags {handle5 p2} -filled 1 \
- -linewidth 0 -fillcolor $handleColor -filled 1
- $w.zinc add arc $group {315 690 335 710} -tags {handle5 p3} -filled 1 \
- -linewidth 0 -fillcolor $handleColor -filled 1
- $w.zinc add arc $group {390 790 410 810} -tags {handle5 p4} -filled 1 \
- -fillcolor $handleColor
-
- $w.zinc add text $group -anchor w -position {570 970} -tags bezier6 -color $textColor -width 280
- $w.zinc add curve $group {600 800 625 700} -tags {line6 l1-2} \
- -linecolor $barColor -linewidth 2
- $w.zinc add curve $group {725 700 750 800} -tags {line6 l3-4} \
- -linecolor $barColor -linewidth 2
- $w.zinc add curve $group {750 800 775 900} -tags {line6 l4-5} \
- -linecolor $barColor -linewidth 2
- $w.zinc add curve $group {875 900 900 800} -tags {line6 l6-7} \
- -linecolor $barColor -linewidth 2
- $w.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 $splineColor -linewidth 5
- $w.zinc add arc $group {590 790 610 810} -tags {handle6 p1} -filled 1 \
- -fillcolor $handleColor
- $w.zinc add arc $group {615 690 635 710} -tags {handle6 p2} -filled 1 \
- -linewidth 0 -fillcolor $handleColor
- $w.zinc add arc $group {715 690 735 710} -tags {handle6 p3} -filled 1 \
- -linewidth 0 -fillcolor $handleColor
- $w.zinc add arc $group {740 790 760 810} -tags {handle6 p4} -filled 1 \
- -linecolor blue -fillcolor blue -linewidth 2
- $w.zinc add arc $group {766 891 784 909} -tags {handle6 p5} -filled 1 \
- -fillcolor $handleColor
- $w.zinc add arc $group {865 890 885 910} -tags {handle6 p6} -filled 1 \
- -linewidth 0 -fillcolor $handleColor
- $w.zinc add arc $group {890 790 910 810} -tags {handle6 p7} -filled 1 \
- -fillcolor $handleColor
-
-
- $w.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"
- proc setText {tag} {
- variable w
- set textItem [$w.zinc find withtype text $tag]
- set curveItem [$w.zinc find withtype curve $tag]
- set coords [$w.zinc coords $curveItem]
- set count 0
- $w.zinc itemconfigure $textItem -text $coords
- }
-
- foreach bezierCount {1 2 3 4 5 6} {
- setText "bezier$bezierCount"
- set curveItem [$w.zinc find withtype curve "bezier$bezierCount"]
- set coords [$w.zinc coords $curveItem]
- #puts "$bezierCount : $curveItem : $coords"
- $w.zinc bind "handle$bezierCount" <1> {::curveBezier::itemStartDrag %x %y}
- $w.zinc bind "handle$bezierCount" <B1-Motion> {::curveBezier::itemDrag %x %y}
- #$w.zinc bind "handle$bezierCount" "<ButtonPress-1>" {\&press \&motion}
- #$w.zinc bind "handle$bezierCount" "<ButtonRelease-1>" {\&release}
- }
-
-
-
-
- ##### bindings for moving the handles
- variable item ""
- variable bezierNum ""
- variable ptNum ""
-
- variable xOrig 0
- variable yOrig 0
-
- proc itemStartDrag {x y} {
- variable w
- variable xOrig
- variable yOrig
- variable bezierNum
- variable ptNum
- variable item
-
- set xOrig $x
- set yOrig $y
- set item [$w.zinc find withtag current]
-
- foreach val [$w.zinc gettags $item] {
- regexp {([a-z]+)(\d)} $val "" name num
- if {$name=="handle"} {set bezierNum $num}
- if {$name=="p"} {set ptNum $num}
- }
- #puts "bezierNum=$bezierNum ptNum=$ptNum"
- }
-
- # Callback for moving an item
- proc itemDrag {x y} {
- variable xOrig
- variable yOrig
- variable w
- variable item
-
- $w.zinc transform $item "[expr $x - $xOrig] [expr $y - $yOrig]"
- moveHandle [expr $x - $xOrig] [expr $y - $yOrig]
- set xOrig $x
- set yOrig $y
- }
-
-
- proc moveHandle {dx dy} {
- variable w
- variable bezierNum
- variable ptNum
- variable item
-
- set pt1 [lindex [$w.zinc coords $item] 0]
- set pt2 [lindex [$w.zinc coords $item] 1]
-
- ## modifying the handle coords
- $w.zinc coords $item "[expr [lindex $pt1 0]+$dx] [expr [lindex $pt1 1]+$dy] [expr [lindex $pt2 0]+$dx] [expr [lindex $pt2 1]+$dy]"
- set prevPtNum [expr $ptNum-1]
-
- # there should only be one such item!
- set lineA [$w.zinc find withtag "line$bezierNum && l$prevPtNum-$ptNum"]
- if {$lineA!=""} {
- set x [lindex [$w.zinc coords $lineA 0 1] 0]
- set y [lindex [$w.zinc coords $lineA 0 1] 1]
- $w.zinc coords $lineA 0 1 "[expr $x+$dx] [expr $y+$dy]"
- }
-
- set nextPtNum [expr $ptNum+1]
- # there should only be one such item:
- set lineB [$w.zinc find withtag "line$bezierNum && l$ptNum-$nextPtNum"]
- if {$lineB!=""} {
- set x [lindex [$w.zinc coords $lineB 0 0] 0]
- set y [lindex [$w.zinc coords $lineB 0 0] 1]
- $w.zinc coords $lineB 0 0 "[expr $x+$dx] [expr $y+$dy]"
- }
- set tab [$w.zinc coords "bezier$bezierNum" 0 [expr $ptNum-1]]
- set x [lindex $tab 0]
- set y [lindex $tab 1]
- set control [lindex $tab 2]
- $w.zinc coords "bezier$bezierNum" 0 [expr $ptNum-1] "[expr $x+$dx] [expr $y+$dy] $control"
- setText "bezier$bezierNum"
- }
-}
-
diff --git a/demos/data/hegias_parouest_TE.vid b/demos/data/hegias_parouest_TE.vid
deleted file mode 100644
index 1755d80..0000000
--- a/demos/data/hegias_parouest_TE.vid
+++ /dev/null
Binary files differ
diff --git a/demos/data/videomap_orly b/demos/data/videomap_orly
deleted file mode 100644
index 17f9c66..0000000
--- a/demos/data/videomap_orly
+++ /dev/null
Binary files differ
diff --git a/demos/data/videomap_paris-w_90_2 b/demos/data/videomap_paris-w_90_2
deleted file mode 100644
index fb32a5b..0000000
--- a/demos/data/videomap_paris-w_90_2
+++ /dev/null
Binary files differ
diff --git a/demos/fillRule.tcl b/demos/fillRule.tcl
deleted file mode 100644
index 8817709..0000000
--- a/demos/fillRule.tcl
+++ /dev/null
@@ -1,105 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval fillRule {
- variable w .fillRule
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Fillrule Demonstration"
- wm iconname $w "Fillrule"
-
- variable defaultfont [font create -family Helvetica -size 16 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- ####### 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
-
- #variable imagePath [file join $zinc_library demos images]
- #variable texture [image create photo -file [file join $imagePath paper-grey1.gif]]
-
- grid [zinc $w.zinc -width 550 -height 680 -font $defaultfont -borderwidth 0 \
- -backcolor \#898A8F] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
-
- $w.zinc add text 1 -position {20 8} -alignment center -text {This static example reproduces figure 11-3
-of "The OpenGL Programming Guide 3rd Edition" V 1.2}
-
- variable group [$w.zinc add group 1]
-
- variable g1 [$w.zinc add group $group]
- variable curve1 [$w.zinc add curve $g1 {}]
- $w.zinc contour $curve1 add +1 { 0 0 0 120 120 120 120 0 0 0}
- $w.zinc contour $curve1 add +1 { 20 20 20 100 100 100 100 20 20 20}
- $w.zinc contour $curve1 add +1 { 40 40 40 80 80 80 80 40 40 40}
- $w.zinc translate $g1 100 100
-
-
- variable g2 [$w.zinc add group $group]
- variable curve2 [$w.zinc add curve $g2 {}]
- $w.zinc contour $curve2 add +1 { 0 0 0 120 120 120 120 0 0 0}
- $w.zinc contour $curve2 add -1 { 20 20 20 100 100 100 100 20 20 20}
- $w.zinc contour $curve2 add -1 { 40 40 40 80 80 80 80 40 40 40}
- $w.zinc translate $g2 260 100
-
-
- variable g3 [$w.zinc add group $group]
- variable curve3 [$w.zinc add curve $g3 {}]
- $w.zinc contour $curve3 add +1 { 20 0 20 120 100 120 100 0 20 0}
- $w.zinc contour $curve3 add +1 { 40 20 60 120 80 20 40 20}
- $w.zinc contour $curve3 add +1 { 0 60 0 80 120 80 120 60 0 60}
- $w.zinc translate $g3 420 100
-
- variable g4 [$w.zinc add group $group]
- variable curve4 [$w.zinc add curve $g4 {}]
- $w.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}
- $w.zinc translate $g4 580 100
-
- $w.zinc scale $group 0.6 0.6
- $w.zinc translate $group 80 40
-
- variable t [$w.zinc add text $group -underlined yes -text "Contours"]
- $w.zinc translate $t 280 30
- set t [$w.zinc add text $group -underlined yes -text "-fillrule"]
- $w.zinc translate $t -110 30
- variable dy 0
- foreach fillrule {odd nonzero positive negative abs_geq_2} {
- set dy [expr $dy + 160]
- set t [$w.zinc add text $group -text $fillrule]
- $w.zinc translate $t -110 [expr 100+$dy]
- foreach item "$curve1 $curve2 $curve3 $curve4" {
- set clone [$w.zinc clone $item -fillrule $fillrule -filled 1]
- $w.zinc translate $clone 0 $dy
- }
- }
-
- # creating simple lines with arrows under each curves
- foreach item "$curve1 $curve2 $curve3 $curve4" {
- set contour_number [$w.zinc contour $item]
- #puts "$item contour_number=$contour_number\n"
- for {set n 0} {$n <=[expr $contour_number-1]} {incr n} {
- set points [$w.zinc coords $item $n]
- set nbpoints [llength $points]
- for {set i 0} {$i <=[expr $nbpoints-2]} {incr i} {
- set firstpoint [lindex $points $i]
- set lastpoint [lindex $points [expr $i+1]]
- set middlepoint "[expr [lindex $firstpoint 0]+([lindex $lastpoint 0]- [lindex $firstpoint 0])/1.5] [expr [lindex $firstpoint 1]+([lindex $lastpoint 1]-[lindex $firstpoint 1])/1.5]"
- $w.zinc add curve [$w.zinc group $item] "$firstpoint $middlepoint" -lastend "7 10 4"
- }
- }
- }
-}
diff --git a/demos/groupsInAtcStrips.tcl b/demos/groupsInAtcStrips.tcl
deleted file mode 100644
index 0c7f4d9..0000000
--- a/demos/groupsInAtcStrips.tcl
+++ /dev/null
@@ -1,902 +0,0 @@
-#-----------------------------------------------------------------------------------
-#
-# 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 named 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.
-#
-#-----------------------------------------------------------------------------------
-#
-# Ported to Tcl by P.Lecoanet
-
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-#package require profiler
-#::profiler::init
-namespace eval groupsInAtcStrips {
- variable w .groupsInAtcStrips
-
- catch {destroy $w}
- toplevel $w
- wm title $w "Atc electronic strips using groups"
- wm iconname $w groupsInAtcStrips
-
- variable defaultfont [font create -family Helvetica -size 10 -weight bold]
- variable imagePath [file join [demosPath] images]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
-
- ###########################################
- # Text zone
- #######################
- ####################
-
- grid [text $w.text -relief sunken -borderwidth 2 -height 5] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end {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}
-
-
- ###########################################
- # Zinc
- ##########################################
- image create photo texture -file \
- [file join [demosPath] images background_texture.gif]
-
- grid [zinc $w.zinc -render 1 -width 700 -height 500 -borderwidth 0 \
- -lightangle 130 -tile texture] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
-
- variable stripGradients {}
- variable stripFontSet {}
-
-
- variable delay 50; # ms between each animation steps
- variable steps 6; # number of steps for the animation
- # 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
- #----------------------
-
- variable ratio2FontSet {{1.2 normal} {10 large}}
-
- set loadedFonts [font names]
- foreach f $loadedFonts {
- if { [regexp {^radar-} $f] } {
- font delete $f
- }
- }
-
- # cenapii-radar-b15
- font create radar-b15 -family helvetica -size 16 -slant roman -weight bold
- # cenapii-digistrips-b12
- font create radar-b12 -family helvetica -size 12 -slant roman -weight bold
- # cenapii-digistrips-b10 and cenapii-digistrips-b10c
- font create radar-b10 -family helvetica -size 10 -slant roman -weight bold
- # cenapii-radar-m18
- font create radar-m18 -family helvetica -size 18 -slant roman -weight normal
- # cenapii-radar-m20
- font create radar-m20 -family helvetica -size 20 -slant roman -weight normal
-
- variable stripStyle {
- gradSet {
- idnt {=axial 90|#ffffff 0|#ffeedd 30|#e9d1ca 90|#e9a89a}
- back {#c1daff|#8aaaff}
- shad {=path -40 -40|#000000;50 0|#000000;50 92|#000000;0 100}
- btnOutside #ffeedd|#8a9acc
- btnInside {=axial 180|#ffeedd|#8a9acc}
- ch1 {#8aaaff|#5b76ed}
- }
- fontSet {
- normal {
- callsign radar-b15
- type1 radar-b12
- type2 radar-b10
- type3 radar-b10
- }
- large {
- callsign radar-m20
- type1 radar-m18
- type2 radar-b15
- type3 radar-b12
- }
- }
- 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 btnOutside
- linewidth 0
- }
- btns {
- btnup {
- coords {0 0 26 43}
- arrow {14 2 24 40 1 40 14 2}
- linewidth 1
- linecolor \#aabadd
- fillcolor btnInside
- label {
- coords {13 27}
- text +
- font radar-m20
- color \#ffffff
- anchor center
- }
- }
- btndn {
- coords {0 43 26 86}
- arrow {14 83 24 43 1 43 14 83}
- linewidth 1
- linecolor \#aabadd
- fillcolor btnInside
- label {
- coords {13 56}
- text -
- font radar-m20
- 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
- }
- }
-
- }
- }
-
-
-
- proc TLGetHash {list tag} {
- array set temp $list
- if { [info exists temp($tag)] } {
- return $temp($tag)
- }
- return ""
- }
-
- proc TLGet {list tag} {
- foreach {key val} $list {
- if { [string compare $key $tag] == 0 } {
- # puts "TLGet found \"$val\" for \"$key\""
- return $val
- }
- }
- # puts "Unknown tag $tag in $list"
- return ""
- }
-
-
- # Création du Strip
- proc createStrip {index x y style} {
- variable w
- variable stripGradients
- variable stripFontSet
- variable textures
- variable imagePath
-
- # initialise les gradients
- if { [llength $stripGradients] == 0 } {
- foreach {name gradient} [TLGet $style gradSet] {
- # création des gradiants nommés
- if {! [$w.zinc gname $name]} {
- $w.zinc gname $gradient $name
- }
- # 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)
- lappend stripGradients $name
- }
- }
-
- # initialise les jeux de fontes
- if { ![llength $stripFontSet] } {
- set stripFontSet [TLGet $style fontSet]
- }
-
- # création du groupe de base : coords
- set g1 [$w.zinc add group 1 -priority 100 -tags "base$index"]
- $w.zinc coords $g1 [list $x $y]
-
- # group de transfo 1 : scaling (à partir du coin haut droit)
- set g2 [$w.zinc add group $g1 -tags "scaling$index"]
-
- #-------------------------------------------------------------
- # réalisation du strip lui même (papier support + ombre portée
- #-------------------------------------------------------------
-
- # params strip
- set stripw [TLGet $style width]
- set striph [TLGet $style height]
-
- # ombre portée
- $w.zinc add rectangle $g2 [TLGet $style shadowcoords] \
- -filled 1 -linewidth 0 -fillcolor [TLGet $style shadowcolor] \
- -priority 10 -tags "shadow$index"
-
- # strip
- set sstyle [TLGet $style strip]
- set strip [$w.zinc add rectangle $g2 [list 0 0 $stripw $striph] -filled 1 \
- -linewidth [TLGet $sstyle linewidth] \
- -linecolor [TLGet $sstyle linecolor] \
- -fillcolor [TLGet $sstyle fillcolor] \
- -relief [TLGet $sstyle relief] \
- -priority 20 -tags "strip$index"]
-
- set texName [TLGet $sstyle texture]
- if { [llength $texName] != 0 } {
- if { ! [info exists textures(strip)] } {
- set textures(strip) [image create photo -file [file join $imagePath $texName]]
- }
- $w.zinc itemconfigure $strip -tile $textures(strip)
- }
-
-
- #-------------------------------------------------
- # ajout de la zone des boutons (à droite du strip)
- #-------------------------------------------------
- set bStyle [TLGet $style buttons]
- if { [llength $bStyle] != 0 } {
- # le groupe de la zone bouton
- set btnGroup [$w.zinc add group $g2 -priority 40]
- $w.zinc coords $btnGroup [TLGet $bStyle coords]
-
- # sa zone de clipping
- set btnClip [$w.zinc add rectangle $btnGroup [TLGet $bStyle clipcoords] \
- -filled 0 -visible 0]
-
- # le clipping du groupe bouton
- $w.zinc itemconfigure $btnGroup -clip $btnClip
-
- # zone bouton
- set bZone [TLGet $bStyle zone]
- $w.zinc add rectangle $btnGroup [TLGet $bZone coords] \
- -filled 1 -linewidth [TLGet $bZone linewidth] \
- -fillcolor [TLGet $bZone fillcolor] -composescale 0 \
- -tags "content$index"
-
- set btns [TLGet $bStyle btns]
- foreach {name btnStyle} $btns {
- # puts "bouton $name $btnStyle"
-
- set sGroup [$w.zinc add group $btnGroup -atomic 1 -sensitive 1 \
- -composescale 0 -tags [list "$name$index" "content$index"]]
-
- $w.zinc add rectangle $sGroup [TLGet $btnStyle coords] \
- -filled 1 -visible 0 -priority 100
- $w.zinc add curve $sGroup [TLGet $btnStyle arrow] \
- -closed 1 -filled 1 -priority 50 \
- -linewidth [TLGet $btnStyle linewidth] \
- -linecolor [TLGet $btnStyle linecolor] \
- -fillcolor [TLGet $btnStyle fillcolor]
- set lab [TLGet $btnStyle label]
- $w.zinc add text $sGroup -priority 60 \
- -position [TLGet $lab coords] -text [TLGet $lab text] \
- -font [TLGet $lab font] -color [TLGet $lab color] \
- -anchor [TLGet $lab anchor]
- }
-
- # bindings boutons Up et Down du Strip
- $w.zinc bind "btnup$index" <1> ::groupsInAtcStrips::extendedStrip
- $w.zinc bind "btndn$index" <1> ::groupsInAtcStrips::smallStrip
- }
-
- # construction du contenu du strip
- buildContent $index $g2 100 $style
-
- # et de la barre d'extension info (extended format)
- buildExtent $index $g2 [TLGet $style zinfo]
- }
-
- # Construction des zones internes du Strips
- proc buildContent {index parent priority style} {
- variable w
- variable textures
- variable stripFontSet
- variable imagePath
-
- # group content
- set g3 [$w.zinc add group $parent -priority $priority]
-
- # zone de clipping
- set clip [$w.zinc add rectangle $g3 [TLGet $style clipcoords] \
- -filled 0 -visible 0]
-
- # clipping du groupe content
- $w.zinc itemconfigure $g3 -clip $clip
-
- # création d'un group intermédiaire pour bloquer le scaling
- set g4 [$w.zinc add group $g3 -composescale 0 -tags "content$index"]
-
- # création des zones
- set zones [TLGet $style zones]
- foreach {name zoneStyle} $zones {
- # group de zone
- set gz [$w.zinc add group $g4]
-
- if { [TLGet $zoneStyle atomic] } {
- $w.zinc itemconfigure $gz -atomic 1 \
- -sensitive [TLGet $zoneStyle sensitive] \
- -priority [TLGet $zoneStyle priority] \
- -tags [concat "$name$index" [TLGet $zoneStyle tags]]
- }
-
- set rectZone [$w.zinc add rectangle $gz [TLGet $zoneStyle coords] \
- -filled [TLGet $zoneStyle filled] \
- -linewidth [TLGet $zoneStyle linewidth] \
- -linecolor [TLGet $zoneStyle linecolor] \
- -fillcolor [TLGet $zoneStyle fillcolor] \
- -relief [TLGet $zoneStyle relief] \
- -priority 10 -tags "$name$index"]
-
- set texName [TLGet $zoneStyle texture]
- if { [llength $texName] != 0 } {
- if { ! [info exists textures($name)] } {
- set textures($name) [image create photo \
- -file [file join $imagePath $texName]]
- }
- $w.zinc itemconfigure $rectZone -tile $textures($name)
- }
-
- set fields [TLGet $zoneStyle fields]
- set fontStyle [TLGet $stripFontSet normal]
- foreach {field fieldStyle} $fields {
- set fsType [TLGet $fieldStyle type]
- if { $fsType == "rect" } {
- $w.zinc add rectangle $gz [TLGet $fieldStyle coords] \
- -filled [TLGet $fieldStyle filled] \
- -fillcolor [TLGet $fieldStyle fillcolor] \
- -linewidth [TLGet $fieldStyle linewidth] \
- -linecolor [TLGet $fieldStyle linecolor] \
- -priority 20
- } else {
- set font [TLGet $fieldStyle font]
- # puts "buildContent field:$field font:$font"
- $w.zinc add text $gz -position [TLGet $fieldStyle coords] \
- -text [TLGet $fieldStyle text] \
- -font [TLGet $fontStyle $font] \
- -color [TLGet $fieldStyle color] \
- -anchor [TLGet $fieldStyle anchor] \
- -priority 30 -tags "$font$index"
- }
- }
- }
- }
-
- # Construction de la barre d'extension info du Strip
- proc buildExtent {index parent infoStyle} {
- variable w
- variable textures
- variable stripFontSet
- variable imagePath
-
- # group content
- set extGroup [$w.zinc add group $parent]
- $w.zinc coords $extGroup [TLGet $infoStyle coords]
- $w.zinc itemconfigure $extGroup -visible 0 \
- -atomic [TLGet $infoStyle atomic] \
- -sensitive [TLGet $infoStyle sensitive] \
- -priority [TLGet $infoStyle priority] \
- -tags [concat "zinfo$index" [TLGet $infoStyle tags]]
-
- # ombre portée
- $w.zinc add rectangle $extGroup [TLGet $infoStyle shadowcoords] \
- -filled 1 -linewidth 0 -priority 10 -tags "shadow$index" \
- -fillcolor [TLGet $infoStyle shadowcolor]
-
- set rectZone [$w.zinc add rectangle $extGroup [TLGet $infoStyle rectcoords] \
- -filled 1 -priority 20 \
- -linewidth [TLGet $infoStyle linewidth] \
- -linecolor [TLGet $infoStyle linecolor] \
- -fillcolor [TLGet $infoStyle fillcolor] \
- -relief [TLGet $infoStyle relief]]
-
- set texName [TLGet $infoStyle texture]
- if { [llength $texName] != 0 } {
- if { ! [info exists textures(zinfo)] } {
- set textures(zinfo) [image create photo \
- -file [file join $imagePath $texName]]
- }
- $w.zinc itemconfigure $rectZone -tile $textures(zinfo)
- }
-
- set fields [TLGet $infoStyle fields]
- set fontStyle [TLGet $stripFontSet normal]
- foreach {field fieldStyle} $fields {
- set fsType [TLGet $fieldStyle type]
- if { $fsType == "rect" } {
- $w.zinc add rectangle $extGroup [TLGet $fieldStyle coords] \
- -filled [TLGet $fieldStyle filled] \
- -fillcolor [TLGet $fieldStyle fillcolor] \
- -linewidth [TLGet $fieldStyle linewidth] \
- -linecolor [TLGet $fieldStyle linecolor] \
- -priority 40
- } else {
- set font [TLGet $fieldStyle font]
- # puts "buildContent field:$field font:$font"
- $w.zinc add text $extGroup -position [TLGet $fieldStyle coords] \
- -text [TLGet $fieldStyle text] \
- -font [TLGet $fontStyle $font] \
- -color [TLGet $fieldStyle color] \
- -anchor [TLGet $fieldStyle anchor] \
- -priority 50 -tags "$font$index"
- }
- }
- }
-
- # initialisation des bindings généraux dy Strip
- proc initBindings {moveTag scaleTag} {
- variable w
-
- $w.zinc bind $moveTag <1> "::groupsInAtcStrips::catchStrip %x %y"
- $w.zinc bind $moveTag <ButtonRelease> ::groupsInAtcStrips::releaseStrip
- $w.zinc bind $moveTag <B1-Motion> "::groupsInAtcStrips::motionStrip %x %y"
-
- $w.zinc bind $scaleTag <Double-Button-1> ::groupsInAtcStrips::microStrip
- }
-
- # Callback CATCH de début de déplacement du Strip
- proc catchStrip {x y} {
- variable w
- variable dx
- variable dy
-
- set index [string range [lindex [$w.zinc itemcget current -tags] 0] 5 end]
- foreach {lx ly} [$w.zinc coords "base$index"] break
- set dx [expr $lx - $x]
- set dy [expr $ly - $y]
-
- $w.zinc itemconfigure "base$index" -priority 200
- }
-
- # Callback MOVE de fin de déplacement du Strip
- proc motionStrip {x y} {
- variable w
- variable dx
- variable dy
-
- set index [string range [lindex [$w.zinc itemcget current -tags] 0] 5 end]
- $w.zinc coords "base$index" [list [expr $x + $dx] [expr $y + $dy]]
- }
-
- # Callback RELEASE de fin de déplacement du Strip
- proc releaseStrip {} {
- variable w
-
- set index [string range [lindex [$w.zinc itemcget current -tags] 0] 5 end]
- $w.zinc itemconfigure "base$index" -priority 100
- }
-
- # Zoom Strip : normal format
- proc normalStrip {} {
- variable w
-
- set index [string range [lindex [$w.zinc itemcget current -tags] 0] 5 end]
- $w.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)
- proc smallStrip {} {
- variable w
-
- set index [string range [lindex [$w.zinc itemcget current -tags] 0] 5 end]
-
- displayRecoZone $index 0
- configButtons $index normalStrip 0
- changeStripFormat $index 1 0.63 0 1
- }
-
- # Zoom Strip : micro format (zone ident)
- proc microStrip {} {
- variable w
- set index [string range [lindex [$w.zinc itemcget current -tags] 0] 5 end]
-
- configButtons $index normalStrip 0
- changeStripFormat $index 0.28 0.63 0 1
-
- }
-
- # Zoom Strip : extendedFormat
- proc extendedStrip {} {
- variable w
-
- set index [string range [lindex [$w.zinc itemcget current -tags] 0] 5 end]
-
- $w.zinc itemconfigure "input$index" -sensitive 0
- $w.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
- proc displayRecoZone {index state} {
- variable w
-
- set priority [expr $state ? 200 : 0]
- $w.zinc itemconfigure "zreco$index" -priority $priority
- }
-
-
- # affiche/masque la zone Extent
- proc displayExtentZone {index state} {
- variable w
-
- $w.zinc itemconfigure "zinfo$index" -visible $state -sensitive $state
- }
-
- # Configure affichage et callbacks des boutons du Strip
- proc configButtons {index funcUp funcDown} {
- variable w
-
- # button Up
- if { $funcUp != 0 } {
- $w.zinc itemconfigure "btnup$index" -visible 1
- $w.zinc bind "btnup$index" <1> ::groupsInAtcStrips::$funcUp
- } {
- $w.zinc itemconfigure "btnup$index" -visible 0
- }
-
- # button Down
- if { $funcDown != 0 } {
- $w.zinc itemconfigure "btndn$index" -visible 1
- $w.zinc bind "btndn$index" <1> ::groupsInAtcStrips::$funcDown
- } {
- $w.zinc itemconfigure "btndn$index" -visible 0
- }
- }
-
-
- # this function has been hacked to provide the user with an animation
- # The animation is (too) simple but provide a better feedback than without
- proc changeStripFormat {index xratio yratio composeflag fontratio} {
- variable w
- variable dx
- variable dy
- variable scales
- variable steps
- variable delay
-
- # réinitialisation du groupe scaling
- $w.zinc treset "scaling$index"
-
- # configure le blocage de transformation du format des champs
- $w.zinc itemconfigure "content$index" -composescale $composeflag
-
- # applique le nouveau scaling
- if { ![info exists scales($index)] } {
- set scales($index) {1 1}
- }
- foreach {oldXratio oldYratio} $scales($index) {}
- set scales($index) [list $xratio $yratio]
- set dx [expr ($xratio - $oldXratio) / $steps]
- set dy [expr ($yratio - $oldYratio) / $steps]
- _resize $index $delay [expr $oldXratio+$dx] [expr $oldYratio+$dy] $dx $dy $steps
- setFontes $index $yratio
- }
-
- proc _resize {index delay newXratio newYratio dx dy steps} {
- variable w
-
- $w.zinc treset "scaling$index"
- $w.zinc scale "scaling$index" $newXratio $newYratio
- # jeu de fontes
- incr steps -1
- if { $steps > 0 } {
- after $delay [list ::groupsInAtcStrips::_resize $index $delay [expr $newXratio+$dx] \
- [expr $newYratio+$dy] $dx $dy $steps]
- }
- #puts [::profiler::print]
- }
-
- proc getFKey {ratio} {
- variable ratio2FontSet
-
- foreach param $ratio2FontSet {
- foreach {maxRatio fKey} $param {}
- set newfKey $fKey
- if { $ratio < $maxRatio } {
- return $newfKey;
- }
- }
-
- return $newfKey;
- }
-
-
- proc setFontes {index ratio} {
- variable w
- variable stripFontSet
- variable oldFKey
-
- set newFKey [getFKey $ratio]
- if {![info exists oldFKey] || ([string compare $oldFKey $newFKey] != 0) } {
- set fontStyle [TLGet $stripFontSet $newFKey]
- #puts "setFontes $oldFKey -> $newFKey"
- if { [llength $fontStyle] != 0 } {
- foreach type {callsign type1 type2 type3} {
- $w.zinc itemconfigure "$type$index" -font [TLGet $fontStyle $type]
- }
- }
- set oldFKey $newFKey
- }
- }
-
-
- # test Strips
- for {set xn 10; set yn 30; set index 0} {$index < 4} {incr index; incr xn 50; incr yn 120} {
- createStrip $index $xn $yn $stripStyle
- }
-
- initBindings move scale
-}
diff --git a/demos/groupsPriority.tcl b/demos/groupsPriority.tcl
deleted file mode 100644
index 07bfbb6..0000000
--- a/demos/groupsPriority.tcl
+++ /dev/null
@@ -1,250 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-
-namespace eval groupsPriority {
- variable w .groupsPriority
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Groups priority Demonstration"
- wm iconname $w Groups
-
- variable defaultfont [font create -family Helvetica -size 14 -weight bold]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- ###########################################
- # Text zone
- ###########################################
-
- grid [text $w.text -relief sunken -borderwidth 2 -height 12] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end "There are two groups (a red one and a green one) each containing\n4 rectangles. Those rectangles display their current priority.\nThe following operations are possible:\n Mouse Button 1 for dragging objects.\n Mouse Button 2 for dragging a colored group.\n Key + on a rectangle to raise it inside its group.\n Key - on a rectangle to lower it inside its group.\n Key l on a rectangle to lower its colored group.\n Key r on a rectangle to raise its colored group.\n Key t on a rectangle to change its group (but not its color!).\n Key 0-9 on a rectangle to set the priority to 0-9\nRaising or lowering an item inside a group modify its priority if necessary"
-
- ###########################################
- # Zinc
- ###########################################
- variable zinc_width 600
- variable zinc_height 500
- grid [zinc $w.zinc -width $zinc_width -height $zinc_height -font $defaultfont \
- -borderwidth 3 -relief sunken] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
-
- #########################################################################"
- # Creating the redish group
- variable group1 [$w.zinc add group 1 -visible 1]
-
- variable counter 0
- # Adding 4 rectangles with text to redish group
- foreach data { {200 100 red} {210 210 red1} {390 110 red2} {395 215 red3} } {
- set counter [expr $counter+ 2]
- set centerx [lindex $data 0]
- set centery [lindex $data 1]
- set color [lindex $data 2]
-
- # this small group is for merging together :
- # the rectangle and the text showing its name
- set g [$w.zinc add group $group1 -visible 1 -atomic 1 -sensitive 1 -priority $counter]
- set rec [$w.zinc add rectangle $g \
- [list [expr $centerx-100] [expr $centery-60] [expr $centerx+100] [expr $centery+60]] \
- -fillcolor $color -filled 1]
-
- set txt [$w.zinc add "text" $g -position "$centerx $centery" -text "pri=$counter" -anchor center]
-
- # Some bindings for dragging the rectangle or the full group
- $w.zinc bind $g <1> "::groupsPriority::itemStartDrag $g %x %y"
- $w.zinc bind $g <B1-Motion> "::groupsPriority::itemDrag $g %x %y"
- $w.zinc bind $g <2> "::groupsPriority::itemStartDrag $g %x %y"
- $w.zinc bind $g <B2-Motion> "::groupsPriority::groupDrag $g %x %y"
- }
-
- #########################################################################"
- # Creating the greenish group
- variable group2 [$w.zinc add group 1 -visible 1]
- variable counter 0
-
- # Adding 4 rectangles with text to greenish group
- foreach data {{200 300 green1} {210 410 green2} {390 310 green3} {395 415 green4}} {
- incr counter
- set centerx [lindex $data 0]
- set centery [lindex $data 1]
- set color [lindex $data 2]
-
- # this small group is for merging together a rectangle
- # and the text showing its priority
- set g [$w.zinc add group $group2 -atomic 1 -sensitive 1 -priority $counter]
-
- set rec [$w.zinc add rectangle $g "[expr $centerx-100] [expr $centery-60] [expr $centerx+100] [expr $centery+60]" -fillcolor $color -filled 1]
-
- set txt [$w.zinc add text $g -position "$centerx $centery" -text "pri=$counter" -anchor center]
-
- # Some bindings for dragging the rectangle or the full group
- $w.zinc bind $g <1> "::groupsPriority::itemStartDrag $g %x %y"
- $w.zinc bind $g <B1-Motion> "::groupsPriority::itemDrag $g %x %y"
- $w.zinc bind $g <2> "::groupsPriority::itemStartDrag $g %x %y"
- $w.zinc bind $g <B2-Motion> "::groupsPriority::groupDrag $g %x %y"
- }
-
-
- #########################################################################"
- # adding the key bindings
-
- # the focus on the widget is ABSOLUTELY necessary for key bindings!
- focus $w.zinc
-
- bind $w.zinc <KeyPress-r> ::groupsPriority::raiseGroup
- bind $w.zinc <KeyPress-l> ::groupsPriority::lowerGroup
- bind $w.zinc <KeyPress-plus> ::groupsPriority::raise
-
- bind $w.zinc <KP_Add> ::groupsPriority::raise
- bind $w.zinc <KeyPress-minus> ::groupsPriority::lower
- bind $w.zinc <KP_Subtract> ::groupsPriority::lower
- bind $w.zinc <KeyPress-t> ::groupsPriority::toggleItemGroup
-
- for {set i 0} {$i<=9} {incr i} {
- bind $w.zinc <KeyPress-$i> "::groupsPriority::setPriority $i"
- bind $w.zinc <KeyPress-KP_$i> "::groupsPriority::setPriority $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]
-
- ####################################withtype#####################################"
- # Definition of all callbacks
-
-
- proc updateLabel {group} {
- variable w
-
- set priority [$w.zinc itemcget $group -priority]
- # we get the text item from this group:
- set textitem [$w.zinc find withtype text ".$group."]
- $w.zinc itemconfigure $textitem -text "pri=$priority"
- }
-
- proc setPriority {priority} {
- variable w
-
- set item [$w.zinc find withtag current]
- #return unless $item
- $w.zinc itemconfigure $item -priority $priority
- updateLabel $item
- }
-
-
- # Callback to lower a small group of a rectangle and a text
- proc lower {} {
- variable w
-
- # to get the item under the cursor!
- set item [$w.zinc find withtag current]
- #return unless $item
- $w.zinc lower $item
- updateLabel $item
- }
-
-
- # Callback to raise a small group of a rectangle and a text
- proc raise {} {
- variable w
-
- # to get the item under the cursor!
- set item [$w.zinc find withtag current]
- #return unless $item
- $w.zinc raise $item
- updateLabel $item
- }
-
- # Callback to raise the group of groups of a rectangle and a text
- proc lowerGroup {} {
- variable w
-
- # to get the item under the cursor!
- set item [$w.zinc find withtag current]
- #return unless $item
- set coloredGroup [$w.zinc group $item]
- $w.zinc lower $coloredGroup
- }
-
- # Callback to raise the group of groups of a rectangle and a text
- proc raiseGroup {} {
- variable w
-
- # to get the item under the cursor!
- set item [$w.zinc find withtag current]
- #return unless $item
- set coloredGroup [$w.zinc group $item]
- $w.zinc raise $coloredGroup
- updateLabel $item
- }
-
- # Callback to change puts raise
- #the group of groups of a rectangle and a text
- proc toggleItemGroup {} {
- variable group1
- variable group2
- variable w
-
- # to get the item under the cursor!
- set item [$w.zinc find withtag current]
-
- # return unless $item
- set newgroup ""
- if {$group1 == [$w.zinc group $item]} {
- set newgroup $group2
- } else {
- set newgroup $group1
- }
- $w.zinc chggroup $item $newgroup 1
- updateLabel $item
- }
-
- # callback for starting a drag
- set xOrig ""
- set yOrig ""
-
- proc itemStartDrag {item x y} {
- variable xOrig
- variable yOrig
-
- set xOrig $x
- set yOrig $y
- }
-
- # Callback for moving an item
- proc itemDrag {item x y} {
- variable xOrig
- variable yOrig
- variable w
-
- $w.zinc translate $item [expr $x-$xOrig] [expr $y-$yOrig];
- set xOrig $x;
- set yOrig $y;
- }
-
- # Callback for moving an item
- proc groupDrag {item x y} {
- variable xOrig
- variable yOrig
- variable w
-
- set coloredGroup [$w.zinc group $item]
- $w.zinc translate $coloredGroup [expr $x-$xOrig] [expr $y-$yOrig];
- set xOrig $x;
- set yOrig $y;
- }
-}
-
-
-
diff --git a/demos/iconTransform.tcl b/demos/iconTransform.tcl
deleted file mode 100644
index e4527c8..0000000
--- a/demos/iconTransform.tcl
+++ /dev/null
@@ -1,157 +0,0 @@
-# $Id$
-# this simple demo has been developped by C. Mertz <mertz@cena.fr>
-# Ported to Tcl by P.Lecoanet
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-
-namespace eval iconTransform {
- variable w .iconTransform
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc icon scale/rotate Demonstration"
- wm iconname $w iconTransform
-
- variable defaultfont [font create -family Helvetica -size 16 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- ###########################################
- # Text zone
- #######################
- ####################
-
- grid [text $w.text -relief sunken -borderwidth 2 -height 6] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end {You can transform this image with your mouse:
- Drag-Button 1 for moving,
- Drag-Button 2 for zooming,
- Drag-Button 3 for rotating,
- Shift-Drag-Button 1 for modifying the transparency (OpenGL only).}
-
-
- ###########################################
- # Zinc
- ##########################################
- grid [zinc $w.zinc -width 350 -height 250 -render 1 -font $defaultfont \
- -borderwidth 3 -relief sunken] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- variable topGroup [$w.zinc add group 1]
-
- image create photo zincAA -file [file join [demosPath] images zinc.gif]
-
- variable zincAA [$w.zinc add icon $topGroup -image zincAA \
- -position {10 10} -composescale 1 -composerotation 1]
-
- $w.zinc add text $topGroup \
- -text "try to zoom/resize the banner!\nNow works also without openGL ;-)" \
- -color white -composescale 1 -composerotation 1 -position {15 100}
-
- #
- # Controls for the window transform.
- #
- bind $w.zinc <ButtonPress-1> "::iconTransform::press motion %x %y"
- bind $w.zinc <ButtonRelease-1> ::iconTransform::release
- bind $w.zinc <ButtonPress-2> "::iconTransform::press zoom %x %y"
- bind $w.zinc <ButtonRelease-2> ::iconTransform::release
- bind $w.zinc <ButtonPress-3> "::iconTransform::press mouseRotate %x %y"
- bind $w.zinc <ButtonRelease-3> ::iconTransform::release
-
- #
- # Controls for alpha and gradient
- #
- bind $w.zinc <Shift-ButtonPress-1> "::iconTransform::press modifyAlpha %x %y"
- bind $w.zinc <Shift-ButtonRelease-1> ::iconTransform::release
-
-
- variable curX 0
- variable curY 0
- variable curAngle 0
-
- proc press {action x y} {
- variable w
- variable curAngle
- variable curX
- variable curY
-
- set curX $x
- set curY $y
- set curAngle [expr atan2($y, $x)]
- bind $w.zinc <Motion> "::iconTransform::$action %x %y"
- }
-
- proc motion {x y} {
- variable w
- variable topGroup
- variable curX
- variable curY
-
- foreach {x1 y1 x2 y2} [$w.zinc transform $topGroup \
- [list $x $y $curX $curY]] break
- $w.zinc translate $topGroup [expr $x1 - $x2] [expr $y1 - $y2]
- set curX $x
- set curY $y
- }
-
- proc zoom {x y} {
- variable w
- variable topGroup
- variable curX
- variable curY
-
- if {$x > $curX} {
- set maxX $x
- } else {
- set maxX $curX
- }
- if {$y > $curY} {
- set maxY $y
- } else {
- set maxY $curY
- }
- if {($maxX == 0) || ($maxY == 0)} {
- return;
- }
- set sx [expr 1.0 + (double($x - $curX) / $maxX)]
- set sy [expr 1.0 + (double($y - $curY) / $maxY)]
- $w.zinc scale $topGroup $sx $sx
-
- set curX $x
- set curY $y
- }
-
- proc mouseRotate {x y} {
- variable w
- variable curAngle
- variable topGroup
-
- set lAngle [expr atan2($y, $x)]
- $w.zinc rotate $topGroup [expr -($lAngle - $curAngle)]
- set curAngle $lAngle
- }
-
- proc release {} {
- variable w
-
- bind $w.zinc <Motion> {}
- }
-
- proc modifyAlpha {x y} {
- variable w
- variable topGroup
-
- set xRate [expr double($x) / [$w.zinc cget -width]]
- set xRate [expr ($xRate < 0) ? 0 : ($xRate > 1) ? 1 : $xRate]
- set alpha [expr int($xRate * 100)]
-
- $w.zinc itemconfigure $topGroup -alpha $alpha
- }
-}
diff --git a/demos/images/background_texture.gif b/demos/images/background_texture.gif
deleted file mode 100644
index 9bb4c11..0000000
--- a/demos/images/background_texture.gif
+++ /dev/null
Binary files differ
diff --git a/demos/images/paper-grey.gif b/demos/images/paper-grey.gif
deleted file mode 100644
index 96775b5..0000000
--- a/demos/images/paper-grey.gif
+++ /dev/null
Binary files differ
diff --git a/demos/images/paper-grey1.gif b/demos/images/paper-grey1.gif
deleted file mode 100644
index fe8c8ef..0000000
--- a/demos/images/paper-grey1.gif
+++ /dev/null
Binary files differ
diff --git a/demos/images/paper.gif b/demos/images/paper.gif
deleted file mode 100644
index 3247d35..0000000
--- a/demos/images/paper.gif
+++ /dev/null
Binary files differ
diff --git a/demos/images/photoAlpha.png b/demos/images/photoAlpha.png
deleted file mode 100644
index 9fdf74b..0000000
--- a/demos/images/photoAlpha.png
+++ /dev/null
Binary files differ
diff --git a/demos/images/stripped_texture.gif b/demos/images/stripped_texture.gif
deleted file mode 100644
index a0b842e..0000000
--- a/demos/images/stripped_texture.gif
+++ /dev/null
Binary files differ
diff --git a/demos/images/zinc.gif b/demos/images/zinc.gif
deleted file mode 100644
index 4d1cda9..0000000
--- a/demos/images/zinc.gif
+++ /dev/null
Binary files differ
diff --git a/demos/items.tcl b/demos/items.tcl
deleted file mode 100644
index 35af800..0000000
--- a/demos/items.tcl
+++ /dev/null
@@ -1,144 +0,0 @@
-# $Id$
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval allItems {
- variable w .items
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Item Demonstration"
- wm iconname $w Items
-
- variable defaultfont [font create -family Helvetica -size 10 -weight bold]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- scrollbar $w.vscroll -command "$w.zinc yview"
- grid $w.vscroll -row 0 -column 2 -sticky ns
- scrollbar $w.hscroll -orient horiz -command "$w.zinc xview"
- grid $w.hscroll -row 1 -column 0 -columnspan 2 -sticky we
-
- zinc $w.zinc -width 700 -height 600 -scrollregion {-100 0 1000 1000} \
- -xscrollcommand "$w.hscroll set" \
- -yscrollcommand "$w.vscroll set" \
- -font 10x20 -borderwidth 3 -relief sunken
- grid $w.zinc -row 0 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 0 -weight 2
-
- $w.zinc add rectangle 1 {10 10 100 50} -fillcolor green -filled 1 -linewidth 10 \
- -relief roundridge -linecolor darkgreen
-
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {120 20} \
- -text {A filled rectangle with a "roundridge" relief border of 10 pixels.}
-
- variable labelformat {x82x60+0+0 x60a0^0^0 x32a0^0>1 a0a0>2>1 x32a0>3>1 a0a0^0>2};
-
- variable x 20;
- variable y 120;
- variable track [$w.zinc add track 1 6 -labelformat $labelformat -position "$x $y" \
- -speedvector {40 -10} -speedvectormark 1 -speedvectorticks 1]
-
- # moving the track, to display past positions
- for {set i 0} {$i<=5} {incr i} {
- set x1 [expr $x+$i*10]
- set y1 [expr $y-$i*2]
- $w.zinc coords "$track" "$x1 $y1"
- }
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {200 80} \
- -text "A flight track for a radar display. A waypoint looks similar,
-but has no speed vector and no past positions."
-
- $w.zinc itemconfigure $track 0 -filled 0 -bordercolor DarkGreen -border contour
-
- $w.zinc itemconfigure $track 1 -filled 1 -backcolor gray60 -text AFR001
- $w.zinc itemconfigure $track 2 -filled 0 -backcolor gray65 -text 360
- $w.zinc itemconfigure $track 3 -filled 0 -backcolor gray65 -text /
- $w.zinc itemconfigure $track 4 -filled 0 -backcolor gray65 -text 410
- $w.zinc itemconfigure $track 5 -filled 0 -backcolor gray65 -text Beacon
-
-
- $w.zinc add arc 1 {150 140 450 240} -fillcolor gray20 -filled 0 -linewidth 1 \
- -startangle 45 -extent 270
- $w.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
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {320 180} \
- -text {Two arcs, starting at 45° with an extent of 270°}
-
-
- $w.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
-
- $w.zinc add text 1 -font $defaultfont -text {An open curve} -anchor nw -position {50 350}
-
- $w.zinc add text 1 -font $defaultfont -text {A waypoint} -anchor nw -position {10 480}
-
- variable waypoint [$w.zinc add waypoint 1 6 -position {100 520} -labelformat $labelformat \
- -symbol AtcSymbol2 -labeldistance 30]
-
- for {set fieldId 1} {$fieldId<=5} {incr fieldId} {
- $w.zinc itemconfigure $waypoint $fieldId -filled 0 -bordercolor DarkGreen \
- -border contour -text "field$fieldId"
- }
-
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {510 380} \
- -text "3 tabulars of 2 fields,\nattached together."
-
- variable labelformat2 {x72x40 x72a0^0^0 x34a0^0>1}
-
- variable tabular1 [$w.zinc add tabular 1 6 -position {570 250} -labelformat $labelformat2]
- variable tabular2 [$w.zinc add tabular 1 6 -connecteditem $tabular1 -labelformat $labelformat2]
- variable tabular3 [$w.zinc add tabular 1 6 -connecteditem $tabular2 -labelformat $labelformat2]
-
- variable count 1
-
- foreach tab "$tabular1 $tabular2 $tabular3" {
- $w.zinc itemconfigure $tab 1 -filled 0 -bordercolor DarkGreen -border contour -text tabular
- $w.zinc itemconfigure $tab 2 -filled 0 -bordercolor DarkGreen -border contour -text "n°$count"
- incr count
- }
-
-
- $w.zinc add reticle 1 -position {530 550} -firstradius 20 -numcircles 6 \
- -period 2 -stepsize 20 -brightlinestyle dashed -brightlinecolor darkred
-
- $w.zinc add text 1 -font $defaultfont -text {a reticle with 6 circles} \
- -anchor nw -position {530 540}
-
- bind $w.zinc <ButtonPress-1> "::allItems::press $w.zinc motion %x %y"
- bind $w.zinc <ButtonRelease-1> "::allItems::release $w.zinc"
-
- variable curX 0
- variable curY 0
-
- proc press {z action x y} {
- variable curX
- variable curY
-
- set curX $x
- set curY $y
- bind $z <Motion> "::allItems::$action $z %x %y"
- }
-
- proc motion {z x y} {
- variable curX
- variable curY
-
- $z translate current [expr $x - $curX] [expr $y - $curY]
- set curX $x
- set curY $y
- }
-
- proc release {z} {
- bind $z <Motion> {}
- }
-}
diff --git a/demos/labelformat.tcl b/demos/labelformat.tcl
deleted file mode 100644
index cab978b..0000000
--- a/demos/labelformat.tcl
+++ /dev/null
@@ -1,86 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval labelFormat {
- variable w .labelformat
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Label Format Demonstration"
- wm iconname $w Label
-
- variable defaultfont [font create -family Helvetica -size 16 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- ###########################################
- # Text zone
- ###########################################
-
- grid [text $w.text -relief sunken -borderwidth 2 -height 4] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end {This scipt 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
- ##########################################
- grid [zinc $w.zinc -width 600 -height 500 -font $defaultfont -borderwidth 3 \
- -relief sunken] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- ### this function displays in each field, the corresponding <fieldPos>
- ### part of the labelformat
- proc setLabelContent {item labelformat} {
- variable w
- set i 0
- foreach fieldSpec $labelformat {
- set posSpec $i
- regexp {^.\d+.\d+(.*)} $fieldSpec "" posSpec
- $w.zinc itemconfigure $item $i -text "$i: $posSpec" -border "contour"
- incr i
- }
- }
-
- ###########################################
- # Tabulars
- ###########################################
-
- ### first labelformat and tabular
- variable labelformat1 {x100x20+0+0 x100x20+100+0 x100x20+0+20 x100x20+100+20 x100x20+50+55}
-
- variable tabular1 [$w.zinc add tabular 1 5 -position {10 10} -labelformat $labelformat1]
-
- setLabelContent $tabular1 $labelformat1
-
- $w.zinc add text 1 -position {10 100} -text "All fields positions\nare given in pixels"
-
-
- ### second labelformat and tabular
- variable labelformat2 {x110x20+100+30 x80x20<0<0 x80x20<0>0 x80x20>0>0 x80x20>0<0}
-
- variable tabular2 [$w.zinc add tabular 1 5 -position {270 10} -labelformat $labelformat2]
- setLabelContent $tabular2 $labelformat2
-
- $w.zinc add text 1 -position {260 100} -text "All fields positions are given\nrelatively to field 0.\nThey are either on the left/right\nand up/down the field 0."
-
-
- ### third labelformat and tabular
- variable labelformat3 {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}
-
- variable tabular3 [$w.zinc add tabular 1 9 -position {150 180} -labelformat $labelformat3]
-
- setLabelContent $tabular3 $labelformat3
-
- $w.zinc add text 1 -position {40 360} -text "Fields 1-4 are positionned relatively to field 0.\nField 5 is positionned relatively to field 1\nField 6 is positionned relatively to field 2..."
-}
diff --git a/demos/lines.tcl b/demos/lines.tcl
deleted file mode 100644
index a974e07..0000000
--- a/demos/lines.tcl
+++ /dev/null
@@ -1,58 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval linesDemo {
- variable w .lines
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Lines Demonstration"
- wm iconname $w Lines
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- variable defaultfont [font create -family Helvetica -size 14 -weight normal]
-
- grid [zinc $w.zinc -width 700 -height 600 -font $defaultfont -borderwidth 3 \
- -relief sunken] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- $w.zinc add text 1 -font $defaultfont -anchor nw -position {20 20} \
--text "A set of lines with different styles of lines and termination\nNB: some attributes such as line styles are not necessarily\navailable with an openGL rendering system"
-
- $w.zinc add curve 1 {20 100 320 100}
- $w.zinc add curve 1 {20 120 320 120} -linewidth 20
-
- $w.zinc add curve 1 {20 160 320 160} -linewidth 20 -capstyle butt
-
- $w.zinc add curve 1 {20 200 320 200} -linewidth 20 -capstyle projecting
-
- $w.zinc add curve 1 {20 240 320 240} -linewidth 20 -linepattern AlphaStipple7 -linecolor red
-
-
- # right column
- $w.zinc add curve 1 {340 100 680 100} -firstend {10 10 10} -lastend {10 25 45}
-
- $w.zinc add curve 1 {340 140 680 140} -linewidth 2 -linestyle dashed
-
- $w.zinc add curve 1 {340 180 680 180} -linewidth 4 -linestyle mixed
-
- $w.zinc add curve 1 {340 220 680 220} -linewidth 2 -linestyle dotted
-
-
- $w.zinc add curve 1 {20 300 140 360 320 300 180 260} -closed 1 -filled 1 -fillpattern "" \
- -fillcolor grey60 -linecolor red -marker AtcSymbol7 -markercolor blue
-
-
- $w.zinc add curve 1 {340 300 440 360 620 300 480 260} -closed 1 -linewidth 10 -joinstyle miter \
- -linecolor red
-
- $w.zinc add curve 1 {400 300 440 330 560 300 480 280} -closed 1 -linewidth 10 -joinstyle round \
- -tile "" -fillcolor grey60 -filled 1 -linecolor red
-}
diff --git a/demos/magicLens.tcl b/demos/magicLens.tcl
deleted file mode 100644
index c142d53..0000000
--- a/demos/magicLens.tcl
+++ /dev/null
@@ -1,306 +0,0 @@
-#-----------------------------------------------------------------------------------
-#
-# 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>
-# Patrick Lecoanet (Translation to Tcl).
-#
-# $Id:
-#-----------------------------------------------------------------------------------
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-package require zincGraphics
-
-namespace eval magicLens {
- variable font9b 7x13bold
- variable font8 7x13
-
- variable 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}
- }
-
- variable circleCoords {
- {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
- variable 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 right
- -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
- }
- }
- }
-
-
- proc SetBindings {} {
- variable zinc
- variable w
-
- $zinc bind lens <1> {::magicLens::LensStart %x %y}
- $zinc bind lens <B1-Motion> {::magicLens::LensMove %x %y}
- $zinc bind lens <ButtonRelease> {::magicLens::LensStop %x %y}
-
- focus $w
-
- # Up, Down, Right, Left : Translate
- bind $w <Up> {::magicLens::LensTranslate up}
- bind $w <Down> {::magicLens::LensTranslate down}
- bind $w <Left> {::magicLens::LensTranslate left}
- bind $w <Right> {::magicLens::LensTranslate right}
- }
-
-
- #-----------------------------------------------------------------------------------
- # Lens Start Move Callback
- #-----------------------------------------------------------------------------------
- proc LensStart {x y} {
- variable dx
- variable dy
-
- set dx [expr 0 - $x]
- set dy [expr 0 - $y]
-
- }
-
-
- #-----------------------------------------------------------------------------------
- # Lens Move Callback.
- #-----------------------------------------------------------------------------------
- proc LensMove {x y} {
- variable dx
- variable dy
- variable zoom
- variable zinc
- variable infoView
-
- $zinc translate current [expr $x + $dx] [expr $y + $dy]
- $zinc translate lenszone [expr $x + $dx] [expr $y + $dy]
- set dx [expr 0 - $x]
- set dy [expr 0 - $y]
-
- foreach {lx ly} [$zinc coords lens 0 0] break
- $zinc coords $infoView [list [expr $lx * (1 - $zoom)] \
- [expr $ly * (1 - $zoom)]]
- }
-
-
- #-----------------------------------------------------------------------------------
- # Lens Release Callback (End of a Move)
- #-----------------------------------------------------------------------------------
- proc LensStop {x y} {
- LensMove $x $y
- }
-
- proc LensTranslate {way} {
- variable zoom
- variable zinc
- variable infoView
-
- set dx 0
- set dy 0
- switch -- $way {
- left {set dx -10}
- up {set dy -10}
- right {set dx 10}
- down {set dy 10}
- }
-
- $zinc translate lens $dx $dy
- $zinc translate lenszone $dx $dy
- foreach {lx ly} [$zinc coords lens 0 0] break
- $zinc coords $infoView [list [expr $lx * (1 - $zoom)] \
- [expr $ly * (1 - $zoom)]]
- }
-
-
- variable w .magicLens
- catch {destroy $w}
- toplevel $w
- wm title $w "Color Magic Lens Demonstration"
- wm geometry $w "1000x900+0+0"
- wm iconname $w magicLens
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- # Create a Zinc instance
- variable zinc [zinc $w.z -render 1 -width 1000 -height 900 -borderwidth 0 \
- -lightangle 140 -backcolor \#cccccc]
- grid $zinc -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- variable imagePath [file join [demosPath] images]
- variable texture [image create photo -file [file join $imagePath paper-grey1.gif]]
- variable lensTexture [image create photo -file [file join $imagePath paper-grey.gif]]
- $zinc configure -tile $texture
-
- # Create the views
- variable normView [$zinc add group 1 -priority 100]
- variable lensView [$zinc add group 1 -priority 200]
- variable infoView [$zinc add group $lensView]
-
- variable zoom 1.20
- $zinc scale $infoView $zoom $zoom
-
- $zinc add rectangle $infoView {{0 0} {1000 900}} \
- -filled 1 -fillcolor \#000000 -tile $lensTexture -linewidth 0
-
- variable x 60
- for {set i 0} {$i < 12} {incr i} {
-
- # Add a group in each view
- set cGroup [$zinc add group $normView]
- $zinc coords $cGroup [list $x 60]
- set lGroup [$zinc add group $infoView]
- $zinc coords $lGroup [list $x 60]
-
- # Color Description : name, Saturated saturée, Unsaturated ZnColor, Shadow ZnColor
- foreach {colorName saturColor greyColor shadColor} [lindex $basicColors $i] break
-
- # Sample of saturated color + relief
- set refGrad "=radial -12 -20|#ffffff 0|$saturColor 40|$shadColor 100"
- set refItem [$zinc add curve $cGroup $circleCoords \
- -filled 1 -fillcolor $refGrad -linewidth 2 -priority 100]
-
- # Clone into infoView group
- set clone [$zinc clone $refItem]
- $zinc chggroup $clone $lGroup
-
- # Color label in infoView
- $zinc add text $lGroup -priority 200 -position {0 0} \
- -text $colorName -anchor center -alignment center -font $font9b -spacing 2
-
- # Color gradient toward a gray with same light
- set barGrad "=axial 270|$saturColor|$greyColor"
-
- # Create the color samples (Multi contours curve)
- set gradBar [$zinc add curve $cGroup {} -closed 1 -filled 1 -fillcolor $barGrad \
- -linewidth 2 -priority 20 -fillrule nonzero]
-
- # Create main gradient colors (saturation 100% -> 0%) and trim alpha
- # channel off.
- set znColors [list]
- foreach color [zincGraphics::CreateGraduate 11 [list $saturColor $greyColor]] {
- lappend znColors [lindex [split $color ";"] 0]
- }
-
- # Create intermediate steps between colors (saturation -> desaturation)
- for {set c 0} {$c < 11} {incr c} {
- # Color of the current step
- set color [lindex $znColors $c]
-
- # Create a zinc item for the color
- set sample [$zinc clone $refItem -fillcolor $color]
- $zinc translate $sample 0 [expr 65*($c+1)]
-
- # Add its shape to the multi-contours curve
- $zinc contour $gradBar add 1 $sample
-
- # Move the item to the info group
- $zinc chggroup $sample $lGroup
-
- # Text of label (% saturation + ZnColor)
- set txtColor "[expr ((10 - $c)*10)]%\n$color"
- $zinc add text $lGroup -priority 200 -position [list 0 [expr ($c + 1)* 65]] \
- -text $txtColor -anchor center -alignment center -font $font8 -spacing 2 \
- -composescale 0
- }
-
- incr x 80
- }
-
- # Create the lens itself
- variable lensGroup [$zinc add group 1 -priority 300 -atomic 1 -tags lens]
- $zinc coords $lensGroup {300 110}
- variable dx 0
- variable dy 0
- LensMove 0 0
-
- # Graphical items defining the lens
- foreach {name style} $lensItems {
- zincGraphics::BuildZincItem $zinc $lensGroup $style {} $name
- }
-
- # Add a clipping shape to lensView
- set lensZone [$zinc clone lensback -tags lenszone]
- $zinc chggroup $lensZone $lensView true
- $zinc itemconfigure $lensView -clip $lensZone
-
- variable consigne [$zinc add text 1 -position {30 840} -font $font8 -alignment left \
- -color \#ffffff -spacing 2 \
- -text "<Up>, <Down>, <Left> and <Right> keys or <Mouse Drag>
-Move the Magic Color Lens behind the color gradiants
-to see the ZnColor value of Hue/saturation"]
-
- variable cClone [$zinc clone $consigne -font $font9b]
- $zinc chggroup $cClone $infoView
-
- SetBindings
-}
diff --git a/demos/pathTags.tcl b/demos/pathTags.tcl
deleted file mode 100644
index 6e7fdcc..0000000
--- a/demos/pathTags.tcl
+++ /dev/null
@@ -1,319 +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.
-# tcl version by Patrick Lecoanet lecoanet@cena.fr
-
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval pathTags {
- variable w .pathTags
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Path tags Demonstration"
- wm iconname $w "Path tags"
-
- variable defaultFont [font create -family Helvetica -size 10 -weight bold]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 3 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 3 -column 1 -pady 10
-
- ## 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
- #grTop is replaced by grOtherTop
-
- variable defaultForeColor grey80
- variable selectedColor yellow
-
- ###########################################
- # Text zone
- ###########################################
-
- grid [text $w.text -relief sunken -borderwidth 2 -height 5 -font $defaultFont] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end {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
- ###########################################
-
- grid [zinc $w.zinc -width 850 -height 360 -font $defaultFont -borderwidth 0 \
- -backcolor black -forecolor $defaultForeColor] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- ###########################################
- # Creation of a bunch of radiobutton and a text input
- ###########################################
-
- variable pathtag {}
- variable explanation {...}
-
- grid [frame $w.toggles] -row 2 -column 0 -columnspan 2 -sticky w
-
- variable tagsExpl {
- top {a simple tag matching the top group}
- .top {all items with tag 'top' in the root group }
- .top. {direct children of a group with tag 'top' in the root group}
- .top* {descendents of a group with tag 'top' in the root group }
- .top*cca {items with a tag 'cca' in a direct group of root group with tag 'top'}
- .5. {direct content of the group with id 5}
- .top*aa {items with a tag 'aa' in a direct group of root group with tag 'top'}
- .top*aa. {direct children of a group with a tag 'aa', descending from a direct group of root group with tag 'top'}
- .top*aa* {descendance of a 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 a group with tag 'a' in a direct group of root group with tag 'top'}
- .5* {descendents of the group of id 5}
- .top*aa*aaa {all items with tag 'aaa' descending from a group with tag 'aa' descending from a group with tag 'top', child of the root group}
- .top*aa*aaa. {children of a group with a tag 'aaa' descending from ONE group with a tag 'aa' descending from a 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}
- *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}
- }
-
- variable row 1
- variable col 2
- foreach {key val} $tagsExpl {
- grid [radiobutton $w.toggles.r$row+$col -text $key -font $defaultFont \
- -command ::pathTags::displayPathtag -variable ::pathTags::pathtag -relief flat \
- -value $key] -column $col -row $row -sticky w -pady 0 -ipady 0
- incr row
- if {$row > 6} {
- set row 1
- incr col
- }
- }
-
- grid [label $w.toggles.lyt -font $defaultFont -relief flat \
- -text {your own tag:}] -column 2 -row 7 -sticky e -ipady 5
- grid [entry $w.toggles.eyt -font $defaultFont -width 15 \
- -textvariable ::pathTags::pathtag] -column 3 -row 7 -sticky w
- bind $w.toggles.eyt <Return> ::pathTags::displayPathtag
- grid [label $w.toggles.elabel -font $defaultFont -text "explanation:"] \
- -row 8 -column 2 -sticky e
- grid [label $w.toggles.explan -font $defaultFont -width 70 -height 3 \
- -justify left -anchor w -wraplength 16c -textvariable explanation] \
- -row 8 -column 3 -columnspan 4 -sticky w
- grid columnconfigure $w.toggles 5 -weight 10
-
-
- ### Here we create the genuine hierarchy of groups and items
- ### Later we will create graphical objects to display groups
- proc createSubHierarchy {gr} {
- variable w
-
- $w.zinc add group $gr -tags a
- $w.zinc add text $gr -tags {b text} -text b -position {270 150}
- $w.zinc add group $gr -tags c
-
- $w.zinc add group a -tags aa
- $w.zinc add text a -tags {ab text} -text ab -position {60 220}
- $w.zinc add group a -tags ac
-
- $w.zinc add group aa -tags aaa
- $w.zinc add text aa -tags {aab text} -text aab -position {90 190}
- $w.zinc add group aaa -tags aaaa
- $w.zinc add text aaaa -tags {aaaaa text} -text aaaaa -position {150 110}
- $w.zinc add text aaaa -tags {aaaab text} -text aaaab -position {150 130}
- $w.zinc add text aaa -tags {aaab text} -text aaab -position {120 160}
-
- $w.zinc add text ac -tags aca -text aca -position {90 260}
- $w.zinc add text ac -tags {acb text} -text acb -position {90 290}
-
- $w.zinc add group c -tags ca
- $w.zinc add text c -tags {cb text} -text cb -position {330 160}
- $w.zinc add group c -tags cc
-
- $w.zinc add text ca -tags {caa text} -text caa -position {360 110}
- $w.zinc add text ca -tags {cab text} -text cab -position {360 130}
-
- $w.zinc add text cc -tags {cca text} -text cca -position {360 200}
- $w.zinc add text cc -tags {ccb text} -text ccb -position {360 220}
- }
-
- # creating the item hierarchy
- $w.zinc add group 1 -tags top
- createSubHierarchy top
-
- # creating a parallel hierarchy
- $w.zinc add group 1 -tags other_top
- createSubHierarchy other_top
-
-
- ## modifying the priority so that all rectangles and text will be visible
- foreach item [$w.zinc find withtype text ".top*"] {
- $w.zinc itemconfigure $item -priority 20
- }
- foreach item [$w.zinc find withtype text ".other_top*"] {
- $w.zinc itemconfigure $item -priority 20
- }
- foreach item [$w.zinc find withtype group ".top*"] {
- $w.zinc itemconfigure $item -priority 20
- }
- foreach item [$w.zinc find withtype group ".other_top*"] {
- $w.zinc itemconfigure $item -priority 20
- }
-
- # converts a list of items ids in a list of sorted tags (the first tag of each item)
- proc items2tags {items} {
- variable w
-
- set selectedTags {}
- foreach item $items {
- set tags [$w.zinc itemcget $item -tags]
- if {[regexp {frame|title} [lindex $tags 0]]} {
- # to remove group titles frame
- continue
- }
- lappend selectedTags [lindex tags 0]
- }
- return [lsort $selectedTags]
- }
-
- ### 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
- variable backgrounds {grey25 grey35 grey43 grey50 grey55}
-
- proc drawHierarchy {group level} {
- variable w
- variable backgrounds
-
- set tags [$w.zinc gettags $group]
- # print "level=$level (" $tags[0],")\n";
- foreach g [$w.zinc find withtype group .$group.] {
- drawHierarchy $g [expr $level + 1]
- }
- foreach {x y x2 y2} [$w.zinc bbox $group] break
- $w.zinc add text $group -position [list [expr $x-5] [expr $y-4]] \
- -text [lindex $tags 0] -anchor w -alignment left -underlined 1 \
- -priority 20 -tags [list title_[lindex $tags 0] group_title]
- foreach {x y x2 y2} [$w.zinc bbox $group] break
- if {$x ne "" } {
- $w.zinc add rectangle $group [list [expr $x+0] [expr $y+5] \
- [expr $x2+5] [expr $y2+2]] \
- -filled 1 -fillcolor [lindex $backgrounds $level] -priority $level \
- -tags [list frame_[lindex $tags 0] group_frame]
- } else {
- puts "undefined bbox for $group : $tags"
- }
- }
-
- ### 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
- proc extractTextAndFrames { } {
- variable w
-
- foreach group_title [$w.zinc find withtag group_title||group_frame] {
- set ancestors [$w.zinc find ancestor $group_title]
- # puts "$group_title $ancestors"
- set grandFather [lindex $ancestors 1]
- $w.zinc chggroup $group_title $grandFather 1
- }
- }
-
- proc TLGet {list tag {default ""}} {
- foreach {key val} $list {
- if { [string compare $key $tag] == 0 } {
- return $val
- }
- }
- return $default
- }
-
- ## this sub modifies the color/line color of texts and rectangles
- ## representing selected items.
- proc displayPathtag { } {
- variable w
- variable explanation
- variable pathtag
- variable defaultForeColor
- variable selectedColor
- variable tagsExpl
-
- if {[catch {set explanation [TLGet $tagsExpl $pathtag]}]} {
- set explanation {sorry, I am not smart enough to explain your pathTag ;-\)}
- }
- set selected [$w.zinc find withtag $pathtag]
- set tags [items2tags $selected]
- # puts "selected: $tags"
-
- ## unselecting all items
- foreach item [$w.zinc find withtype text] {
- $w.zinc itemconfigure $item -color $defaultForeColor
- }
- foreach item [$w.zinc find withtype rectangle] {
- $w.zinc itemconfigure $item -linecolor $defaultForeColor
- }
-
- ## highlighting selected items
- foreach item $selected {
- set type [$w.zinc type $item]
- #puts "$item $type [$w.zinc gettags $item]"
- if {$type eq "text"} {
- $w.zinc itemconfigure $item -color $selectedColor
- } elseif {$type eq "rectangle"} {
- $w.zinc itemconfigure $item -linecolor $selectedColor
- } elseif {$type eq "group"} {
- set tag [lindex [$w.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 {[llength [$w.zinc find ancestors $item top]]} {
- $w.zinc itemconfigure ".top*frame_$tag" -linecolor $selectedColor
- $w.zinc itemconfigure ".top*title_$tag" -color $selectedColor
- } elseif {[llength [$w.zinc find ancestors $item other_top]]} {
- $w.zinc itemconfigure ".other_top*frame_$tag" -linecolor $selectedColor
- $w.zinc itemconfigure ".other_top*title_$tag" -color $selectedColor
- } else {
- $w.zinc itemconfigure "frame_$tag" -linecolor $selectedColor
- $w.zinc itemconfigure "title_$tag" -color $selectedColor
- }
- }
- }
- }
-
- drawHierarchy top 0
- drawHierarchy other_top 0
- $w.zinc translate other_top 400 0
- extractTextAndFrames
-}
diff --git a/demos/photoAlpha.tcl b/demos/photoAlpha.tcl
deleted file mode 100644
index 631c767..0000000
--- a/demos/photoAlpha.tcl
+++ /dev/null
@@ -1,162 +0,0 @@
-# $Id$
-# this simple demo has been developped by P.Lecoanet <lecoanet@cena.fr>
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval photoAlpha {
- package require Img
-
- variable girl [image create photo -file [file join [demosPath] images photoAlpha.png]]
- variable texture [image create photo -file [file join [demosPath] images stripped_texture.gif]]
-
- variable w .photoAlpha
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc photo transparency Demonstration"
- wm iconname $w photoAlpha
-
- variable defaultfont [font create -family Helvetica -size 16 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- ###########################################
- # Text zone
- #######################
- ####################
-
- grid [text $w.text -relief sunken -borderwidth 2 -height 7] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end {This demo needs openGL for displaying the photo
- with transparent pixels and for rescaling/rotating.
- You can transform this png photo with your mouse:
- Drag-Button 1 for moving the photo,
- Drag-Button 2 for zooming the photo,
- Drag-Button 3 for rotating the photo,
- Shift-Drag-Button 1 for modifying the global photo transparency.}
-
-
- ###########################################
- # Zinc
- ##########################################
- if { $tcl_platform(platform) eq "unix" } {
- zinc $w.zinc -width 350 -height 250 -render 1 -font $defaultfont \
- -borderwidth 3 -relief sunken -tile $texture
- } else {
- zinc $w.zinc -width 350 -height 250 -render 1 -font $defaultfont \
- -borderwidth 3 -relief sunken -backcolor \#898A8F
- }
- grid $w.zinc -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- variable topGroup [$w.zinc add group 1]
-
- variable girlItem [$w.zinc add icon $topGroup -image $girl \
- -composescale 1 -composerotation 1]
-
- #
- # Controls for the window transform.
- #
- bind $w.zinc <ButtonPress-1> "::photoAlpha::press motion %x %y"
- bind $w.zinc <ButtonRelease-1> ::photoAlpha::release
- bind $w.zinc <ButtonPress-2> "::photoAlpha::press zoom %x %y"
- bind $w.zinc <ButtonRelease-2> ::photoAlpha::release
- bind $w.zinc <ButtonPress-3> "::photoAlpha::press mouseRotate %x %y"
- bind $w.zinc <ButtonRelease-3> ::photoAlpha::release
-
- #
- # Controls for alpha and gradient
- #
- bind $w.zinc <Shift-ButtonPress-1> "::photoAlpha::press modifyAlpha %x %y"
- bind $w.zinc <Shift-ButtonRelease-1> ::photoAlpha::release
-
-
- variable curX 0
- variable curY 0
- variable curAngle 0
-
- proc press {action x y} {
- variable w
- variable curAngle
- variable curX
- variable curY
-
- set curX $x
- set curY $y
- set curAngle [expr atan2($y, $x)]
- bind $w.zinc <Motion> "::photoAlpha::$action %x %y"
- }
-
- proc motion {x y} {
- variable w
- variable topGroup
- variable curX
- variable curY
-
- foreach {x1 y1 x2 y2} [$w.zinc transform $topGroup \
- [list $x $y $curX $curY]] break
- $w.zinc translate $topGroup [expr $x1 - $x2] [expr $y1 - $y2]
- set curX $x
- set curY $y
- }
-
- proc zoom {x y} {
- variable w
- variable topGroup
- variable curX
- variable curY
-
- if {$x > $curX} {
- set maxX $x
- } else {
- set maxX $curX
- }
- if {$y > $curY} {
- set maxY $y
- } else {
- set maxY $curY
- }
- if {($maxX == 0) || ($maxY == 0)} {
- return;
- }
- set sx [expr 1.0 + (double($x - $curX) / $maxX)]
- set sy [expr 1.0 + (double($y - $curY) / $maxY)]
- $w.zinc scale $topGroup $sx $sx
-
- set curX $x
- set curY $y
- }
-
- proc mouseRotate {x y} {
- variable w
- variable curAngle
- variable topGroup
-
- set lAngle [expr atan2($y, $x)]
- $w.zinc rotate $topGroup [expr $lAngle - $curAngle]
- set curAngle $lAngle
- }
-
- proc release {} {
- variable w
-
- bind $w.zinc <Motion> {}
- }
-
- proc modifyAlpha {x y} {
- variable w
- variable topGroup
-
- set xRate [expr double($x) / [$w.zinc cget -width]]
- set xRate [expr ($xRate < 0) ? 0 : ($xRate > 1) ? 1 : $xRate]
- set alpha [expr int($xRate * 100)]
-
- $w.zinc itemconfigure $topGroup -alpha $alpha
- }
-}
diff --git a/demos/reliefs.tcl b/demos/reliefs.tcl
deleted file mode 100644
index 67dd3c4..0000000
--- a/demos/reliefs.tcl
+++ /dev/null
@@ -1,278 +0,0 @@
-# $Id$
-# this simple demo has been developped by P.Lecoanet <lecoanet@cena.fr>
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval reliefDemo {
- variable w .reliefs
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Relief Testbed"
- wm iconname $w reliefs
-
- variable allReliefs {flat raised sunken groove ridge \
- roundraised roundsunken roundgroove roundridge \
- sunkenrule raisedrule}
-
- variable defaultfont [font create -family Helvetica -size 14 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- ###########################################
- # Text zone
- #######################
- ####################
-
- grid [text $w.text -relief sunken -borderwidth 2 -height 8 -width 50] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end { This demo lets you play with the various relief parameters
- on rectangles polygons and arcs. Some reliefs and The smooth relief
- capability is only available with openGL.
- You can modify the items with your mouse:
-
- Drag-Button 1 for moving Ctrl/Shft-Button 1 for Incr/Decr sides
- Drag-Button 2 for zooming Ctrl/Shft-Button 2 for cycling reliefs
- Drag-Button 3 for rotating Ctrl/Shft-Button 3 for Incr/Decr border}
-
-
- ###########################################
- # Zinc
- ##########################################
- proc deg2Rad {deg} {
- return [expr 3.14159 * $deg / 180.0]
- }
-
- proc rad2Deg {rad} {
- return [expr int(fmod(($rad * 180.0 / 3.14159)+360.0, 360.0))]
- }
-
- variable bw 4
- variable width 60
- variable lightAngle 120
- variable lightAngleRad [deg2Rad $lightAngle]
- variable zincSize 500
-
- grid [zinc $w.zinc -width $zincSize -height $zincSize -render 1 -font 10x20 \
- -highlightthickness 0 -borderwidth 0 -relief sunken -backcolor lightgray \
- -lightangle $lightAngle] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- variable topGroup [$w.zinc add group 1]
-
- proc polyPoints { ox oy rad n } {
- set step [expr 2 * 3.14159 / $n]
- for {set i 0} {$i < $n} {incr i} {
- set x [expr $ox + ($rad * cos($i * $step))];
- set y [expr $oy + ($rad * sin($i * $step))];
- lappend coords $x $y;
- }
- lappend coords [lindex $coords 0] [lindex $coords 1]
- return $coords
- }
-
- proc makePoly {x y bw sides color group} {
- variable w
- variable state
- variable allReliefs
- variable width
-
- set relief 2
-
- set g [$w.zinc add group $group]
- $w.zinc translate $g $x $y
- $w.zinc add curve $g [polyPoints 0 0 $width $sides] \
- -relief [lindex $allReliefs $relief] -linewidth $bw \
- -smoothrelief 1 -fillcolor $color -linecolor $color \
- -filled t -tags {subject polygon}
- $w.zinc add text $g -anchor center \
- -text [lindex $allReliefs $relief] -tags {subject relief}
- $w.zinc add text $g -anchor center -position {0 16} \
- -text $bw -tags {subject bw}
- set state($g,sides) $sides
- set state($g,relief) $relief
- set state($g,bw) $bw
- return $g
- }
-
- variable poly [makePoly 100 100 $bw 8 lightblue $topGroup]
- variable poly [makePoly [expr 100 + 2*($width + 10)] 100 $bw 8 tan $topGroup]
- variable poly [makePoly [expr 100 + 4*($width + 10) ] 100 $bw 8 slateblue $topGroup]
-
- proc lightCenter {radius angle} {
- return [list [expr $radius * (1 + 0.95*cos($angle))] \
- [expr $radius * (1 - 0.95*sin($angle))]]
- }
-
- #
- # Place the light at lightAngle on the circle
- $w.zinc add arc 1 {-5 -5 5 5} -filled 1 -fillcolor yellow \
- -tags light -priority 10
- eval "$w.zinc translate light [lightCenter [expr $zincSize/2] $lightAngleRad]"
-
- #
- # Controls.
- #
- $w.zinc bind subject <ButtonPress-1> "::reliefDemo::press motion %x %y"
- $w.zinc bind subject <ButtonRelease-1> ::reliefDemo::release
- $w.zinc bind subject <ButtonPress-2> "::reliefDemo::press zoom %x %y"
- $w.zinc bind subject <ButtonRelease-2> ::reliefDemo::release
- $w.zinc bind subject <ButtonPress-3> "::reliefDemo::press mouseRotate %x %y"
- $w.zinc bind subject <ButtonRelease-3> ::reliefDemo::release
-
- $w.zinc bind polygon <Shift-ButtonPress-1> "::reliefDemo::incrPolySides 1"
- $w.zinc bind polygon <Control-ButtonPress-1> "::reliefDemo::incrPolySides -1"
-
- $w.zinc bind subject <Shift-ButtonPress-2> "::reliefDemo::cycleRelief 1"
- $w.zinc bind subject <Control-ButtonPress-2> "::reliefDemo::cycleRelief -1"
-
- $w.zinc bind subject <Shift-ButtonPress-3> "::reliefDemo::incrBW 1"
- $w.zinc bind subject <Control-ButtonPress-3> "::reliefDemo::incrBW -1"
-
- $w.zinc bind light <ButtonPress-1> "::reliefDemo::press lightMotion %x %y"
- $w.zinc bind light <ButtonRelease-1> ::reliefDemo::release
-
- variable curX 0
- variable curY 0
- variable curAngle 0
-
- proc press {action x y} {
- variable w
- variable curAngle
- variable curX
- variable curY
-
- $w.zinc raise [$w.zinc group current]
-
- set curX $x
- set curY $y
- set curAngle [expr atan2($y, $x)]
- bind $w.zinc <Motion> "::reliefDemo::$action %x %y"
- }
-
- proc motion {x y} {
- variable w
- variable curX
- variable curY
- variable topGroup
-
- foreach {x1 y1 x2 y2} [$w.zinc transform $topGroup \
- [list $x $y $curX $curY]] break
- $w.zinc translate [$w.zinc group current] [expr $x1 - $x2] [expr $y1 - $y2]
- set curX $x
- set curY $y
- }
-
- proc lightMotion {x y} {
- variable w
- variable zincSize
- variable topGroup
-
- set radius [expr $zincSize/2]
- if { $x < 0 } {
- set x 0
- } elseif { $x > $zincSize } {
- set x $zincSize
- }
-
- set angle [expr acos(double($x-$radius)/$radius)]
- if { $y > $radius } {
- set angle [expr - $angle]
- }
- $w.zinc treset light
- eval "$w.zinc translate light [lightCenter [expr $zincSize/2] $angle]"
- $w.zinc configure -lightangle [rad2Deg $angle]
- }
-
- proc zoom {x y} {
- variable w
- variable curX
- variable curY
-
- if {$x > $curX} {
- set maxX $x
- } else {
- set maxX $curX
- }
- if {$y > $curY} {
- set maxY $y
- } else {
- set maxY $curY
- }
- if {($maxX == 0) || ($maxY == 0)} {
- return;
- }
- set sx [expr 1.0 + (double($x - $curX) / $maxX)]
- set sy [expr 1.0 + (double($y - $curY) / $maxY)]
- $w.zinc scale current $sx $sx
-
- set curX $x
- set curY $y
- }
-
- proc mouseRotate {x y} {
- variable w
- variable curAngle
-
- set lAngle [expr atan2($y, $x)]
- $w.zinc rotate current [expr $lAngle - $curAngle]
- set curAngle $lAngle
- }
-
- proc release {} {
- variable w
-
- bind $w.zinc <Motion> {}
- }
-
- proc incrPolySides {incr} {
- variable w
- variable state
- variable width
-
- set g [$w.zinc group current]
- incr state($g,sides) $incr
- if { $state($g,sides) < 3 } {
- set state($g,sides) 3
- }
-
- set points [polyPoints 0 0 $width $state($g,sides)]
- $w.zinc coords $g.polygon $points
- }
-
- proc cycleRelief {incr} {
- variable w
- variable state
- variable allReliefs
-
- set g [$w.zinc group current]
- incr state($g,relief) $incr
- if { $state($g,relief) < 0 } {
- set state($g,relief) [expr [llength $allReliefs] - 1]
- } elseif { $state($g,relief) >= [llength $allReliefs] } {
- set state($g,relief) 0
- }
- set rlf [lindex $allReliefs $state($g,relief)]
- $w.zinc itemconfigure $g.polygon -relief $rlf
- $w.zinc itemconfigure $g.relief -text $rlf
- }
-
- proc incrBW {incr} {
- variable w
- variable state
-
- set g [$w.zinc group current]
- incr state($g,bw) $incr
- if { $state($g,bw) < 0 } {
- set state($g,bw) 0
- }
- $w.zinc itemconfigure $g.polygon -linewidth $state($g,bw)
- $w.zinc itemconfigure $g.bw -text $state($g,bw)
- }
-}
diff --git a/demos/simpleInteractionTrack.tcl b/demos/simpleInteractionTrack.tcl
deleted file mode 100644
index e5136b0..0000000
--- a/demos/simpleInteractionTrack.tcl
+++ /dev/null
@@ -1,232 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-
-namespace eval simpleInteractionTrack {
- variable w .simpleInteractionTrack
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Track Interaction Demonstration"
- wm iconname $w TrackInteraction
-
- set defaultfont [font create -family Helvetica -size 14 -weight normal]
- set labelfont [font create -family Courier -size 18 -weight bold]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- ###########################################
- # Zinc
- ###########################################
- grid [zinc $w.zinc -width 600 -height 500 -font $labelfont -borderwidth 0] \
- -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
-
- # The explanation displayed when running this demo
- $w.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 leader} -font $defaultfont
-
-
- ###########################################
- # Track
- ###########################################
-
- #the label format 6 formats for 6 fields#
- variable labelformat {x90x55+0+0 a0a0^0^0 a0a0^0>1 a0a0>2>1 a0a0>3>1 a0a0^0>2}
-
- #the track#
- variable x 250
- variable y 200
- variable xi 0
- variable yi 0
- variable track [$w.zinc add track 1 6 -labelformat $labelformat -position "$x $y" \
- -speedvector {30 -15} -markersize 10]
-
- # moving the track to display past positions
- for {set i 0} {$i<=5} {incr i} {
- $w.zinc coords $track [list [expr $x+$i*10] [expr $y-$i*5]]
- }
-
- #fields of the label#
- $w.zinc itemconfigure $track 0 -filled 0 -bordercolor DarkGreen -border contour
- $w.zinc itemconfigure $track 1 -filled 1 -backcolor gray60 -text AFR6128
-
- $w.zinc itemconfigure $track 2 -filled 0 -backcolor gray65 -text 390
-
- $w.zinc itemconfigure $track 3 -filled 0 -backcolor gray65 -text /
-
- $w.zinc itemconfigure $track 4 -filled 0 -backcolor gray65 -text 350
-
- $w.zinc itemconfigure $track 5 -filled 0 -backcolor gray65 -text TUR
-
-
-
- ###########################################
- # Events on the track
- ###########################################
- #---------------------------------------------
- # Enter/Leave a field of the label of the track
- #---------------------------------------------
-
- for {set field 0} {$field<=5} {incr field} {
- #Entering the field $field higlights it#
- $w.zinc bind $track:$field <Enter> "::simpleInteractionTrack::highlightEnter $field"
- #Leaving the field cancels the highlight of $field#
- $w.zinc bind $track:$field <Leave> "::simpleInteractionTrack::highlightLeave $field"
- }
-
- proc highlightEnter {field} {
- if {$field ==0} {
- highlightLabelOn
- } else {
- highlightFieldsOn $field
- }
-
- }
- proc highlightLeave {field} {
- if {$field==0} {
- highlightLabelOff
- } else {
- if {$field==1} {
- highlightField1Off
- } else {
- highlightOtherFieldsOff $field
- }
- }
- }
-
- #fonction#
- proc highlightLabelOn {} {
- variable w
- $w.zinc itemconfigure current 0 -filled 0 -bordercolor red -border contour
- }
-
- proc highlightLabelOff {} {
- variable w
- $w.zinc itemconfigure current 0 -filled 0 -bordercolor DarkGreen -border contour
- }
-
- proc highlightFieldsOn {field} {
- variable w
- $w.zinc itemconfigure current $field -border contour -filled 1 -color white
- }
-
- proc highlightField1Off {} {
- variable w
- $w.zinc itemconfigure current 1 -border "" -filled 1 -color black -backcolor gray60
- }
-
- proc highlightOtherFieldsOff {field} {
- variable w
- $w.zinc itemconfigure current $field -border "" -filled 0 -color black -backcolor gray65
- }
-
- #---------------------------------------------
- # Enter/Leave other parts of the track
- #---------------------------------------------
- $w.zinc bind $track:position <Enter> "$w.zinc itemconfigure $track -symbolcolor red"
- $w.zinc bind $track:position <Leave> "$w.zinc itemconfigure $track -symbolcolor black"
- $w.zinc bind $track:speedvector <Enter> "$w.zinc itemconfigure $track -speedvectorcolor red"
- $w.zinc bind $track:speedvector <Leave> "$w.zinc itemconfigure $track -speedvectorcolor black"
- $w.zinc bind $track:leader <Enter> "$w.zinc itemconfigure $track -leadercolor red"
- $w.zinc bind $track:leader <Leave> "$w.zinc itemconfigure $track -leadercolor black"
-
- #---------------------------------------------
- # Drag and drop the track
- #---------------------------------------------
- #Binding to ButtonPress event -> "moveOn" state#
- $w.zinc bind $track <1> {
- ::simpleInteractionTrack::selectColorOn
- ::simpleInteractionTrack::moveOn %x %y
- }
-
-
-
- #"moveOn" state#
- proc moveOn {x y} {
- variable track
- variable w
- variable xi
- variable yi
-
- set xi $x
- set yi $y
-
- #ButtonPress event not allowed on track
- $w.zinc bind $track <ButtonPress-1> ""
- #Binding to Motion event -> move the track#
- $w.zinc bind $track <Motion> "::simpleInteractionTrack::bindMotion %x %y"
-
- #Binding to ButtonRelease event -> "moveOff" state#
- $w.zinc bind $track <ButtonRelease-1> {
- ::simpleInteractionTrack::selectColorOff
- ::simpleInteractionTrack::moveOff
- }
- }
-
- proc bindMotion { x y} {
- variable xi
- variable yi
-
- move $xi $yi $x $y
-
- set xi $x
- set yi $y
- }
-
- #"moveOff" state#
- proc moveOff {} {
- variable track
- variable w
- #Binding to ButtonPress event -> "moveOn" state#
- $w.zinc bind $track <ButtonPress-1> {
- ::simpleInteractionTrack::selectColorOn
- ::simpleInteractionTrack::moveOn %x %y
- }
-
-
- #Motion event not allowed on track
- $w.zinc bind $track <Motion> ""
- #ButtonRelease event not allowed on track
- $w.zinc bind $track <ButtonRelease-1> ""
- }
-
- #move the track#
- proc move {xi yi x y} {
- variable w
- variable track
-
- selectColorOn
- foreach {X1 Y1} [$w.zinc coords $track] break
- $w.zinc coords $track [list [expr $X1+$x-$xi] [expr $Y1+$y-$yi]]
- }
-
-
- proc selectColorOn {} {
- variable track
- variable w
-
- $w.zinc itemconfigure $track -speedvectorcolor white -markercolor white -leadercolor white
- }
-
- proc selectColorOff {} {
- variable track
- variable w
-
- $w.zinc itemconfigure $track -speedvectorcolor black -markercolor black -leadercolor black
- }
-}
diff --git a/demos/simpleRadar.tcl b/demos/simpleRadar.tcl
deleted file mode 100644
index 15df644..0000000
--- a/demos/simpleRadar.tcl
+++ /dev/null
@@ -1,403 +0,0 @@
-# $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.
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval simpleRadar {
- variable w .simpleRadar
- catch {destroy $w}
- toplevel $w
- wm title $w "Simple radar display"
- wm iconname $w SimpleRadar
-
- text $w.text -relief sunken -borderwidth 2 -height 11
- pack $w.text -expand yes -fill both
-
- $w.text insert end {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 square 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.}
-
-
-
- #-------------------------------------------------
- # Create zinc
- #-------------------------------------------------
- variable top 1
- variable scale 1.0
- variable centerX 0.0
- variable centerY 0.0
- variable zincWidth 800
- variable zincHeight 500
- variable delay 2000
- variable rate 0.3
- array unset tracks
- # if true the flights are no more moving
- variable pause 0
-
- zinc $w.zinc -backcolor gray65 -relief sunken -font 10x20 \
- -width $zincWidth -height $zincHeight
- pack $w.zinc -expand 1 -fill both
-
- $w.zinc add group $top -tags {controls radar}
- $w.zinc configure -overlapmanager [$w.zinc find withtag radar]
-
-
- #-------------------------------------------------
- # Create control panel
- #-------------------------------------------------
- frame $w.f
- pack $w.f
- button $w.f.up -text Up -command "::simpleRadar::Up $w.zinc"
- grid $w.f.up -row 0 -column 2 -sticky ew
- button $w.f.down -text Down -command "::simpleRadar::Down $w.zinc"
- grid $w.f.down -row 2 -column 2 -sticky ew
- button $w.f.left -text Left -command "::simpleRadar::Left $w.zinc"
- grid $w.f.left -row 1 -column 1
- button $w.f.right -text Right -command "::simpleRadar::Right $w.zinc"
- grid $w.f.right -row 1 -column 3
- button $w.f.expand -text Expand -command "::simpleRadar::Expand $w.zinc"
- grid $w.f.expand -row 1 -column 4
- button $w.f.shrink -text Shrink -command "::simpleRadar::Shrink $w.zinc"
- grid $w.f.shrink -row 1 -column 0
- button $w.f.reset -text Reset -command "::simpleRadar::Reset $w.zinc"
- grid $w.f.reset -row 1 -column 2 -sticky ew
- button $w.f.pause -text Pause -command "::simpleRadar::Pause $w.zinc"
- grid $w.f.pause -row 0 -column 6
-
- #--------------------------------------------------
- # Resize handling code
- #--------------------------------------------------
- bind $w.zinc <Configure> "::simpleRadar::resize $w.zinc %w %h"
-
- proc Up {z} {
- variable centerY
- set centerY [expr $centerY - 30.0]
- updateTransform $z
- }
-
- proc Down {z} {
- variable centerY
- set centerY [expr $centerY + 30.0]
- updateTransform $z
- }
-
- proc Left {z} {
- variable centerX
- set centerX [expr $centerX + 30.0]
- updateTransform $z
- }
-
- proc Right {z} {
- variable centerX
- set centerX [expr $centerX - 30.0]
- updateTransform $z
- }
-
- proc Expand {z} {
- variable scale
- set scale [expr $scale * 1.1]
- updateTransform $z
- }
-
- proc Shrink {z} {
- variable scale
- set scale [expr $scale * 0.9]
- updateTransform $z
- }
-
- proc Reset {z} {
- variable centerX
- variable centerY
- variable scale
- set scale 1.0
- set centerX 0.0
- set centerY 0.0
- updateTransform $z
- }
-
- proc Pause {z} {
- variable pause
- set pause [expr ! $pause]
- }
-
- proc resize {z w h} {
- variable zincWidth
- variable zincHeight
-
- set bw [$z cget -borderwidth]
- set zincWidth [expr $w - 2 * $bw]
- set zincHeight [expr $h - 2 * $bw]
- updateTransform $z
- }
-
- proc updateTransform {z} {
- variable centerX
- variable centerY
- variable zincWidth
- variable zincHeight
- variable scale
-
- $z treset 1
- $z translate 1 [expr -$centerX] [expr -$centerY]
- $z scale 1 $scale $scale
- $z scale 1 1 -1
- $z translate 1 [expr $zincWidth/2] [expr $zincHeight/2]
- }
-
- #------------------------------------------------
- # Create the tracks
- #------------------------------------------------
- proc createTracks {z} {
- variable oneTrack
- variable zincWidth
- variable zincHeight
- variable scale
- variable centerX
- variable centerY
- variable tracks
-
- set w [expr $zincWidth / $scale]
- set h [expr $zincHeight / $scale]
-
- set allTracks {}
-
- set bOn "$z itemconfigure current \[$z currentpart\] -border contour"
- set bOff "$z itemconfigure current \[$z currentpart\] -border noborder"
-
- for {set i 20} {$i > 0} {incr i -1} {
- set item [$z add track radar 6 -lastasfirst 1]
- lappend allTracks $item
- set oneTrack $item
-
- set tracks($item,x) [expr rand()*$w - $w/2 + $centerX]
- set tracks($item,y) [expr rand()*$h - $h/2 + $centerY]
- set d [expr (rand() > 0.5) ? 1 : -1]
- set tracks($item,vx) [expr (8.0 + rand()*10.0) * $d]
- set d [expr (rand() > 0.5) ? 1 : -1]
- set tracks($item,vy) [expr (8.0 + rand()*10.0) * $d]
- $z itemconfigure $item -position "$tracks($item,x) $tracks($item,y)" -circlehistory 1 \
- -speedvector "$tracks($item,vx) $tracks($item,vy)" -speedvectorsensitive 1 \
- -labeldistance 30 -markersize 20 -historycolor white -filledhistory 0 \
- -labelformat {x80x60+0+0 x63a0^0^0 x33a0^0>1 a0a0>2>1 x33a0>3>1 a0a0^0>2}
- $z itemconfigure $item 0 -filled 0 -backcolor gray60 -sensitive 1
- $z itemconfigure $item 1 -filled 1 -backcolor gray55 -text [format {AFR%03i} $i]
- $z itemconfigure $item 2 -filled 0 -backcolor gray65 -text 360
- $z itemconfigure $item 3 -filled 0 -backcolor gray65 -text /
- $z itemconfigure $item 4 -filled 0 -backcolor gray65 -text 410
- $z itemconfigure $item 5 -filled 0 -backcolor gray65 -text Balise
-
- for {set j 0} {$j < 6} {incr j} {
- $z bind $item:$j <Enter> $bOn
- $z bind $item:$j <Leave> $bOff
- $z bind $item <1> "::simpleRadar::fieldSensitivity $z"
- $z bind $item <Shift-1> {}
- }
- $z bind $item <Enter> [list $z itemconfigure current -historycolor red3 \
- -symbolcolor red3 -markercolor red3 -leaderwidth 2 \
- -leadercolor red3 -speedvectorwidth 2 -speedvectorcolor red3]
- $z bind $item <Leave> [list $z itemconfigure current -historycolor white \
- -symbolcolor black -markercolor black -leaderwidth 1 \
- -leadercolor black -speedvectorwidth 1 -speedvectorcolor black]
- $z bind $item:position <1> "::simpleRadar::createRoute $z"
- $z bind $item:position <Shift-1> {}
- set tracks($item,route) 0
- }
-
- set tracks(all) $allTracks
- }
-
- createTracks $w.zinc
-
- #---------------------------------------------------
- # Create route way points
- #---------------------------------------------------
- proc createRoute {z} {
- variable tracks
-
- set track [$z find withtag current]
-
- if { $tracks($track,route) == 0 } {
- set x [expr $tracks($track,x) + 8.0 * $tracks($track,vx)]
- set y [expr $tracks($track,y) + 8.0 * $tracks($track,vy)]
- set connected $track
- for {set i 4} {$i > 0} {incr i -1} {
- set wp [$z add waypoint radar 2 -position "$x $y" -labelformat x20x18+0+0 \
- -connecteditem $connected -connectioncolor green -symbolcolor green]
- $z lower $wp $connected
- $z bind $wp:0 <Enter> "$z itemconfigure current 0 -border contour"
- $z bind $wp:position <Enter> "$z itemconfigure current -symbolcolor red"
- $z bind $wp:leader <Enter> "$z itemconfigure current -leadercolor red"
- $z bind $wp:connection <Enter> "$z itemconfigure current -connectioncolor red"
- $z bind $wp:0 <Leave> "$z itemconfigure current 0 -border noborder"
- $z bind $wp:position <Leave> "$z itemconfigure current -symbolcolor green"
- $z bind $wp:leader <Leave> "$z itemconfigure current -leadercolor black"
- $z bind $wp:connection <Leave> "$z itemconfigure current -connectioncolor green"
- $z itemconfigure $wp 0 -text $i -filled 1 -backcolor gray55
- $z bind $wp:position <1> "::simpleRadar::delWaypoint $z"
- set x [expr $x + (2.0 + rand()*8.0) * $tracks($track,vx)]
- set y [expr $y + (2.0 + rand()*8.0) * $tracks($track,vy)]
- set connected $wp
- }
- set tracks($track,route) $wp
- } else {
- set wp $tracks($track,route)
- while { $wp != $track } {
- set tracks($track,route) [$z itemcget $wp -connecteditem]
- $z bind $wp:position <1> {}
- $z bind $wp:position <Enter> {}
- $z bind $wp:position <Leave> {}
- $z bind $wp:leader <Enter> {}
- $z bind $wp:leader <Leave> {}
- $z bind $wp:connection <Enter> {}
- $z bind $wp:connection <Leave> {}
- $z bind $wp:0 <Enter> {}
- $z bind $wp:0 <Leave> {}
- $z remove $wp
- set wp $tracks($track,route)
- }
- set tracks($track,route) 0
- }
- }
-
- #-----------------------------------------------------
- # Toggle current field sensitivity
- #-----------------------------------------------------
- proc fieldSensitivity {z} {
- set curPart [$z currentpart]
- if { [regexp {[0-9]+} $curPart] } {
- set onOff [$z itemcget current $curPart -sensitive]
- $z itemconfigure current $curPart -sensitive [expr !$onOff]
- }
- }
-
- #-----------------------------------------------------
- # Removal of a route Waypoint
- #-----------------------------------------------------
- proc findTrack {z wp} {
- set connected $wp
-
- while { [$z type $connected] != "track" } {
- set connected [$z itemcget $connected -connecteditem]
- }
- return $connected
- }
-
- proc delWaypoint {z} {
- variable tracks
-
- set wp [$z find withtag current]
- set track [findTrack $z $wp]
- set next [$z itemcget $wp -connecteditem]
-
- set prev $tracks($track,route)
- if { $prev != $wp } {
- set prevnext [$z itemcget $prev -connecteditem]
- while { $prevnext != $wp } {
- set prev $prevnext
- set prevnext [$z itemcget $prev -connecteditem]
- }
- }
- $z itemconfigure $prev -connecteditem $next
- $z bind $wp:position <1> {}
- $z remove $wp
- if { $wp == $tracks($track,route) } {
- if { $next == $track } {
- set tracks($track,route) 0
- } else {
- set tracks($track,route) $next
- }
- }
- }
-
-
- #---------------------------------------------
- # Create a macro
- #---------------------------------------------
- set macro [$w.zinc add tabular radar 10 -labelformat {x73x20+0+0 x20x20+0+0 x53x20+20+0}]
- $w.zinc itemconfigure $macro 0 -backcolor tan1 -filled 1 -fillpattern AlphaStipple7 \
- -bordercolor red3
- $w.zinc itemconfigure $macro 1 -text a
- $w.zinc itemconfigure $macro 2 -text macro
- $w.zinc itemconfigure $macro -connecteditem $oneTrack
- foreach part {0 1 2} {
- $w.zinc bind $macro:$part <Enter> "::simpleRadar::borders $w.zinc 1"
- $w.zinc bind $macro:$part <Leave> "::simpleRadar::borders $w.zinc 0"
- }
-
- proc borders {z on} {
- if { $on } {
- set contour contour
- } else {
- set contour noborder
- }
- $z itemconfigure current 0 -border $contour
- }
-
- #---------------------------------------------
- # Create a ministrip
- #---------------------------------------------
- set ministrip [$w.zinc add tabular 1 10 -position {100 10} \
- -labelformat {x153x80^0^0 x93x20^0^0 x63a0^0>1 a0a0>2>1 x33a0>3>1 a0a0^0>2}]
- $w.zinc itemconfigure $ministrip 0 -filled 1 -backcolor grey70 -border contour -bordercolor green
- $w.zinc itemconfigure $ministrip 1 -text ministrip -color darkgreen -backcolor grey40
- $w.zinc itemconfigure $ministrip 2 -text field1 -color darkgreen -backcolor grey40
- $w.zinc itemconfigure $ministrip 3 -text field2 -color darkgreen -backcolor grey40
- $w.zinc itemconfigure $ministrip 4 -text f3 -color darkgreen -backcolor grey40
- $w.zinc itemconfigure $ministrip 5 -text field4 -color darkgreen -backcolor grey40
-
- foreach field {1 2 3 4 5} {
- $w.zinc bind $ministrip:$field <Enter> \
- "$w.zinc itemconfigure current $field -border contour -filled 1 -color white"
- $w.zinc bind $ministrip:$field <Leave> \
- "$w.zinc itemconfigure current $field -border noborder -filled 0 -color darkgreen"
- }
-
- #-------------------------------------------
- # Create some maps
- #-------------------------------------------
- set dataDir [file join [file dirname [info script]] data]
- videomap load [file join $dataDir videomap_paris-w_90_2] 0 paris-w
- videomap load [file join $dataDir videomap_orly] 17 orly
- videomap load [file join $dataDir hegias_parouest_TE.vid] 0 paris-ouest
-
- $w.zinc add map radar -color gray80 -mapinfo orly
- $w.zinc add map radar -color gray60 -filled 1 -priority 0 \
- -fillpattern AlphaStipple6 -mapinfo paris-ouest
- $w.zinc add map radar -color gray50 -mapinfo paris-w
-
-
- #--------------------------------------------
- # Animate tracks along their trajectories
- #--------------------------------------------
- variable timer [after $delay "::simpleRadar::refresh $w.zinc"]
- bind $w.zinc <Destroy> {puts {canceling timer}; after cancel $::simpleRadar::timer}
-
- proc refresh {z} {
- variable pause
- variable timer
- variable delay
- variable tracks
- variable rate
-
- set timer [after $delay "::simpleRadar::refresh $z"]
-
- if { ! $pause } {
- foreach t $tracks(all) {
- set tracks($t,x) [expr $tracks($t,x) + $tracks($t,vx) * $rate]
- set tracks($t,y) [expr $tracks($t,y) + $tracks($t,vy) * $rate]
- $z itemconfigure $t -position [list $tracks($t,x) $tracks($t,y)]
- }
- }
- }
-}
diff --git a/demos/testGraphics.tcl b/demos/testGraphics.tcl
deleted file mode 100644
index 78502db..0000000
--- a/demos/testGraphics.tcl
+++ /dev/null
@@ -1,2130 +0,0 @@
-#!/usr/bin/tclsh
-#-----------------------------------------------------------------------------------
-#
-# testGraphics.pl
-# Fichier test du module Graphics
-#
-# Authors: Jean-Luc Vinot <vinot@cena.fr>
-# Patrick Lecoanet <lecoanet@cena.fr> (Straightt translation
-# to Tcl, based on testGraphics.pl revision 1.9)
-#
-# $Id:
-#-----------------------------------------------------------------------------------
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-package require zincGraphics
-
-namespace eval testGraphics {
- set w .testGraphics
- catch {destroy $w}
- toplevel $w
- wm title $w "zincGraphics Demonstration"
- wm geometry $w "700x600+0+0"
- wm iconname $w testGraphics
- frame $w.buttons
- pack $w.buttons -side bottom -fill x -pady 2m
- button $w.buttons.dismiss -text Dismiss -command "destroy $w"
- button $w.buttons.code -text "See Code" -command "showCode $w"
- pack $w.buttons.dismiss $w.buttons.code -side left -expand 1
-
- # creation du widget Zinc
- set zinc [zinc $w.z -render 1 -width 700 -height 560 -borderwidth 0 \
- -lightangle 140 -backcolor \#cccccc]
- pack $w.z -fill both -expand yes
-
-
- set previousAngle 0
- set rotateAngle .1
- set zoomFactor .1
- set curView 0
- set dx 0
- set dy 0
- set tabAnchor n
- set tabAlign left
-
- set font9b 7x13bold
- # the original font is not standard, even if it is fully free:
- #$font9b = '-cenapii-bleriot mini-bold-r-normal--9-90-75-75-p-75-iso8859-15';
-
- set gradSet {
- 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}
- conicalEdge {=conical 0 0 -45|#ffffff;100 0|#888899;100 30|#555566;100 50|#888899;100 70|#ffffff;100 100}
- conicalExt {=conical 0 0 135|#ffffff;100 0|#777788;100 30|#444455;100 50|#777788;100 70|#ffffff;100 100}
- pushBtnEdge {=axial 140|#ffffff;100 0|#555566;100 100}
- pushBtnEdge2 {=axial 92|#ffffff;100 0|#555566;100 100}
- logoShape {=axial 270|#ffffff|#7192aa}
- logoPoint {=radial -20 -20|#ffffff 0|#f70000 48|#900000 80|#ab0000 100}
- logoPtShad {=path 0 0|#770000;64 0|#770000;70 78|#770000;0 100}
- }
-
-
-# contenu des pages exemples
- variable pagesConf {
- Rectangle {
- consigne {
- -itemtype text
- -coords {-285 155}
- -params {
- -font 7x13bold
- -text "Mouse button 1 drag objects,\nEscape key reset transfos."
- -color \#2222cc
- }
- }
- 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
- }
- }
- rr2 {
- -itemtype roundedrectangle
- -coords {{-250 -100} {-90 60}}
- -params {
- -closed 1
- -filled 1
- -fillcolor roundRect1
- -linewidth 3
- -linecolor \#000000
- -priority 30
- -tags move
- }
- }
- 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
- }
- }
- 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}
- }
- 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 7x13bold
- -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 pushBtnEdge
- -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 {-50 -40}
- -params {
- -priority 40
- }
- -items {
- edge {
- -itemtype hippodrome
- -coords {{-46 -86} {46 86}}
- -params {
- -closed 1
- -filled 1
- -fillcolor pushBtnEdge
- -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 pushBtnEdge2
- -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}
- }
- -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}
- }
- }
- }
- }
- 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}
- }
- }
- }
- }
- hp3c3 {
- -itemtype group
- -coords {80 120}
- -params {
- -priority 40
- }
- -items {
- form {
- -itemtype hippodrome
- -coords {{-39 -20} {38 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}
- }
- }
- }
- }
-
- 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
- -relief raised
- -priority 30
- -tags {b3d pushBtn}
- }
- -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 pushBtnEdge
- -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 conicalEdge
- -linewidth 1
- -linecolor \#ffffff
- -priority 0
- }
- }
- ext {
- -itemtype hippodrome
- -coords {{-53 -53} {53 53}}
- -params {
- -closed 1
- -filled 1
- -fillcolor conicalExt
- -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 pushBtnEdge
- -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 7x13bold
- -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
- -cornerradius 10
- -startangle 90
- -params {
- -closed 1
- -filled 1
- -fillcolor roundPolyg
- -linewidth 2
- -linecolor \#330000
- -priority 20
- -tags {p1 poly}
- }
- }
- text {
- -itemtype text
- -coords {0 0}
- -params {
- -font 7x13bold
- -text "Triangle"
- -anchor center
- -alignment center
- -color \#660000
- -priority 50
- }
- }
- }
- }
- carre {
- -itemtype group
- -coords {-80 -75}
- -items {
- form {
- -itemtype polygone
- -coords {0 0}
- -numsides 4
- -radius 70
- -cornerradius 10
- -startangle 90
- -params {
- -closed 1
- -filled 1
- -fillcolor roundPolyg
- -linewidth 2
- -linecolor \#330000
- -priority 20
- -tags {p2 poly}
- }
- }
- text {
- -itemtype text
- -coords {0 0}
- -params {
- -font 7x13bold
- -text "Carré"
- -anchor center
- -alignment center
- -color \#660000
- -priority 50
- }
- }
- }
- }
- pentagone {
- -itemtype group
- -coords {65 -75}
- -items {
- form {
- -itemtype polygone
- -coords {0 0}
- -numsides 5
- -radius 70
- -cornerradius 10
- -startangle 270
- -params {
- -closed 1
- -filled 1
- -fillcolor roundPolyg
- -linewidth 2
- -linecolor \#330000
- -priority 20
- -tags {p3 poly}
- }
- }
- text {
- -itemtype text
- -coords {0 0}
- -params {
- -font 7x13bold
- -text "Pentagone"
- -anchor center
- -alignment center
- -color \#660000
- -priority 50
- }
- }
- }
- }
- hexagone {
- -itemtype group
- -coords {210 -75}
- -items {
- form {
- -itemtype polygone
- -coords {0 0}
- -numsides 6
- -radius 68
- -cornerradius 10
- -params {
- -closed 1
- -filled 1
- -fillcolor roundPolyg
- -linewidth 2
- -linecolor \#330000
- -priority 20
- -tags {p4 poly}
- }
- }
- text {
- -itemtype text
- -coords {0 0}
- -params {
- -font 7x13bold
- -text "Hexagone"
- -anchor center
- -alignment center
- -color \#660000
- -priority 50
- }
- }
- }
- }
- heptagone {
- -itemtype group
- -coords {-215 85}
- -items {
- form {
- -itemtype polygone
- -coords {0 0}
- -numsides 7
- -radius 64
- -cornerradius 10
- -params {
- -closed 1
- -filled 1
- -fillcolor roundPolyg
- -linewidth 2
- -linecolor \#330000
- -priority 20
- -tags {p5 poly}
- }
- }
- text {
- -itemtype text
- -coords {0 0}
- -params {
- -font 7x13bold
- -text "Heptagone"
- -anchor center
- -alignment center
- -color \#660000
- -priority 50
- }
- }
- }
- }
- octogone {
- -itemtype group
- -coords {-76 85}
- -items {
- form {
- -itemtype polygone
- -coords {0 0}
- -numsides 8
- -radius 64
- -cornerradius 10
- -params {
- -closed 1
- -filled 1
- -fillcolor roundPolyg
- -linewidth 2
- -linecolor \#330000
- -priority 20
- -tags {p6 poly}
- }
- }
- text {
- -itemtype text
- -coords {0 0}
- -params {
- -font 7x13bold
- -text Octogone
- -anchor center
- -alignment center
- -color \#660000
- -priority 50
- }
- }
- }
- }
- petagone {
- -itemtype group
- -coords {66 85}
- -items {
- form {
- -itemtype polygone
- -coords {0 0}
- -numsides 32
- -radius 64
- -cornerradius 10
- -params {
- -closed 1
- -filled 1
- -fillcolor roundPolyg
- -linewidth 2
- -linecolor \#330000
- -priority 20
- -tags {p7 poly}
- }
- }
- text {
- -itemtype text
- -coords {0 0}
- -params {
- -font 7x13bold
- -text "32 cotés..."
- -anchor center
- -alignment center
- -color \#660000
- -priority 50
- }
- }
- }
- }
- etoile {
- -itemtype group
- -coords {210 85}
- -items {
- form {
- -itemtype polygone
- -coords {0 0}
- -numsides 5
- -radius 92
- -innerradius 36
- -cornerradius 10
- -startangle 270
- -corners {1 0 1 0 1 0 1 0 1 0}
- -params {
- -closed 1
- -filled 1
- -fillcolor roundPolyg
- -linewidth 2
- -linecolor \#330000
- -priority 20
- -tags {p8 poly}
- }
- }
- text {
- -itemtype text
- -coords {0 0}
- -params {
- -font 7x13bold
- -text "Etoile"
- -anchor center
- -alignment center
- -color \#660000
- -priority 50
- }
- }
- }
- }
- }
-
- Polyline {
- consigne {
- -itemtype text
- -coords {-285 155}
- -params {
- -font 7x13bold
- -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}
- }
- -cornersradius {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}
- }
- -cornersradius {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}
- }
- -cornersradius {0 0 70 47 47 70 0 0 14 14 0 0 00 }
- -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}
- }
- -cornersradius {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}
- }
- -cornersradius {
- 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 logoShape
- -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}}
- 0 {} {0 0 55 55 0 0 15 15}}
- }
- }
- shad {
- -itemtype arc
- -coords {{75 91} {115 131}}
- -params {
- -priority 20
- -filled 1
- -linewidth 0
- -fillcolor logoPtShad
- -closed 1
- }
- }
- point {
- -itemtype arc
- -coords {{70 86} {110 126}}
- -params {
- -priority 50
- -filled 1
- -linewidth 1
- -linecolor \#a10000
- -fillcolor logoPoint
- -closed 1
- }
- }
- }
- }
- }
-
- MultiContours {
- consigne {
- -itemtype text
- -coords {-285 155}
- -params {
- -font 7x13bold
- -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}
- }
- -cornersradius {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 {} {16 16 0 0}}
- {add -1 {{-175 -72} {-159 0} {-78 0} {-116 -72}} 0 {} {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 7x13bold
- -text "Click on thumbnail to select page\nChange anchor or alignment tabs options with radio buttons.\n"
- -color \#2222cc
- }
- }
- bo1 {
- -itemtype tabbox
- -coords {{-240 -160} {240 100}}
- -radius 8
- -tabwidth 72
- -tabheight 28
- -numpages 8
- -anchor n
- -alignment left
- -overlap 3
- -tabtitles {A B C D E F G H}
- -params {
- -closed 1
- -priority 100
- -filled 1
- -fillcolor \#ffffff
- -linewidth 1.2
- -linecolor \#000000
- -tags {div2 divider intercalaire}
- }
- }
-
- 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 7x13bold
- -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 7x13bold
- -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 7x13bold
- -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 7x13bold
- -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 7x13bold
- -anchor center
- -alignment center
- -priority 40
- -tags {sel1 w btntext selector}
- }
- }
- alignment {
- -itemtype text
- -coords {120 115}
- -params {
- -text {tabs alignment}
- -color \#2222cc
- -font 7x13bold
- -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 7x13bold
- -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 7x13bold
- -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 7x13bold
- -anchor center
- -alignment center
- -priority 40
- -tags {sel2 right btntext selector}
- }
- }
- }
-
- PathLine {
- consigne {
- -itemtype text
- -coords {-285 155}
- -params {
- -font 7x13bold
- -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
- -innerradius 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 right
- -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 right
- -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}
- }
- }
-
- }
- }
- }
- }
-
- variable 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 none. [...] 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 doesnt name an item an error is raised. If belowThis name more than one item the bottom most them is used. If belowThis doesnt 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 doesnt 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."
- }
- }
- }
-
- proc TLGet {list tag {default ""}} {
- foreach {key val} $list {
- if { [string compare $key $tag] == 0 } {
- return $val
- }
- }
- return $default
- }
-
- proc SetBindings {} {
- variable zinc
- variable curView
-
- # focus the keyboard
- focus $zinc
-
- # plusmoins : Zoom++ Zoom--
- bind $zinc <plus> "::testGraphics::ViewZoom $zinc up"
- bind $zinc <minus> "::testGraphics::ViewZoom $zinc down"
-
- # Up Down Right Left : Translate
- bind $zinc <KeyPress-Up> "::testGraphics::ViewTranslate $zinc up"
- bind $zinc <KeyPress-Down> "::testGraphics::ViewTranslate $zinc down"
- bind $zinc <KeyPress-Left> "::testGraphics::ViewTranslate $zinc left"
- bind $zinc <KeyPress-Right> "::testGraphics::ViewTranslate $zinc right"
-
-
- # > < : Rotate counterclockwise et clockwise
- bind $zinc <greater> "::testGraphics::ViewRotate $zinc cw"
- bind $zinc <less> "::testGraphics::ViewRotate $zinc ccw"
-
- # Escape : reset transfos
- bind $zinc <Escape> "$zinc treset poly; $zinc treset move; \
- $zinc raise move; $zinc treset $curView"
-
- $zinc bind divider <1> "::testGraphics::SelectDivider $zinc"
- $zinc bind selector <1> "::testGraphics::ClickSelector $zinc"
- $zinc bind move <1> "::testGraphics::MobileStart $zinc %x %y"
- $zinc bind move <B1-Motion> "::testGraphics::MobileMove $zinc %x %y"
- $zinc bind move <ButtonRelease> "::testGraphics::MobileStop $zinc %x %y"
- $zinc bind pushBtn <1> "::testGraphics::PushButton $zinc"
- $zinc bind pushBtn <ButtonRelease> "::testGraphics::PullButton $zinc"
- $zinc bind poly <1> "::testGraphics::StartRotatePolygone $zinc %x %y"
- $zinc bind poly <B1-Motion> "::testGraphics::RotatePolygone $zinc %x %y"
- }
-
-
- proc SelectDivider {zinc {divName ""} {numPage ""}} {
- variable curView
- variable tabTable
- variable tabAnchor
-
- if { $divName eq "" } {
- foreach {divName numPage} [$zinc itemcget current -tags] break
- }
-
- $zinc itemconfigure $divName&&titre -color \#000099
- $zinc itemconfigure $divName&&intercalaire -linewidth 1.4
- $zinc itemconfigure $divName&&page -visible 0
-
- set divGroup [$zinc group $divName&&$numPage]
- $zinc raise $divGroup
- set 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" } {
- set anchors [TLGet $tabTable $tabAnchor]
- set names [lindex [TLGet $anchors -names] $numPage]
- set explain [lindex [TLGet $anchors -texts] $numPage]
- $zinc itemconfigure $divName&&fontname -text "$names\n\n$explain"
- $zinc raise $divName&&fontname
- }
- }
-
- proc ClickSelector {zinc {btnGroup ""} {value ""}} {
- variable tabTable
- variable tabAnchor
- variable tabAlign
-
- if { $btnGroup eq "" && $value eq "" } {
- set tags [$zinc itemcget current -tags]
- foreach {btnGroup value} $tags break
- }
-
- $zinc treset $btnGroup
- $zinc itemconfigure $btnGroup&&btntext -color \#444444
- $zinc itemconfigure $btnGroup&&$value&&btntext -color \#2222bb
- $zinc translate $btnGroup&&$value 0 1
-
- switch -- $value {
- n -
- e -
- s -
- w { set tabAnchor $value }
- left -
- center -
- right { set tabAlign $value }
- }
-
- set table [TLGet $tabTable $tabAnchor]
- set numPages [TLGet $table -numpages]
- foreach {shapes tCoords} [zincGraphics::TabBoxCoords {{-240 -160} {240 100}} \
- -radius 8 -tabwidth 72 -tabheight 28 \
- -numpages $numPages -anchor $tabAnchor \
- -alignment $tabAlign -overlap 3] break
-
- for {set index 7} {$index >= 0} {incr index -1} {
- set divGroup [$zinc group div2&&$index&&intercalaire]
- $zinc itemconfigure $divGroup -visible [expr $index < $numPages]
-
- if { $index >= $numPages } {
- $zinc lower $divGroup
- } else {
- $zinc raise $divGroup
- $zinc itemconfigure div2&&$index -visible 1
- $zinc coords div2&&$index&&intercalaire [lindex $shapes $index]
- $zinc coords div2&&$index&&titre [lindex $tCoords $index]
- $zinc itemconfigure div2&&$index&&titre \
- -text [lindex [TLGet $table -titles] $index]
- }
- }
-
- SelectDivider $zinc div2 0
- }
-
-
- #-----------------------------------------------------------------------------------
- # Callback sur evt CLICK des items tagés pushBtn
- #-----------------------------------------------------------------------------------
- proc PushButton {zinc} {
- set tag [lindex [$zinc itemcget current -tags] 0]
- $zinc scale $tag .975 .975
- $zinc translate $tag 1 1
- }
-
- #-----------------------------------------------------------------------------------
- # Callback sur evt RELEASE des items tagés pushBtn
- #-----------------------------------------------------------------------------------
- proc PullButton {zinc} {
- set tag [lindex [$zinc itemcget current -tags] 0]
- $zinc treset $tag
- }
-
- #-----------------------------------------------------------------------------------
- # Callback sur evt CATCH des items tagés poly
- # armement de rotation des polygones
- #-----------------------------------------------------------------------------------
- proc StartRotatePolygone {zinc x y} {
- variable previousAngle
-
- foreach {xRef yRef} [$zinc transform [$zinc group current] 1 {0 0}] break
- set previousAngle [zincGraphics::LineAngle [list $x $y] [list $xRef $yRef]]
- }
-
- #-----------------------------------------------------------------------------------
- # Callback sur evt MOTION des items tagés poly
- # rotation des polygones
- #-----------------------------------------------------------------------------------
- proc RotatePolygone {zinc x y} {
- variable previousAngle
-
- set tag [lindex [$zinc itemcget current -tags] 0]
- foreach {xRef yRef} [$zinc transform [$zinc group current] 1 {0 0}] break
- set newAngle [zincGraphics::LineAngle [list $x $y] [list $xRef $yRef]]
-
- $zinc rotate $tag [zincGraphics::deg2rad [expr $newAngle - $previousAngle]]
- set previousAngle $newAngle
- }
-
- #-----------------------------------------------------------------------------------
- # Callback CATCH de sélection (début de déplacement) des items tagés move
- #-----------------------------------------------------------------------------------
- proc MobileStart {zinc x y} {
- variable dx
- variable dy
-
- set dx [expr 0 - $x]
- set dy [expr 0 - $y]
- $zinc raise current
- }
-
- #-----------------------------------------------------------------------------------
- # Callback MOVE de déplacement des items tagés move
- #-----------------------------------------------------------------------------------
- proc MobileMove {zinc x y} {
- variable dx
- variable dy
-
- $zinc translate current [expr $x + $dx] [expr $y + $dy]
- set dx [expr 0 - $x]
- set dy [expr 0 - $y]
- }
-
- #-----------------------------------------------------------------------------------
- # Callback RELEASE de relaché (fin de déplacement) des items tagés move
- #-----------------------------------------------------------------------------------
- proc MobileStop {zinc x y} {
- MobileMove $zinc $x $y
- }
-
- proc ViewTranslate {zinc way} {
- variable curView
-
- set dx 0
- set dy 0
- switch -- $way {
- left {set dx -10}
- up {set dy -10}
- right {set dx 10}
- down {set dy 10}
- }
- $zinc translate $curView $dx $dy
- }
-
- proc ViewZoom {zinc key} {
- variable curView
- variable zoomFactor
-
- set scaleRatio [expr {($key == "up") ? (1 + $zoomFactor) : (1 - $zoomFactor)}]
- $zinc scale $curView $scaleRatio $scaleRatio
- }
-
- proc ViewRotate {zinc way} {
- variable curView
- variable rotateAngle
-
- set deltaAngle $rotateAngle
-
- if { $way eq "cw" } {
- set deltaAngle [expr $deltaAngle * -1]
- }
-
- $zinc rotate $curView $deltaAngle
- }
-
- proc lreverse {l} {
- set res {}
- set i [llength $l]
- while {$i} {
- lappend res [lindex $l [incr i -1]]
- }
- return $res
- }
-
-
- proc BuildTabBox {zinc parentGroup style name} {
- variable tabTable
- variable font9b
-
- set params [TLGet $style -params]
- set tags [TLGet $params -tags]
- set coords [TLGet $style -coords]
- set table [TLGet $tabTable [TLGet $style -anchor]]
- set titles [TLGet $style -tabtitles]
- set cmd [linsert $style 0 zincGraphics::TabBoxCoords $coords]
- foreach {shapes tCoords invert} [eval $cmd] break
-
- set k -1
- if { $invert } {
- set k [llength $shapes]
- }
- foreach shape [lreverse $shapes] {
- incr k [expr $invert ? -1 : 1]
- set group [$zinc add group $parentGroup]
- set cmd [linsert $params 0 $zinc add curve $group $shape]
- lappend cmd -tags [list [lindex $tags 0] $k [lindex $tags 1] intercalaire]
- eval $cmd
- set page [TLGet $style -page {}]
- if { $page ne "" } {
- zincGraphics::BuildZincItem $zinc $group $page
- }
-
- set tIndex [expr $invert ? $k : ([llength $shapes] - $k - 1)]
- if { [llength $titles] } {
- set titlTags [list [lindex $tags 0] $k [lindex $tags 1] titre]
- $zinc add text $group -position [lindex $tCoords $tIndex] \
- -text [lindex $titles $tIndex] -font $font9b -alignment center \
- -anchor center -color \#000099 -priority 200 -tags $titlTags
- }
-
- # exemple fonte
- if { $tIndex == 0 } {
- $zinc add text $parentGroup -position {-165 -105} \
- -text [lindex [TLGet $table -names] 0] -font $font9b \
- -alignment left -anchor nw -color \#000000 -priority 500 \
- -width 350 -tags [list [lindex $tags 0] fontname]
- }
- }
-
- SelectDivider $zinc [lindex $tags 0] $k
- }
-
-
- # initialise les gradients nommés
- zincGraphics::SetGradients $zinc $gradSet
-
- # création de la vue principale
- variable tgroup [$zinc add group 1]
- $zinc coords $tgroup {350 240}
-
- # consigne globale
- $zinc add text 1 -position {50 470} -font $font9b -color \#555555 -spacing 2 \
- -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"
-
- # Création des pages d'exemples
- foreach {shapes tCoords} [zincGraphics::TabBoxCoords {{-315 -210} {315 210}} \
- -numpages 7 -overlap 2 -radius 8 \
- -tabheight 26 -tabwidth {92 100 82 82 82 120 80}] break
- # to find some images (used as textures) needed by this demo
- variable imagePath [file join [demosPath] images]
- variable texture [image create photo -file [file join $imagePath paper.gif]]
- # création des items zinc correspondants
- variable i 0
- variable pageNames {Rectangle Hippodrome Polygone Polyline PathLine MultiContours TabBox}
- variable pageGroups {}
- foreach shape $shapes {
- set divGroup [$zinc add group $tgroup]
-
- # création de l'intercalaire
- set divider [$zinc add curve $divGroup $shape -closed 1 \
- -priority 10 -linewidth 1 -linecolor \#000000 \
- -filled 1 -tile $texture -tags [list div1 $i divider intercalaire]]
-
- # groupe page clippé
- set page [$zinc add group $divGroup -priority 100 -tags [list div1 $i page]]
- set clip [$zinc add rectangle $page {{-300 -170} {300 195}} -linewidth 1 \
- -linecolor \#000099 -filled 1 -fillcolor {#000000;4}]
- $zinc itemconfigure $page -clip $clip
-
- set pGroup [$zinc add group $page -tags [list div1 $i content]]
- lappend pageGroups $pGroup
-
- # titre de l'intercalaire
- $zinc add text $divGroup -position [lindex $tCoords $i] \
- -text [lindex $pageNames $i] \
- -font $font9b -alignment center \
- -anchor center -color \#000099 \
- -priority 200 -tags [list div1 $i divider titre]
-
- incr i
- }
-
- # # création du contenu des pages
- foreach pageName $pageNames pGroup $pageGroups {
- set pageStyle [TLGet $pagesConf $pageName]
- if { $pageStyle ne "" } {
- foreach {itemName itemStyle} $pageStyle {
- if { [TLGet $itemStyle -itemtype] eq "tabbox" } {
- BuildTabBox $zinc $pGroup $itemStyle $itemName
- } else {
- if { [TLGet $itemStyle -itemtype] eq "group" } {
- set subGroup [zincGraphics::BuildZincItem $zinc $pGroup $itemStyle {} $itemName]
- foreach {name style} [TLGet $itemStyle -items] {
- zincGraphics::BuildZincItem $zinc $subGroup $style {} $name
- }
-
- if { [llength [TLGet $itemStyle -repeat]] != 0 } {
- set num [TLGet [TLGet $itemStyle -repeat] -num]
- foreach {dx dy} [TLGet [TLGet $itemStyle -repeat] -dxy] break
- for {set j 1} {$j < $num} {incr j} {
- set clone [$zinc clone $subGroup]
- $zinc translate $clone [expr $dx*$j] [expr $dy*$j]
- set items [$zinc find withtag ".$clone*"]
- foreach item $items {
- set tags [$zinc itemcget $item -tags]
- if { [llength $tags] } {
- foreach {name type} $tags break
- $zinc itemconfigure $item -tags [list $name$j $type]
- }
- }
- }
- }
- } else {
- if { $itemName eq "consigne" } {
- set group [$zinc group $pGroup]
- } else {
- set group $pGroup
- }
- zincGraphics::BuildZincItem $zinc $group $itemStyle {} $itemName
- }
- }
- }
- }
- }
-
- ClickSelector $zinc sel1 n
- ClickSelector $zinc sel2 left
- SelectDivider $zinc div1 0
- SetBindings
-}
diff --git a/demos/textInput.tcl b/demos/textInput.tcl
deleted file mode 100644
index 31da1c5..0000000
--- a/demos/textInput.tcl
+++ /dev/null
@@ -1,80 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval textInputDemo {
- #
- # We need the text input support
- package require zincText
-
-
- variable w .textInput
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc textInput Demonstration"
- wm iconname $w textInput
-
- variable defaultfont [font create -family Helvetica -size 16 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- ###########################################
- # Text zone
- #######################
- ####################
-
- grid [text $w.text -relief sunken -borderwidth 2 -height 5] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end {This demo demonstrates the use of the zincText package.
- This module is designed for facilitating text input.
- It works on text items or on fields of items such as
- tracks, waypoints or tabulars.}
-
-
- ###########################################
- # Zinc
- ##########################################
- grid [zinc $w.zinc -width 500 -height 300 -font $defaultfont -borderwidth 0] \
- -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- #
- # Activate text input support from zincText
- zn_TextBindings $w.zinc
-
- ### creating a tabular with 3 fields 2 of them being editable
- variable labelformat1 {130x100 x130x20+0+0 x130x20+0+20 x130x20+0+40}
-
- variable x 120
- variable y 6
- variable track [$w.zinc add track 1 3 -position "$x $y" -speedvector {40 10} -labeldistance 30 -labelformat $labelformat1 -tags text]
-
- # moving the track to display past positions
- for {set i 0} {$i<=5} {incr i} {
- $w.zinc coords "$track" "[expr $x+$i*10] [expr $y+$i*2]"
- }
-
- $w.zinc itemconfigure $track 0 -border contour -text { editable} -sensitive 0
-
- $w.zinc itemconfigure $track 1 -border contour -text editable -sensitive 1
-
- $w.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
- $w.zinc add text 1 -position {220 160} -text "this text is not editable \nbecause it is not sensitive" -sensitive 0 -tags text
-
-
- # creating an editable text item
- $w.zinc add text 1 -position {50 230} -text {this text IS editable} -sensitive 1 -tags text
-}
diff --git a/demos/tiger.tcl b/demos/tiger.tcl
deleted file mode 100644
index 3baef6e..0000000
--- a/demos/tiger.tcl
+++ /dev/null
@@ -1,605 +0,0 @@
-###
-####### 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 zinc) was
-### done by Daniel Etienne! Thx!
-###
-### It has been subsequently ported to Tcl by P.Lecoanet for testing
-### purposes.
-###
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval tigerDemo {
- variable w .tiger
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc tiger (Generated from SVG) Demonstration"
- wm iconname $w tiger
-
- variable defaultfont [font create -family Helvetica -size 16 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- ###########################################
- # Zinc
- ##########################################
- grid [zinc $w.zinc -width 600 -height 600 -font $defaultfont -borderwidth 0 -backcolor grey90 \
- -render 1] -row 0 -column 0 -columnspan 2 -sticky news
- # -reshape 1 -fullreshape 1
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 0 -weight 2
-
- variable topGroup [$w.zinc add group 1]
-
- variable text {
- Drag-Button 1 for moving the tiger,
- Drag-Button 2 for zooming the tiger,
- }
-
- #variable clip [$w.zinc add curve 1 { {0 150} {150 0} {470 20} {580 200}
- # {600 300} {500 560} {50 550} {10 450} {100 480}} -closed 1 -visible 0]
- #$w.zinc itemconfigure 1 -clip $clip
-
- $w.zinc add text 1 -position {51 521} -anchor w \
- -priority 20 -text $text -color white
-
- $w.zinc add text 1 -position {50 520} -anchor w \
- -priority 20 -text $text -color black
-
- $w.zinc add group $topGroup -tags __svg__1 -priority 10
- $w.zinc add group __svg__1 -tags __g__2 -priority 10
- $w.zinc add curve __g__2 {{-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}} -tags __path__3 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__4 -priority 10
- $w.zinc add curve __g__4 {{-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}} -tags __path__5 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__6 -priority 10
- $w.zinc add curve __g__6 {{-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}} -tags __path__7 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__8 -priority 10
- $w.zinc add curve __g__8 {{-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}} -tags __path__9 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__10 -priority 10
- $w.zinc add curve __g__10 {{-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}} -tags __path__11 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__12 -priority 10
- $w.zinc add curve __g__12 {{-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}} -tags __path__13 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__14 -priority 10
- $w.zinc add curve __g__14 {{-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}} -tags __path__15 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__16 -priority 10
- $w.zinc add curve __g__16 {{-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}} -tags __path__17 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__18 -priority 10
- $w.zinc add curve __g__18 {{-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}} -tags __path__19 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__20 -priority 10
- $w.zinc add curve __g__20 {{-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}} -tags __path__21 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__22 -priority 10
- $w.zinc add curve __g__22 {{-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}} -tags __path__23 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__24 -priority 10
- $w.zinc add curve __g__24 {{-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}} -tags __path__25 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.172
- $w.zinc add group __svg__1 -tags __g__26 -priority 10
- $w.zinc add curve __g__26 {{-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}} -tags __path__27 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1
- $w.zinc add group __svg__1 -tags __g__28 -priority 10
- $w.zinc add curve __g__28 {{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}} -tags __path__29 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#cc7226 -filled 1
- $w.zinc add group __svg__1 -tags __g__30 -priority 10
- $w.zinc add curve __g__30 {{-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}} -tags __path__31 -priority 10 -filled 1 -closed 1 -fillcolor \#cc7226 -filled 1 -linecolor \#cc7226
- $w.zinc add group __svg__1 -tags __g__32 -priority 10
- $w.zinc add curve __g__32 {{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}} -tags __path__33 -priority 10 -filled 1 -closed 1 -fillcolor \#e87f3a -filled 1 -linecolor \#e87f3a
- $w.zinc add group __svg__1 -tags __g__34 -priority 10
- $w.zinc add curve __g__34 {{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}} -tags __path__35 -priority 10 -filled 1 -closed 1 -fillcolor \#ea8c4d -filled 1 -linecolor \#ea8c4d
- $w.zinc add group __svg__1 -tags __g__36 -priority 10
- $w.zinc add curve __g__36 {{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}} -tags __path__37 -priority 10 -filled 1 -closed 1 -fillcolor \#ec9961 -filled 1 -linecolor \#ec9961
- $w.zinc add group __svg__1 -tags __g__38 -priority 10
- $w.zinc add curve __g__38 {{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}} -tags __path__39 -priority 10 -filled 1 -closed 1 -fillcolor \#eea575 -filled 1 -linecolor \#eea575
- $w.zinc add group __svg__1 -tags __g__40 -priority 10
- $w.zinc add curve __g__40 {{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}} -tags __path__41 -priority 10 -filled 1 -closed 1 -fillcolor \#f1b288 -filled 1 -linecolor \#f1b288
- $w.zinc add group __svg__1 -tags __g__42 -priority 10
- $w.zinc add curve __g__42 {{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}} -tags __path__43 -priority 10 -filled 1 -closed 1 -fillcolor \#f3bf9c -filled 1 -linecolor \#f3bf9c
- $w.zinc add group __svg__1 -tags __g__44 -priority 10
- $w.zinc add curve __g__44 {{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}} -tags __path__45 -priority 10 -filled 1 -closed 1 -fillcolor \#f5ccb0 -filled 1 -linecolor \#f5ccb0
- $w.zinc add group __svg__1 -tags __g__46 -priority 10
- $w.zinc add curve __g__46 {{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}} -tags __path__47 -priority 10 -filled 1 -closed 1 -fillcolor \#f8d8c4 -filled 1 -linecolor \#f8d8c4
- $w.zinc add group __svg__1 -tags __g__48 -priority 10
- $w.zinc add curve __g__48 {{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}} -tags __path__49 -priority 10 -filled 1 -closed 1 -fillcolor \#fae5d7 -filled 1 -linecolor \#fae5d7
- $w.zinc add group __svg__1 -tags __g__50 -priority 10
- $w.zinc add curve __g__50 {{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}} -tags __path__51 -priority 10 -filled 1 -closed 1 -fillcolor \#fcf2eb -filled 1 -linecolor \#fcf2eb
- $w.zinc add group __svg__1 -tags __g__52 -priority 10
- $w.zinc add curve __g__52 {{-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}} -tags __path__53 -priority 10 -filled 1 -closed 1 -fillcolor \#ffffff -filled 1 -linecolor \#ffffff
- $w.zinc add group __svg__1 -tags __g__54 -priority 10
- $w.zinc add curve __g__54 {{-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}} -tags __path__55 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__56 -priority 10
- $w.zinc add curve __g__56 {{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}} -tags __path__57 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__58 -priority 10
- $w.zinc add curve __g__58 {{-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}} -tags __path__59 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__60 -priority 10
- $w.zinc add curve __g__60 {{-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}} -tags __path__61 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__62 -priority 10
- $w.zinc add curve __g__62 {{-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}} -tags __path__63 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__64 -priority 10
- $w.zinc add curve __g__64 {{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}} -tags __path__65 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__66 -priority 10
- $w.zinc add curve __g__66 {{-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}} -tags __path__67 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__68 -priority 10
- $w.zinc add curve __g__68 {{-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}} -tags __path__69 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__70 -priority 10
- $w.zinc add curve __g__70 {{-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}} -tags __path__71 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__72 -priority 10
- $w.zinc add curve __g__72 {{-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}} -tags __path__73 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__74 -priority 10
- $w.zinc add curve __g__74 {{-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}} -tags __path__75 -priority 10 -filled 1 -closed 1 -fillcolor \#e5668c -filled 1 -linecolor \#e5668c
- $w.zinc add group __svg__1 -tags __g__76 -priority 10
- $w.zinc add curve __g__76 {{-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}} -tags __path__77 -priority 10 -filled 1 -closed 1 -fillcolor \#b23259 -filled 1 -linecolor \#b23259
- $w.zinc add group __svg__1 -tags __g__78 -priority 10
- $w.zinc add curve __g__78 {{-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}} -tags __path__79 -priority 10 -filled 1 -closed 1 -fillcolor \#a5264c -filled 1 -linecolor \#a5264c
- $w.zinc add group __svg__1 -tags __g__80 -priority 10
- $w.zinc add curve __g__80 {{-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}} -tags __path__81 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ff727f -filled 1
- $w.zinc add group __svg__1 -tags __g__82 -priority 10
- $w.zinc add curve __g__82 {{-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}} -tags __path__83 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__84 -priority 10
- $w.zinc add curve __g__84 {{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}} -tags __path__85 -priority 10 -filled 1 -closed 1 -fillcolor \#cc3f4c -filled 1 -linecolor \#cc3f4c
- $w.zinc add group __svg__1 -tags __g__86 -priority 10
- $w.zinc add curve __g__86 {{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}} -tags __path__87 -priority 10 -filled 1 -closed 0 -linecolor \#a51926 -linewidth 2
- $w.zinc add group __svg__1 -tags __g__88 -priority 10
- $w.zinc add curve __g__88 {{-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}} -tags __path__89 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__90 -priority 10
- $w.zinc add curve __g__90 {{-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}} -tags __path__91 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__92 -priority 10
- $w.zinc add curve __g__92 {{-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}} -tags __path__93 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__94 -priority 10
- $w.zinc add curve __g__94 {{-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}} -tags __path__95 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__96 -priority 10
- $w.zinc add curve __g__96 {{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}} -tags __path__97 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__98 -priority 10
- $w.zinc add curve __g__98 {{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}} -tags __path__99 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__100 -priority 10
- $w.zinc add curve __g__100 {{-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}} -tags __path__101 -priority 10 -filled 1 -closed 0 -linecolor \#a5264c -linewidth 2
- $w.zinc add group __svg__1 -tags __g__102 -priority 10
- $w.zinc add curve __g__102 {{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}} -tags __path__103 -priority 10 -filled 1 -closed 0 -linecolor \#a5264c -linewidth 2
- $w.zinc add group __svg__1 -tags __g__104 -priority 10
- $w.zinc add curve __g__104 {{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}} -tags __path__105 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__106 -priority 10
- $w.zinc add curve __g__106 {{47 244.801} {47 244.801 c} {50.6 242.401 c} {53 243.601}} -tags __path__107 -priority 10 -filled 1 -closed 0 -linecolor \#a5264c -linewidth 2
- $w.zinc add group __svg__1 -tags __g__108 -priority 10
- $w.zinc add curve __g__108 {{53.5 228.401} {53.5 228.401 c} {56.4 223.501 c} {61.2 222.701}} -tags __path__109 -priority 10 -filled 1 -closed 0 -linecolor \#a5264c -linewidth 2
- $w.zinc add group __svg__1 -tags __g__110 -priority 10
- $w.zinc add curve __g__110 {{-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}} -tags __path__111 -priority 10 -filled 1 -closed 1 -fillcolor \#b2b2b2 -filled 1 -linecolor \#b2b2b2
- $w.zinc add group __svg__1 -tags __g__112 -priority 10
- $w.zinc add curve __g__112 {{-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}} -tags __path__113 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__114 -priority 10
- $w.zinc add curve __g__114 {{-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}} -tags __path__115 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__116 -priority 10
- $w.zinc add curve __g__116 {{-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}} -tags __path__117 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__118 -priority 10
- $w.zinc add curve __g__118 {{-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}} -tags __path__119 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__120 -priority 10
- $w.zinc add curve __g__120 {{-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}} -tags __path__121 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__122 -priority 10
- $w.zinc add curve __g__122 {{-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}} -tags __path__123 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__124 -priority 10
- $w.zinc add curve __g__124 {{-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}} -tags __path__125 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__126 -priority 10
- $w.zinc add curve __g__126 {{-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}} -tags __path__127 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__128 -priority 10
- $w.zinc add curve __g__128 {{-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}} -tags __path__129 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffcc -filled 1 -linewidth 0.5
- $w.zinc add group __svg__1 -tags __g__130 -priority 10
- $w.zinc add curve __g__130 {{-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}} -tags __path__131 -priority 10 -filled 1 -closed 1 -fillcolor \#e5e5b2 -filled 1 -linecolor \#e5e5b2
- $w.zinc add group __svg__1 -tags __g__132 -priority 10
- $w.zinc add curve __g__132 {{-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}} -tags __path__133 -priority 10 -filled 1 -closed 1 -fillcolor \#e5e5b2 -filled 1 -linecolor \#e5e5b2
- $w.zinc add group __svg__1 -tags __g__134 -priority 10
- $w.zinc add curve __g__134 {{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}} -tags __path__135 -priority 10 -filled 1 -closed 1 -fillcolor \#cc7226 -filled 1 -linecolor \#cc7226
- $w.zinc add group __svg__1 -tags __g__136 -priority 10
- $w.zinc add curve __g__136 {{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}} -tags __path__137 -priority 10 -filled 1 -closed 1 -fillcolor \#ea8e51 -filled 1 -linecolor \#ea8e51
- $w.zinc add group __svg__1 -tags __g__138 -priority 10
- $w.zinc add curve __g__138 {{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}} -tags __path__139 -priority 10 -filled 1 -closed 1 -fillcolor \#efaa7c -filled 1 -linecolor \#efaa7c
- $w.zinc add group __svg__1 -tags __g__140 -priority 10
- $w.zinc add curve __g__140 {{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}} -tags __path__141 -priority 10 -filled 1 -closed 1 -fillcolor \#f4c6a8 -filled 1 -linecolor \#f4c6a8
- $w.zinc add group __svg__1 -tags __g__142 -priority 10
- $w.zinc add curve __g__142 {{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}} -tags __path__143 -priority 10 -filled 1 -closed 1 -fillcolor \#f9e2d3 -filled 1 -linecolor \#f9e2d3
- $w.zinc add group __svg__1 -tags __g__144 -priority 10
- $w.zinc add curve __g__144 {{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}} -tags __path__145 -priority 10 -filled 1 -closed 1 -fillcolor \#ffffff -filled 1 -linecolor \#ffffff
- $w.zinc add group __svg__1 -tags __g__146 -priority 10
- $w.zinc add curve __g__146 {{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}} -tags __path__147 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__148 -priority 10
- $w.zinc add curve __g__148 {{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}} -tags __path__149 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__150 -priority 10
- $w.zinc add curve __g__150 {{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}} -tags __path__151 -priority 10 -filled 1 -closed 1 -fillcolor \#99cc32 -filled 1 -linecolor \#99cc32
- $w.zinc add group __svg__1 -tags __g__152 -priority 10
- $w.zinc add curve __g__152 {{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}} -tags __path__153 -priority 10 -filled 1 -closed 1 -fillcolor \#659900 -filled 1 -linecolor \#659900
- $w.zinc add group __svg__1 -tags __g__154 -priority 10
- $w.zinc add curve __g__154 {{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}} -tags __path__155 -priority 10 -filled 1 -closed 1 -fillcolor \#ffffff -filled 1 -linecolor \#ffffff
- $w.zinc add group __svg__1 -tags __g__156 -priority 10
- $w.zinc add curve __g__156 {{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}} -tags __path__157 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__158 -priority 10
- $w.zinc add curve __g__158 {{-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}} -tags __path__159 -priority 10 -filled 1 -closed 1 -fillcolor \#cc7226 -filled 1 -linecolor \#cc7226
- $w.zinc add group __svg__1 -tags __g__160 -priority 10
- $w.zinc add curve __g__160 {{-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}} -tags __path__161 -priority 10 -filled 1 -closed 1 -fillcolor \#ffffff -filled 1 -linecolor \#ffffff
- $w.zinc add group __svg__1 -tags __g__162 -priority 10
- $w.zinc add curve __g__162 {{-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}} -tags __path__163 -priority 10 -filled 1 -closed 1 -fillcolor \#eb955c -filled 1 -linecolor \#eb955c
- $w.zinc add group __svg__1 -tags __g__164 -priority 10
- $w.zinc add curve __g__164 {{-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}} -tags __path__165 -priority 10 -filled 1 -closed 1 -fillcolor \#f2b892 -filled 1 -linecolor \#f2b892
- $w.zinc add group __svg__1 -tags __g__166 -priority 10
- $w.zinc add curve __g__166 {{-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}} -tags __path__167 -priority 10 -filled 1 -closed 1 -fillcolor \#f8dcc8 -filled 1 -linecolor \#f8dcc8
- $w.zinc add group __svg__1 -tags __g__168 -priority 10
- $w.zinc add curve __g__168 {{-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}} -tags __path__169 -priority 10 -filled 1 -closed 1 -fillcolor \#ffffff -filled 1 -linecolor \#ffffff
- $w.zinc add group __svg__1 -tags __g__170 -priority 10
- $w.zinc add curve __g__170 {{-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}} -tags __path__171 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__172 -priority 10
- $w.zinc add curve __g__172 {{-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}} -tags __path__173 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__174 -priority 10
- $w.zinc add curve __g__174 {{-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}} -tags __path__175 -priority 10 -filled 1 -closed 1 -fillcolor \#99cc32 -filled 1 -linecolor \#99cc32
- $w.zinc add group __svg__1 -tags __g__176 -priority 10
- $w.zinc add curve __g__176 {{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}} -tags __path__177 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__178 -priority 10
- $w.zinc add curve __g__178 {{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}} -tags __path__179 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__180 -priority 10
- $w.zinc add curve __g__180 {{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}} -tags __path__181 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__182 -priority 10
- $w.zinc add curve __g__182 {{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}} -tags __path__183 -priority 10 -filled 1 -closed 1 -fillcolor \#323232 -filled 1 -linecolor \#323232
- $w.zinc add group __svg__1 -tags __g__184 -priority 10
- $w.zinc add curve __g__184 {{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}} -tags __path__185 -priority 10 -filled 1 -closed 1 -fillcolor \#666666 -filled 1 -linecolor \#666666
- $w.zinc add group __svg__1 -tags __g__186 -priority 10
- $w.zinc add curve __g__186 {{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}} -tags __path__187 -priority 10 -filled 1 -closed 1 -fillcolor \#999999 -filled 1 -linecolor \#999999
- $w.zinc add group __svg__1 -tags __g__188 -priority 10
- $w.zinc add curve __g__188 {{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}} -tags __path__189 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__190 -priority 10
- $w.zinc add curve __g__190 {{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}} -tags __path__191 -priority 10 -filled 1 -closed 1 -fillcolor \#ffffff -filled 1 -linecolor \#ffffff
- $w.zinc add group __svg__1 -tags __g__192 -priority 10
- $w.zinc add curve __g__192 {{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}} -tags __path__193 -priority 10 -filled 1 -closed 1 -fillcolor \#992600 -filled 1 -linecolor \#992600
- $w.zinc add group __svg__1 -tags __g__194 -priority 10
- $w.zinc add curve __g__194 {{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}} -tags __path__195 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__196 -priority 10
- $w.zinc add curve __g__196 {{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}} -tags __path__197 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__198 -priority 10
- $w.zinc add curve __g__198 {{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}} -tags __path__199 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__200 -priority 10
- $w.zinc add curve __g__200 {{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}} -tags __path__201 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__202 -priority 10
- $w.zinc add curve __g__202 {{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}} -tags __path__203 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__204 -priority 10
- $w.zinc add curve __g__204 {{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}} -tags __path__205 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__206 -priority 10
- $w.zinc add curve __g__206 {{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}} -tags __path__207 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__208 -priority 10
- $w.zinc add curve __g__208 {{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}} -tags __path__209 -priority 10 -filled 1 -closed 1 -fillcolor \#cc7226 -filled 1 -linecolor \#cc7226
- $w.zinc add group __svg__1 -tags __g__210 -priority 10
- $w.zinc add curve __g__210 {{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}} -tags __path__211 -priority 10 -filled 1 -closed 1 -fillcolor \#cc7226 -filled 1 -linecolor \#cc7226
- $w.zinc add group __svg__1 -tags __g__212 -priority 10
- $w.zinc add curve __g__212 {{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}} -tags __path__213 -priority 10 -filled 1 -closed 1 -fillcolor \#cc7226 -filled 1 -linecolor \#cc7226
- $w.zinc add group __svg__1 -tags __g__214 -priority 10
- $w.zinc add curve __g__214 {{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}} -tags __path__215 -priority 10 -filled 1 -closed 1 -fillcolor \#cc7226 -filled 1 -linecolor \#cc7226
- $w.zinc add group __svg__1 -tags __g__216 -priority 10
- $w.zinc add curve __g__216 {{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}} -tags __path__217 -priority 10 -filled 1 -closed 1 -fillcolor \#cc7226 -filled 1 -linecolor \#cc7226
- $w.zinc add group __svg__1 -tags __g__218 -priority 10
- $w.zinc add curve __g__218 {{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}} -tags __path__219 -priority 10 -filled 1 -closed 1 -fillcolor \#cc7226 -filled 1 -linecolor \#cc7226
- $w.zinc add group __svg__1 -tags __g__220 -priority 10
- $w.zinc add curve __g__220 {{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}} -tags __path__221 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__230 -priority 10
- $w.zinc add curve __g__230 {{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}} -tags __path__231 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__232 -priority 10
- $w.zinc add curve __g__232 {{-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}} -tags __path__233 -priority 10 -filled 1 -closed 1 -fillcolor \#4c0000 -filled 1 -linecolor \#4c0000
- $w.zinc add group __svg__1 -tags __g__234 -priority 10
- $w.zinc add curve __g__234 {{-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}} -tags __path__235 -priority 10 -filled 1 -closed 1 -fillcolor \#99cc32 -filled 1 -linecolor \#99cc32
- $w.zinc add group __svg__1 -tags __g__236 -priority 10
- $w.zinc add curve __g__236 {{-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}} -tags __path__237 -priority 10 -filled 1 -closed 1 -fillcolor \#659900 -filled 1 -linecolor \#659900
- $w.zinc add group __svg__1 -tags __g__238 -priority 10
- $w.zinc add curve __g__238 {{-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}} -tags __path__239 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__240 -priority 10
- $w.zinc add curve __g__240 {{-65.4 9}} -tags __path__241 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__242 -priority 10
- $w.zinc add curve __g__242 {{-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}} -tags __path__243 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__244 -priority 10
- $w.zinc add curve __g__244 {{-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}} -tags __path__245 -priority 10 -filled 1 -closed 1 -fillcolor \#e59999 -filled 1 -linecolor \#e59999
- $w.zinc add group __svg__1 -tags __g__246 -priority 10
- $w.zinc add curve __g__246 {{-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}} -tags __path__247 -priority 10 -filled 1 -closed 1 -fillcolor \#b26565 -filled 1 -linecolor \#b26565
- $w.zinc add group __svg__1 -tags __g__248 -priority 10
- $w.zinc add curve __g__248 {{-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}} -tags __path__249 -priority 10 -filled 1 -closed 1 -fillcolor \#992600 -filled 1 -linecolor \#992600
- $w.zinc add group __svg__1 -tags __g__250 -priority 10
- $w.zinc add curve __g__250 {{-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}} -tags __path__251 -priority 10 -filled 1 -closed 1 -fillcolor \#ffffff -filled 1 -linecolor \#ffffff
- $w.zinc add group __svg__1 -tags __g__252 -priority 10
- $w.zinc add curve __g__252 {{-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}} -tags __path__253 -priority 10 -filled 1 -closed 1 -fillcolor \#992600 -filled 1 -linecolor \#992600
- $w.zinc add group __svg__1 -tags __g__254 -priority 10
- $w.zinc add curve __g__254 {{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}} -tags __path__255 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__256 -priority 10
- $w.zinc add curve __g__256 {{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}} -tags __path__257 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__258 -priority 10
- $w.zinc add curve __g__258 {{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}} -tags __path__259 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__260 -priority 10
- $w.zinc add curve __g__260 {{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}} -tags __path__261 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__262 -priority 10
- $w.zinc add curve __g__262 {{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}} -tags __path__263 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__264 -priority 10
- $w.zinc add curve __g__264 {{-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}} -tags __path__265 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__266 -priority 10
- $w.zinc add curve __g__266 {{-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}} -tags __path__267 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__268 -priority 10
- $w.zinc add curve __g__268 {{-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}} -tags __path__269 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__270 -priority 10
- $w.zinc add curve __g__270 {{-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}} -tags __path__271 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__272 -priority 10
- $w.zinc add curve __g__272 {{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}} -tags __path__273 -priority 10 -filled 1 -closed 1 -fillcolor \#ffffff -filled 1 -linecolor \#ffffff
- $w.zinc add group __svg__1 -tags __g__274 -priority 10
- $w.zinc add curve __g__274 {{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}} -tags __path__275 -priority 10 -filled 1 -closed 1 -fillcolor \#ffffff -filled 1 -linecolor \#ffffff
- $w.zinc add group __svg__1 -tags __g__276 -priority 10
- $w.zinc add curve __g__276 {{-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}} -tags __path__277 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__278 -priority 10
- $w.zinc add curve __g__278 {{-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}} -tags __path__279 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__280 -priority 10
- $w.zinc add curve __g__280 {{-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}} -tags __path__281 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__282 -priority 10
- $w.zinc add curve __g__282 {{-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}} -tags __path__283 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__284 -priority 10
- $w.zinc add curve __g__284 {{-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}} -tags __path__285 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__286 -priority 10
- $w.zinc add curve __g__286 {{-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}} -tags __path__287 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__288 -priority 10
- $w.zinc add curve __g__288 {{-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}} -tags __path__289 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__290 -priority 10
- $w.zinc add curve __g__290 {{-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}} -tags __path__291 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__292 -priority 10
- $w.zinc add curve __g__292 {{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}} -tags __path__293 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__294 -priority 10
- $w.zinc add curve __g__294 {{-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}} -tags __path__295 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__296 -priority 10
- $w.zinc add curve __g__296 {{-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}} -tags __path__297 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__298 -priority 10
- $w.zinc add curve __g__298 {{-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}} -tags __path__299 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__300 -priority 10
- $w.zinc add curve __g__300 {{-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}} -tags __path__301 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__302 -priority 10
- $w.zinc add curve __g__302 {{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}} -tags __path__303 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__304 -priority 10
- $w.zinc add curve __g__304 {{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}} -tags __path__305 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__306 -priority 10
- $w.zinc add curve __g__306 {{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}} -tags __path__307 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__308 -priority 10
- $w.zinc add curve __g__308 {{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}} -tags __path__309 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__310 -priority 10
- $w.zinc add curve __g__310 {{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}} -tags __path__311 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__312 -priority 10
- $w.zinc add curve __g__312 {{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}} -tags __path__313 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__314 -priority 10
- $w.zinc add curve __g__314 {{-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}} -tags __path__315 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__316 -priority 10
- $w.zinc add curve __g__316 {{-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}} -tags __path__317 -priority 10 -filled 1 -closed 1 -fillcolor \#992600 -filled 1 -linecolor \#992600
- $w.zinc add group __svg__1 -tags __g__318 -priority 10
- $w.zinc add curve __g__318 {{-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}} -tags __path__319 -priority 10 -filled 1 -closed 1 -fillcolor \#992600 -filled 1 -linecolor \#992600
- $w.zinc add group __svg__1 -tags __g__320 -priority 10
- $w.zinc add curve __g__320 {{-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}} -tags __path__321 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__322 -priority 10
- $w.zinc add curve __g__322 {{-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}} -tags __path__323 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__324 -priority 10
- $w.zinc add curve __g__324 {{-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}} -tags __path__325 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__326 -priority 10
- $w.zinc add curve __g__326 {{-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}} -tags __path__327 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__328 -priority 10
- $w.zinc add curve __g__328 {{-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}} -tags __path__329 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__330 -priority 10
- $w.zinc add curve __g__330 {{-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}} -tags __path__331 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__332 -priority 10
- $w.zinc add curve __g__332 {{-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}} -tags __path__333 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__334 -priority 10
- $w.zinc add curve __g__334 {{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}} -tags __path__335 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__336 -priority 10
- $w.zinc add curve __g__336 {{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}} -tags __path__337 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__338 -priority 10
- $w.zinc add curve __g__338 {{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}} -tags __path__339 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__340 -priority 10
- $w.zinc add curve __g__340 {{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}} -tags __path__341 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__342 -priority 10
- $w.zinc add curve __g__342 {{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}} -tags __path__343 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__344 -priority 10
- $w.zinc add curve __g__344 {{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}} -tags __path__345 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__346 -priority 10
- $w.zinc add curve __g__346 {{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}} -tags __path__347 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__348 -priority 10
- $w.zinc add curve __g__348 {{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}} -tags __path__349 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__350 -priority 10
- $w.zinc add curve __g__350 {{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}} -tags __path__351 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__352 -priority 10
- $w.zinc add curve __g__352 {{-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}} -tags __path__353 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__354 -priority 10
- $w.zinc add curve __g__354 {{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}} -tags __path__355 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__356 -priority 10
- $w.zinc add curve __g__356 {{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}} -tags __path__357 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__358 -priority 10
- $w.zinc add curve __g__358 {{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}} -tags __path__359 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__360 -priority 10
- $w.zinc add curve __g__360 {{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}} -tags __path__361 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__362 -priority 10
- $w.zinc add curve __g__362 {{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}} -tags __path__363 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__364 -priority 10
- $w.zinc add curve __g__364 {{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}} -tags __path__365 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__366 -priority 10
- $w.zinc add curve __g__366 {{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}} -tags __path__367 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__368 -priority 10
- $w.zinc add curve __g__368 {{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}} -tags __path__369 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__370 -priority 10
- $w.zinc add curve __g__370 {{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}} -tags __path__371 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__372 -priority 10
- $w.zinc add curve __g__372 {{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}} -tags __path__373 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__374 -priority 10
- $w.zinc add curve __g__374 {{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}} -tags __path__375 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__376 -priority 10
- $w.zinc add curve __g__376 {{-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}} -tags __path__377 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__378 -priority 10
- $w.zinc add curve __g__378 {{-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}} -tags __path__379 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__380 -priority 10
- $w.zinc add curve __g__380 {{-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}} -tags __path__381 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__382 -priority 10
- $w.zinc add curve __g__382 {{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}} -tags __path__383 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__384 -priority 10
- $w.zinc add curve __g__384 {{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}} -tags __path__385 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__386 -priority 10
- $w.zinc add curve __g__386 {{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}} -tags __path__387 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__388 -priority 10
- $w.zinc add curve __g__388 {{-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}} -tags __path__389 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__390 -priority 10
- $w.zinc add curve __g__390 {{-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}} -tags __path__391 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__392 -priority 10
- $w.zinc add curve __g__392 {{-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}} -tags __path__393 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__394 -priority 10
- $w.zinc add curve __g__394 {{-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}} -tags __path__395 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__396 -priority 10
- $w.zinc add curve __g__396 {{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}} -tags __path__397 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__398 -priority 10
- $w.zinc add curve __g__398 {{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}} -tags __path__399 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__400 -priority 10
- $w.zinc add curve __g__400 {{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}} -tags __path__401 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__402 -priority 10
- $w.zinc add curve __g__402 {{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}} -tags __path__403 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__404 -priority 10
- $w.zinc add curve __g__404 {{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}} -tags __path__405 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__406 -priority 10
- $w.zinc add curve __g__406 {{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}} -tags __path__407 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__408 -priority 10
- $w.zinc add curve __g__408 {{-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}} -tags __path__409 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__410 -priority 10
- $w.zinc add curve __g__410 {{-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}} -tags __path__411 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__412 -priority 10
- $w.zinc add curve __g__412 {{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}} -tags __path__413 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__414 -priority 10
- $w.zinc add curve __g__414 {{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}} -tags __path__415 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__416 -priority 10
- $w.zinc add curve __g__416 {{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}} -tags __path__417 -priority 10 -filled 1 -closed 1 -linecolor \#000000 -fillcolor \#ffffff -filled 1 -linewidth 0.1
- $w.zinc add group __svg__1 -tags __g__418 -priority 10
- $w.zinc add curve __g__418 {{-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}} -tags __path__419 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__420 -priority 10
- $w.zinc add curve __g__420 {{-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}} -tags __path__421 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__422 -priority 10
- $w.zinc add curve __g__422 {{-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}} -tags __path__423 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__424 -priority 10
- $w.zinc add curve __g__424 {{-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}} -tags __path__425 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__426 -priority 10
- $w.zinc add curve __g__426 {{-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}} -tags __path__427 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__428 -priority 10
- $w.zinc add curve __g__428 {{-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}} -tags __path__429 -priority 10 -filled 1 -closed 1 -fillcolor \#000000 -filled 1 -linecolor \#000000
- $w.zinc add group __svg__1 -tags __g__430 -priority 10
- $w.zinc add curve __g__430 {{-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}} -tags __path__431 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__432 -priority 10
- $w.zinc add curve __g__432 {{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}} -tags __path__433 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__434 -priority 10
- $w.zinc add curve __g__434 {{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}} -tags __path__435 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__436 -priority 10
- $w.zinc add curve __g__436 {{-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}} -tags __path__437 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__438 -priority 10
- $w.zinc add curve __g__438 {{-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}} -tags __path__439 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__440 -priority 10
- $w.zinc add curve __g__440 {{-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}} -tags __path__441 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__442 -priority 10
- $w.zinc add curve __g__442 {{-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}} -tags __path__443 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__444 -priority 10
- $w.zinc add curve __g__444 {{-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}} -tags __path__445 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__446 -priority 10
- $w.zinc add curve __g__446 {{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}} -tags __path__447 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__448 -priority 10
- $w.zinc add curve __g__448 {{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}} -tags __path__449 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__450 -priority 10
- $w.zinc add curve __g__450 {{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}} -tags __path__451 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__452 -priority 10
- $w.zinc add curve __g__452 {{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}} -tags __path__453 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__454 -priority 10
- $w.zinc add curve __g__454 {{-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}} -tags __path__455 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__456 -priority 10
- $w.zinc add curve __g__456 {{-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}} -tags __path__457 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__458 -priority 10
- $w.zinc add curve __g__458 {{-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}} -tags __path__459 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__460 -priority 10
- $w.zinc add curve __g__460 {{-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}} -tags __path__461 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__462 -priority 10
- $w.zinc add curve __g__462 {{-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}} -tags __path__463 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__464 -priority 10
- $w.zinc add curve __g__464 {{-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}} -tags __path__465 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__466 -priority 10
- $w.zinc add curve __g__466 {{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}} -tags __path__467 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__468 -priority 10
- $w.zinc add curve __g__468 {{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}} -tags __path__469 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__470 -priority 10
- $w.zinc add curve __g__470 {{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}} -tags __path__471 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
- $w.zinc add group __svg__1 -tags __g__472 -priority 10
- $w.zinc add curve __g__472 {{301.5 191.5} {284 179.5} {284 179.5 c} {303 196.5 c} {303.5 200.5} {301.5 191.5}} -tags __path__473 -priority 10 -filled 1 -closed 1 -fillcolor \#cccccc -filled 1 -linecolor \#cccccc
-
-
- ### translating ojects for making them all visibles
-
- $w.zinc translate $topGroup 200 150
-
-
- ##### bindings for moving rotating scaling the items
-
- bind $w.zinc <ButtonPress-1> "::tigerDemo::press motion %x %y"
- bind $w.zinc <ButtonRelease-1> ::tigerDemo::release
- bind $w.zinc <ButtonPress-2> "::tigerDemo::press zoom %x %y"
- bind $w.zinc <ButtonRelease-2> ::tigerDemo::release
- bind $w.zinc <ButtonPress-3> "::tigerDemo::press mouseRotate %x %y"
- bind $w.zinc <ButtonRelease-3> ::tigerDemo::release
-
-
- variable curX 0
- variable curY 0
- variable curAngle 0
-
- proc press {action x y} {
- variable w
- variable curAngle
- variable curX
- variable curY
-
- set curX $x
- set curY $y
- set curAngle [expr atan2($y, $x)]
- bind $w.zinc <Motion> "::tigerDemo::$action %x %y"
- }
-
- proc motion {x y} {
- variable w
- variable topGroup
- variable curX
- variable curY
-
- foreach {x1 y1 x2 y2} [$w.zinc transform $topGroup \
- [list $x $y $curX $curY]] break
- $w.zinc translate $topGroup [expr $x1 - $x2] [expr $y1 - $y2]
- set curX $x
- set curY $y
- }
-
- proc zoom {x y} {
- variable w
- variable curX
- variable curY
-
- if {$x > $curX} {
- set maxX $x
- } else {
- set maxX $curX
- }
- if {$y > $curY} {
- set maxY $y
- } else {
- set maxY $curY
- }
- if {($maxX == 0) || ($maxY == 0)} {
- return;
- }
- set sx [expr 1.0 + (double($x - $curX) / $maxX)]
- set sy [expr 1.0 + (double($y - $curY) / $maxY)]
- $w.zinc scale __svg__1 $sx $sx
- set curX $x
- set curY $y
- }
-
- proc mouseRotate {x y} {
- variable w
- variable curAngle
-
- set lAngle [expr atan2($y, $x)]
- $w.zinc rotate __svg__1 [expr $lAngle - $curAngle]
- set curAngle $lAngle
- }
-
- proc release {} {
- variable w
-
- bind $w.zinc <Motion> {}
- }
-}
diff --git a/demos/tkZincLogo.tcl b/demos/tkZincLogo.tcl
deleted file mode 100644
index 5317f36..0000000
--- a/demos/tkZincLogo.tcl
+++ /dev/null
@@ -1,168 +0,0 @@
-#
-# $Id$
-# this simple demo has been adapted by C. Mertz <mertz@cena.fr> from the original
-# work of JL. Vinot <vinot@cena.fr>
-# Ported to Tcl by P.Lecoanet
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval tkZincLogo {
- #
- # We need the zincLogo support
- package require zincLogo
-
-
- variable w .tkZincLogo
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc logo Demonstration"
- wm iconname $w tkZincLogo
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
-
- ###########################################
- # Text zone
- #######################
- ####################
-
- grid [text $w.text -relief sunken -borderwidth 2 -height 7] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.text insert end {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.}
-
-
- ###########################################
- # Zinc
- ##########################################
- grid [ zinc $w.zinc -width 350 -height 250 -render 1 \
- -borderwidth 3 -relief sunken] -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- variable topGroup [$w.zinc add group 1]
-
- variable logo [zincLogo::create $w.zinc $topGroup 800 40 70 0.6 0.6]
-
- #
- # Controls for the window transform.
- #
- bind $w.zinc <ButtonPress-1> "::tkZincLogo::press motion %x %y"
- bind $w.zinc <ButtonRelease-1> ::tkZincLogo::release
- bind $w.zinc <ButtonPress-2> "::tkZincLogo::press zoom %x %y"
- bind $w.zinc <ButtonRelease-2> ::tkZincLogo::release
- bind $w.zinc <ButtonPress-3> "::tkZincLogo::press mouseRotate %x %y"
- bind $w.zinc <ButtonRelease-3> ::tkZincLogo::release
-
- #
- # Controls for alpha and gradient
- #
- bind $w.zinc <Shift-ButtonPress-1> "::tkZincLogo::press modifyAlpha %x %y"
- bind $w.zinc <Shift-ButtonRelease-1> ::tkZincLogo::release
- bind $w.zinc <Shift-ButtonPress-2> "::tkZincLogo::press modifyGradient %x %y"
- bind $w.zinc <Shift-ButtonRelease-2> ::tkZincLogo::release
-
-
- variable curX 0
- variable curY 0
- variable curAngle 0
-
- proc press {action x y} {
- variable w
- variable curAngle
- variable curX
- variable curY
-
- set curX $x
- set curY $y
- set curAngle [expr atan2($y, $x)]
- bind $w.zinc <Motion> "::tkZincLogo::$action %x %y"
- }
-
- proc motion {x y} {
- variable w
- variable topGroup
- variable curX
- variable curY
-
- foreach {x1 y1 x2 y2} [$w.zinc transform $topGroup \
- [list $x $y $curX $curY]] break
- $w.zinc translate $topGroup [expr $x1 - $x2] [expr $y1 - $y2]
- set curX $x
- set curY $y
- }
-
- proc zoom {x y} {
- variable w
- variable topGroup
- variable curX
- variable curY
-
- if {$x > $curX} {
- set maxX $x
- } else {
- set maxX $curX
- }
- if {$y > $curY} {
- set maxY $y
- } else {
- set maxY $curY
- }
- if {($maxX == 0) || ($maxY == 0)} {
- return;
- }
- set sx [expr 1.0 + (double($x - $curX) / $maxX)]
- set sy [expr 1.0 + (double($y - $curY) / $maxY)]
- $w.zinc scale $topGroup $sx $sx
-
- set curX $x
- set curY $y
- }
-
- proc mouseRotate {x y} {
- variable w
- variable curAngle
- variable logo
-
- set lAngle [expr atan2($y, $x)]
- $w.zinc rotate $logo [expr $lAngle - $curAngle]
- set curAngle $lAngle
- }
-
- proc release {} {
- variable w
-
- bind $w.zinc <Motion> {}
- }
-
- proc modifyAlpha {x y} {
- variable w
- variable topGroup
-
- set xRate [expr double($x) / [$w.zinc cget -width]]
- set xRate [expr ($xRate < 0) ? 0 : ($xRate > 1) ? 1 : $xRate]
- set alpha [expr int($xRate * 100)]
-
- $w.zinc itemconfigure $topGroup -alpha $alpha
- }
-
- proc modifyGradient {x y} {
- variable w
-
- set yRate [expr double($y) / [$w.zinc cget -height]]
- set yRate [expr ($yRate < 0) ? 0 : ($yRate > 1) ? 1 : $yRate]
- set gradPercent [expr int($yRate * 100)]
-
- $w.zinc itemconfigure letters -fillcolor "=axial 270|#ffffff;100 0 28|#66848c;100 $gradPercent|#7192aa;100 100"
- }
-}
diff --git a/demos/transforms.tcl b/demos/transforms.tcl
deleted file mode 100644
index 679d583..0000000
--- a/demos/transforms.tcl
+++ /dev/null
@@ -1,506 +0,0 @@
-# $Id$
-# This simple demo has been developped by P. Lecoanet <lecoanet@cena.fr>
-
-#
-# TODO:
-#
-# Add the building of missing items
-#
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval transforms {
- variable w .transforms
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Transformation Demonstration"
- wm iconname $w Transformation
-
- variable defaultfont [font create -family Helvetica -size 14 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 3 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 3 -column 1 -pady 10
-
-
- ###########################################
- # Text zone
- ###########################################
- grid [text $w.text -relief sunken -borderwidth 2 -setgrid true -height 12] \
- -row 0 -column 0 -columnspan 2 -sticky ew
-
- $w.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 coordinates
- Drag Button 1 on item/group axes, translate that item coordinates
- Home reset the transformation
- Shift-Home reset a group direct children transformations
- +/- scale the selected item up/down
- Ctrl-Left/Right rotate the selected item right/left
- Shift-Up/Down swap the selected item Y axis
- Shift-Left/Right swap the selected item X axis
- 4 arrows translate in the 4 directions
- Delete destroy the selected item}
- $w.text configure -state disabled
-
- ###########################################
- # Zinc
- ###########################################
- variable zincWidth 600
- variable zincHeight 500
-
- grid [zinc $w.zinc -width $zincWidth -height $zincHeight \
- -font $defaultfont -borderwidth 3 -relief sunken -takefocus 1 -render 0] \
- -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
- variable top 1
-
- variable inactiveAxisColor blue
- variable activeAxisColor red
- variable worldAxisColor \#a5a5a5
-
- variable composeRot 1
- variable composeScale 1
- variable drag 0
- variable itemType Rectangle
- variable currentItem 0
-
- image create photo logo -file [file join [demosPath] images zinc.gif]
-
- grid [frame $w.f] -row 2 -column 0 -columnspan 2 -sticky w
-
- tk_optionMenu $w.f.types itemType Rectangle Arc Curve Icon Tabular \
- Text Track Triangles WayPoint
- grid $w.f.types -row 0 -column 1 -sticky w
-
- button $w.f.add -text {Add item} -command "::transforms::addItem $w.zinc"
- grid $w.f.add -row 0 -column 2 -padx 10 -sticky ew
-
- button $w.f.addg -text {Add group} -command "::transforms::addGroup $w.zinc"
- grid $w.f.addg -row 0 -column 3 -padx 10 -sticky ew
-
- button $w.f.remove -text Remove -command "::transforms::removeItem $w.zinc"
- grid $w.f.remove -row 0 -column 4 -padx 10 -sticky ew
-
- checkbutton $w.f.cscale -text -composescale -command "::transforms::toggleComposeScale $w.zinc" \
- -variable ::transforms::composeScale
- grid $w.f.cscale -row 0 -column 6 -sticky w
-
- checkbutton $w.f.crot -text -composesrotation -command "::transforms::toggleComposeRot $w.zinc" \
- -variable ::transforms::composeRot
- grid $w.f.crot -row 1 -column 6 -sticky w
-
-
- variable world [$w.zinc add group $top]
- variable currentGroup $world
- $w.zinc add curve $top {0 0 80 0} -linewidth 3 \
- -linecolor $worldAxisColor -lastend {6 8 3} -tags axis:$world
- $w.zinc add curve $top {0 0 0 80} -linewidth 3 \
- -linecolor $worldAxisColor -lastend {6 8 3} -tags axis:$world
- $w.zinc add rectangle $top {-2 -2 2 2} -filled 1 \
- -fillcolor $worldAxisColor -linecolor $worldAxisColor \
- -linewidth 3 -tags axis:$world
- $w.zinc add text $top -text "This is the origin\nof the world" \
- -anchor s -color $worldAxisColor -alignment center \
- -tags [list "axis:$world" text]
- $w.zinc lower axis:$world
-
- bind $w.zinc <1> {::transforms::mouseAdd %W Item %x %y}
- bind $w.zinc <2> {::transforms::mouseAdd %W Group %x %y}
- bind $w.zinc <Up> {::transforms::moveUp %W}
- bind $w.zinc <Left> {::transforms::moveLeft %W}
- bind $w.zinc <Right> {::transforms::moveRight %W}
- bind $w.zinc <Down> {::transforms::moveDown %W}
- bind $w.zinc <minus> {::transforms::scaleDown %W}
- bind $w.zinc <KP_Subtract> {::transforms::scaleDown %W}
- bind $w.zinc <plus> {::transforms::scaleUp %W}
- bind $w.zinc <KP_Add> {::transforms::scaleUp %W}
- bind $w.zinc <Home> {::transforms::reset %W}
- bind $w.zinc <Shift-Home> {::transforms::resetChildren %W}
- bind $w.zinc <Control-Left> {::transforms::rotateLeft %W}
- bind $w.zinc <Control-Right> {::transforms::rotateRight %W}
- bind $w.zinc <Shift-Up> {::transforms::swapAxis %W y}
- bind $w.zinc <Shift-Down> {::transforms::swapAxis %W y}
- bind $w.zinc <Shift-Left> {::transforms::swapAxis %W x}
- bind $w.zinc <Shift-Right> {::transforms::swapAxis %W x}
- bind $w.zinc <Delete> {::transforms::removeItem %W}
-
- bind $w.zinc <Configure> {::transforms::resize %W %w %h}
-
- focus $w.zinc
- tk_focusFollowsMouse
-
-
- proc resize {z width height} {
- variable world
-
- set x [expr $width/2]
- set y [expr $height/2]
-
- $z treset $world
- $z treset axis:$world
- $z translate $world $x $y
- $z translate axis:$world $x $y
- }
-
- proc swapAxis {z axis} {
- variable currentItem
-
- set sx 1
- set sy 1
- if { $axis eq "x" } {
- set sx -1
- } elseif { $axis eq "y" } {
- set sy -1
- }
- if {$currentItem != 0} {
- $z scale $currentItem $sx $sy
- $z scale axisgrp:$currentItem $sx $sy
- }
- }
-
- proc toggleComposeRot {z} {
- variable currentItem
- variable composeRot
-
- if {$currentItem != 0} {
- $z itemconfigure $currentItem -composerotation $composeRot
- $z itemconfigure axisgrp:$currentItem -composerotation $composeRot
- }
- }
-
- proc toggleComposeScale {z} {
- variable currentItem
- variable composeScale
-
- if {$currentItem != 0} {
- $z itemconfigure $currentItem -composescale $composeScale
- $z itemconfigure axisgrp:$currentItem -composescale $composeScale
- }
- }
-
- proc removeItem {z} {
- variable currentGroup
- variable currentItem
- variable world
-
- if {$currentItem != 0} {
- $z remove $currentItem axisgrp:$currentItem
- if {$currentItem == $currentGroup} {
- set currentGroup $world
- }
- set currentItem 0
- set composeScale 1
- set composeRot 1
- }
- }
-
- proc dragItem {z x y} {
- variable drag
- variable currentItem
-
- set drag 1
- if {$currentItem == 0} {
- return
- }
-
- set group [$z group $currentItem]
- foreach {x y} [$z transform $group [list $x $y]] break
-
- $z treset $currentItem
- $z treset axisgrp:$currentItem
- $z translate $currentItem $x $y
- $z translate axisgrp:$currentItem $x $y
- }
-
- proc select {z} {
- foreach t [$z gettags current] {
- if {[regexp {^axis:(\d+)} $t m item]} {
- changeItem $z $item
- }
- }
- }
-
- proc changeItem {z item} {
- variable currentItem
- variable currentGroup
- variable composeRot
- variable composeScale
- variable drag
- variable activeAxisColor
- variable inactiveAxisColor
-
- if {($currentItem != 0) && !$drag} {
- $z itemconfigure axis:$currentItem&&!text \
- -linecolor $inactiveAxisColor -fillcolor $inactiveAxisColor
- }
- if {($currentItem == 0) || ($item != $currentItem)} {
- $z itemconfigure axis:$item&&!text \
- -linecolor $activeAxisColor -fillcolor $activeAxisColor -linewidth 3
- set currentItem $item
- set composeRot [$z itemcget $currentItem -composerotation]
- $z itemconfigure axisgrp:$currentItem -composerotation $composeRot
- set composeScale [$z itemcget $currentItem -composescale]
- $z itemconfigure axisgrp:$currentItem -composescale $composeScale
- } elseif {!$drag} {
- set currentItem 0
- set composeRot 1
- set composeScale 1
- }
- }
-
- proc selectGroup {z} {
- foreach t [$z gettags current] {
- if {[regexp {^axis:(\d+)} $t m item]} {
- changeGroup $z $item
- return
- }
- }
- }
-
- proc changeGroup {z grp} {
- variable currentItem
- variable currentGroup
- variable world
-
- changeItem $z $grp
- if {$currentItem != 0} {
- set currentGroup $currentItem
- } else {
- set currentGroup $world
- }
- }
-
- proc reset {z } {
- variable currentItem
-
- if {$currentItem != 0} {
- $z treset $currentItem
- $z treset axisgrp:$currentItem
- }
- }
-
- proc resetChildren {z} {
- variable currentItem
-
- if {($currentItem != 0) && ([$z type $currentItem] == "group")} {
- $z addtag rt withtag .$currentItem.
- $z treset rt
- $z dtag rt rt
- }
- }
-
- proc moveUp {z} {
- move $z 0 20
- }
-
- proc moveDown {z} {
- move $z 0 -20
- }
-
- proc moveRight {z} {
- move $z 20 0
- }
-
- proc moveLeft {z} {
- move $z -20 0
- }
-
- proc move {z dx dy} {
- variable currentItem
-
- if {$currentItem != 0} {
- $z translate $currentItem $dx $dy
- $z translate axisgrp:$currentItem $dx $dy
- }
- }
-
- proc scaleUp {z} {
- scale $z 1.1 1.1
- }
-
- proc scaleDown {z} {
- scale $z 0.9 0.9
- }
-
- proc scale {z dx dy} {
- variable currentItem
-
- if {$currentItem != 0} {
- $z scale $currentItem $dx $dy
- $z scale axisgrp:$currentItem $dx $dy
- }
- }
-
- proc rotateLeft {z} {
- rotate $z [expr -3.14159/18]
- }
-
- proc rotateRight {z} {
- rotate $z [expr 3.14159/18]
- }
-
- proc rotate {z angle} {
- variable currentItem
-
- if {$currentItem != 0} {
- $z rotate $currentItem $angle
- $z rotate axisgrp:$currentItem $angle
- }
- }
-
- proc newRectangle {z} {
- variable currentGroup
-
- return [$z add rectangle $currentGroup {-15 -15 15 15} \
- -filled 1 -linewidth 0 -fillcolor tan]
- }
-
- proc newArc {z} {
- variable currentGroup
-
- return [$z add arc $currentGroup {-25 -15 25 15} \
- -filled 1 -linewidth 0 -fillcolor tan]
- }
-
- proc newCurve {z} {
- variable currentGroup
-
- return [$z add curve $currentGroup {-15 -15 -15 15 15 15 15 -15} \
- -filled 1 -linewidth 0 -fillcolor tan]
- }
-
- proc newText {z} {
- variable currentGroup
-
- set item [$z add text $currentGroup -anchor s]
- $z itemconfigure $item -text "Item id: $item"
- return $item;
- }
-
- proc newIcon {z} {
- variable currentGroup
-
- return [$z add icon $currentGroup -image logo -anchor center]
- }
-
- proc newTriangles {z} {
- variable currentGroup
-
- return [$z add triangles $currentGroup \
- {-25 15 -10 -15 5 15 20 -15 35 15 50 -30} \
- -colors {tan wheat tan wheat}]
- }
-
- proc newTrack {z} {
- variable currentGroup
-
- set labelformat {x80x50+0+0 a0a0^0^0 a0a0^0>1 a0a0>2>1 x30a0>3>1 a0a0^0>2}
-
- set item [$z add track $currentGroup 6 -labelformat $labelformat \
- -speedvector {30 -15} -markersize 20]
- $z itemconfigure $item 0 -filled 0 -bordercolor DarkGreen -border contour
- $z itemconfigure $item 1 -filled 1 -backcolor gray60 -text AFR6128
- $z itemconfigure $item 2 -filled 0 -backcolor gray65 -text 390
- $z itemconfigure $item 3 -filled 0 -backcolor gray65 -text /
- $z itemconfigure $item 4 -filled 0 -backcolor gray65 -text 350
- $z itemconfigure $item 5 -filled 0 -backcolor gray65 -text TUR
-
- return $item;
- }
-
- proc newWayPoint {z} {
- variable currentGroup
-
- set labelformat {a0a0+0+0 a0a0>0^1}
-
- set item [$z add waypoint $currentGroup 2 -labelformat $labelformat]
- $z itemconfigure $item 0 -filled 1 -backcolor DarkGreen -text TUR
- $z itemconfigure $item 1 -text >>>
-
- return $item;
- }
-
- proc newTabular {z} {
- variable currentGroup
-
- set labelformat {f700f600+0+0 f700a0^0^0 f700a0^0>1 \
- f700a0^0>2 f700a0^0>3 f700a0^0>4 f700a0^0>5}
-
- set item [$z add tabular $currentGroup 7 -labelformat $labelformat]
- $z itemconfigure $item 0 -filled 1 -border contour \
- -bordercolor black -backcolor gray60
- $z itemconfigure $item 1 -alignment center -text AFR6128
- $z itemconfigure $item 2 -alignment center -text 390
- $z itemconfigure $item 3 -alignment center -text 370
- $z itemconfigure $item 4 -alignment center -text 350
- $z itemconfigure $item 5 -alignment center -text 330
- $z itemconfigure $item 6 -alignment center -text TUR
-
- return $item;
- }
-
- proc addAxes {z item length command inFront} {
- variable currentGroup
-
- set axesGroup [$z add group $currentGroup -tags axisgrp:$item]
- $z add curve $axesGroup [list 0 0 $length 0] -linewidth 3 \
- -lastend {6 8 3} -tags axis:$item
- $z add curve $axesGroup [list 0 0 0 $length] -linewidth 3 \
- -lastend {6 8 3} -tags axis:$item
- $z add rectangle $axesGroup {-3 -3 3 3} -filled 1 \
- -linewidth 0 -composescale 0 -tags axis:$item
- if {$inFront} {
- $z raise $item $axesGroup
- }
- $z bind axis:$item <B1-Motion> {::transforms::dragItem %W %x %y}
- $z bind axis:$item <ButtonRelease-1> "::transforms::$command %W; set drag 0"
- }
-
- proc addItem {z} {
- variable itemType
-
- set length 25
- set itemOnTop 0
-
- set item [eval "new$itemType $z"]
- if {($itemType == "Track") || ($itemType == "WayPoint")} {
- set itemOnTop 1
- }
-
- addAxes $z $item 25 select $itemOnTop
- changeItem $z $item
- }
-
- proc addGroup {z} {
- variable currentGroup
-
- set item [$z add group $currentGroup]
-
- addAxes $z $item 80 selectGroup 1
- changeGroup $z $item
- }
-
- proc mouseAdd {z itemOrGroup x y} {
- variable currentGroup
- variable currentItem
-
- if {[llength [$z find withtag current]] != 0} {
- return
- }
-
- foreach {x y} [$z transform $currentGroup [list $x $y]] break
-
- eval "add$itemOrGroup $z"
-
- $z translate $currentItem $x $y
- $z translate axisgrp:$currentItem $x $y
- }
-}
-
diff --git a/demos/triangles.tcl b/demos/triangles.tcl
deleted file mode 100644
index 7326f32..0000000
--- a/demos/triangles.tcl
+++ /dev/null
@@ -1,48 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr and N. Banoun banoun@cena.fr
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval trianglesDemo {
- variable w .triangles
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Triangles Demonstration"
- wm iconname $w Triangles
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- variable defaultfont [font create -family Helvetica -size 16 -weight normal]
-
- grid [zinc $w.zinc -width 700 -height 300 -font $defaultfont -render 1 -borderwidth 3 -relief sunken] \
- -row 1 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 1 -weight 2
-
-
- # 6 equilateral triangles around a point
- $w.zinc add text 1 -position {40 10} -text "Triangles item without transparency"
-
- variable x0 200
- variable y0 150
- variable coords [list "$x0 $y0"]
- for {set i 0} {$i<=6} {incr i} {
- set angle [expr $i * 6.28/6]
- lappend coords "[expr $x0 + 100 * cos($angle)] [expr $y0 - 100 * sin ($angle)]"
- }
-
- set tr1 [$w.zinc add triangles 1 $coords -fan 1 -colors {white yellow red magenta blue cyan green yellow} -visible 1]
-
-
- $w.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
- set tr2 [$w.zinc clone $tr1]
- $w.zinc translate $tr2 300 0
- $w.zinc itemconfigure $tr2 -colors {white;50 yellow;50 red;50 magenta;50 blue;50 cyan;50 green;50 yellow;50}
-}
diff --git a/demos/windowContours.tcl b/demos/windowContours.tcl
deleted file mode 100644
index 7b6c263..0000000
--- a/demos/windowContours.tcl
+++ /dev/null
@@ -1,92 +0,0 @@
-# these simple samples have been developped by C. Mertz mertz@cena.fr in perl
-# tcl version by Jean-Paul Imbert imbert@cena.fr
-
-if {![info exists zincDemo]} {
- error "This script should be run from the zinc-widget demo."
-}
-
-namespace eval windowContours {
- variable w .windowContours
- catch {destroy $w}
- toplevel $w
- wm title $w "Zinc Contours Demonstration"
- wm iconname $w Contours
-
- variable defaultfont [font create -family Helvetica -size 20 -weight normal]
-
- grid [button $w.dismiss -text Dismiss -command "destroy $w"] -row 2 -column 0 -pady 10
- grid [button $w.code -text "See Code" -command "showCode $w"] -row 2 -column 1 -pady 10
-
- # Creating the zinc widget
- grid [zinc $w.zinc -width 600 -height 500 -font 9x15 -borderwidth 3 \
- -relief sunken] -row 0 -column 0 -columnspan 2 -sticky news
- grid columnconfigure $w 0 -weight 1
- grid columnconfigure $w 1 -weight 1
- grid rowconfigure $w 0 -weight 2
-
- # The explanation displayed when running this demo
- $w.zinc add text 1 -position {10 10} -text "These windows are simply rectangles holed by 4 smaller\nrectangles. The text appears behind the window glasses.\nYou can drag text or windows" -font 10x20
-
-
- # Text in background
- variable backtext [$w.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"]
-
- variable window [$w.zinc add curve 1 {100 100 300 100 300 400 100 400} -closed 1 \
- -visible 1 -filled 1 -fillcolor grey66]
-
-
- variable aGlass [$w.zinc add rectangle 1 {120 120 190 240}]
- $w.zinc contour $window add +1 $aGlass
-
- $w.zinc translate $aGlass 90 0
- $w.zinc contour $window add +1 $aGlass
-
- $w.zinc translate $aGlass 0 140
- $w.zinc contour $window add +1 $aGlass
-
- $w.zinc translate $aGlass -90 0
- $w.zinc contour $window add +1 $aGlass
-
-
- # deleting $aGlass which is no more usefull
- $w.zinc remove $aGlass
-
- # cloning $window
- variable window2 [$w.zinc clone $window]
-
- # changing its background moving it and scaling it!
- $w.zinc itemconfigure $window2 -fillcolor grey50
- $w.zinc translate $window2 30 50
- $w.zinc scale $window 0.8 0.8
-
-
- # adding drag and drop callback to the two windows and backtext
- foreach item "$window $window2 $backtext" {
- # Some bindings for dragging the items
- $w.zinc bind $item <1> "::windowContours::itemStartDrag $item %x %y"
- $w.zinc bind $item <B1-Motion> "::windowContours::itemDrag $item %x %y"
- }
-
- # callback for starting a drag
- variable xOrig ""
- variable yOrig ""
-
- proc itemStartDrag {item x y} {
- variable xOrig
- variable yOrig
- set xOrig $x
- set yOrig $y
- }
-
- # Callback for moving an item
- proc itemDrag {item x y} {
- variable xOrig
- variable yOrig
- variable w
- $w.zinc translate $item [expr $x-$xOrig] [expr $y-$yOrig];
- set xOrig $x;
- set yOrig $y;
- }
-}
diff --git a/demos/zinc-widget b/demos/zinc-widget
deleted file mode 100644
index 9132771..0000000
--- a/demos/zinc-widget
+++ /dev/null
@@ -1,331 +0,0 @@
-#!/bin/sh
-# the next line restarts using wish \
- exec wish "$0" "$@"
-
-#
-# Locate the zinc top level directory.
-#
-set zincRoot [file join [file dirname [info script]] ..]
-
-#
-# And adjust the paths accordingly.
-#
-lappend auto_path $zincRoot
-set zinc_library $zincRoot
-
-package require Tkzinc 3.2
-set zincVersion [lindex [zinc] 0]
-
-eval destroy [winfo child .]
-wm title . "Zinc Widget Demonstration"
-set zincDemo 1
-
-set font {Helvetica 14}
-
-menu .menuBar -tearoff 0
-.menuBar add cascade -menu .menuBar.file -label File -underline 0
-menu .menuBar.file -tearoff 0
-
-.menuBar.file add command -label "About..." -command "aboutBox" \
- -underline 0 -accelerator "<F1>"
-.menuBar.file add sep
-.menuBar.file add command -label Quit -command exit -underline 0 \
- -accelerator Meta-Q
-. configure -menu .menuBar
-bind . <F1> aboutBox
-
-frame .statusBar
-label .statusBar.lab -text " " -relief sunken -bd 1 \
- -font -*-Helvetica-Medium-R-Normal--*-120-*-*-*-*-*-* -anchor w
-label .statusBar.foo -width 8 -relief sunken -bd 1 \
- -font -*-Helvetica-Medium-R-Normal--*-120-*-*-*-*-*-* -anchor w
-pack .statusBar.lab -side left -padx 2 -expand yes -fill both
-pack .statusBar.foo -side left -padx 2
-pack .statusBar -side bottom -fill x -pady 2
-
-frame .textFrame
-scrollbar .s -orient vertical -command {.t yview} -highlightthickness 0 \
- -takefocus 1
-pack .s -in .textFrame -side right -fill y
-text .t -yscrollcommand {.s set} -wrap word -width 60 -height 30 -font $font \
- -setgrid 1 -highlightthickness 0 -padx 4 -pady 2 -takefocus 0
-pack .t -in .textFrame -expand y -fill both -padx 1
-pack .textFrame -expand yes -fill both
-
-# Create a bunch of tags to use in the text widget, such as those for
-# section titles and demo descriptions. Also define the bindings for
-# tags.
-
-.t tag configure title -font {Helvetica 18 bold}
-
-# We put some "space" characters to the left and right of each demo description
-# so that the descriptions are highlighted only when the mouse cursor
-# is right over them (but not when the cursor is to their left or right)
-#
-.t tag configure demospace -lmargin1 1c -lmargin2 1c
-
-
-if {[winfo depth .] == 1} {
- .t tag configure demo -lmargin1 1c -lmargin2 1c -underline 1
- .t tag configure visited -lmargin1 1c -lmargin2 1c \
- -underline 1
- .t tag configure hot -background black -foreground white
-} else {
- .t tag configure demo -lmargin1 1c -lmargin2 1c \
- -foreground blue -underline 1
- .t tag configure visited -lmargin1 1c -lmargin2 1c \
- -foreground #303080 -underline 1
- .t tag configure hot -foreground red -underline 1
-}
-.t tag bind demo <ButtonRelease-1> {
- invoke [.t index {@%x,%y}]
-}
-set lastLine ""
-.t tag bind demo <Enter> {
- set lastLine [.t index {@%x,%y linestart}]
- .t tag add hot "$lastLine +1 chars" "$lastLine lineend -1 chars"
- .t config -cursor hand2
- showStatus [.t index {@%x,%y}]
-}
-.t tag bind demo <Leave> {
- .t tag remove hot 1.0 end
- .t config -cursor xterm
- .statusBar.lab config -text ""
-}
-.t tag bind demo <Motion> {
- set newLine [.t index {@%x,%y linestart}]
- if {[string compare $newLine $lastLine] != 0} {
- .t tag remove hot 1.0 end
- set lastLine $newLine
-
- set tags [.t tag names {@%x,%y}]
- set i [lsearch -glob $tags demo-*]
- if {$i >= 0} {
- .t tag add hot "$lastLine +1 chars" "$lastLine lineend -1 chars"
- }
- }
- showStatus [.t index {@%x,%y}]
-}
-
-# Create the text for the text widget.
-
-.t insert end "Zinc/Tk Widget Demonstrations $zincVersion\n" title
-.t insert end {
- This application provides a front end for several short scripts in Tcl/Tk that demonstrate what you can do with the TkZinc widget. Each of the numbered lines below describes a demonstration; you can click on it to invoke the demonstration. Once the demonstration window appears, you can click the "See Code" button to see the Tcl/Tk code that created the demonstration.
-}
-.t insert end "\n" {} "Small applications\n" title
-.t insert end "1. The famous tiger (better with openGL).\n" {demo demo-tiger}
-.t insert end "2. A toy radar display.\n" {demo demo-simpleRadar}
-.t insert end "3. ATC electronic strips demo (better with openGL).\n" {demo demo-groupsInAtcStrips}
-.t insert end "3. A magic lens simulation (need openGL).\n" {demo demo-magicLens}
-.t insert end "4. A demo of the Graphics tcl module (based on curves).\n" {demo demo-testGraphics}
-
-.t insert end "\n" {} "All Items\n" title
-.t insert end "1. Exemples of all items.\n" {demo demo-items}
-.t insert end "2. All items options (and their types).\n" {demo demo-allOptions}
-.t insert end "3. Examples of line style and line termination.\n" {demo demo-lines}
-.t insert end "4. Curves with multiple contours.\n" {demo demo-contours}
-.t insert end "7. Curves with cubic bezier control points.\n" {demo demo-curveBezier}
-.t insert end "8. Curves with multiple contours and various fillrule.\n" {demo demo-fillRule}
-
-.t insert end "\n" {} "Groups, Priority, Clipping and PathTags\n" title
-.t insert end "1. Groups and Priorities.\n" {demo demo-groupsPriority}
-.t insert end "2. Clipping examples (with simple or multiple contours).\n" {demo demo-clipping}
-.t insert end "3. Group atomicity.\n" {demo demo-atomicGroups}
-.t insert end "4. \"Windows\" with four glasses using curve with multiple contours.\n" {demo demo-windowContours}
-.t insert end "5. Pathtags demonstration.\n" {demo demo-pathTags}
-
-.t insert end "\n" {} "Transformation\n" title
-.t insert end "1. Transformation testbed.\n" {demo demo-transforms}
-
-.t insert end "\n" {} "Use of open GL\n" title
-.t insert end "1. The TkZinc Logo.\n" {demo demo-tkZincLogo}
-.t insert end "2. Applying transformations to an icon.\n" {demo demo-iconTransform}
-.t insert end "3. Using the alpha information from an image (Need Img ext.).\n" {demo demo-photoAlpha}
-.t insert end "4. Axial color variation on the X axis.\n" {demo demo-colorX}
-.t insert end "5. Axial color variation on the Y axis.\n" {demo demo-colorY}
-.t insert end "6. Circular color variation.\n" {demo demo-colorCircular}
-.t insert end "7. The triangles item.\n" {demo demo-triangles}
-.t insert end "8. Relief testbed.\n" {demo demo-reliefs}
-
-.t insert end "\n" {} "ATC oriented features and items\n" title
-.t insert end "1. Examples of labelformat.\n" {demo demo-labelformat}
-.t insert end "2. Simple interaction on a track.\n" {demo demo-simpleInteractionTrack}
-.t insert end "3. Text input in a text item and a track item.\n" {demo demo-textInput}
-
-.t configure -state disabled
-focus .s
-
-# positionWindow --
-# This procedure is invoked by most of the demos to position a
-# new demo window.
-#
-# Arguments:
-# w - The name of the window to position.
-
-proc positionWindow w {
- wm geometry $w +300+300
-}
-
-# showVars --
-# Displays the values of one or more variables in a window, and
-# updates the display whenever any of the variables changes.
-#
-# Arguments:
-# w - Name of new window to create for display.
-# args - Any number of names of variables.
-
-proc showVars {w args} {
- catch {destroy $w}
- toplevel $w
- wm title $w "Variable values"
- label $w.title -text "Variable values:" -width 20 -anchor center \
- -font {Helvetica 18}
- pack $w.title -side top -fill x
- set len 1
- foreach i $args {
- if {[string length $i] > $len} {
- set len [string length $i]
- }
- }
- foreach i $args {
- frame $w.$i
- label $w.$i.name -text "$i: " -width [expr $len + 2] -anchor w
- label $w.$i.value -textvar $i -anchor w
- pack $w.$i.name -side left
- pack $w.$i.value -side left -expand 1 -fill x
- pack $w.$i -side top -anchor w -fill x
- }
- button $w.ok -text OK -command "destroy $w" -default active
- bind $w <Return> "tkButtonInvoke $w.ok"
- pack $w.ok -side bottom -pady 2
-}
-
-#
-# demosPath --
-# Return the path to the installed demo directory.
-
-proc demosPath {} {
- global zinc_library tcl_platform
-
- if { [lindex $tcl_platform(os) 0] eq "Windows" &&
- ! [file exists [file join $zinc_library pkgIndex.tcl]] } {
- return [file join $zinc_library demos Tkzinc]
- } {
- return [file join $zinc_library demos]
- }
-}
-
-# invoke --
-# This procedure is called when the user clicks on a demo description.
-# It is responsible for invoking the demonstration.
-#
-# Arguments:
-# index - The index of the character that the user clicked on.
-
-proc invoke index {
- set tags [.t tag names $index]
- set i [lsearch -glob $tags demo-*]
- if {$i < 0} {
- return
- }
- set cursor [.t cget -cursor]
- .t configure -cursor watch
- update
- set demo [string range [lindex $tags $i] 5 end]
- uplevel [list source [file join [demosPath] $demo.tcl]]
- update
- .t configure -cursor $cursor
-
- .t tag add visited "$index linestart +1 chars" "$index lineend -1 chars"
-}
-
-# showStatus --
-#
-# Show the name of the demo program in the status bar. This procedure
-# is called when the user moves the cursor over a demo description.
-#
-proc showStatus index {
- global zinc_library
- set tags [.t tag names $index]
- set i [lsearch -glob $tags demo-*]
- set cursor [.t cget -cursor]
- if {$i < 0} {
- .statusBar.lab config -text " "
- set newcursor xterm
- } else {
- set demo [string range [lindex $tags $i] 5 end]
- .statusBar.lab config -text "Run the \"$demo\" sample program"
- set newcursor hand2
- }
- if [string compare $cursor $newcursor] {
- .t config -cursor $newcursor
- }
-}
-
-
-# showCode --
-# This procedure creates a toplevel window that displays the code for
-# a demonstration and allows it to be edited and reinvoked.
-#
-# Arguments:
-# w - The name of the demonstration's window, which can be
-# used to derive the name of the file containing its code.
-
-proc showCode w {
- global zinc_library
- set file [string range $w 1 end].tcl
- if ![winfo exists .code] {
- toplevel .code
- frame .code.buttons
- pack .code.buttons -side bottom -fill x
- button .code.buttons.dismiss -text Dismiss \
- -default active -command "destroy .code"
- button .code.buttons.rerun -text "Rerun Demo" -command {
- eval [.code.text get 1.0 end]
- }
- pack .code.buttons.dismiss .code.buttons.rerun -side left \
- -expand 1 -pady 2
- frame .code.frame
- pack .code.frame -expand yes -fill both -padx 1 -pady 1
- text .code.text -height 40 -wrap word\
- -xscrollcommand ".code.xscroll set" \
- -yscrollcommand ".code.yscroll set" \
- -setgrid 1 -highlightthickness 0 -pady 2 -padx 3
- scrollbar .code.xscroll -command ".code.text xview" \
- -highlightthickness 0 -orient horizontal
- scrollbar .code.yscroll -command ".code.text yview" \
- -highlightthickness 0 -orient vertical
-
- grid .code.text -in .code.frame -padx 1 -pady 1 \
- -row 0 -column 0 -rowspan 1 -columnspan 1 -sticky news
- grid .code.yscroll -in .code.frame -padx 1 -pady 1 \
- -row 0 -column 1 -rowspan 1 -columnspan 1 -sticky news
- # grid .code.xscroll -in .code.frame -padx 1 -pady 1 \
- # -row 1 -column 0 -rowspan 1 -columnspan 1 -sticky news
- grid rowconfig .code.frame 0 -weight 1 -minsize 0
- grid columnconfig .code.frame 0 -weight 1 -minsize 0
- } else {
- wm deiconify .code
- raise .code
- }
- wm title .code "Demo code: [file join $zinc_library demos $file]"
- wm iconname .code $file
- set id [open [file join $zinc_library demos $file]]
- .code.text delete 1.0 end
- .code.text insert 1.0 [read $id]
- .code.text mark set insert 1.0
- close $id
-}
-
-# aboutBox --
-#
-# Pops up a message box with an "about" message
-#
-proc aboutBox {} {
- tk_messageBox -icon info -type ok -title "About Zinc Demo" -message \
- "Tkzinc widget demonstration\n\n\
-Copyright (c) 2003 CENA\n\n
-The demo framework \n
-Copyright (c) 1996-1997 Sun Microsystems, Inc."
- }
diff --git a/doc/.cvsignore b/doc/.cvsignore
deleted file mode 100644
index 2ad5cb1..0000000
--- a/doc/.cvsignore
+++ /dev/null
@@ -1,19 +0,0 @@
-*.log
-*.idx
-*.ilg
-*.ind
-refman
-*.aux
-*.dvi
-*.toc
-*.lot
-*.lof
-*.ps
-*.pdf
-*.tpt
-*.png
-*.gif
-_region_.tex
-*.out
-log
-*.eps
diff --git a/doc/alledges.png b/doc/alledges.png
deleted file mode 100644
index ed2e97e..0000000
--- a/doc/alledges.png
+++ /dev/null
Binary files differ
diff --git a/doc/allgradients.png b/doc/allgradients.png
deleted file mode 100644
index dc26472..0000000
--- a/doc/allgradients.png
+++ /dev/null
Binary files differ
diff --git a/doc/alllineshapes.png b/doc/alllineshapes.png
deleted file mode 100644
index d1ea9c9..0000000
--- a/doc/alllineshapes.png
+++ /dev/null
Binary files differ
diff --git a/doc/allreliefs.png b/doc/allreliefs.png
deleted file mode 100644
index b3fe223..0000000
--- a/doc/allreliefs.png
+++ /dev/null
Binary files differ
diff --git a/doc/alphastip.png b/doc/alphastip.png
deleted file mode 100644
index c1ba78a..0000000
--- a/doc/alphastip.png
+++ /dev/null
Binary files differ
diff --git a/doc/atcsymb.png b/doc/atcsymb.png
deleted file mode 100644
index 73bae01..0000000
--- a/doc/atcsymb.png
+++ /dev/null
Binary files differ
diff --git a/doc/fillrule.png b/doc/fillrule.png
deleted file mode 100644
index bf84865..0000000
--- a/doc/fillrule.png
+++ /dev/null
Binary files differ
diff --git a/doc/refman.tex b/doc/refman.tex
deleted file mode 100644
index ea242d0..0000000
--- a/doc/refman.tex
+++ /dev/null
@@ -1,4914 +0,0 @@
-\documentclass[11pt,twoside,a4paper]{book}
-
-%----------------------------------------------------------------------
-% $Revision$
-
-%
-% TODO
-%
-% Relire et reprendre l'item Track et compléter les attributs
-% Même chose pour triangles
-% Vérifier que les couleurs sont bien décrites comme des gradients
-% Les reliefs sont calculés sur le linecolor/bordercolor et non
-% sur le fillcolor comme avant
-% Ecrire les quelques descriptions d'item qui manquent.
-% Mettre quelques images: au moins une par item, une pour chaque relief,
-% une pour chaque type de gradient.
-%
-%
-
-\newif\ifpdf
- \ifx\pdfoutput\undefined
- \pdffalse % we are not running PDFLaTeX
- \else
- \pdfoutput=1 % we are running PDFLaTeX
- \pdftrue
- \fi
-
-\ifpdf
- \usepackage[pdftex,
- colorlinks=true,
- urlcolor=rltblue,
- anchorcolor=rltbrightblue,
- filecolor=rltgreen,
- linkcolor=rltred,
- menucolor=webdarkblue,
- citecolor=webbrightgreen,
- pdftitle={Zinc, an advanced scriptable Canvas.},
- pdfauthor={Patrick Lecoanet, Christophe Mertz, Centre d'Étude de la Navigation Aérienne},
- pdfsubject={The 3.3 Reference Manual.},
- pdfkeywords={tk tcl perl x11 canvas opengl script gui TkZinc},
- pagebackref,
- pdfpagemode=None,
- bookmarksopen=true
- ]{hyperref}
-% \pdfpagewidth=210truemm
-% \pdfpageheight=297truemm
- \pdfcompresslevel=9
- \usepackage[pdftex]{graphicx}
- \usepackage{thumbpdf}
- \usepackage{color}
- \definecolor{rltred}{rgb}{0.75,0,0.20}
- \definecolor{rltgreen}{rgb}{0,0.5,0}
- \definecolor{rltblue}{rgb}{0,0,0.75}
-\else
- \usepackage{graphicx}
-\fi
-
-
-\usepackage{html}
-\usepackage[widemargins]{a4}
-\usepackage{calc}
-\usepackage{makeidx}
-
-
-\newcommand{\cident}[1] {%
- {\tt #1}}
-
-\newcommand{\code}[1] {%
- {\tt #1}}
-
-\newcommand{\ident}[1] {%
- {\tt\large #1}}
-
-\newenvironment{blockindent} {\begin{quote}\latexhtml{\ifpdf\vspace{-0.8\baselineskip}\fi}{}} {\end{quote}\latexhtml{\ifpdf\vspace{-0.5\baselineskip}\fi}{}}
-%\newenvironment{blockindent}{\begin{quote}\vspace{-0.8\baselineskip}}{\end{quote}\vspace{-0.5\baselineskip}}
-
-
-\newcommand{\option}[3]{%
- \label{opt:#1}
- \index{#1}
- \latexhtml{\ifpdf\hyperdef{opt}{#1}{}\fi}{\htmlrule[WIDTH="70\%" left]}
- \begin{tabular}{rl}
- Command line switch: & \ident{-#1} \\
- Database name: & \ident{#2} \\
- Database class: & \ident{#3} \\
- \end{tabular}}
-% \begin{blockindent}#4\end{blockindent}}
-
-
-\newcommand{\command}[3]{%
- \label{cmd:#2}
- \index{#2}
- \latexhtml{\ifpdf\hyperdef{cmd}{#2}{}\fi}{\htmlrule[WIDTH="70\%" left]}
- {\tt\large #1 {\bf #2} #3}}
-
-\newcommand{\zinccmd}[2]{%
- \command{pathname}{#1}{#2}}
-
-\newcommand{\mapinfocmd}[3]{%
- \label{mapcmd:#2}
- \index{#2}
- \latexhtml{\ifpdf\hyperdef{mapcmd}{#2}{}\fi}{\htmlrule[WIDTH="70\%" left]}
- {\tt\large mapinfo #1 {\bf #2} #3}\\
- {\tt\large \$mainwindow->mapinfo(#1, {\bf #2}, #3) }
- % slightly buggy XXX : missing commas when #3 contains many words
-}
-
-\newcommand{\attrtype}[1]{%
- \label{attrtype:#1}
- \index{#1}
- \latexhtml{\ifpdf\hyperdef{attrtype}{#1}{}\fi}{\htmlrule[WIDTH="300" left]}
- {\tt {\bf #1}}
-}
-
-\newcommand{\attrtyperef}[1]{%
- \latexhtml{\ifpdf\hyperlink{attrtype.#1}{\ident{#1}}\else\ident{#1}\fi}{%
- \hyperref[page]{\ident{#1}}{\ident{#1} (}{)}{attrtype:#1}}
- }
-
-
-% the following command is never used!!
-\newcommand{\available}[1]{%
- \latexhtml{\ifpdf\hyperlink{obj.#1}{\ident{#1}}\else\ident{#1}\fi}{%
- \hyperref[page]{\ident{#1}}{\ident{#1} (}{)}{obj:#1}}
- }
-
-\newcommand{\optref}[1]{%
- \latexhtml{\ifpdf\hyperlink{opt.#1}{\ident{-#1}}\fi}{%
- \hyperref[page]{\ident{-#1}}{\ident{-#1} (}{)}{opt:#1}}
- }
-
-\newcommand{\cmdref}[1]{%
- \latexhtml{\ifpdf\hyperlink{cmd.#1}{\ident{#1}}\else\ident{#1}\fi}{%
- \hyperref[page]{\ident{#1}}{\ident{#1} (}{)}{cmd:#1}}
- }
-
-%first argument : item type or 'option'
-%second argument: attribute
-%third argument : type
-%fourth argument; explanation
-\newcommand{\attribute}[4]{%
- \label{attribute:#1:#2}
- \ident{-#2 }%
- \index{#2}
- \latexhtml{\ifpdf\hyperlink{attrtype.#3}{\ident{#3}}\hyperdef{attribute}{#1#2}{}\fi}{%
- \hyperref[no]{\tt \bf #3}{\ident{#3}}{attrtype:#3}}
- \begin{quote}\vspace{-\baselineskip}#4\vspace{-0.8\baselineskip}\end{quote}
- }
-
-% first argument : item type or 'option'
-% second argument: attribute
-\newcommand{\attributeref}[2]{%
- \latexhtml{\ifpdf\hyperlink{attribute.#1#2}{\ident{-#2}}\else\ident{-#2}\fi}{%
- \hyperref[page]{\ident{#2}}{\ident{-#2} (}{)}{attribute:#1:#2}}
- }
-
-\newcommand{\object}[1]{%
- \label{obj:#1}
- \index{#1}
- \latexhtml{\ifpdf\hyperdef{obj}{#1}{}\fi}{\index{#1}}
- }
-
-\newcommand{\concept}[1]{%
- \label{concept:#1}
- \latexhtml{\ifpdf\hyperdef{concept}{#1}{}\fi}{}
-% XXX bug? en html?
- }
-
-\newcommand{\objectref}[1]{%
- \latexhtml{\ifpdf\hyperlink{obj.#1}{\ident{#1}}\else\ident{#1}\fi}{%
- \hyperref[page]{\ident{#1}}{\ident{#1} (}{)}{obj:#1}}
- }
-
-\newcommand{\conceptref}[2]{%
- \latexhtml{\ifpdf\hyperlink{concept.#2}{\ident{#1}}\else\ident{#1}\fi}{%
- \hyperref[page]{#1}{#1 (page }{)}{concept:#2}}
- }
-
-% Premier parametre : nom du fichier image
-% Deuxieme parametre : legende
-% Troisieme parametre : scaling (e.g. 2.2 1 ou 0.54) à appliquer en pdf / dvi
-\newcommand{\fig}[3]{%
- \latexhtml{%
- \begin{figure}[htbp]%
- \centering%
- \label{fig:#1}%
- \ifpdf\includegraphics[scale=#3]{#1.png}\else\includegraphics[scale=#3]{#1.eps}\fi%
- \caption{#2}%
- \end{figure}}{%
- \begin{center}%
- \htmladdimg{#1.png}%
- %scale factor for html is a bad idea !?
- \end{center} } }
-
-
-\newcommand{\anurl}[1]{%
- \latexhtml{\ifpdf\href{#1}{#1}\else{\tt #1}\fi}{%
- \htmladdnormallink{#1}{#1}}
-}
-
-
-\makeindex
-
-\setlength{\parindent}{0cm}
-\setlength{\parskip}{0.2cm}
-\setlength{\oddsidemargin}{10pt}
-\setlength{\evensidemargin}{20pt}
-\setlength{\marginparwidth}{20pt}
-\setlength{\textwidth}{480pt}
-
-\title{Zinc, an advanced scriptable Canvas.\\The pre 3.3 Reference Manual.\\\small{[CENA technical Note NT03-532]} }
-\author{Patrick Lecoanet, Christophe Mertz}
-\date{1 Septembre 2004}
-
-
-\begin{document}
-%pdfpagewidth: \the\pdfpagewidth pdfpageheight: \the\pdfpageheight voffset: \the\voffset ~topmargin: \the\topmargin ~textheight: \the\textheight \linebreak
-
-\latexhtml{\ifpdf\voffset=-0.5in \setlength\textheight{ (\textheight+0.5in) }\fi}
-
-%voffset: \the\voffset ~topmargin: \the\topmargin ~textheight: \the\textheight \linebreak
-
-
-\latex{\DeclareGraphicsExtensions{.png,.ps,.eps,.pdf}}
-
-\maketitle
-
-\tableofcontents
-
-%%
-%%
-%% C h a p t e r : I n t r o d u c t i o n
-%%
-%%
-\chapter{Introduction}
-\concept{introduction}
-
-
-\section{What is TkZinc ?}
-
-TkZinc widgets are very similar to Tk Canvases in that they support
-structured graphics. Like the Canvas, TkZinc implements items used to
-display graphical entities. Those items can be manipulated and bindings can be
-associated with them to implement interaction behaviors. But unlike the
-Canvas, TkZinc can structure the items in a hierarchy (with the use of
-group items), has support for affine 2D transforms (i.e.\ translation, scaling, and
-rotation), 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.
-
-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 : \objectref{triangles}.
-In order to use the openGL features, you need the support of the GLX extension on
-your X11 server. Of course, performances will be dependant of your graphic card. At
-the time of writing, NVidia drivers for XFree86 R4.1 are doing a nice job. A laptop
-with a GeForce GO graphic card works nice for non trivial applications. We also
-succeeded in using TkZinc with openGL on the Exceed X11 server (running on windows and
-developped by Hummingbird) with the 3D extension.
-
-As an example of TkZinc capabilities when combined with openGL, we implemented
-the TkZinc logo as a Perl module (available as a goodie in \ident{LogoZinc.pm}).
-This logo (see below) was designed with Adobe Illustrator and then programmed in Perl.
-
-
-%\includefigure{tkzinclogo}{Zinc logo written as a Perl/Tk module}{fig:logozinc}
-
-\fig{tkzinclogo}{Zinc Logo written as a Perl/Tk module}{1}
-
-Like the canvas TkZinc focuses on the notion of script language. We strongly
-believe that the script environments are very powerful for rapid prototyping and for
-developping small to medium scale field specific applications. In these cases
-developper know-how and time are a scarce resource and the application either has few
-clients or is short lived. It is important to grant non-specialists an access to the
-powerful tools that are available today for HMI building, through a rather simple
-product.
-
-The TkZinc widget is available for the Tcl/Tk and the Perl/Tk scripting
-environments. A binding over Tcl/Tk is also provided for Python. It should be easy
-to do the same for Ruby, a binding for Tk is provided in the standard distribution of
-Ruby. Other scripting languages may be used as well depending on the availability
-of a Tk interface.
-
-This document is Tcl/Tk and Perl/Tk oriented but it should be easy for Python or Ruby
-programmers to adapt. Every time a TkZinc command is described in this
-document, it is given first in Tcl/Tk idiom and then in Perl/Tk idiom.
-
-This document is also referenced as CENA technical note NT03-532.
-
-\section{Differences with previous versions}
-
-\subsection{Differences between 3.3 and 3.2.97 release}
-This release has been mainly focused on producing a stable code
-base that compile and run on all three supported platforms with
-as little effort as possible.
-
-The only functional change is the integration of the fieldbbox
-command into the bbox command.
-
-
-\subsection{Differences between 3.2.97 and 3.2.6 release}
-\begin{itemize}
-\item TkZinc now works with Perl ptk 8.4 and utf8; However there remains
-some serious performance hit at launch time, when combinig openGL and ptk8.4,
-due to utf8 fonts management.
-\item text and icons can now be scaled and rotated in X (i.e. without openGL)
-\item translate method accepts an additionnal argument 'absolute'
-\item scale method accepts additionnal arguments: unit and rotation center
-\item find and addtag methods can now search inside atomic group
-\item the bbox method accepts into account the clipping area of a group
-\item TkZinc option -trackmanagehistory is replaced by -trackvisiblehistorysize
-and in for track items the attribute -visiblehistorysize has been removed and
-replaced by -historyvisible. {\bf Beware: Incompatible change}
-\item Default value of -composescale and -composerotation of texts
-and icons is now false. This is coherent with the default behavior
-of these items (being rigids). The impact of this change is
-greatly minored by the new processing of the -position attribute.
-\item transformation of items with a -position has been slightly
-modified. The point described by -position is no longer considered
-in the coordinate space of the item but in the coordinate space
-of its parent group. The item is always located in 0,0 of its
-own coordinate space. This is so to make use of -composescale and
--composerotation a lot more useful (and compatible).
-\item The fieldbbox method has been added to get item filed bounding box.
-\item Four new methods are now available for managing the transforms:
-tcompose, tget, tset and skew. A predefined named transformation is also available
-'identity' to be used with tsave. A predefined tag 'device' can be used to
-convert coordinates in or from device coordinates (with transform method).
-\item TkZinc with Tcl/Tk now works on windows and MacOS X (with X11 and fink).
-\item compilation on Linux works fine now, and TkZinc for Perl is on the CPAN
-\item A powerful perl module Tk::Zinc::Graphics has been added to help creating
-complex curves. French man pages are available. A port in Tcl is also available.
-\item png images with transparencies can now be displayed (requires openGL rendering)
-\item bezier items have been suppressed; they can now be easily replaced by curve items.
-\item curve items support now a higher level of description: they may be composed of line
-segments, and bezier segments. In the future they may also support other kinds of segments
-(such as arcs...).
-\item the coords method accepts a list of arrays as well as flat list of coordinates.
-When coords returns more than one point it is always a list of arrays.
-(and no more a flat list of x y x y ...). {\bf Beware this is a small incompatible change in the API}.
-\item operators of the contour command have been replaced by a flag which indicates
-if the contour must be taken as counterclockwise, clockwise or unchanged.
-Contours ids are now predictable. The GPC ``not-so-free'' library is no more used.
-It has been replaced by the GLU library. So TkZinc is again fully free software.
-\item curve item have a new -fillrule attribute.
-\item the syntax of gradient has been changed, mainly to accomodate with any color specification
-defined for X. {\bf Beware that old gradient are no more compatible}
-\item conical gradient type has been added; gradient paramaters has been extended.
-\item Perl modules ZincText, ZincDebug, ZincTrace and ZincTraceErrors have been renamed Tk::Zinc::Text Tk::Zinc::Debug
-Tk::Zinc::Trace and Tk::Zinc::Trace.
-\item TkZinc comes now with a ZincTrace.pm module to trace every TkZinc method call
-\item the hierarchical view in ZincDebug.pm can now display some choosen attributes
-in a choosen format.
-\item 6 new Perl demos in zinc-demos: ``testGraphics'', ``magic Lens'', ``pathTags'', ``tiger'' and ``curve with bezier control points''
-and ``fillrule''. Many Perl/Tk demos have been ported to Tcl/Tk.
-\item pathTags introduced in 3.2.6 have been documented. Label and label
-format documentation has been enhanced.
-\end{itemize}
-
-
-\section{Where can I find TkZinc and documentation ?}
-
-\ident{Zinc} is available as source in tar.gz format or as Debian or RedHat/Mandrake
-packages at
-\begin{itemize}
-\item
- \anurl{http://www.tkzinc.org/} or
-\item
- \anurl{http://freshmeat.net/projects/zincisnotcanvas/}
-\end{itemize}
-
-For people from CENA, its possible to get the TkZinc source code through
-a private CVS server. Please contact directly {\tt lecoanet@cena.fr} for more informations.
-
-This documentation is available as part of the TkZinc software. It is also
-available separately on the web sites. This document is formatted with \LaTeX\
-and is distributed as either html pages or a pdf file.
-
-As a complement to this reference manual, small Perl/Tk demos of TkZinc are
-also available through a small application named \conceptref{zinc-demos}{zinc-demos},
-highly inspired from the \emph{widget} application included in Tk. The aim of these demos
-are both to demonstrates the power of TkZinc and to help newcomers start using
-Zinc with small examples.
-
-
-\section{What is this document about ?}
-
-This reference manual describes the TkZinc widget interface. It shows how to
-create and configure a TkZinc widget, and how to use the commands it provides to
-create and manipulate items. The next chapter \conceptref{Widget creation and
-options}{options} describes how to create a new widget and which options and resources are
-available to configure it.
-The chapter \conceptref{Groups, Display List and Transformations}{coordinates} describes
-the use of groups and coordinates transformations.
-The chapter \conceptref{Item ids, tags and indices} {tagOrId} describes the item tags
-along with their main purposes. Also introduced is the concept of part name used by some
-items (\objectref{track} and \objectref{waypoint}). Finally, this chapter provides a
-description of textual indices.
-
-The chapter \conceptref{Widget commands}{commands} describes the commands which apply to a
-Zinc widget. They are used for creating, modifying or deleting objects, applying
-transforms ...
-The chapter \conceptref{Item types}{items} describes all the items provided by TkZinc along
-with their attributes.
-The chapter \conceptref{Labels, fields and labelformat}{labelsandfields} describes the
-use of labels, the possible attributes of fields and finally the labelformat syntax.
-The chapter \conceptref{Attributes types}{types} describes the legal form of all item
-attributes.
-The chapter \conceptref{The mapinfo commands}{mapinfocmds} introduces the mapinfo, a
-simple map description structure, and describes the commands used to create and
-manipulate mapinfos.
-Finally the chapter \conceptref{Other resources provided by the widget}{otherresources}
-describes some resources provided by or with TkZinc.
-
-
-\section{Copyright and Licence}
-
-Zinc has been developed by the CENA (Centres d'Etudes de la Navigation
-Aérienne) for its own needs in advanced HMI (Human Machine Interfaces or Interactions).
-Because we are confident in the benefit of free software, the CENA delivered this
-toolkit under the GNU Library General Public License.
-
-This code is free software; you can redistribute it and/or
-modify it under the terms of the GNU Library General Public
-License as published by the Free Software Foundation; either
-version 2 of the License, or (at your option) any later version.
-
-This code is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-Library General Public License for more details.
-
-You should have received a copy of the GNU Library General Public
-License along with this code; if not, write to the Free
-Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
-MA 02111-1307, USA.
-
-
-While this software is distributed under the GNU Library General Public License, part
-of it are derived from the Tk toolkit which is copyrighted under another open source
-license by The Regents of the University of California and Sun Microsystems, Inc..
-The GL font rendering is derived from Mark Kilgard code described in ``A Simple
-OpenGL-based API for Texture Mapped Text'' and is copyrighted by Mark Kilgard
-under an open source license.
-
-
-\section{Authors and credits}
-
-Zinc has been developed by Patrick Lecoanet. He also developed two previous
-version called \emph{Radar Widget} which share some characteristics with this
-version. The \emph{Radar Widget} was heavily used at CENA for many projects over nearly
-10 years. The release 2 is still in use. It was enhanced and then used for actual
-radar displays in two main French Air Traffic Control Centres 24 hours a
-day. Dominique Ruiz, Frederic Lepied helped a lot in the developement of these
-earlier versions.
-
-Zinc benefited greatly from the close interaction and the needs expressed by
-Jean-Luc Vinot. Jean-Luc has a background of Graphic Designer and is now an HMI
-developer at CENA. He envisions many, many new ideas for advanced HMI. Many of them
-would have been difficult to implement if at all possible with similar widgets.
-Zinc would have been less interesting without his ideas.
-
-Didier Pavet and his team as well as Daniel Etienne and Herve Damiano were the first
-users and helped a lot either by reporting bugs, problems or solutions. Thanks to all
-these people and to the CENA for supporting this work.
-
-The core of this documentation has been written by Patrick Lecoanet, the main author
-of TkZinc. This documentation has been enriched by Christophe Mertz.
-
-
-\section{How can I find help with TkZinc}
-
-If you are stuck with a feature you don't understand. If you don't know how to
-do something with TkZinc. If you think you have found a bug or a mismatch between
-the documentation and the behavior of the widget. Please feel free to contact us.
-Mail either {\tt lecoanet@cena.fr} or the TkZinc mailing list. To subscribe to the mailing
-list, please consult the site \anurl{http://www.tkzinc.org/}.
-
-
-\section{How may I contribute to TkZinc development}
-
-If you think TkZinc is an interesting tool, they are many ways to help with TkZinc
-development. First of all, subscribe to the TkZinc mailing list and get in touch with us. To
-subscribe, please consult the site \anurl{http://www.tkzinc.org/}.
-
-\begin{itemize}
-\item The very first way to contribute is to use TkZinc and to report
-any bug or problem you may experiment. Of course, if you send a script that
-exhibits the problem or even better a patch, your problem will have more
-chance to find a solution.
-\item The second way to contribute is by commenting on and proposing enhancement to
-this reference manual. As it has been written by french writers, english readers may
-really help in making this document easier to use. If you really feel ambitious, you
-may even try to write a tutorial, but that may be quite an undertaking! Some
-documentation (currently Tk::Zinc::Graphics) are in French only. Translating it in
-english would be great.
-\item The third way to contribute, and may be the funniest way, is to enrich the set
-of demos (see chapter \conceptref{Other resources provided by the
-widget}{otherresources}). Feel free to send us your productions. They may be simple
-but demonstrative or more complex. It is up to you! They will be integrated in the
-next release of TkZinc if they are worth it.
-\item The fourth way to contribute, and may be the most difficult, is to enrich the set
-of items (see section \conceptref{C api for adding new items}{Capi}) in an separate
-dynamic library. Then send us source code (with appropriate copyright and licence)
-if you want them to be integrated in a future release of TkZinc.
-\end{itemize}
-
-
-%%
-%%
-%% C h a p t e r : W i d g e t c r e a t i o n a n d o p t i o n s
-%%
-%%
-\chapter{Widget creation and options}
-\concept{options}
-
-The TkZinc command creates a new TkZinc widget, the general form are in Tcl and Perl:
-
-\begin{quote}
-{\tt\large zinc}\medskip
-
-{\tt\large \$version = \$mainwindow->zinc();}\smallskip
-
-{\tt\large \$Tk::Zinc::VERSION;}
-\end{quote}
-
-These expressions can be used to get the version of TkZinc. The string returned by the last expression also details the graphic head available. For example : ``zinc-version-3205d X11 GL''.
-
-\begin{quote}
-{\tt\large zinc pathname ?options?}\medskip
-
-{\tt\large \$mainwindow->Zinc(?option=>value?, ..., ?option=>value?);}
-\end{quote}
-
-{\tt pathname} name the new widget and specifies where in the widget hierarchy
-it will be located.
-
-You can set the {\tt \$ZINC\_GLX\_INFO} environment variable in order to display some information about the OpenGL instance used by TkZinc \textit{(New since TkZinc v3.2.6i)}.
-
-Any new TkZinc widget comes with a root group item, always identified by
-the item id 1. This group will contain all other items, either directly or through
-groups created themselves in the root group. Together the items form a tree rooted
-at the root group, hence its name.
-The chapter \conceptref{Groups, Display List and Transformations}{coordinates}
-describes the use of groups. The chapter \conceptref{Item ids, tags and indices}{tagOrId}
-describes the item ids and item tags, used as argument in most commands.
-
-The options are used to configure how the newly created widget will behave.
-They can be changed later by using the \cmdref{configure} and \cmdref{itemconfigure}
-Tk commands.
-
-Options apply only to the widget itself. They are a Tk supported concept and
-benefit from the option database an other mechanisms used to externally adapt the
-application to different environments. Attributes are a similar concept available for
-items and other TkZinc objects. But they are private to TkZinc and do not benefit from Tk
-support. They have been named differently to avoid confusion.
-
-Any number of options may be specified on the command line or in the option
-database to modify the global behavior of the widget. Available options are
-described below.
-
-
-\option{backcolor}{backColor}{BackColor}
-\begin{blockindent}
-This is the color that will
-be used to fill the TkZinc window. It is also used as a default color
-for some item color attributes. See each color attribute for the
-actual source of the default color. Its default value is
-{\tt \#c3c3c3}, a light grey.
-\end{blockindent}
-
-\option{borderwidth}{borderWidth}{BorderWidth}
-\begin{blockindent}
- Specifies the width of the 3d border that should be displayed around the widget
- window. This border does overlap the active TkZinc display area. The area
- requested from the geometry manager (or the window manager if applicable)
- is the area defined by \optref{width} and \optref{height}, the border is not
- taken into account. This value can be given in any of the forms valid for
- coordinates (See \cident{TkGet\_Pixels}). The default value is {\tt 2}.
-\end{blockindent}
-
-\option{confine}{confine}{Confine}
-\begin{blockindent}
- Specifies a boolean value that indicates whether or not it should be allowable
- to set the TkZinc's view outside the region defined by the \optref{scrollregion}.
- Defaults to true, which means that the view will be constrained within the scroll region.
-\end{blockindent}
-
-\option{cursor}{cursor}{Cursor}
-\begin{blockindent}
- Specifies the cursor to use when the pointer is in the TkZinc window. The default
- value is set to preserve the cursor inherited at widget creation.
-\end{blockindent}
-
-\option{font}{font}{Font}
-\begin{blockindent}
- The font specified by this option is used as a default font for item attributes of
- type font. Its default value is {\tt -adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*}.
-\end{blockindent}
-
-\option{forecolor}{foreColor}{ForeColor} %% XXX CM Foreground ?!
-\begin{blockindent}
- The color specified by this option is used as a default color for many item color
- attributes. See each each color attribute for the actual source of the default
- color. Its default value is {\tt black}.
-\end{blockindent}
-
-\option{fullreshape}{fullReshape}{FullReshape}
-\begin{blockindent}
- If this option is True, the shape applied to the TkZinc window will propagate up the
- window hierarchy to the toplevel window. The result will be a shaped toplevel.
- See also the \optref{reshape} option, it controls whether a shape is applied
- to the TkZinc window or not. The default is {\tt true}.
-\end{blockindent}
-
-\option{height}{height}{Height}
-\begin{blockindent}
- Specifies the height of the TkZinc window. This value can be given in any of the
- forms valid for coordinates (See \cident{Tk\_GetPixels}). The default is {\tt 100}
- pixels.
-\end{blockindent}
-
-\option{highlightbackground}{highlightBackground}{HighlightBackground}
-\begin{blockindent}
- Specifies the color to display in the traversal highlight region when the
- widget does not have the input focus. The default value is {\tt \#c3c3c3}.
-\end{blockindent}
-
-\option{highlightcolor}{highlightColor}{HighlightColor}
-\begin{blockindent}
- Specifies the color to use for the traversal highlight rectangle that is drawn
- around the widget when it has the input focus. The default value is {\tt black}.
-\end{blockindent}
-
-\option{highlightthickness}{highlightThickness}{HighlightThickness}
-\begin{blockindent}
- Specifies a non-negative value indicating the width of the highlight rectangle
- drawn around the outside of the widget when it has the input focus. The value may
- have any of the forms acceptable to \cident{Tk\_GetPixels}. If the value is zero,
- no focus highlight is drawn around the widget. The default value is {\tt 2}.
-\end{blockindent}
-
-\option{insertbackground}{insertBackground}{InsertBackground} %% XXX CM Foreground ?!
-\begin{blockindent}
- Specifies the color to use as background in the area covered by the insertion
- cursor. This color will normally override either the normal background for the
- widget (or the selection background if the insertion cursor happens to fall in the
- selection). The default value is {\tt black}.
-\end{blockindent}
-
-\option{insertofftime}{insertOffTime}{InsertOffTime} %% XXX CM OffTime ?!
-\begin{blockindent}
- Specifies a non-negative integer value indicating the number of milliseconds the
- insertion cursor should remain off in each blink cycle. If this option is zero
- then the cursor is on all the time. The default value is {\tt 300}.
-\end{blockindent}
-
-\option{insertontime}{insertOnTime}{InsertOnTime} %% XXX CM OnTime ?!
-\begin{blockindent}
- Specifies a non-negative integer value indicating the number of milliseconds the
- insertion cursor should remain on in each blink cycle. The default value is {\tt 600}.
-\end{blockindent}
-
-\option{insertwidth}{insertWidth}{InsertWidth}
-\begin{blockindent}
- Specifies a value indicating the width of the insertion cursor. The value may have
- any of the forms acceptable to \cident{Tk\_GetPixels}. The default value is {\tt 2}.
-\end{blockindent}
-
-\option{lightangle}{lightAngle}{LightAngle}
-\begin{blockindent}
- Specifies the lighting angle in degre used when displaying relief. The default value is {\tt 120}. %%% XXX CM to be completed!
-\end{blockindent}
-
-\option{mapdistancesymbol}{mapDistanceSymbol}{MapDistanceSymbol}
-\begin{blockindent}
- This option specifies the symbol to be used as a milestone along map lines. This
- option can be given any Tk bitmap which can be obtained by
- \cident{Tk\_GetBitmap}. The spacing between markers is 10 nautic miles. The default
- value is {\tt AtcSymbol19} (see \conceptref{Other resources provided by the widget}{otherresources}).
-\end{blockindent}
-
-\option{maptextfont}{mapTextFont}{MapTextFont}
-\begin{blockindent}
- Specifies the font used to draw the texts contained in maps. The default is
- {\tt -adobe-helvetica-bold-r-normal--*-120-*-*-*-*-*-*}.
-\end{blockindent}
-
-\option{overlapmanager}{overlapManager}{OverlapManager}
-\begin{blockindent}
- This 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 {\tt 0}.
-\end{blockindent}
-
-\option{pickaperture}{pickAperture}{PickAperture}
-\begin{blockindent}
- 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
- {\tt 1}.
-\end{blockindent}
-
-\option{relief}{relief}{Relief}
-\begin{blockindent}
- Specifies the border relief. This option can be given any legal value for a relief
- (See \attrtyperef{relief} for a description of possible values). The default
- value is {\tt flat}.
-\end{blockindent}
-
-\option{render}{render}{Render}
-\begin{blockindent}
- Specifies whether to use or not the openGL rendering. The value is
- a positive integer that can have the values 0, 1 and 2. The value 0
- specifies a X11 rendering while the other two ask for an OpenGL
- rendering and as such requires the GLX extension to the X server.
- A value of 1 asks for direct OpenGL rendering which is the faster but
- is limited to a local session with the display while a value of 2
- requests an indirect rendering which is slower but can be streamed
- to a distant display (at least under X11). If a direct rendering
- mode is requested but can't be achieved the indirect render mode
- will be tried automatically. If neither OpenGL modes are available
- the X11 mode is used as a fallback.
- This option must be defined at widget creation time and is readonly
- for the rest of the session. It can be used to ask if the widget is
- drawing in OpenGL mode or in plain X mode (to adapt the
- application code for example). The default value is {\tt 0}.
-\end{blockindent}
-
-\option{reshape}{reshape}{Reshape}
-\begin{blockindent}
- Specifies if the clipping shape that can be set in the root group item should clip
- the root group children or be used to reshape the TkZinc window. This option can be
- used with the fullreshape option to reshape the toplevel window as well. The
- default value is {\tt true}.
-\end{blockindent}
-
-\option{scrollregion}{scrollRegion}{ScrollRegion}
-\begin{blockindent}
- Specifies a list with four coordinates describing the left, top, right, and bottom
- coordinates of a rectangular region. This region is used for scrolling purposes and
- is considered to be the boundary of the information in the TkZinc.
-\end{blockindent}
-
-\option{selectbackground}{selectBackground}{SelectBackground} %% XXX CM Foreground ?!
-\begin{blockindent}
- Specifies the background color to use for displaying the selection in text
- items. The default value is {\tt \#a0a0a0}.
-\end{blockindent}
-
-\option{speedvectorlength}{speedVectorLength}{SpeedVectorLength}
-\begin{blockindent}
- Specifies the duration of track speed vectors. This option is expressed using a
- time unit that should be chosen by the application (usually minutes) and kept
- coherent with the unit of the track attribute \attributeref{track}{speedvector} (usually nautic
- mile / minute). The default value is {\tt 3}.
-\end{blockindent}
-
-\option{takefocus}{takeFocus}{TakeFocus}
-\begin{blockindent}
- (Slightly adapted from the Tk options manpage).
-
- Determines whether the window accepts the focus during keyboard traversal (e.g., Tab and
- Shift-Tab). Before setting the focus to a window, the traversal scripts consult the
- value of the takeFocus option. A value of 0 means that the window should be skipped
- entirely during keyboard traversal. 1 means that the window should receive the input
- focus as long as it is viewable (it and all of its ancestors are mapped). An empty
- value for the option means that the traversal scripts make the decision about whether or
- not to focus on the window: the current algorithm is to skip the window if it is
- disabled, if it has no key bindings, or if it is not viewable. If the value has any
- other form, then the traversal scripts take the value, append the name of the window to
- it (with a separator space), and evaluate the resulting string as a callback. The
- script must return 0, 1, or an empty string: a 0 or 1 value specifies whether the window
- will receive the input focus, and an empty string results in the default decision
- described above. \emph{Note: this interpretation of the option is defined entirely by
- the callbacks (part of the keyboard traversal scripts) that implement traversal; the
- widget implementations ignore the option entirely, so you can change its meaning if you
- redefine the keyboard traversal scripts.}
- The default value is empty.
-\end{blockindent}
-
-\option{tile}{tile}{Tile}
-\begin{blockindent}
- Specifies an image name to be used as a tile for painting the TkZinc window
- background. The default value is {\tt ""} (the empty string).
-\end{blockindent}
-
-\option{trackmanagedhistorysize}{trackManagedHistorySize}{TrackManagedHistorySize}
-\begin{blockindent}
- This option accepts only positive integers. It specifies the number of positions
- collected in the history list by the track items. When this many positions have
- been collected, the oldest is dropped to make room for a new one on a first-in
- first-out basis. See also the \optref{trackvisibehistorysize} option and the
- \attributeref{track}{historyvisible} track attribute. The default value is {\tt 6}.
-\end{blockindent}
-
-
-\option{trackvisiblehistorysize}{trackVisibleHistorySize}{TrackVisibleHistorySize}
-\begin{blockindent}
- This option accepts only positive integers. It specifies the number of
- past positions to display for tracks. It is a widget wide control. Users
- of previous releases used the {\tt -visiblehistorysize} track attribute
- for the same effect. The number of past positions displayed can not exceed
- the accumulated positions controlled by the option \optref{trackmanagedhistorysize}.
- The track \attributeref{track}{historyvisible} attribute controls whether
- a track should display its history. The default value is {\tt 6}.
-\end{blockindent}
-
-
-\option{tracksymbol}{trackSymbol}{TrackSymbol}
-\begin{blockindent}
- Specifies the symbol displayed at the current position of a track. This option
- accepts a \attrtyperef{bitmap}. The default value is {\tt AtcSymbol15}.
-\end{blockindent}
-
-
-\option{xscrollcommand}{xScrollCommand}{ScrollCommand}
-\begin{blockindent}
- Specifies a callback used to communicate with horizontal scrollbars. When
- the view in the widget's window changes (or whenever anything else occurs
- that could change the display in a scrollbar, such as a change in the total
- size of the widget's contents), the widget will make a callback passing two
- numeric arguments in addition to any specified in the callback. Each of the
- numbers is a fraction between 0 and 1, which indicates a position in the
- document. 0 indicates the beginning of the document, 1 indicates the end,
- .333 indicates a position one third the way through the document, and so on.
- The first fraction indicates the first information in the document that is
- visible in the window, and the second fraction indicates the information
- just after the last portion that is visible. Typically the xScrollCommand
- option consists of the scrollbar widget object and the method ``set'' i.e.
- [set => \$sb]: this will cause the scrollbar to be updated whenever the view
- in the window changes. If this option is not specified, then no command
- will be executed.
-\end{blockindent}
-
-\option{xscrollincrement}{scrollincrement}{xScrollIncrement}
-\begin{blockindent}
- Specifies an increment for horizontal scrolling. If the value of this option
- is greater than zero, the horizontal view in the window will be constrained
- so that the TkZinc x coordinate at the left edge of the window is always an
- even multiple of {\tt xScrollIncrement}; furthermore, the units for scrolling
- (e.g., the change in view when the left and right arrows of a scrollbar are
- selected) will also be {\tt xScrollIncrement}. If the value of this option
- is less than or equal to zero, then horizontal scrolling is unconstrained.
-\end{blockindent}
-
-\option{yscrollcommand}{yScrollCommand}{ScrollCommand}
-\begin{blockindent}
- Specifies a callback used to communicate with vertical scrollbars. This option
- is treated in the same way as the xScrollCommand option, except that it is used
- for vertical scrollbars and is provided by widgets that support vertical
- scrolling. See the description of xScrollCommand for details on how this option is used.
-\end{blockindent}
-
-\option{yscrollincrement}{scrollincrement}{yScrollIncrement}
-\begin{blockindent}
- Specifies an increment for vertical scrolling. If the value of this option
- is greater than zero, the vertical view in the window will be constrained
- so that the TkZinc y coordinate at the left edge of the window is always an
- even multiple of {\tt yScrollIncrement}; furthermore, the units for scrolling
- (e.g., the change in view when the top and bottom arrows of a scrollbar are
- selected) will also be {\tt yScrollIncrement}. If the value of this option
- is less than or equal to zero, then vertical scrolling is unconstrained.
-\end{blockindent}
-
-\option{width}{width}{Width}
-\begin{blockindent}
- Specifies the width of the TkZinc window. This value can be given in any of
- the forms valid for coordinates (See \cident{Tk\_GetPixels}). The default is
- {\tt 100} pixels.
-\end{blockindent}
-
-
-
-%%
-%%
-%% C h a p t e r : G r o u p s , D i s p l a y l i s t s , C l i p p i n g
-%%
-%%
-\chapter{Groups, Display lists, Clipping and Transformations}
-\concept{coordinates}
-
-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 and we will describe them in this chapter. The main usages
-are:
-
-\begin{itemize}
-\item to bundle items together so they can be cloned, destroyed, hidden,
- moved and more as a whole,
-\item to bundle several items together so that they form a new single item
- composed of several simpler one. This is done by modifying the way events
- are associated with items (see \attributeref{group}{atomic}),
-\item to interpose a new coordinate system in a hierarchy of items. This
- can be very useful to manage panning, zooming and other kind of viewing
- transformation. See below for an explanation of the transformation system
-\item to compose some specific attributes such as transparency, sensitivity,
- visibility, ...\ with those of their children items,
-\item to apply a clipping to their children items,
-\item to manage display ordering between items and to do the display lists
- housekeeping.
-\end{itemize}
-
-
-\section{The root group and the item tree}
-
-An item, be it simple like a rectangle or more complex like a group, is always
-created relative to a group which is known as its parent, the group's items are its
-children. The items form a tree whose nodes are the group items. The top-most node is
-known as the root group, of id 1, which is automatically created with TkZinc. By
-convention, the root group is its own parent. It is not possible to change the parent
-of the root group and it is not possible to delete it. However, it is possible to
-change the group of all other items after creation, and thus modify the item tree at
-any time. This is the use of the \cmdref{chggroup} command.
-
-
-\section{Attributes composed with children}
-
-The following attributes are composed down the item tree to form the
-resulting attribute value in the leaf items:
-\begin{itemize}
-\item\ident{-sensitive}: the sensitivity (to keyboards or mouse event) of an
- item is the result of and-ing together the \ident{-sensitive} attributes
- found when descending from the root group to a specific leaf item.
-\item\ident{-visible}: the visibility of an item is the result of and-ing together
- the \ident{-visible} attributes found when descending from the root group to a
- specific leaf item.
-\item\ident{-alpha}: the transparency of an item is the result of combining
- the \ident{-alpha} attributes of the groups found when descending from the
- root group to a specific item with the alpha channel found in a given color
- of this item. The transparency is a percentage between 0 and 100, two
- transparencies are combined by multiplying both and then dividing by 100.
- The transparency can be used only if the environment support openGL and if
- the widget was created with the \optref{render} option set to True.
-\end{itemize}
-
-
-\section{Atomic groups}
-
-It may seem at first that there is a contradiction in this title, but there is not. It is
-possible to built complex objects from simple items simply by assembling those items
-together in a group (using other intervening groups if the need arise). Once this is
-done, it would be convenient if the whole acted as a single item, the top assembling
-group. It is already so for many commands that act on a group, it is possible to move,
-resize, rotate, restack, clone, hide, change the transparency, delete the group as a whole
-without knowing anything of its children. But when it comes to event dispatching, the
-group is completly transparent so far. So the event dispatch mecanism will try to locate
-the smallest most visible item containing the pointer and will trigger the associated
-bindings. Not exactly what we meant. So groups have a feature, the
-\attributeref{group}{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.
-
-It must also be noted that commands such as \cmdref{find} {\tt 'enclosed'/'overlapping'} or
-\cmdref{addtag} {\tt 'enclosed'/'overlapping'} {\bf act differently on an atomic group}.
-Such search command will not traverse an atomic group. So if a part of the atomic
-group is enclosed or overlapping, the search command will return the atomic group
-and not its part.
-
-A small program, \ident{Atomic groups} is available as part of
-\conceptref{zinc-demos}{zinc-demos} to demonstrate the atomic groups behaviour.
-
-
-\section{Display order and display lists}
-
-The items are displayed in a specific order which determines how they stack. This
-order is also important for associating events with items. 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. Each time a group is
-encoutered the traversal proceed with this group display list before resuming the
-upper display list traversal. 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.
-
-It is important to note as a consequence of this structuring, that items of a group are
-stacked between the items that are under the group and the items that are on top of the
-group. Thus, items of two groups cannot be intertwinned, they stack exactly as their groups
-stack, that is items of the underneath group a drawn then the items of the other group are
-drawn on top.
-
-The item ordering imposed by the display lists can be ajusted in three ways. The two
-first are local to a group's display list. The third can be used to rearrange between
-groups.
-
-\begin{itemize}
-\item
- The attribute \ident{-priority} can be used to give an absolute stacking position
- to an item amongst the items of its group. When a new item is added to a group with a
- priority matching the priority of existing items of the group, the new item is placed on
- top of the those items. Last comer is most visible. The same rule is followed when
- changing the priority of an item and when moving an item to a new group.
- \objectref{map} and \objectref{reticle} default priority is 0. \objectref{window}
- item attribute is meaningless. All other items default priority is 1.
-\item
- The commands \cmdref{raise} and \cmdref{lower} adjust the relative order of an item
- in its group. These commands can be used to bring an item in front or to the back of
- its group. It is also possible to place an item before or after a given item of its group.
- These commands act in such a way as to preserve the absolute relationship set by the
- \ident{-priority} attribute. To do so they may adjust the priority of the
- moved item to match the priority of the item just below (raise) or just above (lower).
- If the priority of the moved item is not in conflict with its new neighborhood, it is
- not affected.
-\item
- It is also possible to move the item to another group. This has an effect on the item
- stacking as it will be forced to the stacking location of its new group.
-\end{itemize}
-
-
-\section{Event sensitivity}
-
-An item will catch an event if all the following conditions are satisfied:
-\begin{itemize}
-\item
- the item \ident{-sensitive} must be set to true (this is the default).
-\item
- the item must be under the pointer location.
-\item
- the item must be on top of the display list (at the pointer location). Beware
- that an other item with its \ident{-visible} set to false DOES catch event
- before any underneath items.
-\item
- the item must not be clipped (at the pointer location)
-\item
- the item must not belong to an atomic group, since an atomic group catchs the event
- instead of the item.
-\end{itemize}
-
-An item satisfying all the above conditions can have its \ident{-visible} set
-to false, or can be fully transparent (when using openGL). It will still catch
-the events.
-
-
-\section{Transformations}
-
-In TkZinc each item is geometrically defined in its own coordinate space. So
-each time a new item is created, a new coordinate system is attached to it.
-This coordinate system must be related to the coordinate systems of the other
-items to place the items with respect to each other. This relationship is
-defined by an affine transformation associated with the item. This transformation
-establishes the relationship between an item and its group. The items being
-arranged in a tree by their groups, its possible via the transformations to place
-all the items in an absolute coordinate system known as the window space.
-
-Just after item creation, the item transformation is set to identity, i.e the item
-coordinate system maps exactly on the system of its group. The commands
-\cmdref{translate}, \cmdref{scale}, \cmdref{rotate} , \cmdref{skew} can be
-used to modify this relationship to the effect of translating, enlarging, shrinking,
-rotating or skewing the item. It must be emphasized that those commands act on the
-relation between two coordinate spaces, \emph{not} on the item geometry itself.
-If the goal is to change the item (except for groups, see next paragraph) geometry,
-the command \cmdref{coords} may be more appropriate (but see below the command
-\cmdref{tapply}).
-
-As it should be clear, groups are like any other items, they are defined in
-their own coordinate space and are assembled with their parents by transformations.
-This is a very powerful tool to manage the geometry of clusters of items.
-One must not refrain from using groups only to assign them a transformation
-task such as panning a whole set of items or scaling a set while another is
-kept in place in another group. For the developper convenience, the \cmdref{coords}
-method on a group change its transformation. It defines the absolute translation
-applied to the group.
-
-Another very interesting use of a group as a transformation tool is to manage a window
-coordinate space where the origin is not in the top left corner and where the Y axis goes
-from bottom to top. It is quite simple to write a function that is triggerred on the
-window resize event whose only goal is to compute a new transformation for the group.
-Other parts of the application and the other items are not aware of this happening. A
-good factorization example.
-
-In fact, transformation are so useful that a whole set of functions are available
-to help use them in full. Apart from the already mentioned \cmdref{translate},
-\cmdref{scale}, \cmdref{rotate}, and \cmdref{skew} commands, it is also possible
-to restore a transformation to its initial state, identity, with the
-\cmdref{treset} command.
-It is also possible to compose a transformation with another name transform with
-the \cmdref{tcompose} command.
-
-An item transformation can be saved under a name, in fact creating
-a named transformation which can be manipulated just as an item transformation (i.e
-using translate, scale, rotate, treset). Once a transformation has been named it
-can be used to set the transformation of any item using with the command \cmdref{trestore}.
-And it can be disposed of with the command \cmdref{tdelete}.
-
-An item can be physically modified by applying its own transformation to itself. This is
-the goal of the \cmdref{tapply} command. It applies the item transformation to its own
-coordinates an then reset the item transformation. Visually nothing has changed but in
-fact the item is irrevocably modified. Be aware that if it is quite easy to undo a change
-in a transformation by using treset or by saving and then restoring a transformation, it
-is not so easy to revert a physical modification on an item. The exact order of the
-operations must be recorded and even then there is no shield against round off errors
-that will probably occur. This command may be used together with the translate, scale and
-rotate commands if someone really want, even after reading this paragraph, to implement
-the canvas move, scale and even rotate commands.
-
-A predefined named transformation exists. Its name is \ident{identity} and refers to the
-identity transform. it can not be modified by the user.
-
-When dealing with mouse events and other sources of window coordinates, it is
-often useful to map the window coordinates to an appropriate coordinate space. The
-command \cmdref{transform} is just what is needed to do so. It is powerful enough to be
-able to convert coordinates from any coordinate space to any other. A special provision
-has been made to facilitate conversion from window space to another space. The opposite
-is not impossible but rely on a small trick: the root group transformation must be left as
-identity (the default at creation time). In this way, it is possible to use the root group
-space, which is then the same as the window space, as the target space of the
-\cmdref{transform} command.
-
-If you need to manage many different transformations independently, it is a good
-practice to apply these transformations to different groups. For example, a group
-can be used for translation and an other group (father or son) for scaling.
-
-When a rotation or a scale appear in a transformation, all items do not behave exactly in
-the same manner. For example text items do not scale or rotate. Only their
-position moves according to the rotation or the scaling factor. Here is how items react
-to the scale and rotation factors of the transformation.
-
-\begin{itemize}
-\item \objectref{group} They have no graphical shape by themselves;
-\item \objectref{track} The position, past positions, speedvector are fully transformed. The
- circular marker is transformed by the X scale factor, it always remains circular. The label
- position is computed relative to the new position and speedvector direction but is otherwise
- rigid and its distance (in pixels) to the position is unchanged.
-\item \objectref{waypoint} The position is fully transformed. The label position is computed
- relative to the new position and new rotation but is otherwise rigid and its distance
- (in pixels) to the position is unchanged.
-\item \objectref{tabular}, \objectref{text} Only the position (relative to the
- anchor) is affected.
-\item \objectref{icon} With openGL, icon items can be rotated and zoomed.
-\item \objectref{reticle} Only the center and the spacing between circles are affected.
-\item \objectref{map} lines and arcs are fully transformed. For texts and symbols only the position
- is affected.
-\item \objectref{rectangle}, \objectref{arc}, and \objectref{curve} are fully transformed.
-\item \objectref{window} Only the position (relative to the anchor) is affected.
-\end{itemize}
-
-However, every item has a couple of attributes \ident{-composescale} and
-\ident{-composerotation} that can be used to control how the scale and rotation factors
-are inherited from the parents' transformations. These attributes default to \ident{true}
-(i.e.\ rotation and scale from parents are meaningful, except for \objectref{icon} where these attributes
-defaulted to \ident{false}). When one of these attributes is set
-to false the corresponding factor is reset from the inherited transformation. Scale factors
-are reset to 1.0 and rotation is reset to 0. Be careful that this applies to the inherited
-transformation, \emph{not} to the item transformation itself which is composed \emph{after}
-taking into account the composition attributes.
-
-As you can see, the transformation process is quite powerful but complex. A small program,
-\ident{Tranformation testbed} is available as part of \conceptref{zinc-demos}{zinc-demos}
-to demonstrate the transformation capabilities of TkZinc. This is also a great resource
-to understand how it works and to tame its complexity. It is possible to use this program
-to test one's idea on a given transformation problem before coding it as part of a
-complex application.
-
-
-\section{Clipping and groups}
-Groups can set a clip boundary before drawing their children. Thought of this feature as
-if a group can be made to act as a window on its children. Except that the window can have
-any shape you like to give it. Each group has a \attributeref{group}{clip} attribute which
-can be set to an item of the group. This item, known as the clipper of the group, defines
-the shape of the clipping. All item types except \objectref{group}, \objectref{track},
-\objectref{waypoint}, \objectref{reticle} and \objectref{map} can be used as clippers
-but the clipper must be a direct child of the clipped group. The clipper defines the shape
-of the clipping but is also drawn as a regular group item. It is typical to either mask
-explicitly the clipper by turning off its \ident{-visible} attribute or to fill and lower
-it so it can act as the background. Of course, other creative uses can be found but be
-warned that the clipper outline will never be easthetically drawn due to round off or
-quantization errors, it is better to turn off borders or outlines in this case.
-
-It is also possible to clip the root group (only on X11 system. Does not work on windows
-systems). Depending on the value of TkZinc options \optref{reshape} and
-\optref{fullreshape}, the clipping form can be used either to clip all items in the TkZinc
-widget, or reshape the TkZinc widget, or to propagate the TkZinc widget shape to the parent
-windows. In the latter case, this allows to build non-rectangulaire applications. This
-requires both the SHAPE X11 extension and a compliant Window Manager (fvwm is known
-to support non rectangulaire top windows). The clipping form should have a bounding box
-with the same ratio as the topwindow or some normalisation will occur. Example:
-
-\code{
- use Tk::Zinc;\\
-
- my \$mw = MainWindow->new();\\
- my \$zinc = \$mw->Zinc(-reshape => 1, -fullreshape => 1)->pack;\\
-
- \# creating a triangulaire curve\\
- my \$triangle= \$zinc->add('curve',1, [ [0,0], [100,0], [50,100] ], -closed => 1);\\
- \# using the triangulaire curve to reshape both TkZinc and Mainwindow widgets\\
- \$zinc->itemconfigure(1, -clip => \$triangle);\\
-
- \$zinc->add('arc',1, [ [0,0], [100,100] ], -filled => 1, -fillcolor => 'darkblue');
- ...\\
- \&Tk::MainLoop;
-}
-
-
-%%
-%%
-%% C h a p t e r : I t e m I d s , t a g s a n d i n d i c e s
-%%
-%%
-\chapter{Item ids, tags and indices}
-\concept{tagOrId}
-
-\section{Item ids}
-Each item is associated with a unique numerical id which is returned by the
-\cmdref{add} or \cmdref{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.
-
-\section{Tags}
-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: \verb+. * ! ( ) & | :+.
-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. Tags can be used to group items to
-do some action, or to mark an item that has a special function. Many other
-tasks can be solved with tags once one gets used to them.
-
-Two special tags are implicitly managed by TkZinc. The tag \ident{all} is
-associated with all items in TkZinc. The tag \ident{current} is always
-associated with the topmost item that lies under the mouse pointer. If no
-such item exists, no item has this tag.
-
-In commands, tags can be used almost anywhere an item id would be legal.
-In the command descriptions, the expression \ident{tagOrId} means that it
-is legal to provide either a tag or an item id. This means that virtually
-all actions can be either performed on a specific item by using its id or
-on a whole set of items by using a tag. In order for this collective
-behavior to be useful, if a command or an attribute does not apply to an
-item named by the tag, it is simply ignored, no error will be reported
-(This may yet not be the case with all commands, please report
-infringements).
-
-Everywhere a \ident{tagOrId} can be specified as a target for some action,
-it is possible to give a logical expression of tags and ids. The available
-boolean operators include logical and \verb+&&+, logical or \verb+||+,
-logical xor \verb+^+, logical not \verb+!+ and subexpression grouping
-\verb+()+. Here is an example of a \cmdref{bbox} command called on a set of
-items defined by a logical expression. Note that tags and ids can be mixed. For example:
-\begin{verbatim}
- ($xo, $yo, $xc, $yc) = $zinc->bbox("(red && black)||(pink && !$thisitem)");
-\end{verbatim}
-
-Many methods only operate on a single item at a time; if \ident{tagOrId} is
-specified in a way that names multiple items, then the normal behavior for
-these methods is to use the first of these items in the display list (most
-visible) that is suitable for the method. Exceptions are noted in the
-method descriptions below.
-
-Tags can be associated with items by giving a tag list to the \ident{-tags}
-attribute or by using the more powerful \cmdref{addtag} command. A tag can
-be removed by the \cmdref{dtag} command, by setting the \ident{-tags}
-attribute to the empty list, all tags are remove from an item at once
-(except the implicit ones). Tags can be read with the \cmdref{gettags} or
-by querying the \ident{-tags} attribute. The items named by a tag are
-returned in a list by the \cmdref{find} command which as exactly the same
-capabilities as \cmdref{addtag}.
-
-\section{PathTags}
-\concept{pathTags}
-A special form of tag called a pathTag can be used as a tagOrId argument in all
-commands except \cmdref{bind}. This special tag describes an item or a group of
-items in the absolute item hierarchy. The pathTag consists in a path down the
-group hierarchy followed by an (optionnal) effective tag, in the usual sense.
-
-The path is an ordered list of tags set up on groups that drives the search
-from the root group down the group hierarchy. The path starts with either a dot
-or a star, and the tags in the path are separated by dots or stars. The dot
-means that the next tag selects a group item that is a direct child of the
-current group, starting with the root group. The star selects a group item that
-is a possibly indirect child of the current group, the candidate is found
-in display list order. The first tag in the path, the one just after the first
-dot or star, can be a group id; This is useful in order to limit the search in a
-specific sub-hierarchy.
-
-The last tag of a pathTag, the one not followed by a dot or a star, is the
-effective tag searched for. It can be omitted, in this case the search
-proceed with the tag all. The dot or star just before the effective tag,
-even if the tag is implied, controls how the tag is searched. If a dot is
-present, the search is limited to the current group level. If a star is
-present, the search proceed from the current group level down the whole
-group subtree.
-
-A demo called ``Using pathTags'' in zinc-demos may help you better understand pathTags.
-Here are some commonly used pathTags idioms:
-
-\begin{description}
-
-\item{\ident{.group1Tag.group2Tag.aTag}}\\
-Selects all {\bf direct} children with the tag \ident{aTag} in the group obtained by
-following the path \ident{.group1Tag.group2Tag} from the root group.
-The search proceed from the root group to the first direct child group in display
-list order with tag \ident{group1Tag}. Then it searches for the first direct child group
-with tag \ident{group2Tag}. Finally in this group, the search ends by finding all direct
-children items (including groups) with tag \ident{aTag}. If a tag is not found the whole
-search is aborted and no item is selected.
-
-\item{\ident{.group1Tag.group2Tag*aTag}}\\
-Selects all children, {\bf direct or indirect}, with the tag \ident{aTag} in
-the group obtained by following the path \ident{.group1Tag.group2Tag} from the root group.
-
-\item{\ident{.group1Tag*group2Tag.aTag}}\\
-Selects all {\bf direct} children with the tag \ident{aTag} in
-the group obtained by following the path \ident{.group1Tag*group2Tag} from the root group.
-The search proceed from the root group to the first direct child group in display
-list order with tag \ident{group1Tag}. Then it searches in display list order down the
-hierearchy for the first group with tag \ident{group2Tag} . Finally in this group, the
-search ends by finding all direct children items (including groups) with tag \ident{aTag}.
-If a tag is not found the whole search is aborted and no item is selected.
-
-\item{\ident{.group1Tag*group2Tag*aTag}}\\
-Selects all items with the tag \ident{aTag} in the hierarchy
-of the group obtained by following the path \ident{.group1Tag*group2Tag} from the root
-group. The search proceed from the root group to the first direct child group in
-display list order with tag \ident{group1Tag}. Then it searches in display list order down
-the hierearchy for the first group with tag \ident{group2Tag} . Finally in this group, the
-search ends by finding all direct children items (including groups) with tag \ident{aTag}.
-If a tag is not found the whole search is aborted and no item is selected.
-
-\item{\ident{.group1Tag.group2Tag.}}\\
-Selects all {\bf direct} children of the group obtained
-by following the path \ident{.group1Tag.group2Tag} from the root group. If a tag is not
-found the whole search is aborted and no item is selected.
-
-\item{\ident{.group1Tag.group2Tag*}}\\
-Selects all items in the hierarchy of the group obtained
-by following the path \ident{.group1Tag.group2Tag} from the root group. If a tag is not
-found the whole search is aborted and no item is selected.
-
-\item{\ident{.groupId.aTag}}\\
-Selects all {\bf direct} children with tag \ident{aTag} of the group with id \ident{groupId}.
-If \ident{groupId} is not found or is not a group id, the search is aborted and no item
-is selected. This form together with the next is specially useful with cloned
-items hierarchies where only the topmost group item is known after cloning. Using
-pathTags it is now possible to make use of designs using components with named
-sub-components. It is possible to clone a component and afterward to change the
-behavior of named sub-components with pathTags of the form
-\ident{.componentId.subComponentName} or perhaps better {.componentId*subComponentName} . Some
-care is needed in order to avoid sub-component name clash. Remember that the search for
-tags proceed in {\bf display list order}, not in hierarchy order. In other more
-technical words the search walks the item tree {\bf depth first} not breadth first.
-
-\item{\ident{.groupId*aTag}}\\
-Selects all items with tag \ident{aTag} in the hierarchy of the
-group with id \ident{groupId}. If \ident{groupId} is not found or is not a group id, the search
-is aborted and no item is selected.
-
-\item{\ident{.groupId.}}\\
-Selects all {\bf direct} children of the group with id \ident{groupId}. It is the only
-way to get direct children of a group.
-
-\item{\ident{.groupId*}}\\
-Selects all items in the hierarchy of the group with id \ident{groupId}.
-
-\item{\ident{.}}\\
-Selects all {\bf direct} children of the root group.
-
-\item{\ident{*}}\\
-Selects all items in the hierarchy (not counting the root group itself).
-
-\item{\ident{.aTag}}\\
-Selects all {\bf direct} children of the root group with the tag \ident{aTag}.
-
-\item{\ident{*aTag}}\\
-Selects all items in the whole hierarchy (starting a the root group)
-with the tag \ident{aTag}. It is the same as using the simple tag \ident{aTag}.
-
-\end{description}
-
-
-\section{Tags and bindings}
-\concept{tagsAndBindings}
-Tags are also very useful to associate scripts with events. The \cmdref{bind}
-command is used to specify a script to be invoqued when an event sequence is
-associated with a tag.
-
-The event dispatch mecanism in TkZinc collects which tags are related to a given event and
-then use the bindings established by \cmdref{bind} to activate the related scripts. Event
-dispatching operates on three event sources: mouse events, keyboard events and internally
-generated enter/leave events. Mouse events are dispatched to the item under the mouse
-pointer, if any; keyboard events are dispatched to the focus item, if any; leave events
-are dispatched to the item previously under the pointer, enter events to the item newly
-under the pointer. Tags are collected from the item found.
-
-Special tags are managed for items with fields or parts (e.g.\ a \objectref{track} has both, a
-\objectref{tabular} has only \ident{fields} and a \objectref{rectangle} has none). They are built
-from a tag or an id followed by a \verb+:+ followed by a (zero based) field index or by the
-name of a part. Those tags can only be used in event bindings.
-
-Here is the complete list of tags, either real or implicit, that are tried to find bindings.
-They are listed in the order they are processed.
-\begin{enumerate}
-\item the implicit tag \verb+all+ (associated with all items),
-\item the other tags (in some not reliable order),
-\item the item id,
-\item the implicit tags build from the tags and the current part name or field index, if any,,
-\item the implicit tag build from the item id and the current part name or field index, if any.
-\end{enumerate}
-
-An exception is made for the \ident{Leave} event when dispatched to an item with parts
-or fields. This is needed to process the exit of a field/part before the exit of the
-corresponding item. In this case the order is shown by the following list.
-\begin{enumerate}
-\item the implicit tags build from the tags and the current part name or field index,
-\item the implicit tag build from the item id and the current part name or field index,
-\item the implicit tag \verb+all+,
-\item the other tags,
-\item the item id.
-\end{enumerate}
-
-Here are examples of possible bindings.
-
-\begin{enumerate}
-\item \verb+$zinc->bind($id, '<1>', \&acallback);+\\
- will call \verb+acallback+ if mouse button 1 is clicked anywhere over item \verb+$id+;
-\item \verb+$zinc->bind('selected', '<1>', \&acallback);+\\
- the click must be anywhere over any item associated with the \verb+selected+ tag;
-\item \verb+$zinc->bind('foo:0', '<1>', \&acallback);+\\
- the click must occurs over field 0 of an item with tag \verb+foo+;
-\item \verb+$zinc->bind("$id:3", '<1>', \&acallback);+\\
- the click must be over field 3 of item \verb+$id+, and the field must exists in the item;
-\item \verb+$zinc->bind("$id:speedvector", '<1>', \&acallback);+\\
- the click must be over a part named \verb+speedvector+ (item track) in item \verb+$id+,
- the part must exists in the
-item.%$
-\end{enumerate}
-
-
-\section{Text indices}
-\concept{indices}
-
-Indices are used to specify a character position in textual items such as the \objectref{text}
-item. Indices are accepted as parameters by commands managing text: \cmdref{cursor},
-\cmdref{index}, \cmdref{insert}, \cmdref{dchars} and \cmdref{select}.
-
-\begin{description}
-\item{\ident{number}} This should be an integer giving the character position within the
- text of the item. The indices are zero based. A number less than zero is treated as zero
- and a number greater than the text length is rounded to the text length. A number equal to
- the text length refers to the position past the last character in the text.
-\item{\ident{end}} Refers to the position past the last character in the text. This is the
- same as specifying a number equal to the text length.
-\item{\ident{insert}} Refers to the character just before the insertion cursor in the
- item.
-\item{\ident{sel.first}} Refers to the first character of the selection in the item. If
- the selection is not in the item, this form returns an error.
-\item{\ident{sel.last}} Refers to the last character of the selection in the item. If the
- selection is not in the item, this form returns an error.
-\item{\ident{@x,y}} Refers to the character at the point given by \ident{x} and \ident{y},
- \ident{x} and \ident{y} are interpreted as window coordinates. If the point lies outside
- of the area corvered by the item, they refer to the first or last character in the line
- that is closest to the point.
-\item{\ident{bol}} refers to the beginning of line
-\item{\ident{eol}} refers to the end of line
-\item{\ident{bow}} refers to the beginning of word
-\item{\ident{eow}} refers to the end of word
-\item{\ident{up}} refers to previous line
-\item{\ident{down}} refers to next line
-\end{description}
-
-
-%%
-%%
-%% C h a p t e r : W i d g e t c o m m a n d s
-%%
-%%
-\chapter{Widget commands}
-\concept{commands}
-
-In this chapter, we first list all commands by categories, then we details each command, by alphabetical order.
-
-\section{Categories of commands}
-\concept{commandsCategories}
-
-\begin{itemize}
-
-\item{Items creation and deletion} : \cmdref{add} \cmdref{becomes} \cmdref{clone} \cmdref{remove}
-
-\item{Accessing options and attributes} : \cmdref{chggroup} \cmdref{configure}
-\cmdref{coords} \cmdref{gettags} \cmdref{group} \cmdref{itemcget} \cmdref{itemconfigure}
-
-\item{Accessing field attributes of track, waypoint and tabular} : \cmdref{currentpart}
-\cmdref{hasfields} \cmdref{itemcget} \cmdref{itemconfigure} \cmdref{numparts}
-
-\item{Transformations} : \cmdref{coords} \cmdref{rotate} \cmdref{scale} \cmdref{skew} \cmdref{tapply}
-\cmdref{tcompose} \cmdref{tdelete} \cmdref{tget} \cmdref{transform} \cmdref{translate} \cmdref{treset}
-\cmdref{tsave} \cmdref{tset}
-
-\item{Groups, Display list and Priorities} : \cmdref{chggroup} \cmdref{find}('ancestors') \cmdref{group} \cmdref{lower}
-\cmdref{raise}
-
-\item{Tag management} : \cmdref{addtag} \cmdref{dtag} \cmdref{find} \cmdref{gettags} \cmdref{hastag}
-
-\item{Text management (text item and text fields} : \cmdref{cursor} \cmdref{dchars} \cmdref{focus}
-\cmdref{index} \cmdref{insert} \cmdref{select}
-
-\item{Bindings} : \cmdref{bind} \cmdref{focus}
-
-\item{Coordinates} : \cmdref{anchorxy} \cmdref{bbox} \cmdref{coords} \cmdref{contour}
-\cmdref{fit} \cmdref{hasanchor} \cmdref{smooth} \cmdref{transform} \cmdref{vertexat}
-
-\item{Named resources} : \cmdref{gname} \cmdref{gdelete} \cmdref{tsave}
-
-\item{Micellanous} : \cmdref{monitor} \cmdref{postscript} \cmdref{type}
-
-\end{itemize}
-
-
-\section{Commands by alphabetical order}
-\concept{commandsAlphabetically}
-
-The available commands are listed in alphabetical order.
-
-The command set for the TkZinc widget is much inspired by the Canvas command set. Someone
-comfortable with the Canvas should not have much trouble using the TkZinc's commands.
-Eventually, the command set will be a superset of the Canvas command set. Anyway
-some commands depart radically from the equivalent in the Canvas. For example, the user
-should be aware that \cmdref{scale} and \cmdref{translate} do not behave in the same
-way at all; \cmdref{find} and \cmdref{addtag} have been extended to support groups,
-etc. So use the available knowledge with some care.
-
-In the Perl/Tk version, the commands returning a list, return a Perl array (not a
-reference) and all list parameters are given as array references.
-
-\vspace{.5cm}
-\zinccmd{add}{?type group? ?initargs? ?option value? ... ?option value?}
-
-{\tt\large @types = \$zinc->{\bf add}();}\\
-{\tt\large \$id = \$zinc->{\bf add}(type, group);}\\
-{\tt\large \$id = \$zinc->{\bf add}(type, group, initargs);}\\
-{\tt\large \$id = \$zinc->{\bf add}(type, group, initargs, option=>value, ..., ?option=>value?);}
-
-\begin{blockindent}
- This command is used to create new items in a TkZinc widget. It can be called with no
- parameters to return the list of all item types currently known by TkZinc. It can also be
- called with a valid item type as first parameter and a group item as second parameter to
- create a new item of this type in the given group.
-
- After these first two parameters come some item type specific arguments. Here is
- detailed description of these arguments by type:
- \begin{description}
- \item{\objectref{arc}}\\
- The arc type expects a list of four floating point numbers \verb+xo yo xc yc+,
- giving the coordinates of the origin and the corner of the enclosing rectangle.
- The origin should be the top left vertex of the enclosing rectangle and the
- corner the bottom right vertex of the rectangle.
- \item{\objectref{curve}}\\
- The curve type expects either a flat list or a list of lists. In the first case, the flat list
- must be a list of floating point numbers \verb+x0 y0 x1 y1 ... xn yn+,
- giving the coordinates of the curve vertices. The number of values should be
- even (or the last value will be discarded) but the list can be empty to build
- an empty invisible curve. In the second case, the list must contain lists of 2 or 3
- elements: xi, yi and and an optionnal point type. Currently, the only available point type
- is 'c' for a cubic bezier control point. For example in Perl/Tk, the following list
- is an example of 2 beziers segments with a straight segment in-between:
-
-\code{
-( [x0, y0], [x1, y1, 'c'], [x2, y2, 'c'], [x3, y3],
- [x4, y4, 'c'], [x5, y5] )
-}
-
- As there is only on control point, \code{[x4, y4, 'c']} , for the second cubic bezier,
- the omitted second control point will be defaulted to the same point.
- A curve can be defined later with the \cmdref{contour}
- or \cmdref{coords} commands. As a side effect of the curve behavior, a one vertex
- curve is essentially the same as an empty curve, it only waste some more memory.
- \item{\objectref{rectangle}}\\
- The rectangle type expects a list of four floating point numbers \verb+xo yo xc yc+,
- giving the coordinates of the origin and the corner of the rectangle.
- \item{\objectref{triangles}}\\
- The triangles type expects a list of at least 6 floating point numbers
- \verb+x0 y0 x1 y1+ \verb+... xn yn+, giving the coordinates of the vertices of the triangles
- composing this item. The triangles layout is defined by the attribute
- \attributeref{triangles}{fan}. If \attributeref{triangles}{fan} is true, the triangles
- are arranged in a fan with the first point being the center and the other
- points defining the perimeter. If \attributeref{triangles}{fan} is false, the
- triangles are arranged in a strip.
- \item{\objectref{tabular}, \objectref{track}, \objectref{waypoint}}\\
- These types expect the number of fields they will manage in the label or
- tabular form. This number must be greater or equal to zero.
- \item{\objectref{group}, \objectref{icon}, \objectref{map}, \objectref{reticle}, \objectref{text}, \objectref{window}}\\
- These types do not expect type specific arguments.
- \end{description}
-
- Following the creation args the command accept any number of
- attributes\ -\ values pairs to configure the newly created item.
- All the configurable item type attributes are valid in this context. The
- command returns the item id.
-\end{blockindent}
-
-
-\zinccmd{addtag}{tag searchSpec ?arg arg ...?}
-
-{\tt\large \$zinc->{\bf addtag}(tag, searchSpec);}
-
-\begin{blockindent}
- This command add the given tag to all items matching the
- search specification. If the tag is already present on some item,
- nothing is done for that item. The command has no effect if no
- item satisfy the given criteria. The command returns an empty
- string.
-
- Many commands take a group as a starting point for the search. If no
- group is given, the root group is assumed. In any cases, the starting
- group will not be reported in the search result. This means that the
- root group will never be reported in a search and that tags cannot be
- attached to it except in specifying its id.
-
- The search specification and the associated arguments can
- take the following forms:
-
- \begin{itemize}
- \item{\tt\large
- pathname {\bf addtag} tag above tagOrId \\
- \$zinc->{\bf addtag}(tag, 'above', tagOrId);}
-
- Selects the item just above the one given by {\tt tagOrId}. If
- {\tt tagOrId} names more than one item, the topmost of these
- items in the display list will be used. If {\tt tagOrId} does
- not refer to any item then nothing happen.
-
- \item{\tt\large
- pathname {\bf addtag} tag all ?inGroup? ?recursive?\\
- \$zinc->{\bf addtag}(tag, 'all', ?inGroup?, ?recursive?);}
-
- This form is no more allowed since version 3.2.6 of TkZinc.
- Please use a form '"withtag", "all"' as documented below.
-
- \item{\tt\large
- pathname {\bf addtag} tag atpriority priority ?tagOrId?\\
- \$zinc->{\bf addtag}(tag, 'atpriority', priority, ?tagOrId?);}
-
- Selects all the items at the given priority. The tagOrId optional
- parameter can be specified to restrict the search. It specifies a
- group to start with instead of the root group and it can be used to
- control if the search should be recursive or not (see \conceptref{PathTags}{pathTags} for
- more on this subject).
-
- \item{\tt\large
- pathname {\bf addtag} tag ancestors tagOrId ?tagOrId2?\\
- \$zinc->{\bf addtag}(tag, 'ancestors', tagOrId, ?tagOrId2?);}
-
- Selects all ancestors (i.e.\ parent groups) of tagOrId. If
- {\tt tagOrId} names more than one item, the first, (or the topmost)
- of these items in the display list will be used. If ?tagOrId2? is specified,
- only parent groups with this tag are selected.
-
- \item{\tt\large
- pathname {\bf addtag} tag below tagOrId\\
- \$zinc->{\bf addtag}(tag, 'below', tagOrId);}
-
- Selects the item just below the one given by {\tt tagOrId}. If
- {\tt tagOrId} names more than one item, the lowest of these
- items in the display list will be used. If {\tt tagOrId} does
- not refer to any item then nothing happen.
-
- \item{\tt\large
- pathname {\bf addtag} tag closest x y ?halo? ?startItem?, ?recursive?\\
- \$zinc->{\bf addtag}(tag, 'closest', x, y, ?halo?, ?startItem?, ?recursive?);}
-
- Selects the item closest to the point {\tt x - y}. Any item overlapping
- the point is considered as closest and the topmost is selected. If {\tt halo}
- is given, it defines the size of the point {\tt x - y}. {\tt halo} must
- be a non negative integer. If {\tt start} is specified, it must be
- an item tag or id. If it names a group and this group is not atomic,
- the search starts with the first item of this group.
- If it names a non group item or an atomic group (for a tag, the lowest
- item with the tag is considered), the search starts with the item
- below {\tt start} instead of the first item in the display
- order. If {\tt startItem} does not name a valid item, it is ignored.
- If {\tt recursive} is false the search is limited to
- the starting group. If set to true, not specified or ``override'',
- the search proceed from the starting group down the hierarchy
- rooted at this group. ``override'' forces the search to explore
- atomic groups and report the most specific item instead of the
- group itself.
-
- \item{\tt\large
- pathname {\bf addtag} tag enclosed xo yo xc yc ?inGroup? ?recursive?\\
- \$zinc->{\bf addtag}(tag, 'enclosed', xo, yo, xc, yc, ?inGroup?, ?recursive?);}
-
- Selects all the items completely enclosed in the rectangle whose
- origin is at {\tt xo - yo} and corner at {\tt xc - yc}. {\tt xc}
- must be no greater than {\tt xo} and {\tt yo} must be no greater
- than {\tt yc}. All coordinates must be integers. {\tt inGroup} specifies
- a group to start with instead of the root group.
- If {\tt recursive} is false the search is limited to
- the starting group. If set to true, not specified or ``override'',
- the search proceed from the starting group down the hierarchy
- rooted at this group. ``override'' forces the search to explore
- atomic groups and report the most specific item instead of the
- group itself.
-
- It may be necessary to update the TkZinc internal geometry with a call
- to {\tt update} if the current state is not stable (i.e before calling
- the main loop or in a callback after modifying the transform or doing
- something else affecting the geometry of items).
-
- \item{\tt\large
- pathname {\bf addtag} tag overlapping xo yo xc yc ?inGroup? ?recursive?\\
- \$zinc->{\bf addtag}(tag, 'overlapping', xo, yo, xc, yc, ?inGroup?, ?recursive?);}
-
- Selects all the items that overlaps or are enclosed in the rectangle
- whose origin is at {\tt xo - yo} and corner at {\tt xc - yc}. {\tt xc}
- must be no greater than {\tt xo} and {\tt yo} must be no greater than
- {\tt yc}. All coordinates must be integers. {\tt inGroup} specifies
- a group to start with instead of the root group.
- If {\tt recursive} is false, the search is limited to the starting
- group. If set to true, not specified or ``override'',
- the search proceed from the starting group down the hierarchy
- rooted at this group. ``override'' forces the search to explore
- atomic groups and report the most specific item instead of the
- group itself.
-
- See also the {\tt enclosed} variant above for a discussion on updating the geometry.
-
- \item{\tt\large
- pathname {\bf addtag} tag withtag tagOrId\\
- \$zinc->{\bf addtag}(tag, 'withtag', tagOrId);}
-
- Selects all the items given by {\tt tagOrId}.
-
- \item{\tt\large
- pathname {\bf addtag} tag withtype type ?tagOrId?\\
- \$zinc->{\bf addtag}(tag, 'withtype', type, ?tagOrId?);}
-
- Selects all the items of type {\tt type}. The tagOrId optional
- parameter can be specified to restrict the search. It specifies a
- group to start with instead of the root group and it can be used to
- control if the search should be recursive or not (see \conceptref{PathTags}{pathTags} for
- more on this subject).
- \end{itemize}
-\end{blockindent}
-
-
-\zinccmd{anchorxy}{tagOrId anchor}
-
-{\tt\large (\$x, \$y) = \$zinc->{\bf anchorxy}(tagOrId, anchor);}
-
-\begin{blockindent}
- Returns the \emph{window coordinates} of an item anchor. If no item is named by {\tt tagOrId}
- or if the item doesn't support anchors, an error is raised. If more than one item match
- {\tt tagOrId}, the topmost in display list order is used.
-\code{
-\# for example to get the lower right corner of a text item\\
-(\$x ,\$y) = \$zinc->anchorxy('myTextTag', 'se');
-}
-
-\end{blockindent}
-
-
-\zinccmd{bbox}{?-field fieldNo? ?-label? tagOrId ?tagOrId ...?}
-
-{\tt\large (\$xo, \$yo, \$xc, \$yc) = \\
-\$zinc->{\bf bbox}(?-field fieldNo? ?-label? tagOrId, ?tagOrId ...?);}
-
-\begin{blockindent}
- Returns a list of 4 numbers describing the \emph{window coordinates} of the origin
- and corner of a rectangle bounding all the items named by the {\tt tagOrId}
- arguments.
- If no items are named by {\tt tagOrId} or if the matching items have an empty bounding
- box, an empty string is returned.
- The {\tt -field} and {\tt -label} options can be used to query the bounding box
- of an item's field or an item's label. These two options are mutually exclusives.
- When one of these options is specified, the bbox command is applied to the first
- item selected by the tagOrId arguments. If no labelformat has been set for the item,
- bbox will return an empty array.
-\end{blockindent}
-
-
-\zinccmd{becomes}{}
-
-{\tt\large \$zinc->{\bf becomes}();}
-
-\begin{blockindent}
- Not yet implemented.
-\end{blockindent}
-
-
-\zinccmd{bind}{tagOrId ?part? ?sequence? ?command?}
-
-{\tt\large @bindings = \$zinc->{\bf bind}(tagOrId, ?part?);}\\
-{\tt\large @binding = \$zinc->{\bf bind}(tagOrId, ?fpart?, sequence);}\\
-{\tt\large \$zinc->{\bf bind}(tagOrId, ?part?, sequence, '');}\\
-{\tt\large \$zinc->{\bf bind}(tagOrId, ?part?, sequence, command);}
-
-\begin{blockindent}
- This command associates {\tt command} with the item tag, item id, part tag {\tt
- tagOrId}. If an event sequence matching {\tt sequence} occurs for an item, or an item
- part, the command will be invoked. If all parameters are specified a new binding
- between {\tt sequence} and {\tt command} is established, overriding any existing binding
- for the sequence. If the first character of {\tt command} is ``+'', then {\tt command}
- augments the existing binding instead of replacing it. In this case the command returns
- an empty string. If the {\tt command} parameter is omitted, the command returns the {\tt
- command} associated with {\tt tagOrId} and {\tt sequence} or an error is raised if there
- is no such binding. If only {\tt tagOrId} is specified the command returns a list of all
- the sequences for which there are bindings for {\tt tagOrId}.
-
- This widget command is similar to the Tk \ident{bind} command except that it operates on
- TkZinc items instead of widgets. Another difference with the \ident{bind} command
- is that only mouse and keyboard related events can be specified (such as \ident{Enter},
- \ident{Leave}, \ident{ButtonPress}, \ident{ButtonRelease}, \ident{Motion},
- \ident{KeyPress}, \ident{KeyRelease}). The \ident{bind} manual page is the most
- accurate place to look for a definition of {\tt sequence} and {\tt command} and for a
- general understanding of how the binding mecanism works.
-
- The handling of events in the widget is done with respect to the current item and when
- applicable the current item part (see \conceptref{Item ids, tags and indices}{tagOrId} for a
- discussion of the \ident{current} tag and the special tags used in
- bindings). \ident{Enter} and \ident{Leave} events are trigerred for an item when it
- becomes or cease to be the current item. Mouse related events are reported with respect
- to the current item. Keyboard related events are reported with respect to the focus item
- if it exists (See the \cmdref{focus} command for more on this).
-
- It is possible that several bindings match a particular event sequence. When this
- occurs, all matching bindings are triggered. The order of invocation is as follow: the
- binding associated with the tag \ident{all} is invoked first, followed by the bindings
- associated with the item tags in order, followed by the binding associated with the item
- id, followed by bindings associated with the item part tags if relevant, followed by
- the binding associated with the item part if relevant. If there are more than one
- binding for a single tag or id, only the most specific is triggered.
-
- Two syntaxes are available for addressing item parts (for items having part ie.
- \objectref{track} \objectref{waypoint} and \objectref{tabular}): either an Id
- of the following form: {\tt id:part} or by using the optionnal {\tt part} argument.
-
- If bindings have been registered for the widget window using the \ident{bind} command,
- they are invoked in addition to bindings registered for the items using this widget
- command. The bindings for items will be invoked before the bindings for the window.
-\end{blockindent}
-
-
-\zinccmd{cget}{option}
-
-{\tt\large \$val = \$zinc->{\bf cget}(option);}
-
-\begin{blockindent}
- Returns the current value of the widget option given by {\tt option}.
- {\tt option} may be any of the options described in the
- chapter \conceptref{Widget options}{options}.
-\end{blockindent}
-
-
-\zinccmd{chggroup}{tagOrId group ?adjustTransform?}
-
-{\tt\large \$zinc->{\bf chggroup}(tagOrId, group, ?adjustTransform.?);}
-
-\begin{blockindent} Move the item described by {\tt tagOrId} in the group described by
-{\tt group}. If {\tt tagOrId} or {\tt group} describes more than one item, the first in
-display list order will be used. If {\tt adjustTransform} is specified, it will be
-interpreted as a boolean. A true value will lead to an adjustment of the item transform in
-order to maintain an identical display rendering of the item regardless of its new
-position in the display hierarchy. If {\tt adjustTransform} is omitted, it defaults to
-false.
-\end{blockindent}
-
-
-\zinccmd{clone}{tagOrId ?attr value ...?}
-
-{\tt\large \$id = \$zinc->{\bf clone}(tagOrId, ?attr=>value, ...?);}
-
-\begin{blockindent}
- Create an exact copy of all the items described by {\tt tagOrId}. The copy goes
- recursively for group items (deep copy). After copying the pairs {\tt attr value} are
- used, if any, to reconfigure the items. Any attribute that as no meaning in the context
- of some item is ignored. The items down the hierarchy of group items are not concerned
- by the configuration phase. The command returns the list of cloned items id in creation
- order (display list order of the models). No item id will be returned for items cloned
- in the hierarchy of cloned groups.
-
-\end{blockindent}
-
-
-\zinccmd{configure}{?option? ?value? ?option value ...?}
-
-{\tt\large @options = \$zinc->{\bf configure}();}\\
-{\tt\large @option = \$zinc->{\bf configure}(option);}\\
-{\tt\large \$zinc->{\bf configure}(option=>value, ?option=>value,...?);}
-
-\begin{blockindent}
- Query or modify the options of the widget. If no {\tt option} is given, returns a list
- describing all the supported options in the standard format for Tk options (see the
- chapter \conceptref{Widget options}{options} for a list of available options). If an
- {\tt option} is specified without a {\tt value}, the command returns a list describing
- the named option in the standard Tk format. If some {\tt option - value} pairs are
- given, then the corresponding options are changed and the command returns an empty
- string.
-\end{blockindent}
-
-
-\zinccmd{contour}{tagOrId ?operatorSpec coordListOrTagOrId?}
-
-{\tt\large \$contourNum = \$zinc->{\bf contour}(tagOrId);}\\
-{\tt\large \$contourNum = \$zinc->{\bf contour}(tagOrId, operatorAndFlag, coordListOrTagOrId);}
-
-\begin{blockindent}
- Manipulate contours on items that can handle multiples geometric contours. Currently
- only curve items can do this.
-
- {\tt tagOrId} specifies the item whose contours will be modified. If {\tt tagOrId}
- describes more than one item, the first in display list order will be used.
-
- If the command is invoked with only the tagOrId parameter, it returns the number of
- contours composing the item. In fact it always returns the number of contours after
- a command has been conducted, it happens that with this reduced form nothing is done
- except returning the number of contours.
-
- On items that do not support multiple contours, the returned value is 0 or 1 depending
- on the item having a contour or not. \objectref{track}, \objectref{waypoint},
- \objectref{reticle}, \objectref{group}, \objectref{map}, and yield 0
- while \objectref{rectangle}, \objectref{tabular}, \objectref{arc}, \objectref{icon},
- \objectref{triangles}, \objectref{text}, and \objectref{window} yield 1.
-
- {\tt coordListOrTagOrId} specifies a list of coordinates (either a flat list of X and Y, or
- a list similar to the one allowed for a curve item) or an item describing a
- contour. If a flat list is specified it should contain an even number of floating point values
- specifying the contour vertices X and Y in order. If a tag or an id is specified, it is
- should be from one of these classes: arc, curve, icon, rectangle, tabular, text,
- window. The external shape of the item will be used as the contour. If {\tt
- coordListOrTagOrId} describes more than one item, the first in display list order will
- be used.
-
- {\tt operatorAndFlag} specifies the operation that will be carried. This can be:
-
- \begin{description}
- \item{\ident{add}} to extend the surface of the curve. In this case there is a mandatory
- flag describing the way the contour will be added. It may take the following values:
- \begin{description}
- \item{0} the list of points is taken unchanged. In this case, the {\tt coordListOrTagOrId}
- parameter cannot be a tag and must be an explicit list of points.
- \item{1} the list of points is reverted, if needed, so that the points defines
- a {\bf counterclockwise} contour.
- \item{-1} the list of points is reverted,if needed, so that the points defines
- a {\bf clockwise} contour.
- \end{description}
- The exact graphical effect depends on the value of the \attributeref{curve}{fillrule}
- as described in the \attrtyperef{fillrule} type description.
- \item{\ident{remove}} to remove an existing contour
- \end{description}
-
- The following operations are no more available: \ident{diff},
- \ident{inter}, \ident{union}, \ident{xor};
- An error is generated if the items are not of a correct type or if the coordinate list
- is malformed.
-
-\end{blockindent}
-
-
-\zinccmd{coords}{tagOrId ?add/remove? ?contour? ?index? ?coordList?}
-
-{\tt\large \$zinc->{\bf coords}(tagOrId, ?add/remove?, ?contour?, ?index?, ?coordList?);}
-
-\begin{blockindent}
- Query or changes the coordinates of the item described by {\tt tagOrId}. If the
- item is a group, query or set the translation applied to the group. If {\tt
- tagOrId} describes more than one item, the first in display list order is used. The
- optional {\tt contour} gives the contour, if available, that should be operated. The
- default contour is 0. The optional {\tt index} gives the vertex index that should be
- operated in the given contour. The optional {\tt coordList} is either a flat list (of
- one or more vertices described as X, Y floating point values) or a list of lists
- [X Y ?type?] such as described in the curve item. The coordinates will be used to
- replace or add coordinates to the current contour.
-
- Almost all items can be manipulated by this command, the map item is the only current
- exception. The effect of the command can be quite different depending on the item. For
- icons, texts, windows, tabulars, the coordinates of the anchor can be modified or
- read. For groups, the coordinates of the origin of the transformation can be set or
- read. For tracks and waypoints, the coordinates of the current position can be set or
- read. For tracks setting the current position this way will make the previous position
- shift into the history. For reticles, the coordinates of the center can be set or
- read. For arcs and rectangles, the coordinates of the origin and corner can be set or
- read. For curves and triangles, coordinates of all points defining the item can be set or
- read. For all items that do not support multiple contours (currently all except curves)
- the {\tt contour} parameter should be omitted or specified as zero.
-
- When {\tt coords} is used to get potentially more than one point, it returns {\bf always}
- a list of lists. Each sub list contains X, Y, and 'c' if the point is a
- bezier control point.
-
- When {\tt coords} is used to get exactly one point (either because it is used to
- get the nth point of an item or because the item always has exactly one point (e.g.
- the item is a group, track, waypoint, map, or reticle)), it returns
- a flat list of 2 (or may be 3 for control points of curve items) values.
-
- The optional parameters must be combined to produce a given behavior. Here are the
- various form recognized by the command:
-
- \begin{itemize}
- \item{\tt\large
- pathname {\bf coords} tagOrId contourIndex\\
- @coords = \$zinc->{\bf coords}(tagOrId, contourIndex);}
-
- Get all coordinates of contour at contourIndex. All items can answer if contourIndex
- is zero. Curves can handle other contours.
-
- \item{\tt\large
- pathname {\bf coords} tagOrId contourIndex coordList\\
- \$zinc->{\bf coords}(tagOrId, contourIndex, coordList);}
-
- Set all coordinates of contour at contourIndex. All items can do it if contourIndex is
- zero. Curves can handle other contours. For groups, icons, texts, windows, tabulars,
- reticles, tracks, waypoints, only the first vertex will be used. For rectangles and
- arcs, only the first two vertices will be used. Curves can handle any number of vertices.
-
- \item{\tt\large
- pathname {\bf coords} tagOrId contourIndex coordIndex\\
- (\$x, \$y) = \$zinc->{\bf coords}(tagOrId, contourIndex, coordIndex);}
-
- Get coordinate at coordIndex in contour at contourIndex. All items can answer if
- contourIndex is zero. Curves can handle other contours. For groups, icons, texts,
- windows, tabulars, reticles, tracks, waypoints, coordIndex must be zero. For
- rectangles and arcs, coordIndex must zero or one.
-
- \item{\tt\large
- pathname {\bf coords} tagOrId contourIndex coordIndex coordList\\
- \$zinc->{\bf coords}(tagOrId, contourIndex, coordIndex, coordList);}
-
- Set coordinate at coordIndex in contour at contourIndex. All items can do it if
- contourIndex is zero. Curves can handle other contours. For groups, icons, texts,
- windows, tabulars, reticles, tracks, waypoints, coordIndex must be zero. For
- rectangles and arcs, coordIndex must zero or one. {\bf WARNING:} coordList must be a
- list of one list describing x, y and optionnaly the point type.
-
- \item{\tt\large
- pathname {\bf coords} tagOrId remove contourIndex coordIndex\\
- \$zinc->{\bf coords}(tagOrId, 'remove', contourIndex, coordIndex);}
-
- Remove coordinate at coordIndex in contour at contourIndex. Can only be handled by
- curves. Only curves can handle contourIndex other than zero.
-
- \item{\tt\large
- pathname {\bf coords} tagOrId add contourIndex coordList\\
- \$zinc->{\bf coords}(tagOrId, 'add', contourIndex, coordList);}
-
- Add coordinates at the end of contour at contourIndex. Can only be handled by curves.
- Only curves can handle contourIndex other than zero.
-
- \item{\tt\large
- pathname {\bf coords} tagOrId add contourIndex coordIndex coordList\\
- \$zinc->{\bf coords}(tagOrId, 'add', contourIndex, coordIndex, coordList);}
-
- Add coordinates at coordIndex in contour at contourIndex. Can only be handled by
- curves. Only curves can handle contourIndex other than zero.
- \end{itemize}
-
- And the slightly abbreviated forms:
-
- \begin{itemize}
- \item{\tt\large
- pathname {\bf coords} tagOrId\\
- @coords = \$zinc->{\bf coords}(tagOrId);}
-
- Get all coordinates of contour 0. See first form.
-
- \item{\tt\large
- pathname {\bf coords} tagOrId coordList\\
- \$zinc->{\bf coords}(tagOrId, coordList);}
-
- Set all coordinates of contour 0. See second form.
-
- \item{\tt\large
- pathname {\bf coords} tagOrId remove coordIndex\\
- \$zinc->{\bf coords}(tagOrId, 'remove', coordIndex);}
-
- Remove coordinate at coordIndex in contour 0. See fifth form.
-
- \item{\tt\large
- pathname {\bf coords} tagOrId add coordList\\
- \$zinc->{\bf coords}(tagOrId, 'add', coordList);}
-
- Add coordinates at the end of contour 0. See sixth form.
- \end{itemize}
-\end{blockindent}
-
-
-\zinccmd{currentpart}{}
-
-{\tt\large \$num = \$zinc->{\bf currentpart}();}
-
-\begin{blockindent}
- Returns a string specifying the item part that has the pointer. If the current item
- doesn't have parts or if the pointer is not over an item (no item has the
- \ident{current} tag) the command returns {\tt ""}. The string can be either an integer
- describing a field index or the name of a special part of the item. Consult each item
- description to find out which part names can be reported.
-\end{blockindent}
-
-
-\zinccmd{cursor}{tagOrId index}
-
-{\tt\large \$zinc->{\bf cursor}(tagOrId, index);}
-
-\begin{blockindent}
- Set the position of the insertion cursor for the items described by {\tt tagOrId} to be
- just before the character at {\tt index}. If some of the items described by {\tt
- tagOrId} don't support an insertion cursor, the command doesn't change them. The
- possible values for {\tt index} are described in the section \conceptref{Text indices}
- {indices}. The command returns an empty string.
-\end{blockindent}
-
-
-\zinccmd{dchars}{tagOrId first ?last?}
-
-{\tt\large \$zinc->{\bf dchars}(tagOrId, first);}\\
-{\tt\large \$zinc->{\bf dchars}(tagOrId, first, last);}
-
-\begin{blockindent}
- Delete the character range defined by the parameters {\tt first} and {\tt last}
- inclusive in all the items described by {\tt tagOrId}. Items that doesn't support text
- indexing are skipped by the command. If {\tt last} is not specified, the command
- deletes the character located at {\tt first}. The command returns an empty string. {\tt
- first} and {\tt last} are indices as described in \conceptref{Text indices}{indices}.
-\end{blockindent}
-
-
-\zinccmd{dtag}{tagOrId ?tagToDelete?}
-
-{\tt\large \$zinc->{\bf dtag}(tagOrId);}\\
-{\tt\large \$zinc->{\bf dtag}(tagOrId, tagToDelete);}
-
-\begin{blockindent}
- Delete the tag {\tt tagToDelete} from the list of tags associated with each item named
- by {\tt tagOrId}. If an item doesn't have the tag then it is leaved unaffected. If {\tt
- tagToDelete} is omitted, {\tt tagOrId} is used instead. The command returns an empty
- string as result.
-\end{blockindent}
-
-
-\zinccmd{find}{searchCommand ?arg arg ...?}
-
-{\tt\large @items = \$zinc->{\bf find}(searchCommand, ?arg?, ...);}
-
-\begin{blockindent}
- This command returns the list of all items selected by {\tt searchCommand} and the {\tt
- args}. See the \cmdref{addtag} command for an explanation of {\tt searchCommand} and the
- various {\tt args}. The items are sorted in drawing order, topmost first. For example:\\
- \code{ \# to get the item under the mouse cursor:\\
- \$item = \$zinc->find('withtag', 'current');\\
-
- \# to get the closest item of a point:\\
- \$closest = \$zinc->find ('closest', \$x, \$y);\\
-
- \# to get direct children of an atomic group with a pathTag:\\
- @children = \$zinc->find('withtag', ".atomicGroup.");\\
-
- \# to get all groups recursively contained in a group\\
- @groups = \$zinc->find('withtype', 'group', ".aGroup*");
- }
-
- As detailled in \cmdref{addtag} command the following searchCommands are possible:
- \begin{itemize}
- \item{\tt\large
- pathname {\bf find} above tagOrId \\
- \$zinc->{\bf find}('above', tagOrId);}
- \item{\tt\large
- pathname {\bf find} atpriority priority ?tagOrId?\\
- \$zinc->{\bf find}('atpriority', priority, ?tagOrId?);}
- \item{\tt\large
- pathname {\bf find} ancestors tagOrId ?tagOrId2?\\
- \$zinc->{\bf find}('ancestors', tagOrId, ?tagOrId2?);}
- \item{\tt\large
- pathname {\bf find} below tagOrId\\
- \$zinc->{\bf find}('below', tagOrId);}
- \item{\tt\large
- pathname {\bf find} closest x y ?halo? ?startItem?, ?recursive?\\
- \$zinc->{\bf find}('closest', x, y, ?halo?, ?startItem?, ?recursive?);}
- \item{\tt\large
- pathname {\bf find} enclosed xo yo xc yc ?inGroup? ?recursive?\\
- \$zinc->{\bf find}('enclosed', xo, yo, xc, yc, ?inGroup?, ?recursive?);}
- \item{\tt\large
- pathname {\bf find} overlapping xo yo xc yc ?inGroup? ?recursive?\\
- \$zinc->{\bf find}('overlapping', xo, yo, xc, yc, ?inGroup?, ?recursive?);}
- \item{\tt\large
- pathname {\bf find} withtag tagOrId\\
- \$zinc->{\bf find}('withtag', tagOrId);}
- \item{\tt\large
- pathname {\bf find} withtype type ?tagOrId?\\
- \$zinc->{\bf find}('withtype', type, ?tagOrId?);}
- \end{itemize}
-\end{blockindent}
-
-
-\zinccmd{fit}{coordList error}
-
-{\tt\large @controls = \$zinc->{\bf fit}(coordList, error);}
-
-\begin{blockindent}
- This command fits a sequence of Bezier segments on the curve described by the vertices
- in {\tt 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 {\tt error}
- distance from the given curve. {\tt 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.
-\end{blockindent}
-
-
-\zinccmd{focus}{?tagOrId? ?itemPart?}
-
-{\tt\large (\$item, \$part) = \$zinc->{\bf focus}();}\\
-{\tt\large \$zinc->{\bf focus}(tagOrId, ?itemPart?);}
-
-\begin{blockindent}
- Set the keyboard focus to the item described by {\tt tagOrId}, and to
- its {\tt itemPart} if the item has parts. If {\tt tagOrId} describes
- more than one item, the first item in display list order that accept the focus is
- used. If no such item exists, the command has no effect. If {\tt tagOrId} is an empty
- string the focus is reset and no item has the focus. If {\tt tagOrId} is not specified,
- the command returns a list of two elements. The first is the id of the item with the focus
- or an empty string if no item has the focus. The second is the item part or an empty
- string if not appliable.
-
- When the focus has been set to an item that support an insertion cursor, the item will
- display its cursor and the keyboard events will be directed to that item.
-
- The widget receive keyboard events only if it has the window focus. It may be necessary
- to use the Tk \ident{focus} command to force the focus to the widget window.
-
-\end{blockindent}
-
-
-\zinccmd{gdelete}{gradientName}
-
-{\tt\large \$zinc->{\bf gdelete}('fading');}
-
-\begin{blockindent}
- This command breaks the binding between the given gradient name and the named
- gradient. When the gradient will be no longer used it will be deallocated.
-\end{blockindent}
-
-
-\zinccmd{gettags}{tagOrId}
-
-{\tt\large @tags = \$zinc->{\bf gettags}(tagOrId);}
-
-\begin{blockindent}
- This command returns the list of all the tags associated with the item specified by {\tt
- tagOrId}. If more than one item is named by {\tt tagOrId}, then the topmost in display
- list order is used to return the result. If no item is named by {\tt tagOrId}, then the
- empty list is returned.
-\end{blockindent}
-
-
-\zinccmd{gname}{?gradientDesc? gradientName}
-
-{\tt\large \$zinc->{\bf gname}('black:100|white:0/0', 'fading');}\\
-{\tt\large \$exist = \$zinc->{\bf gname}('nameOrGradient');}
-
-\begin{blockindent}
- This command sets a name binding between the given gradient description and the given
- name. The name can be used in the same way the gradient description would be. The
- gradient will not be deallocated until the \cmdref{gdelete} command is invoqued on the
- name (and no item use the gradient). This feature can be a big performance gain when
- using many gradients in an animation, the name acts here as a caching mecanism.
-
- When gname is called with only one argument, it returns iehter false or the
- name of a named gradient if the argument is either a named gradient or the name
- of a named gradient.
-\end{blockindent}
-
-
-\zinccmd{group}{tagOrId}
-
-{\tt\large \$group = \$zinc->{\bf group}(tagOrId);}
-
-\begin{blockindent}
- Returns the group containing the item described by {\tt tagOrId}. If more than one item
- is named by {\tt tagOrId}, then the topmost in display list order is used to return the
- result.
-\end{blockindent}
-
-
-\zinccmd{hasanchors}{tagOrId}
-
-{\tt\large \$bool = \$zinc->{\bf hasanchors}(tagOrId);}
-
-\begin{blockindent}
- This command returns a boolean telling if the item specified by {\tt tagOrId} supports
- anchors. If more than one item is named by {\tt tagOrId}, then the topmost in display
- list order is used to return the result. If no items are named by {\tt tagOrId}, an
- error is raised.
-\end{blockindent}
-
-
-\zinccmd{hasfields}{tagOrId}
-
-{\tt\large \$bool = \$zinc->{\bf hasfields}(tagOrId);}
-
-\begin{blockindent}
- This command returns a boolean telling if the item specified by {\tt tagOrId} supports
- fields. If more than one item is named by {\tt tagOrId}, then the topmost in display
- list order is used to return the result. If no items are named by {\tt tagOrId}, an
- error is raised.
-\end{blockindent}
-
-
-\zinccmd{hastag}{tagOrId tag}
-
-{\tt\large \$bool = \$zinc->{\bf hastag}(tagOrId, tag);}
-
-\begin{blockindent}
- This command returns a boolean telling if the item specified by {\tt tagOrId} has the
- specified tag. If more than one item is named by {\tt tagOrId}, then the topmost in
- display list order is used to return the result. If no items are named by {\tt tagOrId},
- an error is raised.
-\end{blockindent}
-
-
-\zinccmd{index}{tagOrId index}
-
-{\tt\large \$num = \$zinc->{\bf index}(tagOrId, index);}
-
-\begin{blockindent}
- This command returns a number which is the numerical index in the item described by {\tt
- tagOrId} corresponding to {\tt index}. The possible forms for {\tt index} are described
- in \conceptref{Text indices}{indices}. The command returns a value between 0 and the
- number of character in the item. If {\tt tagOrId} describes more than one item, the index
- is processed in the first item supporting text indexing in display list order.
-\end{blockindent}
-
-
-\zinccmd{insert}{tagOrId before string}
-
-{\tt\large \$zinc->{\bf insert}(tagOrId, before, string);}
-
-\begin{blockindent}
- This command inserts {\tt string} in each item described by {\tt tagOrId} just before
- the text position described by {\tt before}. The possible values for {\tt before} are
- described in \conceptref{Text indices}{indices}. Items that doesn't support text
- indexing are skipped by the command. The command returns an empty string.
-\end{blockindent}
-
-
-\zinccmd{itemcget}{tagOrId ?fieldId? attr}
-
-{\tt\large \$val = \$zinc->{\bf itemcget}(tagOrId, attr);}\\
-{\tt\large \$val = \$zinc->{\bf itemcget}(tagOrId, field, attr);}
-
-\begin{blockindent}
- Returns the current value of the attribute given by {\tt attr} for the item named by
- {\tt tagOrId}. If {\tt tagOrId} name more than one item, the topmost in display list
- order is used. If {\tt field} is given, it must be a valid field index for the item or
- an error will be reported. If a field index is given, the command will interpret {\tt
- attr} as a field attribute (see \objectref{field}), otherwise it will be interpreted as
- an item attribute (see the chapter \conceptref{Item types}{items}). If the attribute is
- not available for the field or item type, an error is reported.
-\end{blockindent}
-
-
-\zinccmd{itemconfigure}{tagOrId ?fieldId? ?attr? ?value? ?attr value ...?}
-
-{\tt\large @attribs = \$zinc->{\bf itemconfigure}(tagOrId);}\\
-{\tt\large @attrib = \$zinc->{\bf itemconfigure}(tagOrId, attrib);}\\
-{\tt\large \$zinc->{\bf itemconfigure}(tagOrId, attrib=>value, ?attrib=>value?, ...);}\\
-{\tt\large @attrib = \$zinc->{\bf itemconfigure}(tagOrId, fieldId, attrib);}\\
-{\tt\large \$zinc->{\bf itemconfigure}(tagOrId, fieldId, attrib=>value, ?attrib=>value?, ...);}
-
-\begin{blockindent}
- Query or modify the attributes of an item or field. If no attribute is given, returns a
- list of lists describing all the supported attributes in the same format as for a single
- attribute, as described next. If a single attribute is specified without a value, the
- command returns a list describing the named attribute. Each attribute is described by a
- list with the following content: the attribute name, the attribute type, a boolean
- telling if the attribute is read-only, an empty string, and the current value of the
- attribute. In the two querying forms of the command the topmost item described by {\tt
- tagOrId} is used.
-
- If at least one attribute - value pair is given, then the corresponding attributes are
- changed for all the items described by {\tt tagOrId} and the command returns an empty
- string. If {\tt field} is given, it must be a valid field index for the item or an
- error will be reported. If a field index is given, the command will interpret the given
- attributes as field attributes, otherwise they will be interpreted as item attributes.
- If an attribute does not belong to the item or field, an error is reported. When configuring
- a set of item defiend by a tag, all items must then accept these attributes.
-\end{blockindent}
-
-
-\zinccmd{lower}{tagOrId ?belowThis?}
-
-{\tt\large \$zinc->{\bf lower}(tagOrId);}\\
-{\tt\large \$zinc->{\bf lower}(tagOrId, belowThis);}
-
-\begin{blockindent}
- Reorder all the items given by {\tt tagOrId} so that they will be under the item given
- by {\tt belowThis}. If {\tt tagOrId} name more than one item, their relative order will
- be preserved. If {\tt tagOrId} doesn't name an item, an error is raised. If {\tt
- belowThis} name more than one item, the bottom most them is used. If {\tt belowThis}
- doesn't name an item, an error is raised. If {\tt belowThis} is omitted the items are
- put at the bottom most position of their respective groups. The command ignore all items
- named by {\tt tagOrId} that are not in the same group than {\tt belowThis} or, if not
- specified, in the same group than the first item named by {\tt tagOrId}. The command
- returns an empty string. As a side affect of this command, the \ident{-priority}
- attribute of all the reordered items is ajusted to match the priority of the {\tt
- belowThis} item (or the priority of the bottom most item).
-\end{blockindent}
-
-
-\zinccmd{monitor}{?onOff?}
-
-{\tt\large \$bool = \$zinc->{\bf monitor}();}\\
-{\tt\large \$zinc->{\bf monitor}(onOff);}
-
-\begin{blockindent}
- This command controls the gathering of performance data. The data gathering is inited
- and turned on when the command is called with a boolean true parameter. The gathering is
- stopped if the command is called with a boolean false parameter. If the command is
- called with no parameters or with a boolean false parameter, it returns a string
- describing the currently collected data. The other form of the command returns the empty
- string.
-\end{blockindent}
-
-
-\zinccmd{numparts}{tagOrId}
-
-{\tt\large \$num = \$zinc->{\bf numparts}(tagOrId);}
-
-\begin{blockindent}
- This command tells how many fieldId are available for event bindings or for field
- configuration commands in the item specified by {\tt tagOrId}. If more than one item is
- named by {\tt tagOrId}, the topmost in display list order is used to return the
- result. If no items are named by {\tt tagOrId}, an error is raised. This command
- returns always 0 for items which do not support fields. The command \cmdref{hasfields}
- may be used to decide whether an item has fields.
-\end{blockindent}
-
-
-\zinccmd{postscript}{}
-
-{\tt\large \$zinc->{\bf postscript}();}
-
-\begin{blockindent}
- Not yet implemented.
-\end{blockindent}
-
-
-\zinccmd{raise}{tagOrId ?aboveThis?}
-
-{\tt\large \$zinc->{\bf raise}(tagOrId);}\\
-{\tt\large \$zinc->{\bf raise}(tagOrId, aboveThis);}
-
-\begin{blockindent}
- Reorder all the items given by {\tt tagOrId} so that they will be above the item given
- by {\tt aboveThis}. If {\tt tagOrId} name more than one item, their relative order will
- be preserved. If {\tt tagOrId} doesn't name an item, an error is raised. If {\tt
- aboveThis} name more than one item, the topmost in display list order is used. If {\tt
- aboveThis} doesn't name an item, an error is raised. If {\tt aboveThis} is omitted the
- items are put at the top most position of their respective groups. The command ignore
- all items named by {\tt tagOrId} that are not in the same group than {\tt aboveThis} or,
- if not specified, in the same group than the first item named by {\tt tagOrId}. The
- command returns an empty string. As a side affect of this command, the \ident{-priority}
- attribute of all the reordered items is ajusted to match the priority of the {\tt
- aboveThis} item (or the priority of the topmost item).
-\end{blockindent}
-
-
-\zinccmd{remove}{tagOrId ?tagOrId ...?}
-
-{\tt\large \$zinc->{\bf remove}(tagOrId, ?tagOrId?, ...);}
-
-\begin{blockindent}
- Delete all the items named by each {\tt tagOrId}. The command returns an empty string.
-\end{blockindent}
-
-
-\zinccmd{rotate}{tagOrId angle ?degree? ?centerX centerY?}
-
-{\tt\large \$zinc->{\bf rotate}(tagOrId, angle);}\\
-{\tt\large \$zinc->{\bf rotate}(tagOrId, angle, centerX, centerY);}
-
-\begin{blockindent}
- Add a rotation to the items or the transform described by {\tt tagOrId}. If {\tt
- tagOrId} describes a named transform then this transform is used to do the operation.
- If {\tt tagOrId} describes more than one item then all the items are affected by the
- operation. If {\tt tagOrId} describes neither a named transform nor an item, an error
- is raised. The angle is given in radian if {\tt degree} is omitted or false, if it is
- specified as true, the angle is in degrees. The last two optional parameters describe
- the center of rotation, which defaults to the origin.
-\end{blockindent}
-
-
-\zinccmd{scale}{tagOrIdOrTName xFactor yFactor ?centerX centerY?}
-
-{\tt\large \$zinc->{\bf scale}(tagOrIdOrTName, xFactor, yFactor);}\\
-{\tt\large \$zinc->{\bf scale}(tagOrIdOrTName, xFactor, yFactor, centerX, centerY);}
-
-\begin{blockindent}
- Add a scale factor to the items or the transform described by {\tt tagOrId}. If {\tt
- tagOrId} describes a named transform then this transform is used to do the operation.
- If {\tt tagOrId} describes more than one item then all the items are affected by the
- operation. If {\tt tagOrId} describes neither a named transform nor an item, an error
- is raised. A separate factor is specified for X and Y. The optional parameters
- describe the center of scaling, which defaults to the origin.
-\end{blockindent}
-
-
-\zinccmd{select}{option ?tagOrId? ?arg?}
-
-{\tt\large \$zinc->{\bf select}(option, ?tagOrId?, ?arg?);}
-
-\begin{blockindent}
- Manipulates the selection as requested by {\tt option}. {\tt tagOrId} describes the
- target item. This item must support text indexing and selection. If more than one item
- is referred to by {\tt tagOrId}, the first in display list order that support both text
- indexing and selection will be used. Some forms of the command include an {\tt index}
- parameter, this parameter describes a textual position within the item and should be a
- valid index as described in \conceptref{Text indices}{indices}. The valid forms of the
- command are :
-
- \begin{itemize}
- \item{\tt\large
- pathname {\bf select} adjust tagOrId index\\
- \$zinc->{\bf select}('adjust', tagOrdId, index);}
-
- Adjust the end of the selection in {\tt tagOrId} that is nearest to the character
- given by {\tt index} so that it is at {\tt index}. The other end of the selection is
- made the anchor for future select to commands. If the selection is not currently in
- {\tt tagOrId}, this command behaves as the select to command. The command returns an
- empty string.
-
- \item{\tt\large
- pathname {\bf select} clear\\
- \$zinc->{\bf select}('clear');}
-
- Clear the selection if it is in the widget. If the selection is not in the widget, the
- command has no effect. Return an empty string.
-
- \item{\tt\large
- pathname {\bf select} from tagOrId index\\
- \$zinc->{\bf select}('from', tagOrdId, index);}
-
- Set the selection anchor point for the widget to be just before the character given by
- {\tt index} in the item described by {\tt tagOrId}. The command has no effect on the
- selection, it sets one end of the selection so that future select to can actually set
- the selection. The command returns an empty string.
-
- \item{\tt\large
- pathname {\bf select} item\\
- (\$item, \$part) = \$zinc->{\bf select}('item');}
-
- Returns a list of two elements. The first is the id of the selected item if the selection
- is in an item on this widget; Otherwise the first element is an empty string. The second
- element is the part of the item (track, waypoint or tabular item only) or the empty string.
-
- \item{\tt\large
- pathname {\bf select} to tagOrId index\\
- \$zinc->{\bf select}('to', tagOrdId, index);}
-
- Set the selection to be the characters that lies between the selection anchor and {\tt
- index} in the item described by {\tt tagOrId}. The selection includes the character
- given by {\tt index} and includes the character given by the anchor point if {\tt
- index} is greater or equal to the anchor point. The anchor point is set by the most
- recent select adjust or select from command issued for this widget. If the selection
- anchor point for the widget is not currently in {\tt tagOrId}, it is set to the
- character given by index. The command returns an empty string.
- \end{itemize}
-
-\end{blockindent}
-
-
-\zinccmd{skew}{tagOrIdOrTName xSkewAngle ySkewAngle}
-
-{\tt\large \$zinc->{\bf skew}(tagOrIdOrTName, xSkewAngle, ySkewAngle);}
-
-\begin{blockindent}
- Add a skew (or shear) transform to the to the items or the transform described
- by {\tt tagOrIdOrTName}. If {\tt tagOrId} describes a named transform then this
- transform is used to do the operation. If {\tt tagOrId} describes more than
- one item then all the items are affected by the operation.
- If {\tt tagOrId} describes neither a named transform nor an item, an
- error is raised. The angles are given in radian.
-\end{blockindent}
-
-
-\zinccmd{smooth}{coordList}
-
-{\tt\large @coords = \$zinc->{\bf smooth}(coordList);}
-
-\begin{blockindent}
- This command computes a sequence of segments that will smooth the polygon
- described by the vertices in {\tt coordList} and returns a list of lists describing
- points of the generated segments. These segments are approximating a Bezier curve.
- {\tt 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.
-\end{blockindent}
-
-
-\zinccmd{tapply}{}
-
-{\tt\large \$zinc->{\bf tapply}();}
-
-\begin{blockindent}
- Not yet implemented.
-\end{blockindent}
-
-
-\zinccmd{tcompose}{tagOrIdOrTName tName ?invert?}
-
-{\tt\large \$zinc->{\bf tcompose}(tagOrIdOrTName, tName);}\\
-{\tt\large \$zinc->{\bf tcompose}(tagOrIdOrTName, tName, invert);}
-
-\begin{blockindent}
- Modify either the named transform {\tt tagOrIdOrTName} or the corresponding
- item by composing the {\tt tName} transform. The {\tt invert} boolean, if specified,
- causes the {\tt tName} transform to be inverted prior composition.
-
- If {\tt tagOrIdOrTName} describes neither a named transform nor an item, an error is
- raised. If {\tt tName} does not describe a named transform an error is raised.
-\end{blockindent}
-
-
-\zinccmd{tdelete}{tName}
-
-{\tt\large \$zinc->{\bf tdelete}(tName);}
-
-\begin{blockindent}
- Destroy a named transform. If the given name is not found among the named transforms, an
- error is raised.
-\end{blockindent}
-
-
-\zinccmd{tget}{tagOrIdOrTName ?selector?}
-
-{\tt\large (\$m00, \$m01, \$m10, \$m11, \$m20, \$m21) = \$zinc->{\bf tget}(tagOrIdOrTName);}\\
-{\tt\large (\$xtranslate, \$ytranslate, \$xscale, \$yscale, \$angle, \$xskew) =\\
- \$zinc->{\bf tget}(tagOrIdOrTName, 'all');}\\
-{\tt\large (\$xtranslate, \$ytranslate) = \$zinc->{\bf tget}(tagOrIdOrTName, 'translate');}\\
-{\tt\large (\$xscale, \$yscale) = \$zinc->{\bf tget}(tagOrIdOrTName, 'scale');}\\
-{\tt\large (\$angle) = \$zinc->{\bf tget}(tagOrIdOrTName, 'rotate');}\\
-{\tt\large (\$xskew) = \$zinc->{\bf tget}(tagOrIdOrTName, 'skew');}
-
-\begin{blockindent}
- With only one argument, get the six elements of the 3x4 matrix used in affine
- transformation for {\tt tagOrIdOrTName}. The result is compatible with the tset method.
- With optional second parameter 'all' returns the transform decomposed in translation,
- scale, rotation, skew and return the list in this order,
- With 'translation', 'scale', 'rotation', 'skew' optional second parameter,
- returns the corresponding values.
-\end{blockindent}
-
-
-\zinccmd{transform}{?tagOrIdFrom? tagOrIdTo coordList}
-
-{\tt\large @coords = \$zinc->{\bf transform}(tagOrIdTo, coordList);}\\
-{\tt\large @coords = \$zinc->{\bf transform}(tagOrIdFrom, tagOrIdTo, coordList);}
-
-\begin{blockindent}
- This command returns a list of coordinates obtained by transforming the coordinates
- given in {\tt coordList} from the coordinate space of the transform or item described by
- {\tt tagOrIdFrom} to the coordinate space of the transform or item described by {\tt
- tagOrIdTo}. If {\tt tagOrIdFrom} is omitted it defaults to the window coordinate
- space. If either {\tt tagOrIdFrom} or {\tt tagOrIdTo} describes more than one item,
- the topmost in display list order is used. If either {\tt tagOrIdFrom} or {\tt tagOrIdTo}
- doesn't describe either a transform or an item, an error is raised.
- The {\tt coordList} should either be a flat list containing an even number of
- coordinates each point having two coordinates, or a list of lists each sublist of the form
- [ X Y ?pointtype? ]. The returned coordinates list will be isomorphic to the list given
- as argument.
-
- It is possible to convert from window coordinate space to the coordinate space of any
- item. This is done by omitting {\tt ?tagOrIdFrom?} and specifying in {\tt tagOrIdTo},
- the id of the item. It can also be done by using the predefined tag 'device' as first argument.
-
- It is also possible to convert from the coordinate space of an item to the window
- coordinate space by using the predefined tag 'device' as second argument.
-
- For example:
-
- \begin{itemize}
- \item{\verb+($x, $y) = $zinc->transform('device', $mygroup, [$xdev, $ydev]);+}\\
- transforms the point described by \verb+$xdev,$ydev+ in window coordinates,
- to \verb+$mygroup+ coordinates in \verb+$x,$y+;
- \item{\verb+($xdev, $ydev) = $zinc->transform($mygroup, 'device', [$x, $y]);+}\\
- transforms the point described by \verb+$x,$y+ in \verb+$mygroup+
- coordinates, to window coordinates in \verb+$xdev,$ydev+
- \item{\verb+($x2, $y2) = $zinc->transform($group1, $group2, [$x1, $y1]);+}\\
- transforms the point described by \verb+$x1,$y1+ in \verb+$group1+ coordinates,
- to \verb+$group2+ coordinates in \verb+$x2,$y2+;%$
- \end{itemize}
-\end{blockindent}
-
-
-\zinccmd{translate}{tagOrIdOrTName xAmount yAmount ?absolute?}
-
-{\tt\large \$zinc->{\bf translate}(tagOrdIdOrTName, xAmount, yAmount, ?absolute?);}
-
-\begin{blockindent}
- Add a translation to the items or the transform described by {\tt tagOrIdOrTName}. If {\tt
- tagOrIdOrTName} describes a named transform then this transform is used to do the operation. If
- {\tt tagOrIdOrTName} describes more than one item then all the items are affected by the
- opration. If {\tt tagOrIdOrTName} describes neither a named transform nor an item, an error is
- raised. A separate value is specified for X and Y.
- If the optionnal {\tt ?absolute?} parameter is true, it will set an absolute translation to
- the {\tt tagOrIdOrTName}
-\end{blockindent}
-
-
-\zinccmd{treset}{tagOrIdOrTName}
-
-{\tt\large \$zinc->{\bf treset}(tagOrdIdOrTName);}
-
-\begin{blockindent}
- Set the named transform or the transform for the items described by {\tt tagOrIdOrTName} to
- identity. If {\tt tagOrIdOrTName} describes neither a named transform nor an item, an error is
- raised.
-\end{blockindent}
-
-
-\zinccmd{trestore}{tagOrId tName}
-
-{\tt\large \$zinc->{\bf trestore}(tagOrdId, tName);}
-
-\begin{blockindent}
- Set the transform for the items described by {\tt tagOrId} to the transform named by
- {\tt tName}. If {\tt tagOrId} doesn't describe any item or if the transform named {\tt
- tName} doesn't exist, an error is raised.
-\end{blockindent}
-
-
-\zinccmd{tsave}{?tagOrIdOrTName? tName ?invert?}
-
-{\tt\large \$zinc->{\bf tsave}(tName);}\\
-{\tt\large \$zinc->{\bf tsave}(tagOrdIdOrTName, tName);}\\
-{\tt\large \$zinc->{\bf tsave}(tagOrdIdOrTName, tName, invert);}
-
-\begin{blockindent}
- Create (or reset) a transform associated with the name {\tt tName} with initial
- value the transform associated with the item {\tt tagOrIdOrTName}. If {\tt tagOrIdOrTName} describes
- more than one item, the topmost in display list order is used. If {\tt tagOrIdOrTName} doesn't
- describe any item or named transformation, an error is raised. If {\tt tName} already exists,
- the transform is set to the new value. This command is the only way to create a named transform.
- If {\tt tagOrIdOrTName} is not specified, the command returns a boolean telling if the
- name is already in use. The {\tt invert} boolean, if specified, cause the transform
- to be inverted prior to be saved.
-
- It is possible to create a new named transformation from the identity by using the predefined tag 'identity': {\verb+$zinc->tsave('identity', 'myTransfo');+}
-% $ this comment is for emacs colorization only!
-\end{blockindent}
-
-\zinccmd{tset}{tagOrIdOrTName m00 m01 m10 m11 m20 m21}
-
-{\tt\large \$zinc->{\bf tset}(tagOrIdOrTName, m00, m01, m10, m11, m20, m21);}
-
-\begin{blockindent}
- Set the six elements of the 3x4 matrix used in affine transformation for
- {\tt tagOrIdOrTName}. \bf{ BEWARE that depending on mij values, it is possible
- to define a not inversible matrix which will end up in core dump. This
- method must BE USED CAUTIOUSLY. }
-\end{blockindent}
-
-
-\zinccmd{type}{tagOrId}
-
-{\tt\large \$name = \$zinc->{\bf type}(tagOrdId);}
-
-\begin{blockindent}
- This command returns the type of the item specified by {\tt tagOrId}. If more than one
- item is named by {\tt tagOrId}, then the type of the topmost item in display list order
- is returned. If no items are named by {\tt tagOrId}, an error is raised.
-\end{blockindent}
-
-
-\zinccmd{vertexat}{tagOrId x y}
-
-{\tt\large (\$contour, \$vertex, \$edgevertex) = \$zinc->{\bf vertexat}(tagOrdId, x, y);}
-
-\begin{blockindent}
- Return a list of values describing the vertex and edge closest to the \emph{window
- coordinates} {\tt x} and {\tt y} in the item described by {\tt tagOrId}. If {\tt
- 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).
-\end{blockindent}
-
-
-%%
-%%
-%% C h a p t e r : I t e m t y p e s
-%%
-%%
-\chapter{Item types}
-\concept{items}
-
-This chapter introduces the item types that can be used in TkZinc. Each item type
-provides a set of options that may be used to query or change the item behavior. Some item
-types cannot be used with some widget commands, or use special parameters with some
-commands. Those cases are noted in the description of the item.
-
-%%% XXX CM : the two previous sentences are really not clear!
-
-\section{Group items}
-\object{group}
-
-Group items are used for grouping objects together. Their usage is very powerfull and
-their use is best described in the previous chapter \conceptref{Groups, Display List, Clipping
-and Transformations}{coordinates}.
-
-Applicable attributes for \ident{group} are:
-
-\attribute{group}{alpha}{alpha}{Specifies the transparency to compose with the children
-transparencies. Needs the openGL extension.}
-
-\attribute{group}{atomic}{boolean}{Specifies if the group should report itself or its
-components during a search or for binding related operations. This attribute enable the
-use of a group as a single complex object build from smaller parts. It is possible to
-search for this item or use it in bindings without dealing with its smaller parts. The
-defaut value is {\tt false}.}
-
-\attribute{group}{clip}{item}{The item used to clip the children of the group. The shape
-of this item define an area that is used as a clipping shape when drawing the children of
-the group. Most items can be used here but notable exceptions are the \objectref{reticle} and
-\objectref{map} items. The default value is {\tt ""} which means that no clipping will be
-performed.}
-
-\attribute{group}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group must be composed with the alpha of this group. The default value is
-{\tt true}.}
-
-\attribute{group}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{group}{composescale}{boolean}{Specifies if the current scale should be composed
-with the local transform. The default value is {\tt true}.}
-
-\attribute{group}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}.}
-
-\attribute{group}{sensitive}{boolean}{Specifies if the item and all its children should
-react to events. The defaut value is {\tt true}.}
-
-\attribute{group}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{group}{visible}{boolean}{Specifies if the item and all its children is
-displayed. The defaut value is {\tt true}.}
-
-
-\section{Track items}
-\object{track}
-
-Track items have been designed for figuring out typical radar information for Air Traffic
-Control. However they may certainly be used by other kinds of radar view and surely by
-other kind of plan view with many moving objects and associated textual information.
-
-A track is composed of two main parts:
-\begin{itemize}
-\item The first one is purely graphic and is composed of many parts, some of them being
-identified by their ``partName'':
-
-\begin{itemize}
-\item the {\bf current position} of the object. Its partName is \ident{position}.
-\item a {\bf speed vector} which size depends on the attribute
-\attributeref{track}{speedvector} for the track and the option \optref{speedvectorlength}.
-This speed vector may be set visible or not, sensitive or other attributes can be set such
-as color, width, ticks, mark at the end... Its partName is \ident{speedvector}.
-\item a {\bf leader} which links the current position to the label. The leader may be
-visible or not, sensitive or not, and other graphic characteristics can be modified. Its
-partName is \ident{leader}.
-\item {\bf past positions} which are previous position after the track has been moved by
-the \cmdref{coords} command. The number of such past positions, their visibility and other
-graphic characteristics can be be modified. This part is never sensitive.
-\item a {\bf marker}, which is a circle around the current position. This marker can be
-visible or not and other graphic characteristics can be configured. The marker is never
-sensitive.
-\item a {\bf connection}, which is a link with another track or waypoint item; links are
-drawn between their {\bf current position}. This connection may be visible or not,
-sensitive or not, and other graphic characteristics can be be modified. Its partName
-is \ident{connection}.
-\end{itemize}
-
-\item the second part is a block of texts described by a labelformat (see chapter
-\conceptref{Labels, labelformats, and fields}{labelformat}. Each text can have its graphic
-decorations (alignment, background, images, borders...). These attributes are listed in
-the chapter \conceptref{Labels, label formats and fields}{labelformat} and can be changed
-by the command \cmdref{itemconfigure}.
-\end{itemize}
-
-The following picture shows a simple \ident{track} with a label of 5 fields and 5 past
-positions. This track also shows a marker, the circle around the current position.
-
-\fig{trackexample}{A track with a label composed of 5 fields}{1}
-
-
-%%% XXX CM add here an image with a openGL track (end ticks,... antialising...)
-An other very important feature of \ident{track} item is that TkZinc offers an
-anti-overlap manager. This manager tries to avoid any overlap of tracks labels. It also
-avoids that the label overlap the speedvector. This manager is stable over time: there
-should be few cases where labels are moved to a very different position. This manager
-applies to all tracks included in a group (by default the group 1). It can be
-enabled/disabled with the TkZinc attribute \optref{overlapmanager}.
-New labels positions are computed by the overlap
-manager every time a track is moved, a track is created or destroyed and every time the
-TkZinc widget is resized. Due to software licence limitation, TkZinc \emph{do not include}
-the very last version of this anti-overlap manager. If you are interested
-in this anti-overlap manager, please contact Didier Pavet at {\tt pavet@cena.fr}.
-
-Track items can be linked together or to waypoint items. The line figuring the link
-is configurable.
-
-Applicable attributes for \ident{track} are :
-
-\attribute{track}{circlehistory}{boolean}{If set to true the track history will be plotted
-as circles otherwise it will be plotted as squares. The default value is {\tt false}.}
-
-\attribute{track}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group must be composed with the alpha of this item. The default value is
-{\tt true}.}
-
-\attribute{track}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{track}{composescale}{boolean}{Specifies if the current scale should be composed
-with the local transform. The default value is {\tt true}.}
-
-\attribute{track}{connecteditem}{item}{The \ident{track} or \ident{waypoint} item at the
-other end of the connection link. The default value is {\tt ""} which means that
-no connection link will be drawn.}
-
-\attribute{track}{connectioncolor}{gradient}{The uniform (possibly transparent)
-color of the connection link. The first color of a real gradient color
-will be used. The default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{track}{connectionsensitive}{boolean}{Specifies if the connection link is
-sensitive. The actual sensitivity is the logical \ident{and} of this attribute and of the
-item \attributeref{track}{sensitive} attribute. The default value is {\tt true}.}
-
-\attribute{track}{connectionstyle}{linestyle}{The line style of the connection link. The
-default value is {\tt simple}.}
-
-\attribute{track}{connectionwidth}{dimension}{The width of the connection link. The
-default value is {\tt 1}.}
-
-\attribute{track}{filledhistory}{boolean}{If set to true the track history will be filled
-otherwise it will be outlined. The default value is {\tt true}.}
-
-\attribute{track}{filledmarker}{boolean}{If set to true the circular marker will be filled
-otherwise it will be outlined. The default value is {\tt false}.}
-
-\attribute{track}{frozenlabel}{boolean}{Specifies if the label should be frozen at its
-current location to prevent the anti overlapping system from moving it. The default value
-is {\tt false}.}
-
-\attribute{track}{historycolor}{gradient}{The uniform (possibly transparent) color of the
-track history. The first color of a real gradient color will be used. The default
-value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{track}{labelanchor}{anchor}{The anchor used in positionning the label. The
-default value is {\tt center}.}
-
-\attribute{track}{labelangle}{angle}{The angle in degrees between the label anchor and the
-normal to the speed vector. This attribute works with the \attributeref{track}{labeldistance} attribute to
-specify a position for the label anchor with respect to the item origin. There is another
-alternative method for label positioning which is implemented with the \attributeref{track}{labeldx} and
-\attributeref{track}{labeldy} methods. Simultaneous use of the two methods should be done with care as
-there is no automatic update of values from the \attributeref{track}{labeldx},
-\attributeref{track}{labeldy} set to the \attributeref{track}{labeldistance},
-\attributeref{track}{labelangle} set. The default value is {\tt 20}.}
-
-\attribute{track}{labelconvergencestyle}{dimension}{XXX New. To be documented. The default
-value is ??.}
-
-\attribute{track}{labeldistance}{dimension}{The minimum distance in pixels between the
-track position and the label anchor. See the explanation of the \attributeref{track}{labelangle} attribute
-for some more details. The default value is 50.}
-
-\attribute{track}{labeldx}{dimension}{The X offset between the track position and the
-label anchor. The default value is computed from the values in the \attributeref{track}{labeldistance} and
-\attributeref{track}{labelangle} attributes.}
-
-\attribute{track}{labeldy}{dimension}{The Y offset between the track position and the
-label anchor. The default value is computed from the values in the \attributeref{track}{labeldistance} and
-\attributeref{track}{labelangle} attributes.}
-
-\attribute{track}{labelformat}{labelformat}{Geometry of the label fields. The default
-value is {\tt ""} which means that no label will be displayed.}
-
-\attribute{track}{labelpreferredangle}{angle}{XXX New. To be documented. The default value
-is ??.}
-
-\attribute{track}{lastasfirst}{boolean}{If set to true, the last position in the history
-will be drawn in the same color as the current position instead of being drawn in the
-history color. The default value is {\tt false}.}
-
-\attribute{track}{leaderanchors}{leaderanchors}{The attachment of the leader on the label
-left or right side (whether the label is on the right or left of the current position).
-The default value is {\tt ""} which means that the leader anchor is at the label
-center, whatever the label position.}
-
-\attribute{track}{leadercolor}{gradient}{The uniform (possibly transparent) color of the label
-leader. The first color of a real gradient color will be used. The default
-value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{track}{leaderfirstend}{lineend}{Describes the arrow shape at the current
-position end of the leader. The default value is {\tt ""}.}
-
-\attribute{track}{leaderlastend}{lineend}{Describes the arrow shape at the label end of the
-leader. The default value is {\tt ""}.}
-
-\attribute{track}{leadersensitive}{boolean}{Specifies if the label leader is sensitive.
-The actual sensitivity is the logical \ident{and} of this attribute and of the item
-\attributeref{track}{sensitive} attribute. The default value is {\tt true}.}
-
-\attribute{track}{leadershape}{lineshape}{The shape of the label leader. The default value
-is {\tt straight}.}
-
-\attribute{track}{leaderstyle}{linestyle}{The line style of the label leader. The default
-value is {\tt simple}.}
-
-\attribute{track}{leaderwidth}{dimension}{The width of the label leader. The default value
-is {\tt 1}.}
-
-\attribute{track}{markercolor}{gradient}{The uniform (possibly transparent) color of the
-circular marker. The first color of a real gradient color will be used. The
-default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{track}{markerfillpattern}{bitmap}{The pattern to use when filling the circular
-marker. The default value is {\tt ""}.}
-
-\attribute{track}{markersize}{dimension}{The (scale sensitive) size of the circular marker.
-The default value is {\tt 0} which turn off the display of the marker.}
-
-\attribute{track}{markerstyle}{linestyle}{The line style of the marker outline. The
-default value is {\tt simple}.}
-
-\attribute{track}{mixedhistory}{boolean}{If true the track history will be plotted with
-dots every other position. The default value is {\tt false}.}
-
-\attribute{track}{numfields}{unsignedint}{Gives the number of fields available for the
-label. This attribute is read only.}
-
-\attribute{track}{position}{point}{The current location of the track. The default value
-is {\tt "0 0"}.}
-
-\attribute{track}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}.}
-
-\attribute{track}{sensitive}{boolean}{Specifies if the item should react to events. The
-default value is {\tt true}.}
-
-\attribute{track}{speedvector}{point}{The speed vector $\Delta x$ and $\Delta y$ in
-unit / minute. The default value is {\tt "0 0"} which results in no speed vector
-displayed.}
-
-\attribute{track}{speedvectorcolor}{gradient}{The uniform (possibly transparent) color of
-the track's speed vector. The first color of a real gradient color will be used.
-The default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{track}{speedvectormark}{boolean}{If set a small point is drawn at the end of
-the speed vector. The point is drawn with the speed vector color. The default is {\tt
-false}.Not yet available without openGL}
-
-\attribute{track}{speedvectorsensitive}{boolean}{Specifies if the track's speed vector is
-sensitive. The actual sensitivity is the logical \ident{and} of this attribute and of the
-item \attributeref{track}{sensitive} attribute. The default value is {\tt true}. }
-
-\attribute{track}{speedvectorticks}{boolean}{If set a mark is drawn at each minute
-position. The default is {\tt false}. Not yet available without openGL}
-
-\attribute{track}{speedvectorwidth}{dimension}{New. XXX To be documented. The default value is
-{\tt 1}.}
-
-\attribute{track}{symbol}{bitmap}{The symbol displayed at the current position. The
-default value is the current value of the widget option \optref{tracksymbol}.}
-
-\attribute{track}{symbolcolor}{gradient}{The uniforme (possibly transparent) color of the symbol
-displayed at the current position. The first color of a real gradient color will be used.
-The default value is the current value of the widget option
-\optref{forecolor}.}
-
-\attribute{track}{symbolsensitive}{boolean}{Specifies if the current position's symbol is
-sensitive to events. The actual sensitivity is the logical \ident{and} of this attribute
-and of the item \attributeref{track}{sensitive} attribute. The default value is {\tt true}.}
-
-\attribute{track}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{track}{visible}{boolean}{Specifies if the item is displayed. The default value
-is {\tt true}.}
-
-\attribute{track}{historyvisible}{boolean}{Specifies whether the item should display
-its history according to the options \optref{trackvisiblehistorysize} and
-\optref{trackmanagedhistorysize}. The default value is {\tt true}.}
-
-
-\section{WayPoint items}
-\object{waypoint}
-
-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.
-
-A waypoint is composed of the following parts:
-\begin{itemize}
-\item the {\bf position} of the waypoint. Its partName is \ident{position}.
-\item a {\bf leader} which links the current position to the label. The leader may be
-visible or not, sensitive or not, and other graphic characteristics can be be modified. Its
-partName is \ident{leader}.
-\item a {\bf label} which is a block of texts described by a labelformat (see chapter
-\conceptref{Labels, labelformat, and fields}{labelformat}. Each text can have its graphic
-decorations (alignment, background, images, borders...). These attributes are listed in
-the chapter \conceptref{Labels, label formats and fields}{labelformat} and can be changed
-by the command \cmdref{itemconfigure}.
-\item a {\bf connection}, which is a link with another \ident{waypoint} or \ident{track} item.
-This connection may be visible or not, sensitive or not, and other graphic characteristics
-can be be modified. Its partName is \ident{connection}.
-\end{itemize}
-
-
-\fig{waypointexample}{A waypoint with a label composed of five fields; fields have
-borders}{1}
-
-
-Applicable attributes for \ident{waypoint} are:
-
-\attribute{waypoint}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group must be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{waypoint}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt true}. }
-
-\attribute{waypoint}{composescale}{boolean}{Specifies if the current scale should be
-composed with the local transform. The default value is {\tt true}. }
-
-\attribute{waypoint}{connecteditem}{item}{The \ident{track} or \ident{waypoint} item at the
-other end of the connection link. The default value is {\tt ""} which means that
-no connection link will be drawn.}
-
-\attribute{waypoint}{connectioncolor}{gradient}{The uniform (possibly transparent) color of
-the connection link. The first color of a real gradient color will be used. The
-default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{waypoint}{connectionsensitive}{boolean}{Specifies if the connection link is
-sensitive. The actual sensitivity is the logical \ident{and} of this attribute and of the
-item \attributeref{waypoint}{sensitive} attribute. The default value is {\tt true}.}
-
-\attribute{waypoint}{connectionstyle}{linestyle}{The line style of the connection link.
-The default value is {\tt simple}.}
-
-\attribute{waypoint}{connectionwidth}{dimension}{The width of the connection link. The
-default value is {\tt 1}.}
-
-\attribute{waypoint}{filledmarker}{boolean}{If set to true the circular marker will be
-filled otherwise it will be outlined. The default value is {\tt false}.}
-
-\attribute{waypoint}{labelanchor}{anchor}{The anchor used in positionning the label. The
-default value is {\tt center}.}
-
-\attribute{waypoint}{labelangle}{angle}{The angle in degrees between the label anchor and
-the normal to the speed vector. This attribute works with the \attributeref{track}{labeldistance}
-attribute to specify a position for the label anchor with respect to the item origin.
-There is another alternative method for label positioning which is implemented with the
-\attributeref{track}{labeldx} and \attributeref{track}{labeldy} methods. Simultaneous use
-of the two methods should be done with care as there is no automatic update of values from the
-\attributeref{track}{labeldx}, \attributeref{track}{labeldy} set to the
-\attributeref{track}{labeldistance}, \attributeref{track}{labelangle} set. The default value is {\tt
-20}.}
-
-\attribute{waypoint}{labeldistance}{dimension}{The minimum distance in pixels between the
-way point position and the label anchor. See the explanation of the \attributeref{waypoint}{labelangle}
-attribute for some more details. The default value is {\tt 50}.}
-
-\attribute{waypoint}{labeldx}{dimension}{The X offset between the way point position and
-the label anchor. The default value is computed from the values in the
-\attributeref{waypoint}{labeldistance} and \attributeref{waypoint}{labelangle} attributes.}
-
-\attribute{waypoint}{labeldy}{dimension}{The Y offset between the way point position and
-the label anchor. The default value is computed from the values in the
-\attributeref{waypoint}{labeldistance} and \attributeref{waypoint}{labelangle} attributes.}
-
-\attribute{waypoint}{labelformat}{labelformat}{Geometry of the label fields. The default
-value is {\tt ""} which means that no label will be displayed.}
-
-\attribute{waypoint}{leaderanchors}{leaderanchors}{The attachment of the leader on the label
-left or right side (whether the label is on the right or left of the current position).
-The default value is {\tt ""} which means that the leader anchor is at the label
-center, whatever the label position.}
-
-\attribute{waypoint}{leadercolor}{gradient}{The uniform (possibly transparent) color of the
-label leader. The first color of a real gradient color will be used. The
-default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{waypoint}{leaderfirstend}{lineend}{Describes the arrow shape at the current
-position end of the leader. The default value is {\tt ""}.}
-
-\attribute{waypoint}{leaderlastend}{lineend}{Describes the arrow shape at the label end of
-the leader. The default value is {\tt ""}.}
-
-\attribute{waypoint}{leadersensitive}{boolean}{Specifies if the label leader is sensitive.
-The actual sensitivity is the logical \ident{and} of this attribute and of the item
-\attributeref{waypoint}{sensitive} attribute. The default value is {\tt true}.}
-
-\attribute{waypoint}{leadershape}{lineshape}{The shape of the label leader. The default
-value is {\tt straight}.}
-
-\attribute{waypoint}{leaderstyle}{linestyle}{The line style of the label leader. The
-default value is {\tt simple}.}
-
-\attribute{waypoint}{leaderwidth}{dimension}{The width of the label leader. The default
-value is {\tt 1}.}
-
-\attribute{waypoint}{markercolor}{gradient}{The uniform (possibly transparent) color of the
-circular marker. The first color of a real gradient color will be used. The
-default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{waypoint}{markerfillpattern}{bitmap}{The pattern to use when filling the
-circular marker. The default value is {\tt ""}.}
-
-\attribute{waypoint}{markersize}{dimension}{The (scale sensitive) size of the circular
-marker. The default value is {\tt 0} which turn off the display of the marker.}
-\attribute{waypoint}{markerstyle}{linestyle}{The line style of the marker outline. The
-default value is {\tt simple}.}
-
-\attribute{waypoint}{numfields}{unsignedint}{Gives the number of fields available for the
-label. This attribute is read only.}
-
-\attribute{waypoint}{position}{point}{The current location of the way point. The
-default value is {\tt "0 0"}.}
-
-\attribute{waypoint}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}.}
-
-\attribute{waypoint}{sensitive}{boolean}{Specifies if the item should react to events.
-The default value is {\tt true}.}
-
-\attribute{waypoint}{symbol}{bitmap}{The symbol displayed at the current position. The
-default value is {\tt AtcSymbol15}.}
-
-\attribute{waypoint}{symbolcolor}{gradient}{The uniform (possibly transparent) color of the
-symbol displayed at the current position. The first color of a real gradient color will be used.
-The default value is the current value of the widget option
-\optref{forecolor}.}
-
-\attribute{waypoint}{symbolsensitive}{boolean}{Specifies if the current position's symbol
-is sensitive to events. The actual sensitivity is the logical \ident{and} of this
-attribute and of the item \attributeref{waypoint}{sensitive} attribute. The default value is {\tt true}.}
-
-\attribute{waypoint}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{waypoint}{visible}{boolean}{Specifies if the item is displayed. The default
-value is {\tt true}.}
-
-
-\section{Tabular items}
-\object{tabular}
-
-Tabular items have been initially designed for displaying block of textual information,
-organised in lists or spread out on a radar display.
-
-A tabular item is mainly composed of a \emph{label} which is a block of texts described
-by a labelformat (see chapter \conceptref{Labels, labelformats and fields}{labelformat}.
-Each text can have its graphic decorations (alignment, background, images, borders...).
-This attributes are listed in the chapter \conceptref{Labels, label formats and
-fields}{labelformat} and can be changed by the command \cmdref{itemconfigure}.
-A tabular can be attached with the \attributeref{tabular}{connecteditem} attribute to the
-label of a \objectref{track}, \objectref{waypoint} or another \objectref{tabular}.
-
-Applicable attributes for \ident{tabular} are:
-
-\attribute{tabular}{anchor}{anchor}{The anchor used in positionning the item. The default
-value is {\tt nw}.}
-
-\attribute{tabular}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{tabular}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{tabular}{composescale}{boolean}{Specifies if the current scale should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{tabular}{connecteditem}{item}{Specifies the The \ident{track}, \ident{waypoint} or
-\ident{tabular} item relative to which this item is
-placed. Connected item should be in the same group. The default value is {\tt ""}.}
-
-\attribute{tabular}{connectionanchor}{anchor}{Specifies the anchor on the connected item.
-The default value is {\tt sw}.}
-
-\attribute{tabular}{labelformat}{labelformat}{Geometry of the label fields. The default
-value is {\tt ""} which means that nothing will be displayed.}
-
-\attribute{tabular}{numfields}{unsignedint}{Gives the number of fields available for the
-label. This attribute is read only.}
-
-\attribute{tabular}{position}{point}{The item's position relative to the anchor (if no
-connected item specified). The default value is {\tt "0 0"}.}
-
-\attribute{tabular}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}. }
-
-\attribute{tabular}{sensitive}{boolean}{Specifies if the item should react to events. The
-default value is {\tt true}.}
-
-\attribute{tabular}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{tabular}{visible}{boolean}{Specifies if the item is displayed. The default
-value is {\tt true}.}
-
-
-\section{Text items}
-\object{text}
-
-Text items are used for displaying text. They can also be used for text input. In this
-case, they must get the focus for keyboards events with the command \cmdref{focus}. Many
-TkZinc options (see chapter \conceptref{Widget options}{options} can be used for
-configuring the text input (for example : \optref{insertbackground},
-\optref{insertofftime} \optref{insertontime}, \optref{insertwidth}).
-
-With and without openGL, text items can be rotated or scaled. However,
-attributes \attributeref{text}{composerotation} and \attributeref{text}{composescale}
-must be set before rotation and scaling.
-
-A Tcl module, zincText is available, it provides simple bindings for interactive
-text input. For enabling interactive text editing on an item, the item should
-be sensitive and should have the tag ``text''.
-
-A Perl module, called Tk::Zinc::Text (see the section
-\conceptref{Tk::Zinc::Text}{zinctext}) is provided for easing text input in text items
-(it can also be used for text input in labelled items such as \objectref{track},
-\objectref{waypoint} or \objectref{tabular}).
-
-
-
-Applicable attributes for \ident{text} are:
-
-\attribute{text}{alignment}{alignment}{Specifies the horizontal alignment of the lines in
-the item. The default value is {\tt left}.}
-
-\attribute{text}{anchor}{anchor}{The anchor used in positionning the item. The default
-value is {\tt nw}.}
-
-\attribute{text}{color}{gradient}{Specifies the uniform (possibly transparent) color for
-drawing the text characters, the overstrike and underline lines. The first color of a
-real gradient color will be used. The default value is the current value of
-the widget option \optref{forecolor}.}
-
-\attribute{text}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{text}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt false}.}
-
-\attribute{text}{composescale}{boolean}{Specifies if the current scale should be composed
-with the local transform. The default value is {\tt false}.}
-
-\attribute{text}{connecteditem}{item}{Specifies the item relative to which this item is
-placed. Connected item should be in the same group. The default value is {\tt ""}.}
-
-\attribute{text}{connectionanchor}{anchor}{Specifies the anchor on the connected item.
-The default value is {\tt sw}.}
-
-\attribute{text}{fillpattern}{bitmap}{Specifies the pattern used to draw the text
-characters, the overstrike and underline lines. The default value is {\tt ""}.}
-
-\attribute{text}{font}{font}{Specifies the font for the text. The default value is the
-current value of the widget option \optref{font}.}
-
-\attribute{text}{overstriked}{boolean}{If true, a thin line will be drawn horizontally
-across the text characters. The default value is {\tt false}.}
-
-\attribute{text}{position}{point}{The item's position relative to the anchor (if no
-connected item specified). The default value is {\tt "0 0"} (Tcl/Tk) or {\tt [0,0]} (Perl/Tk).}
-
-\attribute{text}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}.}
-
-\attribute{text}{sensitive}{boolean}{Specifies if the item should react to events. The
-default value is {\tt true}.}
-
-\attribute{text}{spacing}{dimension}{Specifies a pixel value that will be added to the
-inter-line spacing specified in the font. The value can be positive to increase the
-spacing or negative to reduce it. The default value is {\tt 0}.}
-
-\attribute{text}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{text}{text}{string}{Specifies the text characters. Newline characters can be
-embedded to force line ends. The default value is {\tt ""}.}
-
-\attribute{text}{underlined}{boolean}{If true, a thin line will be drawn under the text
-characters. The default value is {\tt false}.}
-
-\attribute{text}{visible}{boolean}{Specifies if the item is displayed. The default value
-is {\tt true}.}
-
-\attribute{text}{width}{dimension}{Specifies the maximum pixel width of the text, a line
-break will be automatically inserted at the closest character position to match this
-constraint. If the value is zero, the width is not under the item control and line breaks
-must be inserted in the text to have multiple lines. The default value is {\tt 0}.}
-
-
-\section{Icon items}
-\object{icon}
-
-Icon items are used for displaying bitmap images. Any bitmap file format
-supported by Tk can be used. If the bitmap file supports transparency
-(not alpha-blending, only full transparency), TkZinc will render this transparent area.
-With and without openGL, icons can be rotated or scaled. However,
-attributes \attributeref{icon}{composerotation} and \attributeref{icon}{composescale}
-must be set before rotation and scaling.
-
-Applicable attributes for \ident{icon} are:
-
-\attribute{icon}{anchor}{anchor}{The anchor used in positionning the item. The default
-value is {\tt nw}.}
-
-\attribute{icon}{color}{gradient}{Specifies the uniform (possibly transparent) fill color
-used for drawing the bitmap. The first color of a real gradient color will be used. If
-The icon contains an image, only the transparency of the color is used and
-defines the alpha transparency of the image when \optref{render} is set to true.
-The default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{icon}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is
-{\tt true}.}
-
-\attribute{icon}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt false}.}
-
-\attribute{icon}{composescale}{boolean}{Specifies if the current scale should be composed
-with the local transform. The default value is {\tt false}.}
-
-\attribute{icon}{connecteditem}{item}{Specifies the item relative to which this item is
-placed. Connected item should be in the same group. The default value is {\tt ""}.}
-
-\attribute{icon}{connectionanchor}{anchor}{Specifies the anchor on the connected item.
-The default value is {\tt sw}.}
-
-\attribute{icon}{image}{image}{Specifies a Tk image that will be displayed by the item.
-The image may have a mask (depend on the image format) that clip some parts. This option
-has precedence over the {\tt mask} option if both are specified. The default value is {\tt
-""}.}
-
-\attribute{icon}{mask}{bitmap}{Specifies a Tk bitmap that will be displayed by the
-item. The bitmap is filled with the color specified with the {\tt color} option. This
-option is inactive if an image has been specified with the {\tt image} option.
-The default value is {\tt ""}.}
-
-\attribute{icon}{position}{point}{The item's position relative to the anchor (if no
-connected item specified). The default value is {\tt "0 0"} (Tcl/Tk) or {\tt [0,0]} (Perl/Tk.}
-
-\attribute{icon}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}.}
-
-\attribute{icon}{sensitive}{boolean}{Specifies if the item should react to events. The
-default value is {\tt true}.}
-
-\attribute{icon}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{icon}{visible}{boolean}{Specifies if the item is displayed. The default value
-is {\tt true}.}
-
-
-\section{Reticle items}
-\object{reticle}
-
-Reticle items are set of concentric circles. The number of circles can be either
-finite or not. Some periodic circles may be different, they are called bright circles; they
-can be configured differently from other circles. This item has mainly be designed for
-radar display images, to help user evaluationg distances from the central point.
-Reticle cannot handle events.
-
-Applicable attributes for \ident{reticle} are:
-
-\attribute{reticle}{brightlinecolor}{gradient}{This is the uniform (possibly transparent)
-color of highlighted circles. The first color of a real gradient color will be used.
-The default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{reticle}{brightlinestyle}{linestyle}{This is the line style of the highlighted
-circles. The default value is {\tt simple}.}
-
-\attribute{reticle}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{reticle}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{reticle}{composescale}{boolean}{Specifies if the current scale should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{reticle}{firstradius}{dimension}{This is the radius of the innermost circle of the
-reticle. The default value is {\tt 80}.}
-
-\attribute{reticle}{linecolor}{gradient}{This is the uniform (possibly transparent) color of
-regular (not highlighted) circles. The first color of a real gradient color will be used.
-The default value is the current value of the widget option
-\optref{forecolor}.}
-
-\attribute{reticle}{linestyle}{linestyle}{This is the line style of the regular (not
-highlighted) circles. The default value is {\tt simple}.}
-
-\attribute{reticle}{numcircles}{unsignedint}{Specifies how many circles should be drawn. The
-default value is {\tt -1} which means draw as many circles as needed to encompass the
-current widget window. This does not take into account any possible clipping that can mask
-part of the reticle. The idea behind this trick is to draw an infinite reticle that is
-optimized for the current scale.}
-
-\attribute{reticle}{period}{unsignedint}{Specifies the recurrence of the bright circles over
-the regulars. The default value is {\tt 5} which means that a bright circle is drawn then
-4 regulars, etc.}
-
-\attribute{reticle}{position}{point}{Location of the center of the reticle. The default
-value is {\tt "0 0"}.}
-
-\attribute{reticle}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 0}.}
-
-\attribute{reticle}{sensitive}{boolean}{Specifies if the item should react to events. The
-default value is {\tt false} as the item cannot handle events.}
-
-\attribute{reticle}{stepsize}{dimension}{The (scale sensitive) size of the step between two
-consecutive circles. The default value is {\tt 80}.}
-
-\attribute{reticle}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{reticle}{visible}{boolean}{Specifies if the item is displayed. The default value
-is {\tt true}.}
-
-
-\section{Map items}
-\object{map}
-
-
-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 \conceptref{videomap}{videomapcmd}
-command or more generally created and edited with a set of commands described in the
-\conceptref{The mapinfo related commands}{mapinfocmds} section.
-
- Applicable attributes for \ident{map} are:
-
-\attribute{map}{color}{gradient}{Specifies the uniform (possibly transparent) color used
-to draw or fill the map. The texts and symbols that are part of the map are also drawn in
-this color. The first color of a real gradient color will be used. The
-default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{map}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{map}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{map}{composescale}{boolean}{Specifies if the current scale should be composed
-with the local transform. The default value is {\tt true}.}
-
-\attribute{map}{filled}{boolean}{If set to true the map wil be filled otherwise it will be
-drawn as thin lines. The default is {\tt false}.}
-
-\attribute{map}{fillpattern}{bitmap}{Specifies the pattern to be used when filling the
-map. The value should be a legal Tk bitmap. The default value is {\tt ""}.}
-
-\attribute{map}{font}{font}{Specifies the font that will be used to drawn the texts of the
-map. The default value is the current value of the widget option \optref{maptextfont}.}
-
-\attribute{map}{mapinfo}{mapinfo}{Specifies the lines, texts, symbols and other various
-graphical components that should be displayed by the map item. All these graphical
-components will share the graphical attributes (color, font, etc) of the item and its
-coordinate system. The default value is {\tt ""} which means that nothing will be
-displayed by the map.}
-
-\attribute{map}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 0}.}
-
-\attribute{map}{sensitive}{boolean}{Specifies if the item should react to events. The
-default value is {\tt false} as the item cannot handle events.}
-
-\attribute{map}{symbols}{bitmaplist}{XXX to be detailed. The default value is {\tt ??}.}
-
-\attribute{map}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{map}{visible}{boolean}{Specifies if the item is displayed. The default value is
-{\tt true}.}
-
-
-\section{Rectangle items}
-\object{rectangle}
-
-
- Items of type \ident{rectangle} display a rectangular shape, optionally filled. The
- rectangle is described by its bottom-left and top right corners.
-
- It is possible to use this item as a clip item for its group. It is also possible to use
- the rectangle in a \cmdref{contour} command to build a complex shape in a \objectref{curve}
- item. The two points describing the rectangle can be read and modified with the
- \cmdref{coords} command.
-
-%%%% XXX CM insert here two rectangles, one rotated and with a relief!! One used as a clipper!
-
- Applicable attributes for \ident{rectangle} are:
-
-\attribute{rectangle}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{rectangle}{composerotation}{boolean}{Specifies if the current rotation should
-be composed with the local transform. The default value is {\tt true}.}
-
-\attribute{rectangle}{composescale}{boolean}{Specifies if the current scale should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{rectangle}{fillcolor}{gradient}{Specifies the color that will be used to
-fill the rectangle if requested by the \attributeref{rectangle}{filled} attribute. The default
-value is a one color gradient based on the current value of the widget option \optref{forecolor}.}
-
-\attribute{rectangle}{filled}{boolean}{Specifies if the item should be filled. The default
-value is {\tt false}.}
-
-\attribute{rectangle}{fillpattern}{bitmap}{Specifies the pattern to use when filling the
-item. The default value is {\tt ""}.}
-
-\attribute{rectangle}{linecolor}{gradient}{Specifies the uniform (possibly transparent)
-color used to draw the item outline. The first color of a real gradient color
-will be used. The default value is the current value of the widget option
-\optref{forecolor}.}
-
-\attribute{rectangle}{linepattern}{bitmap}{Specifies the pattern to use when drawing the
-outline. The default value is {\tt ""}.}
-
-\attribute{rectangle}{linestyle}{linestyle}{Specifies the line style to use when drawing
-the outline. The default value is {\tt simple}.}
-
-\attribute{rectangle}{linewidth}{dimension}{Specifies the width of the item outline (not
-scalable). The default value is {\tt 1}.}
-
-\attribute{rectangle}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}.}
-
-\attribute{rectangle}{relief}{relief}{Specifies the relief used to drawn the rectangle
-outline. This attribute has priority over the \attributeref{rectangle}{linepattern} and
-\attributeref{rectangle}{linestyle} attributes. The color of the relief is derived from
-the color in \attributeref{rectangle}{linecolor}. The default value is {\tt flat}.}
-
-\attribute{rectangle}{sensitive}{boolean}{Specifies if the item should react to events.
-The default value is {\tt true}.}
-
-\attribute{rectangle}{tags}{taglist}{The list of tags associated with the item. The
-default value is {\tt ""}.}
-
-\attribute{rectangle}{tile}{image}{Specifies an image used for filling the item with
-tiles. This will be done only if filling is requested by the \attributeref{rectangle}{filled}
-attribute. This attribute has priority over the \attributeref{rectangle}{fillcolor} attribute
-and the \attributeref{rectangle}{fillpattern} attribute. The default value is {\tt ""}.}
-
-\attribute{rectangle}{visible}{boolean}{Specifies if the item is displayed. The default
-value is {\tt true}.}
-
-
-\section{Arc items}
-\object{arc}
-
- Items of type \ident{arc} display an oval section, optionally filled, delimited by two
- angles. The oval is described by its enclosing rectangle. The arc can be closed either
- by a straight line joining its end points or by two segments going throught the center
- to form a pie-slice.
-
- It is possible to use this item as a clip item for its group, the clip shape will be the
- polygon obtained by closing the arc. It is also possible to use this polygon in a
- \cmdref{contour} command to build a complex shape in a \objectref{curve} item. The two points
- describing the enclosing rectangle can be read and modified with the \cmdref{coords}
- command. The first point should be the top left vertex of the rectangle and the second
- should be the bottom right.
-
- Applicable attributes for \ident{arc} are:
-
-\attribute{arc}{closed}{boolean}{Specifies if the outline of the arc should be
-closed. This is only pertinent if the arc extent is less than 360 degrees. The default
-value is {\tt false}.}
-
-\attribute{arc}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{arc}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{arc}{composescale}{boolean}{Specifies if the current scale should be composed
-with the local transform. The default value is {\tt true}.}
-
-\attribute{arc}{extent}{angle}{Specifies the angular extent of the arc relative to the
-start angle. The angle is expressed in degrees in the trigonometric system. The default
-value is {\tt 360}.}
-
-\attribute{arc}{fillcolor}{gradient}{ Specifies the color used to fill
-the arc if requested by the \attributeref{arc}{filled} attribute. The default value is a one color
-gradient based on the current value of the widget option \optref{backcolor}.}
-
-\attribute{arc}{filled}{boolean}{Specifies if the item should be filled. The default value
-is {\tt false}.}
-
-\attribute{arc}{fillpattern}{bitmap}{Specifies the pattern to use when filling the
-item. The default value is {\tt ""}.}
-
-\attribute{arc}{firstend}{lineend}{Describes the arrow shape at the start end of the
-arc. This attribute is applicable only if the item is not closed and not filled. The
-default value is {\tt ""}.}
-
-\attribute{arc}{lastend}{lineend}{Describes the arrow shape at the extent end of the
-arc. This attribute is applicable only if the item is not closed and not filled. The
-default value is {\tt ""}.}
-
-\attribute{arc}{linecolor}{gradient}{Specifies the uniform (possibly transparent) color
-used to draw the item outline. The first color of a real gradient color
-will be used. The default value is the current value of the widget option
-\optref{forecolor}.}
-
-\attribute{arc}{linepattern}{bitmap}{Specifies the pattern to use when drawing the
-outline. The default value is {\tt ""}.}
-
-\attribute{arc}{linestyle}{linestyle}{Specifies the line style to use when drawing the
-outline. The default value is {\tt simple}.}
-
-\attribute{arc}{linewidth}{dimension}{Specifies the with of the item outline (not
-scalable). The default value is {\tt 1}.}
-
-\attribute{arc}{pieslice}{boolean}{This attribute tells how to draw an arc whose extent is
-less than 360 degrees. If this attribute is true the arc open end will be drawn as a pie
-slice otherwise it will be drawn as a chord. The default value is {\tt false}.}
-
-\attribute{arc}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}.}
-
-\attribute{arc}{sensitive}{boolean}{Specifies if the item should react to events. The
-default value is {\tt true}.}
-
-\attribute{arc}{startangle}{angle}{Specifies the arc starting angle. The angle is
-expressed in degrees in the trigonometric system. The default value is {\tt 0}.}
-
-\attribute{arc}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{arc}{tile}{image}{Specifies an image used for filling the item with tiles. This
-will be done only if filling is requested by the \attributeref{arc}{filled} attribute. This
-attribute has priority over the \attributeref{arc}{fillcolor} attribute and the
-\attributeref{arc}{fillpattern} attribute. The default value is {\tt ""}.}
-
-\attribute{arc}{visible}{boolean}{Specifies if the item is displayed. The default value is
-{\tt true}.}
-
-
-\section{Curve items}
-\object{curve}
-
-
- Items of type \ident{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 polygon delimited by the path can optionally be filled.
- It is possible to build curve items with more than one path to
- describe complex shapes with the \cmdref{contour} command. This command can be used to
- perform boolean operations between a curve and almost any other item available in TkZinc
- including another curve. The exact appearance of a multi-contour curve (i.e. which parts
- are filled and which are holes) depends on the value of an attribute, called
- \attributeref{curve}{fillrule}.
- In the following figure (a snapshot of \conceptref{zinc-demos}{zinc-demos}) two curves
- with four holes each are in front of a text. You can partially see the text through the holes.
-
-\fig{textthroughholes}{Two curves with 4 holes each. A text is visible behind}{0.8}
-
- It is possible to use this item as a clip item for its group, the clip shape will be the
- polygon obtained by closing the path. The vertices can be read, modified, added or
- removed with the \cmdref{coords} command.
-
- Applicable attributes for \ident{curve} are:
-
-\attribute{curve}{capstyle}{capstyle}{Specifies the form of the outline ends. This
-attribute is only applicable if the curve is not closed and the outline relief is
-flat. The default value is {\tt round}.}
-
-\attribute{curve}{closed}{boolean}{Specifies if the curve outline should be drawn between
-the first and last vertex or not. The default value is {\tt false}.}
-
-\attribute{curve}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{curve}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{curve}{composescale}{boolean}{Specifies if the current scale should be composed
-with the local transform. The default value is {\tt true}.}
-
-\attribute{curve}{fillcolor}{gradient}{Specifies the color used to fill
-the curve if requested by the \attributeref{curve}{filled} attribute. The default value is
-a one color gradient based on the current value of the widget option \optref{backcolor}.}
-
-\attribute{curve}{filled}{boolean}{Specifies if the item should be filled. The default
-value is {\tt false}.}
-
-\attribute{curve}{fillpattern}{bitmap}{Specifies the pattern to use when filling the
-item. The default value is {\tt ""}.}
-
-\attribute{curve}{fillrule}{fillrule}{Specifies the way contours are combined together to
-specify complex surfaces, with holes and disjoint surfaces. The default value is {\tt "odd"}.
-This means that a point of the space is considered inside the curve surface if an odd number
-of contours are surrounding the point. This attribute should only be modified for curves with
-multiple or complicated contours.}
-
-\attribute{curve}{firstend}{lineend}{Describes the arrow shape at the start of the curve.
-This attribute is applicable only if the item is not closed, not filled and the relief of
-the outline is flat. The default value is {\tt ""}.}
-
-\attribute{curve}{joinstyle}{joinstyle}{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 {\tt round}.}
-
-\attribute{curve}{lastend}{lineend}{Describes the arrow shape at the end of the curve.
-This attribute is applicable only if the item is not closed, not filled and the relief of
-the outline is flat. The default value is {\tt ""}.}
-
-\attribute{curve}{linecolor}{gradient}{Specifies the uniform (possibly transparent) color
-used to draw the item outline. The first color of a real gradient color will be used.
-The default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{curve}{linepattern}{bitmap}{Specifies the pattern to use when drawing the
-outline. The default value is {\tt ""}.}
-
-\attribute{curve}{linestyle}{linestyle}{Specifies the line style to use when drawing the
-outline. The default value is {\tt simple}.}
-
-\attribute{curve}{linewidth}{dimension}{Specifies the with of the item outline (not
-scalable). The default value is {\tt 1}.}
-
-\attribute{curve}{marker}{bitmap}{Specifies a bitmap that will be used to draw a mark at
-each vertex of the curve. This attribute is not applicable if the outline relief is not
-flat. The default value is {\tt ""} which means do not draw markers.}
-
-\attribute{curve}{markercolor}{gradient}{Specifies the uniform (possibly transparent) color of the
-markers. The first color of a real gradient color will be used.
-The default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{curve}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}.}
-
-\attribute{curve}{relief}{relief}{Specifies the relief used to drawn the curve
-outline. This attribute has priority over the \attributeref{curve}{linepattern} and
-\attributeref{curve}{linestyle} attributes. The color of the relief is derived from
-the color in \attributeref{curve}{linecolor}. The default value is {\tt flat}.}
-
-\attribute{curve}{sensitive}{boolean}{Specifies if the item should react to events. The
-default value is {\tt true}.}
-
-\attribute{curve}{smoothrelief}{boolean}{Specifies if the relief should be smoothed along
-the curve. This is useful to obtain smooth curved reliefs instead of facets The default
-value is {\tt false}.}
-
-\attribute{curve}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{curve}{tile}{image}{Specifies an image used for filling the item with
-tiles. This will be done only if filling is requested by the \attributeref{curve}{filled} attribute.
-This attribute has priority over the \attributeref{curve}{fillcolor} attribute and the
-\attributeref{curve}{fillpattern} attribute. The default value is {\tt ""}.}
-
-\attribute{curve}{visible}{boolean}{Specifies if the item is displayed. The default value
-is {\tt true}.}
-
-
-\section{Triangles items}
-\object{triangles}
-
-Triangles items are used for displaying complexe surfaces with variables colors
-and transparencies. For example, it can be used to create a circular color selector
-displaying a range of colors. The way triangles composing a triangle item are arranged
-is defined by the \attributeref{triangles}{fan} option.
-
-This item has been added to provide access to a basic openGL geometric construction but
-it is also available in the X environment albeit with less features.
-
-Applicable attributes for \ident{triangles} are:
-
-\attribute{triangles}{colors}{gradientlist}{Specifies the colors of each vertex of the
-triangles.} %% XXX what if less/more colors than vertex?
-
-\attribute{triangles}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{triangles}{composerotation}{boolean}{Specifies if the current rotation should
-be composed with the local transform. The default value is {\tt true}.}
-
-\attribute{triangles}{composescale}{boolean}{Specifies if the current scale should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{triangles}{fan}{boolean}{ If true, triangles are created with a fan like layout.
-Otherwise triangles are arranged like a strip. The default value is {\tt true}.}
-
-\attribute{triangles}{priority}{priority}{The absolute position in the stacking order among
-siblings of the same parent group. The default value is {\tt 1}.}
-
-\attribute{triangles}{sensitive}{boolean}{Specifies if the item should react to events.
-The default value is {\tt true}.}
-
-\attribute{triangles}{tags}{taglist}{The list of tags associated with the item. The
-default value is {\tt ""}.}
-
-\attribute{triangles}{visible}{boolean}{Specifies if the item is displayed. The default
-value is {\tt true}.}
-
-
-\section{Window items}
-\object{window}
-
- Items of type \ident{window} display an X11 window at a given position in the widget.
-
- It is possible to use this item as a clip item for its group, the clip shape will be the
- window rectangle. It is also possible to use the rectangular shape of the window item in
- a \cmdref{contour} command to build a complex shape in a \objectref{curve} item. The
- position of the window, relative to the anchor, can be set or read with the \cmdref{coords}
- command (i.e. if no connected item is specified).
-
- One of the most frequent use of this item is to embed any Tk widget into TkZinc,
- including, of course, another TkZinc instance. Another less obvious use is to embed a
- whole Tk application into TkZinc, here is how to do it: The embedding application should
- create a frame with the \ident{-container} option set to true; Add a window item to the
- relevant TkZinc widget with the \attributeref{window}{window} attribute set to the id of
- the container frame; The embedded application should create its toplevel with the
- \ident{-use} option set to the id of the container frame; Or, as an alternative, the
- embedded \cident{wish} can be launched with the \ident{-use} option set to the container
- frame id.
-
-Applicable attributes for \ident{window} items are:
-
-\attribute{window}{anchor}{anchor}{The anchor used in positionning the item. The default
-value is {\tt nw}.}
-
-\attribute{window}{composealpha}{boolean}{Specifies if the alpha value inherited from
-the parent group should be composed with the alpha of this item. The default value is {\tt true}.}
-
-\attribute{window}{composerotation}{boolean}{Specifies if the current rotation should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{window}{composescale}{boolean}{Specifies if the current scale should be
-composed with the local transform. The default value is {\tt true}.}
-
-\attribute{window}{connecteditem}{item}{Specifies the item relative to which this item is
-placed. Connected item should be in the same group. The default value is {\tt ""}.}
-
-\attribute{window}{connectionanchor}{anchor}{Specifies the anchor on the connected item
-used for the placement. The default value is {\tt sw}.}
-
-\attribute{window}{height}{dimension}{Specifies the height of the item window in screen
-units. The default value is {\tt 0}.}
-
-\attribute{window}{position}{point}{The item's position relative to the anchor (if no
-connected item specified). The default value is {\tt "0 0"} (Tcl/Tk) or {\tt [0,0]} (Perl/Tk).}
-
-\attribute{window}{priority}{priority}{Constraints of the underlying window system dictate
-the stacking order of window items. They can't be lowered under the other
-items. Additionally, to manipulate their stacking order, you must use the raise and lower
-Tk commands on the associated Tk window. The value of this attribute is meaningless.}
-
-\attribute{window}{sensitive}{boolean}{This option has no effect on window items. The
-default value is {\tt false}.}
-
-\attribute{window}{tags}{taglist}{The list of tags associated with the item. The default
-value is {\tt ""}.}
-
-\attribute{window}{visible}{boolean}{Specifies if the item is displayed. The default value
-is {\tt true}.}
-
-\attribute{window}{width}{dimension}{Specifies the width of the item window in screen
-units. The default value is {\tt 0}.}
-
-\attribute{window}{window}{window}{Specifies the X id of the window that is displayed by
-the item. This id can be obtained by the Tk command \ident{winfo id widgetname}. The
-default value is {\tt ""}.}
-
-
-%%
-%%
-%% C h a p t e r : L a b e l s , l a b e l f o r m a t s a n d f i e l d s
-%%
-%%
-\chapter{Labels, label formats and fields}
-\concept{labelsandfields}
-
-TkZinc was initially developed for building interactive radar image working on X
-server. This requires very good performances, for displaying many hundred tracks and
-moving them every few second. Tracks are typically composed of some geometric parts and
-some textual parts. These two parts are connected together with a leader. The geometric
-parts are subject to scaling. For example the speed vector length in pixel depends on the
-scale. But the textual part must not be zoomed. Managing parts which are scaled and others
-which are not, can be a real challenge. Usual toolkits or widget are not suited to such
-behaviours, but TkZinc is.
-
-To be able to manage many items mixing geometric parts and non-geometric parts,
-TkZinc introduces the concepts of label, labelformat, fields and fields attributes.
-
-\section {Labels and labelformats}
-\concept{label} \concept{labelformat}
-
-A label is a set of rectangular fields attached to the following item types :
-\objectref{track}, \objectref{waypoint} and \objectref{tabular}. The fields of a
-label may contain either text or bitmaps or images. A label cannot be identified
-or manipulated by itself; There is no function nor method to get or manipulate a
-label as an object or an item. A label is always associated to an item and
-is manipulated through this item.
-
-Some label global characteristics are set/get at the item level:
-
-\begin{itemize}
-\item The maximum number of fields is defined at item creation, as the second
-argument of the \cmdref{add} method. The field number can not be changed after creation.
-These fields will be indexed from 0 to n-1. The number of fields can be read
-with the command \cmdref{numparts}. For example:
-\begin{verbatim}
- $track = $zinc->add('track',1, 4, ....);
- # this creates a track item in root group with 4 fields, indexed from 0 to 3
-\end{verbatim}
-% $ comment for emacs colorization only!
-\item The rectangular geometries of displayable fields are defined through
-the item attribut \ident{-labelformat}. The value is a string following
-the syntax of the \attrtyperef{labelformat} type. This attribute can be set at any time;
-thus modifying its value is a way to quickly change the geometry (or the visibility) of
-some fields. Fields may overlap. They are drawn according to the index order:
-field 0 is drawn before (thus under) field 1. The labelformat also optionnaly
-describes a clipping rectangle. For example:
-\begin{verbatim}
- $zinc->itemconfigure($track, -labelformat => 'a12a0+0+ x20x100>0 a2a0>1>0');
- ## ^ ^ ^
- ## field0 field1 field2
- # the labelformat indicates that only the first 3 fields will be displayed:
- # field 0 expands for the size of the text + 12 pixels.
- # It starts at the top left point
- # field 1 has a size of 20x10 pixels.
- # It is left aligned with field 0, just under field 0
- # field 2 expands for the size of the text + 2 pixels.
- # It is adjacent to the right of field 1, just under field 0
-\end{verbatim}
-\end{itemize}
-
-Characteristics of each individual field are called field attributes. They are all
-described in next section \conceptref{Attributes for fields}{fieldAttributes}.
-They may be set or get with the \cmdref{itemcget} and \cmdref{itemconfigure} command.
-These commands require as a second argument the field number. By configuring
-field attributes you can modify :
-\begin{itemize}
-\item the field content : \attributeref{field}{text}, \attributeref{field}{image},
-\attributeref{field}{tile}, \attributeref{field}{fillpattern},
-\item the field colors : \attributeref{field}{backcolor}, \attributeref{field}{bordercolor},
-\attributeref{field}{color},
-\item the text general appearance : \attributeref{field}{alignment},
-\attributeref{field}{autoalignment}, \attributeref{field}{font},
-\item the field border : \attributeref{field}{border}, \attributeref{field}{relief},
-\attributeref{field}{reliefthickness},
-\item and the field visibility and sensitivity: \attributeref{field}{sensitive},
-\attributeref{field}{visible}.
-\end{itemize}
-
-As an example:
-\begin{verbatim}
- $zinc->itemconfigure($track, 0, -text => 'Hello World',
- -color => 'white',
- -backcolor => 'black',
- -filled => 1);
- # this should display "Hello World" in white on black in field 0
-\end{verbatim}
-
-It is possible to bind callbacks to fields, with the command \cmdref{bind} and
-special tags (described \conceptref{Tags and bindings}{tagsAndBindings}).
-As an example:
-\begin{verbatim}
- $zinc->bind("$track:1", '<1>', \&acallback);
- # this binds &acallback to field 1
-\end{verbatim}
-
-Inside a callback function, it is possible to know which field the mouse cursor is over
-with the command \cmdref{currentpart}.
-
-A Perl module, called Tk::Zinc::Text (see the section \conceptref{Tk::Zinc::Text}{zinctext})
-is provided for easing text input in text fields (it can also be used for easing text input
-in \objectref{text} item).
-
-
-
-\section{Attributes for fields}
-\object{field}
-\concept{fieldAttributes}
-
-Fields are item parts of items supporting labelformat (i.e.\ \objectref{track},
-\objectref{waypoint} and \objectref{tabular}). They can be configured in a similar way of
-items themselves, with the command \cmdref{itemconfigure}, but this command requires an
-additionnal parameter (in second position) the \ident{fieldId}. To get the value of a
-field attribute, you can use the command {itemcget} with the \ident{fieldId} as an
-additionnal second parameter.\\ NB: Field attributes cannot be configured at item creation
-with the command \cmdref{add}.
-
-Applicable attributes for fields are:
-
-
-\attribute{field}{alignment}{alignment}{ The horizontal alignment of both the text and the
-image. The default value is {\tt left}.}
-
-\attribute{field}{autoalignment}{autoalignment}{ The dynamic horizontal alignments used
-depending on the label orientation. The default value is {\tt "-"} which means do not use
-dynamic alignment.}
-
-\attribute{field}{backcolor}{gradient}{ The field background color. The default value is the
-current value of the widget option \optref{backcolor}.}
-
-\attribute{field}{border}{edgelist}{ The border description edge by edge. The border is a
-one pixel wide outline that is drawn around the field outside the relief. Some border
-edges can be omitted, this attribute describes the edges that should be displayed as part
-of the border. The default value is {\tt ""}.}
-
-\attribute{field}{bordercolor}{gradient}{ The border uniform (possibly transparent) color.
-The first color of a real gradient color will be used.
-The default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{field}{color}{gradient}{ The text uniform (possibly transparent) color.
-The first color of a real gradient color will be used.
-The default value is the current value of the widget option \optref{forecolor}.}
-
-\attribute{field}{filled}{boolean}{ Specifies if the field background should be
-filled. The default value is {\tt false}.}
-
-\attribute{field}{fillpattern}{bitmap}{ The fill pattern used when filling the
-background. This attribute is overrided by the tile attribute. The default value is {\tt
-""}.}
-
-\attribute{field}{font}{font}{ The text font. The default value is the current value of
-the widget option \optref{font}.}
-
-\attribute{field}{image}{image}{ An image to be displayed in the field. The image will be
-centered vertically in the field. The default value is {\tt ""}.}
-
-\attribute{field}{relief}{relief}{ Specifies the relief to be drawn around the field,
-inside the border. The color of the relief is derived from the color in
-\attributeref{field}{backcolor}. The default value is {\tt flat}.}
-
-\attribute{field}{reliefthickness}{dimension}{ Width of the relief drawn around the
-field. The default value is {\tt 0} which means that no relief should be drawn around the
-field.}
-
-\attribute{field}{sensitive}{boolean}{ Specifies if the field should react to input
-events. The default value is {\tt true}.}
-
-\attribute{field}{text}{string}{ A line of text to be displayed in the field. The text
-will be centered vertically in the field. The default value is {\tt ""}.}
-
-\attribute{field}{tile}{image}{ Specifies an image that will be tiled over the field
-background is the field is filled. This attribute has precedence over the
-\attributeref{field}{fillpattern} attribute. The default value is {\tt ""}.}
-
-\attribute{field}{visible}{boolean}{ Specifies if the field is displayed. The default
-value is {\tt true}.}
-
-
-%%
-%%
-%% C h a p t e r : A t t r i b u t e t y p e s
-%%
-%%
-\chapter{Attribute types}
-\concept{types}
-
-We describe in this chapter all the available types in TkZinc. They are listed by
-alphabetical order.
-
-\emph{NB: Two types are very important and their existence should be known
-by any new user of TkZinc: \attrtyperef{gradient} and \attrtyperef{labelformat}.}
-
-
-\attrtype{alignment}
-\begin{blockindent}
- Specifies the horizontal alignment of an entity. The legal values are: {\tt left}, {\tt
- right}, {\tt center}.
-\end{blockindent}
-
-\attrtype{alpha}
-\begin{blockindent}
- Specifies the transparency of an item. The value must be an integer from 0 (fully
- transparent) to 100 (fully opaque).
-\end{blockindent}
-
-\attrtype{anchor}
-\begin{blockindent}
- Specifies one of the nine characteristic points of a rectangle or a bounding box that will
- be used to position the object. These points include the four corners, the four edge
- centers, and the center of the rectangle. The possible values are: {\tt nw}, {\tt n},
- {\tt ne}, {\tt e}, {\tt se}, {\tt s}, {\tt sw}, {\tt w}, {\tt center}.
-\end{blockindent}
-
-\attrtype{angle}
-\begin{blockindent}
- Specifies an angle in degrees, the value must be an integer from 0 to 360 inclusive.
-\end{blockindent}
-
-\attrtype{autoalignment}
-\begin{blockindent}
- Specifies the horizontal alignments that should be used for track or way point fields
- depending on the label position relative to the position of the item. The attribute may
- have two forms: a single dash {\tt -} means turning of the automatic alignment feature
- for the field; The other form consists in three letters which describe in order: the
- alignment to be used when the label is to the left of the item position, above or below
- the item position and to the right of the item position. The possible values for each
- letter is: {\tt l} for left alignment, {\tt c} for center alignment and {\tt r} for
- right alignment. Here is an example: {\tt rll} means right align the field if the label
- is on the left side of the item, and left align if the label is above, below or on the
- right of the item.
-\end{blockindent}
-
-\attrtype{bitmap}
-\begin{blockindent}
- This should be a string naming a valid Tk bitmap. The bitmap should be known to Tk prior
- to its use. TkZinc registers a set of bitmaps that can be used for any bitmap valued
- attribute (see section \conceptref{Bitmaps}{builtinbitmaps}). Extensions to Tk are available to create or
- manipulate bitmaps from a script. The value may also name a file containing a valid X11
- bitmap description. The syntax in this case is {\tt @filename}.
-\end{blockindent}
-
-\attrtype{bitmaplist}
-\begin{blockindent}
- This is an extension of the \attrtyperef{bitmap} attribute type. It describes a list of
- bitmaps that will be the value of the attribute.
-\end{blockindent}
-
-\attrtype{boolean}
-\begin{blockindent}
- This is the description of a standard Tcl boolean value. The possible values are {\tt
- 0}, {\tt false}, {\tt no} or {\tt off} for the false value and {\tt 1}, {\tt true}, {\tt
- yes} or {\tt on} for the true value.
-\end{blockindent}
-
-\attrtype{capstyle}
-\begin{blockindent}
- This the description of a line cap. The possible values are {\tt butt}, {\tt projecting}
- and {\tt round}.
-\end{blockindent}
-
-\attrtype{color}
-\begin{blockindent}
- This is a string that describes a color. The description may have one of two forms, a
- colorname such as {\tt green} or {\tt LemonChiffon} or an rgb specification in one of
- the following formats, {\tt \#rgb}, {\tt \#rrggbb}, {\tt \#rrrgggbbb} or {\tt
- \#rrrrggggbbbb}. If less than four digits are provided for a color component, they
- represent the most significant bits of the component. For example {\tt \#3a7} is
- equivalent to {\tt \#3000a0007000}.
-\end{blockindent}
-
-\attrtype{dimension}
-\begin{blockindent}
- This is a string that represent distance. The string consists in a floating point signed
- number.
-\end{blockindent}
-
-\attrtype{edgelist}
-\begin{blockindent}
- This is a list describing the edges of a border that should be considered for processing
- (e.g for drawing). The possible values are {\tt left}, {\tt right}, {\tt top}, {\tt
- bottom}, {\tt contour}, {\tt oblique} and {\tt counteroblique}. The {\tt contour} value
- is the same as the {\tt "left top right bottom"} list. The {\tt oblique} and {\tt
- counteroblique} values describe diagonal segments from top-left to bottom-right and from
- top-right to bottom-left respectively. The following picture gives some edges examples.
-
-\fig{alledges}{edgelist examples}{0.5}
-
-\end{blockindent}
-
-
-\attrtype{fillrule}
-\begin{blockindent}
- This is a string describing the rule used to compose the different contours or pathes of
- a curve. The allowed values are directly inspired from the openGL GLU tesselators as
-described for example in the chapter 11 of the ``The OpenGL Programming Guide 3rd Edition
-The Official Guide to Learning OpenGL Version 1.2'', ISBN 0201604582. You can also refer to
-the example fillrule provided with TkZinc in \conceptref{zinc-demos}{zinc-demos}. The allowed values are
-{\tt odd}, {\tt nonzero}, {\tt positive}, {\tt negative}, and {\tt abs\_geq\_2}.
-The following figure shows the effect of fillrule value on curves with multiple contours:
-
-\fig{fillrule}{Examples of fillrule on curves}{0.4}
-
-\end{blockindent}
-
-
-\attrtype{font}
-\begin{blockindent}
- This is a string describing a font. For an exhaustive description of what is legal as a
- font description, refer to the Tk \ident{font} command man page. Just to mention to
- popular methods, it is possible to specify a font by it's X11 font name or by a list
- whose elements are the font family, the font size and then zero or more styles including
- {\tt normal}, {\tt bold}, {\tt roman}, {\tt italic}, {\tt underline}, {\tt overstrike}.
-
- {\bf Please note, that some font data are cached by TkZinc, on the application level.
- This is specially usefull with openGL}. To avoid breaking the cache mecanism, you
- should avoid using a font once on only one item, then modifiy this item font
- and repeat this again and again.
-\end{blockindent}
-
-\attrtype{gradient}
-\begin{blockindent}
- This is a string describing a color gradient to be used for example to fill a surface.
- Gradient are also used to describe color of lines, even if in this case the lines are
- limited to one color with and optionnal alpha percentage.
-
- The string may consist in a single color specification that will be used to paint a solid surface
- or a color with an alpha value or a list of gradient steps separated by \verb+|+ characters.
-
- \begin{itemize}
- \item The general pattern for an axial gradient is :
-
- \verb+"=axial degre | gradient_step1 | ... | gradient_stepn"+ or
-
- \verb+"=axial x1 y1 x2 y2 | gradient_step1 | ... | gradient_stepn"+
-
- The \verb+degre+ parameter defines the angle of the axe in the usual
- trigonometric sense. It defaults to 0. The \verb+x1 y1 x2 y2+ parameters
- define both the angle and the extension of the axe.
-
-
- \item The general pattern for a radial gradient is :
-
- \verb+"=radial x y | gradient_step1 | ... | gradient_stepn"+ or
-
- \verb+"=radial x1 y1 x2 y2 | gradient_step1 | ... | gradient_stepn"+
-
- The \verb+x y+ parameters define the center of the radial. The \verb+x1 y1 x2 y2+
- parameters define both the center and the extension of the radial.
-
-
- \item The general pattern for a path gradient is :
-
- \verb+"=path x y | gradient_step1 | ... | gradient_stepn"+
-
- The \verb+x y+ parameters define the center of the gradient.
-
-
- \item The general pattern for a conical gradient is :
-
- \verb+"=conical degre | gradient_step1 | ... | gradient_stepn"+ or
-
- \verb+"=conical degre x y | gradient_step1 | ... | gradient_stepn"+ or
-
- \verb+"=conical x1 y1 x2 y2 | gradient_step1 | ... | gradient_stepn"+
-
- The \verb+degre+ parameter defines the angle of the cone in the usual
- trigonometric sense. The optional \verb+x y+ parameters define the center of
- the cone. By default, it is the center of the bounding-box.
- The \verb+x1 y1 x2 y2+ parameters define the center and the angle of the cone.
-
- \end{itemize}
-
- All x and y coordinates are expressed in percentage of the bounding box, relatively
- to the center of the bounding box. So \verb+0 0+ means the center while \verb+-50 -50+
- means the lower left corner of the bounding box.
-
- If none of the above gradient type specification is given, the gradient will be drawn as
- an axial gradient with a null angle.
-
- Each gradient segment section has the general form:
-
- \verb+color;alpha color_position mid_span_position+
-
- Each color can be specified as a valid X color : either a named color or \#rrggbb value
- or any valid X color specification such as standard device-independent color specification
- (e.g. \verb+CIEuvY:<u>/<v>/<Y>+ as defined in the X man page). An alpha value
- can be applied to the color using the optional \verb+;alpha+ parameter whose value should be in the
- 0..100 intervalle.
-
- The color position tells where in the gradient surface, measured as a percentage of the
- total gradient distance, the color should start. The first gradient segment has its
- position set to 0 and the last segment has its position set to 100, regardless of the
- specification. The position can thus be safely omitted for these segments. The in
- between segments must have a position explicitly set. If not given, the position will
- default to 0.
-
- The mid span position tells where in the current gradient segment should be the median
- color. The position is given in percentage of the current gradient segment distance.
- The mid span position can be used to obtain a non linear gradient segment, this is
- useful to describe relief shapes. This parameter can be omitted in which case it
- defaults to 50 and the gradient segment is perfectly linear.
-
- A gradient segment can be specified as a single color. In this case a flat uniform fill
- will result.
-
- The following picture gives many examples of gradients. They correspond to the following values:
-
-\verb+axial 1 : '=axial 0 | black|white' := 'black|white'+
-
-\verb+axial 2 : '=axial 90 | black|white'+
-
-\verb+axial 3 : '=axial 30 |black|white'+
-
-\verb+axial 4 : '=axial 30|black|black;0'+
-
-\verb+radial 1 : '=radial -14 -20|white|black'+
-
-\verb+radial 2 : '=radial 0 0 | white;50 0 70|black 50|white 100'+
-
-\verb+path 1 : '=path -14 -20|white|black;80'+
-
-\verb+path 2 : '=path -14 -20 |white|white 30|black;80'+
-
-\fig{allgradients}{Examples of axial, radial and path gradients}{0.5}
-
-\end{blockindent}
-
-\attrtype{gradientlist}
-\begin{blockindent}
- This is an extension of the \attrtyperef{gradient} attribute type. It describes a list of
- gradients that will be the value of the attribute.
-\end{blockindent}
-
-\attrtype{image}
-\begin{blockindent}
- This should be the name of a previously registered Tk image.
-
- In pure Tcl-Tk only GIF, PPM
- and bitmap formats are available as source for images. With the Img extension many
- others popular formats are added including JPEG, XPM and PNG.
-
- In Perl/Tk most image formats can be used, specially with Tk::JPEG or Tk::PNG modules.
-
- {\bf Please note, that some image data are cached by TkZinc, on the application level.
- This is specially usefull with openGL}. To avoid breaking the cache mecanism, you
- should avoid using an image once on only one item option, then modifiy this item option
- and repeat this again and again.
-
-\end{blockindent}
-
-\attrtype{item}
-\begin{blockindent}
- Describes an item id or a tag. If a tag is provided an item will be searched for the tag
- and the first matching in display list order will be used.
-\end{blockindent}
-
-\attrtype{joinstyle}
-\begin{blockindent}
- Describes a join style. The possible values are {\tt bevel}, {\tt miter} and {\tt
- round}.
-\end{blockindent}
-
-\attrtype{labelformat}
-\begin{blockindent}
- The format is as follow. Parameters between \verb+[]+ are optional and take default values
- when omitted. Spaces can appear between blocks but not inside.
-
- \verb+[WidthxHeight] [<field0Spec>] [<field1Spec>] ... [<fieldnSpec>]+
-
- \verb+Width+ and \verb+Height+ are strictly positive integers. They set
- the size of the clipping box surrounding the label. If not specified,
- there will be no clipping. If specified alone, they specify the size of
- the only displayed field which index is 0.
-
- \verb+<fieldiSpec> ::= <fieldiSize>[<fieldiPos>]+
-
- Each fieldiSpec specify the size and position of the field numbered i.
-
- \verb+<fieldiSize> ::= <sChar><fieldWidth><sChar><fieldHeight>+
-
- \verb+<sChar> ::= x|f|i|a|l+
-
- \verb+<sChar>+ specifies the meaning of the following \verb+<fieldWidth>+ or
- \verb+<fieldHeight>+. Those are positive integers. Values for \verb+<sChar>+
- have the following meaning :
-
- \begin{itemize}
- \item \verb+'x'+ : the corresponding dimension (either width or height) is in pixel,
- according to the value of the \verb+<fieldWidth>+ or \verb+<fieldHeight>+
- \item \verb+'f'+ : the corresponding dimension is in percentage of the mean
- width/height of a character (in the field font). The following \verb+<fieldWidth>+
- or \verb+<fieldHeight>+ gives the percentage. The value must be an integer between
- 0 and 100.
-%%% XXX CM How is computed ``the mean width/height of a character''
- \item \verb+'i'+ : the corresponding dimension is in percentage of the size of the
- image in the field. The following \verb+<fieldWidth>+ or \verb+<fieldHeight>+ gives
- the percentage. The value must be an integer between 0 and 100. If the field contains
- no image, the dimension is 0.
- \item \verb+'a'+ : the corresponding dimension is automatically adjusted to match
- the field's content plus the given value in pixels.
- \item \verb+'l'+ : the corresponding dimension is adjusted to match the
- global size of the label (not counting fields with \verb+'l'+ size specs). The
- corresponding integer parameter is not used with this size specification.
- The global size of the label is considered when the labelformat is set. If some fields
- sizes change afterwards, you should set again the labelformat so that fields using
- a \verb+'l'+ specification are re-computed.
- It is not possible to reference the field in another \verb+<fieldiPos>+ (see below).
- \end{itemize}
-
- \verb+<fieldiPos> ::= <pChar><fieldX><pChar><fieldY>+.
-
- \verb-<pChar> ::= +|<|>|^|$-
-%$ this comment if for emacs coloring only!
-
- \verb+<fieldX>+ and \verb+<fieldY>+ are either integer or index refering an
- other field of the labelformat.
-
- Values for \verb+pChar+ have the following meaning :
-
- \begin{itemize}
- \item \verb-'+'- : the position, either on the X or Y axis, is in pixel, possibly
- negative. XXX what does it mean if negative? The value is given by the corresponding
- \verb+<fieldX>+ or \verb+<fieldY>+.
- \item \verb+'<'+ : The field will be at the left (or top) of the field refered
- by the corresponding index \verb+<fieldX>+ (or \verb+<fieldY>+)
- \item \verb+'>'+ : The field will be at the right (or bottom) of the field refered
- by the corresponding index \verb+<fieldX>+ (or \verb+<fieldY>+)
- \item \verb+'^'+ : The field will be left (or top) aligned with the field refered
- by the corresponding index \verb+<fieldX>+ (or \verb+<fieldY>+).
- \item \verb+'$'+ : The field will be right (or bottom) aligned with the field refered
- by the corresponding index \verb+<fieldX>+ (or \verb+<fieldY>+).
-%$ this comment if for emacs coloring only!
- \end{itemize}
-
- \verb+<fieldiPos>+ can be omitted if there is only one field.
-\end{blockindent}
-
-\attrtype{leaderanchors}
-\begin{blockindent}
- Describes where to attach the label leader on the label. Two positions can be defined: one
- when the label is at the right of current position and the other when the label is at the
- left of current position. {\bf Not to be confused with the regular rectangular anchors}.
-
- The format is: \verb+lChar leftLeaderAnchor [lChar rightLeaderAnchor]+
-
- If \verb+lChar+ is a \verb+|+, \verb+leftLeaderAnchor+ and \verb+rightLeaderAnchor+ are
- the indices of the field that serve to anchor the label's leader. More specifically the
- bottom right corner is used when \verb+leftLeaderAnchor+ is active and the bottom left
- corner is used when \verb+rightLeaderAnchor+ is active.
-
- If \verb+lChar+ is \verb+%+, \verb+leftLeaderAnchor+ and \verb+rightLeaderAnchor+ should
- be specified as \verb+widthPercentxheightPercent+, each value being a percentage
- (between 1 and 100) of the width or height of the label bounding box. If
- \verb+rightLeaderAnchor+ is not specified it defaults to \verb+leftLeaderAnchor+. If
- neither are specified, the center of the label is used as an anchor.
-\end{blockindent}
-
-\attrtype{lineend}
-\begin{blockindent}
- Describes the shape of the arrow at the beginning or end of a path. This is a list of
- three numbers describing the arrow shape in the following order: distance along the axis
- from neck to tip of the arrowhead, distance from trailing points to tip and distance
- from outside edge of the line to the trailing points (see canvas). If an empty list is
- given, there is no arrow.
-\end{blockindent}
-
-\attrtype{lineshape}
-\begin{blockindent}
- Describes the shape of a path connecting two points. The possible values are {\tt
- straight}, {\tt rightlightning}, {\tt leftlightning}, {\tt rightcorner}, {\tt
- leftcorner}, {\tt doublerightcorner} and {\tt doubleleftcorner}. The following figure
- shows these different line shapes:
-
-\fig{alllineshapes}{Examples of all available line shapes}{0.4}
-
-\end{blockindent}
-
-\attrtype{linestyle}
-\begin{blockindent}
- Describes the style of the dashes that should be used to draw a line. The possible
- values are {\tt simple}, {\tt dashed}, {\tt mixed} and {\tt dotted}.
-\end{blockindent}
-
-\attrtype{mapinfo}
-\begin{blockindent}
- This is the name of a previously registered mapinfo object (see the chapter
- \conceptref{The mapinfo related commands}{mapinfocmds}) that will define the lines, arcs,
- symbols, and texts displayed in a map item.
-\end{blockindent}
-
-\attrtype{point}
-\begin{blockindent}
- This is a list of two floating point values that describes a point position or some two
- dimensional delta (used for example to describe the speed vector of a track item).
-\end{blockindent}
-
-\attrtype{priority}
-\begin{blockindent}
- A strictly positive integer value for the display priority.
-\end{blockindent}
-
-\attrtype{relief}
-\begin{blockindent}
- Describes a border relief. The possible values, illustrated in the following figure are
- {\tt flat},
- {\tt raised}, {\tt sunken}, {\tt ridge}, {\tt groove},
- {\tt roundraised}, {\tt roundsunken}, {\tt roundridge}, {\tt roundgroove},
- {\tt raisedrule}, {\tt sunkenrule}.
-
-\fig{allreliefs}{Examples of all available non-flat reliefs}{0.5}
-
-\end{blockindent}
-
-\attrtype{string}
-\begin{blockindent}
- Just what its name implies, a string.
-\end{blockindent}
-
-\attrtype{taglist}
-\begin{blockindent}
- This should be a list of strings describing the tags that are set for an item.
-\end{blockindent}
-
-\attrtype{unsignedint}
-\begin{blockindent}
- Describes an unsigned integer value.
-\end{blockindent}
-
-\attrtype{window}
-\begin{blockindent}
- A string describing an X window id. This id can be returned by the {\tt winfo id
- a-widget-path} command.
-\end{blockindent}
-
-
-
-%%
-%%
-%% C h a p t e r : T h e m a p i n f o c o m m a n d s
-%%
-%%
-\chapter{The mapinfo related commands}
-\concept{mapinfocmds}
-
- MapInfo objects are used to describe graphical primitives that will be displayed in map
- items. It is possible to describe lines, arcs, symbols and texts as part of a
- MapInfo. The \ident{mapinfo} and \ident{videomap} commands are provided to create and
- manipulate the mapinfo objects.
-
-\section{The mapinfo command}
-
-\mapinfocmd{name}{create}{}
-\begin{blockindent}
- Create a new empty map description. The new mapinfo object named {\tt name}.
-\end{blockindent}
-
-\mapinfocmd{mapInfoName}{delete}{}
-\begin{blockindent}
- Delete the mapinfo object named by {\tt mapInfoName}. All maps that refer to the deleted
- mapinfo are updated to reflect the change.
-\end{blockindent}
-
-\mapinfocmd{mapInfoName}{duplicate}{newName}
-\begin{blockindent}
- Create a new mapinfo that is a exact copy of the mapinfo named {\tt mapInfoName}. The
- new mapinfo object will be named {\tt newName}.
-\end{blockindent}
-
-\mapinfocmd{name}{add}{type args}
-\begin{blockindent}
- Add a new graphical element to the mapinfo object named by {\tt name}. The {\tt type}
- parameter select which element should be added while the {\tt args} arguments provide
- some type specific values such as coordinates. Here is a description of recognized types
- and their associated parameters.
-
- \begin{description}
- \item{line} \\ This element describes a line segment. Its parameters consists in a line
- style ({\tt simple}, {\tt dashed}, {\tt dotted}, {\tt mixed}, {\tt marked}), an integer
- value setting the line width in pixels and four integer values setting the X and Y
- coordinates of the two end vertices.
- \item{arc} \\ This element describes an arc segment. Its parameters consists in a line
- style ({\tt simple}, {\tt dashed}, {\tt dotted}, {\tt mixed}, {\tt marked}), an integer
- value setting the line width in pixels, two integer values setting the X and Y of the
- arc center, integer value setting the arc radius and two integer values setting the
- start angle (in degree) and the angular extent of the arc (in degree).
- \item{symbol} \\ This element describes a symbol. Its parameters consists in two integer
- values setting the X and Y of the symbol position and an integer setting the symbol
- index in the {\tt -symbols} list of the map item.
- \item{text} \\ This element describes a line of text. Its parameters consists in a text
- style ({\tt normal}, {\tt underlined}), a line style ({\tt simple}, {\tt dashed}, {\tt
- dotted}, {\tt mixed}, {\tt marked}) to be used for the underline, two integer values
- setting the X and Y of the text position and a string describing the text.
- \end {description}
-
-\end{blockindent}
-
-\mapinfocmd{name}{count}{type}
-\begin{blockindent}
- Return an integer value that is the number of elements matching {\tt type} in the
- mapinfo named {\tt name}. {\tt type} may be one the legal element types as described in
- the {\tt mapinfo add} command.
-\end{blockindent}
-
-\mapinfocmd{name}{get}{type index}
-\begin{blockindent}
- Return the parameters of the element at {\tt index} with type {\tt type} in the mapinfo
- named {\tt name}. The returned value is a list. The exact number of parameters in the
- list and their meaning depend on {\tt type} and is accurately described in
- \ident{mapinfo add}. {\tt type} may be one the legal element types as described in the
- {\tt mapinfo add} command. Indices are zero based and elements are listed by type.
-\end{blockindent}
-
-\mapinfocmd{name}{replace}{type index args}
-\begin{blockindent}
- Replace all parameters for the element at {\tt index} with type {\tt type} in the
- mapinfo named {\tt name}. The exact number and content for {\tt args} depend on {\tt
- type} and is accurately described in \ident{mapinfo add}. {\tt type} may be one the
- legal element types as described in the {\tt mapinfo add} command. Indices are zero
- based and elements are listed by type.
-\end{blockindent}
-
-\mapinfocmd{name}{remove}{type index}
-\begin{blockindent}
- Remove the element at {\tt index} with type {\tt type} in the mapinfo named {\tt
- name}. {\tt type} may be one the legal element types as described in the {\tt mapinfo
- add} command. Indices are zero based and elements are listed by type.
-\end{blockindent}
-
-\mapinfocmd{name}{scale}{factor}
-\begin{blockindent}
- Scale all coordinates of all the elements described in the mapinfo named {\tt name} by
- {\tt factor}. The same value is used for X and Y axes.
-\end{blockindent}
-
-\mapinfocmd{name}{translate}{xAmount yAmount}
-\begin{blockindent}
- Translate all coordinates of all the elements described in the mapinfo named {\tt
- name}. The {\tt xAmount} value is used for the X axis and the {\tt yAmount} value is
- used for the Y axis.
-\end{blockindent}
-
-
-
-\section{The videomap command}
-\concept{videomapcmd}
-
- This section describes the videomap command, used to create a mapinfo from a proprietary
- file format for simple maps, in use in french Air Traffic Control Centres. The format is the
- binary cautra4 (with x and y in 1/8nm units)
-
-\command{videomap}{ids}{fileName}
-\begin{blockindent}
- Return all sub-map ids that are described in the videomap file described by {\tt
- fileName}. The ids are listed in file order. This command makes possible to iterate
- through a videomap file one sub-map at a time, to know how much sub-maps are there and
- to sort them according to their ids.
-\end{blockindent}
-
-\command{videomap}{load}{fileName index mapInfoName}
-\begin{blockindent}
- Load the videomap sub-map located at position {\tt index} in the file named {\tt
- fileName} into a mapinfo object named {\tt mapInfoName}. It is possible, if needed, to
- use the \ident{videomap ids} command to help translate a sub-map id into a sub-map file
- index.
-\end{blockindent}
-
-
-%%
-%%
-%% C h a p t e r : O t h e r r e s o u r c e s p r o v i d e d
-%%
-%%
-\chapter{Other resources provided by the widget}
-\concept{otherresources}
-
-In this chapter we describe resources included in TkZinc widget. This include
-bitmaps sets (used as symbols for some items or used as stipples), Perl modules goodies
-and TkZinc simple demonstrations.
-
-\section{Bitmaps}
-\concept{builtinbitmaps}
-
-TkZinc creates two sets of bitmaps.
-
-The first set contains symbols for ATC tracks position, waypoints position and maps
-symbols. These bitmaps are named AtcSymbol1 to AtcSymbol22.
-
-\fig{atcsymb}{Bitmaps available for position of tracks, waypoints, and maps}{0.5}
-
-
-The second set provides stipples that can be used to implement transparency, they are
-named AlphaStipple0 to AlphaStipple15, AlphaStipple0 being the most transparent.
-
-\fig{alphastip}{Bitmaps available for creating stipples}{0.5}
-
-\latexhtml{\tolerance 2000 %allow somewhat looser lines.
- \hbadness 10000}{} %don't complain about underfull lines.
-
-
-
-\section{Tk::Zinc::Debug Perl module}
-
-\ident{Tk::Zinc::Debug.pm} is a Perl module useful for debugging purpose. It can be used in a
-Perl application using TkZinc to display the hierarchical tree of items, to display
-items selected by their id or tags, to grab items with the mouse and to get the list of
-items enclosed or overlapped by a rectangle designated by the mouse. You will be
-presented a list of items, with many interesting attributes such as position, priority,
-visibility, group...\ and even more information on request. Much of the selected items
-attributes can be interactively modified. When an application uses
-\ident{Tk::Zinc::Debug.pm}, you can get a short reminder by depressing the {\tt Esc} key in
-the main window of this application. For more information, please refer to the
-\ident{Tk::Zinc::Debug.pm} man pages with the classical command {\tt man Tk::Zinc::Debug}
-
-To use this module, you can import it either by adding, for example, the following
-statements in your source code:
-\code{\\use Tk::Zinc::Debug;\\
-finditems(\$zinc);\\
-tree(\$zinc, -optionsToDisplay => '-tags', -optionsFormat => 'row');\\}
-or simply by using the -M option of Perl:
-\code{\\perl -MTk::Zinc::Debug yourscript.pl\\}
-
-\section{Tracing TkZinc methods call in Perl/Tk}
-
-TkZinc package includes two tools for helping you debugging your Perl/Tk scripts
-or tracking some nasty segfault which should never occure since TkZinc is
-(almost) totally bugfree.
-
-\subsection{Tracking Perl/Tk script errors}
-
-Because you sometime get some errors inside \ident{TkZinc} with a cryptic message
-like {\tt ".... errors in Tk.pm line 228"}, it may be usefull to know where exactly
-in your code is the error. There is a simple and convenient mean to do this, just
-by using a small module called \ident{Tk::Zinc::TraceErrors}, released with \ident{TkZinc}.
-It traces every call of a TkZinc method inducing a Tk error. It prints on
-the standard output the following informations:
-\begin{itemize}
-\item the filename where the method has been invoked
-\item the line number in the source file
-\item the TkZinc method name
-\item the list of arguments in a human-readable form
-\item the error message
-\end{itemize}
-
-To use this module you can import it either by adding the following
-statement in your source code:
-\code{\\use Tk::Zinc::TraceErrors;\\} or better, by using the -M option of Perl:
-\code{\\perl -MTk::Zinc::TraceErrors yourscript.pl\\}
-
-\subsection{Tracking TkZinc segfaults in Perl/Tk}
-
-If you encounters a segfault in one Perl/Tk script and you suspects
-that TkZinc might be responsible, you should use a small module called
-\ident{Tk::Zinc::Trace}, released with \ident{TkZinc}.
-It traces every call of a TkZinc method. The method call is printed
-on the standard output before the effective call, and the
-result of the invokation is printed after the call. To be sure
-to identify a segfault at the proper time, it forces an update of TkZinc
-widget. Thus, this might slow down your script, but should dramatically
-speed up the identification of the call which makes TkZinc segfaulting.
-It prints on the standard output the following informations:
-\begin{itemize}
-\item the filename where the method has been invoked
-\item the line number in the source file
-\item the TkZinc method name
-\item the list of arguments in a human-readable form
-\item the returned value
-\end{itemize}
-
-To use this module you can import it either by adding the following
-statement in your source code:
-\code{\\use Tk::Zinc::Trace;\\} or better, by using the -M option of Perl:
-\code{\\perl -MTk::Zinc::Trace yourscript.pl\\}
-
-
-\section{zinc-demos}
-\concept{zinc-demos}
-
-Starting at version 3.2.4 of TkZinc small applications are included as demos. They
-are all accessible through an application called \ident{zinc-demos}. These numerous
-(about 30) tiny demos are useful for newcomers and as starting points for developing
-real applications. They consists in toy applications, graphically advanced examples
-or even a TkZinc port of \ident{TkTetris} from Slaven Rezic.
-
-\section{Tk::Zinc::Graphics Perl module}
-\concept{zincGraphics}
-
-The Tk::Zinc::Graphics Perl module implements many high level functions for
-building high quality graphic objects with TkZinc.
-
-Please read the man page for more details: {\tt man Tk::Zinc::Graphics}, french
-version only currently. Any volontear to translate it in English?
-
-NB: There is also a tcl version of this module.
-
-\section{Tk::Zinc::Text Perl module}
-\concept{zinctext}
-
-The Tk::Zinc::Text Perl module implements bindings for text input 'a la emacs'.
-It works for text item or for text fields of track, waypoint or tabular items.
-The item which requires text input must just be tagged with the 'text' tag.
-
-Please read the man page for more details: {\tt man Tk::Zinc::Text}
-
-\section{C api for adding new items}
-\concept{Capi}
-
-The C function AddItemClass provided with the source code of TkZinc, can be used to extent
-the default set of items in TkZinc in an additionnal dynamic library. The AddItemClass C
-function is extensively used for implementing the core item set. So please refer to the source
-code for examples or send email for more information on precise problems.
-
-We will try to further document this feature in the future.
-
-%\listoftables
-
-\listoffigures
-
-\printindex
-
-\label{interne:DernierePage}
-
-
-\end{document}
diff --git a/doc/tabularexample.png b/doc/tabularexample.png
deleted file mode 100644
index e5d1fdb..0000000
--- a/doc/tabularexample.png
+++ /dev/null
Binary files differ
diff --git a/doc/textthroughholes.png b/doc/textthroughholes.png
deleted file mode 100644
index 81da10b..0000000
--- a/doc/textthroughholes.png
+++ /dev/null
Binary files differ
diff --git a/doc/tkzinclogo.png b/doc/tkzinclogo.png
deleted file mode 100644
index ee452b5..0000000
--- a/doc/tkzinclogo.png
+++ /dev/null
Binary files differ
diff --git a/doc/trackexample.png b/doc/trackexample.png
deleted file mode 100644
index 7bbfa7b..0000000
--- a/doc/trackexample.png
+++ /dev/null
Binary files differ
diff --git a/doc/waypointexample.png b/doc/waypointexample.png
deleted file mode 100644
index b7c8ad1..0000000
--- a/doc/waypointexample.png
+++ /dev/null
Binary files differ
diff --git a/library/pkgIndex.tcl b/library/pkgIndex.tcl
deleted file mode 100644
index fed6d76..0000000
--- a/library/pkgIndex.tcl
+++ /dev/null
@@ -1,13 +0,0 @@
-# Tcl package index file, version 1.1
-# This file is generated by the "pkg_mkIndex" command
-# and sourced either when an application starts up or
-# by a "package unknown" script. It invokes the
-# "package ifneeded" command to set up package-related
-# information so that packages will be loaded automatically
-# in response to "package require" commands. When this
-# script is sourced, the variable $dir must contain the
-# full path name of this file's directory.
-
-package ifneeded zincText 1.0 [list source [file join $dir zincText.tcl]]
-package ifneeded zincLogo 1.0 [list source [file join $dir zincLogo.tcl]]
-package ifneeded zincGraphics 1.0 [list source [file join $dir zincGraphics.tcl]]
diff --git a/library/zincGraphics.tcl b/library/zincGraphics.tcl
deleted file mode 100644
index 10f6a27..0000000
--- a/library/zincGraphics.tcl
+++ /dev/null
@@ -1,1322 +0,0 @@
-#
-#-----------------------------------------------------------------------------------
-#
-# Graphics.tcl
-# some graphic design functions
-#
-#-----------------------------------------------------------------------------------
-# Functions to create complexe graphic component :
-# ------------------------------------------------
-# BuildZincItem (realize a zinc item from description hash table)
-#
-# Function to compute complexe geometrical forms :
-# (text header of functions explain options for each form,
-# function return curve coords using control points of cubic curve)
-# -----------------------------------------------------------------
-# RoundedRectangleCoords (return curve coords of rounded rectangle)
-# HippodromeCoords (return curve coords of circus form)
-# PolygonCoords (return curve coords of regular polygon)
-# RoundedCurveCoords (return curve coords of rounded curve)
-# PolylineCoords (return curve coords of polyline)
-# TabBoxCoords (return curve coords of tabBox's pages)
-# PathLineCoords (return triangles coords of pathline)
-#
-# Geometrical basic Functions :
-# -----------------------------
-# PerpendicularPoint
-# LineAngle
-# VertexAngle
-# ArcPts
-# RadPoint
-#
-# Pictorial Functions :
-# ----------------------
-# SetGradients
-# GetPattern
-# GetTexture
-# GetImage
-# InitPixmaps
-# HexaRGBcolor
-# CreateGraduate
-#
-#-----------------------------------------------------------------------------------
-# Authors: Jean-Luc Vinot <vinot@cena.fr>
-# Patrick Lecoanet <lecoanet@cena.fr> (Straight translation
-# to Tcl, based on Graphics.pm revision 1.9)
-# $Id:
-#-----------------------------------------------------------------------------------
-
-namespace eval ::zincGraphics {
-
- package provide zincGraphics 1.0
-
- namespace export BuildZincItem RoundedRectangleCoords HippodromeCoords \
- PolygonCoords RoundedCurveCoords PolylineCoords TabBoxCoords PathLineCoords \
- PerpendicularPoint SetGradients GetPattern GetTexture GetImage InitPixmaps \
- HexaRGBcolor CreateGraduate
-
- namespace eval v {
- # constante facteur point directeur
- variable constPtdFactor 0.5523
- variable Gradients {}
- variable textures {}
- variable images {}
- variable bitmaps {}
- variable pi 3.14159
- }
-
- if { ![info exists zinc_library] } {
- set zinc_library [file dirname [info script]]
- }
-
- set imagePath [file join $zinc_library .. demos images]
-
- proc deg2rad {angle} {
- return [expr {$angle * $v::pi / 180.0}]
- }
-
- proc TLGet {list tag {default ""}} {
- foreach {key val} $list {
- if { [string compare $key $tag] == 0 } {
- return $val
- }
- }
- return $default
- }
-
- #proc TLGet {assoc tag {default ""}} {
- # array set temp $assoc
- # if { [info exists temp($tag)] } {
- # return $temp($tag)
- # }
- # return $default
- #}
-
- proc PointX {point} {
- return [lindex $point 0]
- }
-
- proc PointY {point} {
- return [lindex $point 1]
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::BuildZincItem
- # Création d'un objet Zinc de représentation
- # paramètres :
- # widget : <widget>
- # parentGroup : <group>
- # style : {hash table options}
- # specificTags : [list of specific tags] to add to params -tags
- # name : <str> nom de l'item
- #-----------------------------------------------------------------------------------
- # type d'item valide :
- # les items natifs zinc : group, rectangle, arc, curve, text, icon
- # les items ci-après permettent de spécifier des curves 'particulières' :
- # -roundedrectangle : rectangle à coin arrondi
- # -hippodrome : hippodrome
- # -polygone : polygone régulier à n cotés (convexe ou en étoile)
- # -roundedcurve : curve multicontours à coins arrondis (rayon unique)
- # -polyline : curve multicontours à coins arrondis (le rayon pouvant être défini
- # spécifiquement pour chaque sommet)
- # -pathline : création d'une ligne 'épaisse' avec l'item Zinc triangles
- # décalage par rapport à un chemin donné (largeur et sens de décalage)
- # dégradé de couleurs de la ligne (linéaire, transversal ou double)
- #-----------------------------------------------------------------------------------
- proc BuildZincItem {zinc parentGroup styleTL specificTags name} {
- array set style $styleTL
- if { [info exists style(-params)] } {
- array set params $style(-params)
- }
-
- if { ! $parentGroup } {
- set parentGroup 1
- }
-
- if { [llength $specificTags] } {
- if { [info exists params(-tags)] } {
- set params(-tags) [concat $specificTags $params(-tags)]
- } else {
- set params(-tags) $specificTags
- }
- }
-
- set itemType $style(-itemtype)
- set coords {}
- if { [info exists style(-coords)] } {
- set coords $style(-coords)
- }
- # gestion des polygones particuliers et à coin arrondi
- switch -- $itemType {
- roundedrectangle {
- set itemType curve
- set params(-closed) 1
- set coords [RoundedRectangleCoords $coords $styleTL]
- }
- hippodrome {
- set itemType curve
- set params(-closed) 1
- set coords [HippodromeCoords $coords $styleTL]
- }
- polygone {
- set itemType curve
- set params(-closed) 1
- set coords [PolygonCoords $coords $styleTL]
- }
- roundedcurve -
- polyline {
- set itemType curve
- if { $itemType eq "roundedcurve" } {
- set params(-closed) 1
- set coords [RoundedCurveCoords $coords $styleTL]
- } else {
- set coords [PolylineCoords $coords $styleTL]
- }
- #
- # multi-contours
- if { [info exists style(-contours)] } {
- set contours $style(-contours)
- set numContours [llength $contours]
- for {set i 0} {$i < $numContours} {incr i} {
- # radius et corners peuvent être défini spécifiquement
- # pour chaque contour
- foreach {type way inCoords radius corners cornersRadius} \
- [lindex $contours $i] break
-
- if { $radius eq "" } {
- set radius $style(-radius)
- }
- if { $itemType eq "roundedcurve" } {
- set newCoords [RoundedCurveCoords $inCoords [list -radius $radius \
- -corners $corners]]
- } else {
- set newCoords [PolylineCoords $inCoords \
- [list -radius $radius -corners $corners \
- -cornersradius $cornersRadius]]
- }
- lset style(-contours) $i [list $type $way $newCoords]
- }
- }
- }
- pathline {
- set itemType triangles
- if { [info exists style(-metacoords)] } {
- set coords [MetaCoords $style(-metacoords)]
- }
-
- if { [info exists style(-graduate)] } {
- set numColors [llength $coords]
- set params(-colors) [PathGraduate $numColors $style(-graduate)]
- }
- set coords [PathLineCoords $coords $styleTL]
- }
- }
-
- switch -- $itemType {
- group {
- set item [eval {$zinc add $itemType $parentGroup} [array get params]]
- if { [llength $coords] } {
- $zinc coords $item $coords
- }
-
- }
- text -
- icon {
- set imageFile ""
- if { $itemType eq "icon" } {
- set imageFile $params(-image)
- if { $imageFile ne "" } {
- set params(-image) [InitPixmap $imageFile]
- }
- }
-
- set item [eval {$zinc add $itemType $parentGroup -position $coords} [array get params]]
- if { $imageFile ne "" } {
- set params(-image) $imageFile
- }
- }
- default {
- set item [eval {$zinc add $itemType $parentGroup $coords} [array get params]]
- if { $itemType eq "curve" && [info exists style(-contours)] } {
- foreach contour $style(-contours) {
- eval $zinc contour $item $contour
- }
- }
-
- # gestion du mode norender
- if { [info exists style(-texture)] } {
- set texture [GetTexture $style(-texture)]
- if { $texture ne "" } {
- $zinc itemconfigure $item -tile $texture
- }
- }
-
- if { [info exists style(-fillpattern)] } {
- set bitmap [GetBitmap $style(-fillpattern)]
- if { $bitmap ne "" } {
- $zinc itemconfigure $item -fillpattern $bitmap
- }
- }
- }
- }
-
- # transformation scale de l'item si nécessaire
- if { [info exists style(-scale)] } {
- $zinc scale $item $style(-scale)
- }
-
- # transformation rotate de l'item si nécessaire
- if { [info exists style(-rotate)] } {
- $zinc rotate $item [deg2rad $style(-rotate)]
- }
- # transformation scale de l'item si nécessaire
- if { [info exists style(-translate)] } {
- $zinc translate $item $style(-translate)
- }
-
- return $item
- }
-
- #-----------------------------------------------------------------------------------
- # FONCTIONS GEOMETRIQUES
- #-----------------------------------------------------------------------------------
-
- #-----------------------------------------------------------------------------------
- # Graphics::MetaCoords
- # retourne une liste de coordonnées en utilisant la fonction d'un autre type d'item
- # paramètres : (options)
- # -type : type de primitive utilisée
- # -coords : coordonnées nécessitée par la fonction [type]Coords
- # + options spécialisées passés à la fonction [type]Coords
- #-----------------------------------------------------------------------------------
- proc MetaCoords {options} {
- set pts {}
- set type [TLGet $options -type]
- set coords [TLGet $options -coords]
-
- switch -- $type {
- polygone {
- set pts [PolygonCoords $coords $options]
- }
- hippodrome {
- set pts [HippodromeCoords $coords $options]
- }
- polyline {
- set pts [PolylineCoords $coords $options]
- }
- }
-
- return $pts
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::RoundedRectangleCoords
- # calcul des coords du rectangle à coins arrondis
- # paramètres :
- # coords : point centre du polygone
- # options :
- # -radius : rayon de raccord d'angle
- # -corners : liste des raccords de sommets [0 (aucun raccord)|1] par défaut [1,1,1,1]
- #-----------------------------------------------------------------------------------
- proc RoundedRectangleCoords {coords optionsTL} {
- foreach {p0 p1} $coords break
- foreach {x0 y0} $p0 break
- foreach {xn yn} $p1 break
-
- set radius [TLGet $optionsTL -radius]
- set corners [TLGet $optionsTL -corners]
- if { [llength $corners] == 0 } {
- set corners [list 1 1 1 1]
- }
-
- # attention aux formes 'négatives'
- if { $xn < $x0 } {
- set xs $x0
- set x0 $xn
- set xn $xs
- }
- if { $yn < $y0 } {
- set ys $y0
- set y0 $yn
- set yn $ys
- }
-
- set height [_min [expr {$xn - $x0}] [expr {$yn - $y0}]]
-
- if { $radius eq "" } {
- set radius [expr {int($height/10.0)}]
- if { $radius < 3 } {
- set radius 3
- }
- }
-
- if { $radius < 2 } {
- return [list [list $x0 $y0] [list $x0 $yn] \
- [list $xn $yn] [list $xn $y0]]
- }
-
-
- # correction de radius si necessaire
- set maxRad $height
- if { $corners eq "" } {
- set maxRad [expr {$maxRad / 2.0}]
- }
- if { $radius > $maxRad } {
- set radius $maxRad
- }
-
- # points remarquables
- set ptdDelta [expr {$radius * $v::constPtdFactor}]
- set x2 [expr {$x0 + $radius}]
- set x3 [expr {$xn - $radius}]
- set x1 [expr {$x2 - $ptdDelta}]
- set x4 [expr {$x3 + $ptdDelta}]
- set y2 [expr {$y0 + $radius}]
- set y3 [expr {$yn - $radius}]
- set y1 [expr {$y2 - $ptdDelta}]
- set y4 [expr {$y3 + $ptdDelta}]
-
- # liste des 4 points sommet du rectangle : angles sans raccord circulaire
- set anglePts [list [list $x0 $y0] [list $x0 $yn] \
- [list $xn $yn] [list $xn $y0]]
-
- # liste des 4 segments quadratique : raccord d'angle = radius
- set roundeds [list \
- [list [list $x2 $y0] [list $x1 $y0 c] \
- [list $x0 $y1 c] [list $x0 $y2]] \
- [list [list $x0 $y3] [list $x0 $y4 c] \
- [list $x1 $yn c] [list $x2 $yn]] \
- [list [list $x3 $yn] [list $x4 $yn c] \
- [list $xn $y4 c] [list $xn $y3]] \
- [list [list $xn $y2] [list $xn $y1 c] \
- [list $x4 $y0 c] [list $x3 $y0]]]
-
- set pts [list]
- set previous 0
- foreach seg $roundeds aPt $anglePts corner $corners {
- set px 0
- set py 0
- if { $corner } {
- # on teste si non duplication de point
- foreach {nx ny} [lindex $seg 0] break
- if { $previous && ($px == $nx && $py == $ny) } {
- eval lappend pts [lrange $seg 1 end]
- } else {
- eval lappend pts $seg
- }
- foreach {px py} [lindex $seg 3] break
- set previous 1
- } else {
- lappend pts $aPt
- }
- }
- return $pts
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::HippodromeCoords
- # calcul des coords d'un hippodrome
- # paramètres :
- # coords : coordonnées du rectangle exinscrit
- # options :
- # -orientation : orientation forcée de l'ippodrome [horizontal|vertical]
- # -corners : liste des raccords de sommets [0|1] par défaut [1,1,1,1]
- # -trunc : troncatures [left|right|top|bottom|both]
- #-----------------------------------------------------------------------------------
- proc HippodromeCoords {coords optionsTL} {
- foreach {p0 p1} $coords break
- foreach {x0 y0} $p0 break
- foreach {xn yn} $p1 break
-
- set orientation [TLGet $optionsTL -orientation none]
-
- # orientation forcée de l'hippodrome (sinon hippodrome sur le plus petit coté)
- switch -- $orientation {
- horizontal { set height [expr {abs($yn - $y0)}] }
- vertical { set height [expr {abs($xn - $x0)}] }
- default { set height [_min [expr {abs($xn - $x0)}] [expr {abs($yn - $y0)}]] }
- }
-
- set radius [expr {$height/2.0}]
-
- set corners [TLGet $optionsTL -corners]
- set trunc [TLGet $optionsTL -trunc]
- if { [llength $corners] == 0 } {
- switch -- $trunc {
- both { return [list [list $x0 $y0] [list $x0 $yn] \
- [list $xn $yn] [list $xn $y0]] }
- left { set corners [list 0 0 1 1] }
- right { set corners [list 1 1 0 0] }
- top { set corners [list 0 1 1 0] }
- bottom { set corners [list 1 0 0 1] }
- default { set corners [list 1 1 1 1] }
- }
- }
-
- # l'hippodrome est un cas particulier de roundedRectangle
- # on retourne en passant la 'configuration' à la fonction
- # générique roundedRectangleCoords
- return [RoundedRectangleCoords $coords [list -radius [expr {$height/2.0}] -corners $corners]]
- }
-
-
- #-----------------------------------------------------------------------------------
- # Graphics::PolygonCoords
- # calcul des coords d'un polygone régulier
- # paramètres :
- # coords : point centre du polygone
- # options :
- # -numsides : nombre de cotés
- # -radius : rayon de définition du polygone (distance centre-sommets)
- # -innerradius : rayon interne (polygone type étoile)
- # -corners : liste des raccords de sommets [0|1] par défaut [1,1,1,1]
- # -cornerradius : rayon de raccord des cotés
- # -startangle : angle de départ du polygone
- #-----------------------------------------------------------------------------------
- proc PolygonCoords {coords optionsTL} {
- set numSides [TLGet $optionsTL -numsides 0]
- set radius [TLGet $optionsTL -radius 0]
- if { $numSides < 3 || !$radius } {
- puts "Vous devez au moins spécifier un nombre de cotés >= 3 et un rayon..."
- return {};
- }
-
- if { [llength $coords] } {
- foreach {cx cy} $coords break
- } else {
- set cx 0
- set cy 0
- }
-
- set startAngle [TLGet $optionsTL -startangle 0]
- set angleStep [expr {360.0/$numSides}]
- set innerRadius [TLGet $optionsTL -innerradius 0]
- set pts [list]
-
- # points du polygone
- for {set i 0} {$i < $numSides} {incr i} {
- set p [RadPoint $cx $cy $radius [expr {$startAngle + ($angleStep*$i)}]]
- lappend pts $p
-
- # polygones 'étoiles'
- if { $innerRadius } {
- set p [RadPoint $cx $cy $innerRadius [expr {$startAngle + ($angleStep*($i+ 0.5))}]]
- lappend pts $p
- }
- }
-
- set cornerRadius [TLGet $optionsTL -cornerradius {}]
- if { $cornerRadius ne "" } {
- set pts [RoundedCurveCoords $pts [list -radius $cornerRadius -corners \
- [TLGet $optionsTL -corners {}]]]
- }
- return $pts
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::RoundedAngle
- # THIS FUNCTION IS NO MORE USED, NEITHER EXPORTED
- # curve d'angle avec raccord circulaire
- # paramètres :
- # zinc : widget
- # parentGroup : group zinc parent
- # coords : les 3 points de l'angle
- # radius : rayon de raccord
- #-----------------------------------------------------------------------------------
- proc RoundedAngle {zinc parentGroup coords radius} {
- foreach {pt0 pt1 pt2} $coords break
-
- foreach {cornerPts centerPts} [RoundedAngleCoords $coords $radius] break
- foreach {cx0 cy0} $centerPts break
-
- # valeur d'angle et angle formé par la bisectrice
- # set angle [VertexAngle $pt0 $pt1 $pt2]
-
- if { $parentGroup eq "" } {
- set parentGroup 1
- }
-
- set cornerPts [linsert $cornerPts 0 $pt0]
- lappend cornerPts $pt2
- $zinc add curve $parentGroup $cornerPts -closed 0 -linewidth 1 -priority 20
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::RoundedAngleCoords
- # calcul des coords d'un raccord d'angle circulaire
- #-----------------------------------------------------------------------------------
- # le raccord circulaire de 2 droites sécantes est traditionnellement réalisé par un
- # arc (conique) du cercle inscrit de rayon radius tangent à ces 2 droites
- #
- # Quadratique :
- # une approche de cette courbe peut être réalisée simplement par le calcul de 4 points
- # spécifiques qui définiront - quelle que soit la valeur de l'angle formé par les 2
- # droites - le segment de raccord :
- # - les 2 points de tangence au cercle inscrit seront les points de début et de fin
- # du segment de raccord
- # - les 2 points de controle seront situés chacun sur le vecteur reliant le point de
- # tangence au sommet de l'angle (point secant des 2 droites)
- # leur position sur ce vecteur peut être simplifiée comme suit :
- # - à un facteur de 0.5523 de la distance au sommet pour un angle >= 90° et <= 270°
- # - à une 'réduction' de ce point vers le point de tangence pour les angles limites
- # de 90° vers 0° et de 270° vers 360°
- # ce facteur sera légérement modulé pour recouvrir plus précisement l'arc correspondant
- #-----------------------------------------------------------------------------------
- proc RoundedAngleCoords {coords radius} {
- foreach {pt0 pt1 pt2} $coords break
- foreach {pt1x pt1y} $pt1 break
-
- # valeur d'angle et angle formé par la bisectrice
- foreach {angle bisecAngle} [VertexAngle $pt0 $pt1 $pt2] break
-
- # distance au centre du cercle inscrit : rayon/sinus demi-angle
- set sin [expr {sin([deg2rad $angle] / 2.0)}]
- set delta [expr {$sin ? abs($radius / $sin) : $radius}]
-
- # point centre du cercle inscrit de rayon $radius
- set refAngle [expr {($angle < 180) ? $bisecAngle+90 : $bisecAngle-90}]
- set c0 [RadPoint $pt1x $pt1y $delta $refAngle]
-
- # points de tangeance : pts perpendiculaires du centre aux 2 droites
- set p1 [PerpendicularPoint $c0 [list $pt0 $pt1]]
- set p2 [PerpendicularPoint $c0 [list $pt1 $pt2]]
- foreach {p1x p1y} $p1 break
- foreach {p2x p2y} $p2 break
-
- # point de controle de la quadratique
- # facteur de positionnement sur le vecteur pt.tangence, sommet
- set ptdFactor $v::constPtdFactor
- if { $angle < 90 || $angle > 270 } {
- set diffAngle [expr {($angle < 90) ? $angle : 360 - $angle}]
- if { $diffAngle > 15 } {
- set ptdFactor [expr {$ptdFactor - (((90.0 - $diffAngle)/90.0) * ($ptdFactor/4.0))}]
- }
- set ptdFactor [expr {($diffAngle/90.0) * \
- ($ptdFactor + ((1.0 - $ptdFactor) * (90.0 - $diffAngle)/90.0))}]
- } else {
- set diffAngle [expr {abs(180.0 - $angle)}]
- if { $diffAngle > 15 } {
- set ptdFactor [expr {$ptdFactor + (((90.0 - $diffAngle)/90.0) * ($ptdFactor/3.0))}]
- }
- }
-
- # delta xy aux pts de tangence
- set d1x [expr {($pt1x - $p1x) * $ptdFactor}]
- set d1y [expr {($pt1y - $p1y) * $ptdFactor}]
- set d2x [expr {($pt1x - $p2x) * $ptdFactor}]
- set d2y [expr {($pt1y - $p2y) * $ptdFactor}]
-
- # les 4 points de l'arc 'quadratique' et le centre du cercle inscrit
- set cornerPts [list $p1 \
- [list [expr {$p1x + $d1x}] [expr {$p1y + $d1y}] c] \
- [list [expr {$p2x + $d2x}] [expr {$p2y + $d2y}] c] \
- $p2]
-
- return [list $cornerPts $c0]
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::RoundedCurveCoords
- # retourne les coordonnées d'une curve à coins arrondis
- # paramètres :
- # coords : points de la curve
- # options :
- # -radius : rayon de raccord d'angle
- # -corners : liste des raccords de sommets [0|1] par défaut [1,1,1,1]
- #-----------------------------------------------------------------------------------
- proc RoundedCurveCoords {coords options} {
- set numFaces [llength $coords]
- set curvePts {}
- set radius [TLGet $options -radius 0]
- set corners [TLGet $options -corners {}]
-
- for {set index 0} {$index < $numFaces} {incr index} {
- if { ([llength $corners] > $index) && ([lindex $corners $index] == 0) } {
- lappend curvePts [lindex $coords $index]
- } else {
- set prev [expr {$index ? $index - 1 : $numFaces - 1}]
- set next [expr {($index > $numFaces - 2) ? 0 : $index + 1}]
- set angleCoords [list [lindex $coords $prev] \
- [lindex $coords $index] \
- [lindex $coords $next]]
- foreach {quadPts centerPts} [RoundedAngleCoords $angleCoords $radius] break
- set curvePts [concat $curvePts $quadPts]
- }
- }
- return $curvePts
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::PolylineCoords
- # retourne les coordonnées d'une polyline
- # paramètres :
- # coords : sommets de la polyline
- # options :
- # -radius : rayon global de raccord d'angle
- # -corners : liste des raccords de sommets [0|1] par défaut [1,1,1,1],
- # -cornersradius : liste des rayons de raccords de sommets
- #-----------------------------------------------------------------------------------
- proc PolylineCoords {coords options} {
- set numFaces [llength $coords]
- set curvePts {}
-
- set radius [TLGet $options -radius 0]
- set cornersRadius [TLGet $options -cornersradius]
-
- if { [llength $cornersRadius] } {
- set corners $cornersRadius
- } else {
- set corners [TLGet $options -corners]
- }
-
- set numCorners [llength $corners]
- for {set index 0} {$index < $numFaces} {incr index} {
- if { $numCorners && (($index >= $numCorners) || ![lindex $corners $index]) } {
- foreach {x y} [lindex $coords $index] { lappend curvePts [list $x $y] }
- } else {
- set prev [expr {$index ? $index - 1 : $numFaces - 1}]
- set next [expr {($index > $numFaces - 2) ? 0 : $index + 1}]
- set angleCoords [list [lindex $coords $prev] [lindex $coords $index] \
- [lindex $coords $next]]
-
- if { [llength $cornersRadius] } {
- set rad [lindex $cornersRadius $index]
- } else {
- set rad $radius
- }
- foreach {cornerPts centerPts} [RoundedAngleCoords $angleCoords $rad] break
- set curvePts [concat $curvePts $cornerPts]
- }
- }
-
- return $curvePts
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::PathLineCoords
- # retourne les coordonnées d'une pathLine
- # paramètres :
- # coords : points de path
- # options :
- # -closed : ligne fermée
- # -shifting : sens de décalage [both|left|right] par défaut both
- # -linewidth : epaisseur de la ligne
- #-----------------------------------------------------------------------------------
- proc PathLineCoords {coords options} {
- set numFaces [llength $coords]
- set pts {}
-
- set closed [TLGet $options -closed]
- set lineWidth [TLGet $options -linewidth 0]
- set shifting [TLGet $options -shifting both]
-
- if { ! $numFaces || $lineWidth < 2 } {
- return {}
- }
-
- set previous {}
- if { $closed } {
- set previous [lindex $coords [expr $numFaces - 1]]
- }
- set next [lindex $coords 1]
- if { $shifting eq "both" } {
- set lineWidth [expr {$lineWidth / 2.0}]
- }
-
- for {set i 0} {$i < $numFaces} {incr i} {
- set pt [lindex $coords $i]
- foreach {ptX ptY} $pt break
- foreach {nextX nextY} $next break
-
- if { [llength $previous] == 0 } {
- # extrémité de curve sans raccord -> angle plat
- set previous [list [expr {$ptX + ($ptX - $nextX)}] \
- [expr {$ptY + ($ptY - $nextY)}]]
- }
-
- foreach {angle bisecAngle} [VertexAngle $previous $pt $next] break
-
- # distance au centre du cercle inscrit : rayon/sinus demi-angle
- set sin [expr {sin([deg2rad [expr $angle/2.0]])}]
- set delta [expr {$sin ? abs($lineWidth / $sin) : $lineWidth}]
-
- if { $shifting eq "left" || $shifting eq "right" } {
- set adding [expr {($shifting eq "left") ? 90 : -90}]
- foreach {x y} [RadPoint $ptX $ptY $delta [expr {$bisecAngle + $adding}]] {
- lappend pts $x $y
- }
- lappend pts $ptX $ptY
-
- } else {
- foreach {x y} [RadPoint $ptX $ptY $delta [expr {$bisecAngle + 90}]] {
- lappend pts $x $y
- }
- foreach {x y} [RadPoint $ptX $ptY $delta [expr {$bisecAngle - 90}]] {
- lappend pts $x $y
- }
- }
-
- if { $i == [expr $numFaces - 2] } {
- if { $closed } {
- set next [lindex $coords 0]
- } else {
- set nextI [expr $i + 1]
- set next [list [expr {2 * [PointX [lindex $coords $nextI]] - [PointX $pt]}] \
- [expr {2 * [PointY [lindex $coords $nextI]] - [PointY $pt]}]]
- }
- } else {
- set next [lindex $coords [expr {$i + 2}]]
- }
- set previous [lindex $coords $i]
- }
-
- if { $closed } {
- lappend pts [lindex $pts 0] [lindex $pts 1] [lindex $pts 2] [lindex $pts 3]
- }
-
- return $pts
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::PerpendicularPoint
- # retourne les coordonnées du point perpendiculaire abaissé d'un point sur une ligne
- #-----------------------------------------------------------------------------------
- proc PerpendicularPoint {point line} {
- foreach {x y} $point {p1 p2} $line break
- foreach {x1 y1} $p1 {x2 y2} $p2 break
-
- # cas particulier de lignes ortho.
- set minDist .01
- if { abs($y2 - $y1) < $minDist } {
- # la ligne de référence est horizontale
- return [list $x $y1]
- } elseif { abs($x2 - $x1) < $minDist } {
- # la ligne de référence est verticale
- return [list $x1 $y]
- }
-
- set a1 [expr {double($y2 - $y1) / double($x2 - $x1)}]
- set b1 [expr {$y1 - $a1 * $x1}]
-
- set a2 [expr {-1.0 / $a1}]
- set b2 [expr {$y - $a2 * $x}]
-
- set xRet [expr {double($b2 - $b1) / double($a1 - $a2)}]
- set yRet [expr {$a1 * $xRet + $b1}]
-
- return [list $xRet $yRet]
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::LineAngle
- # retourne l'angle d'un point par rapport à un centre de référence
- #-----------------------------------------------------------------------------------
- proc LineAngle {p center} {
- foreach {x y} $p {xref yref} $center break
- set angle [expr {(atan2($y - $yref, $x - $xref) + $v::pi/2.0) * 180.0 / $v::pi}]
- if { $angle < 0 } {
- set angle [expr {$angle + 360}]
- }
- return $angle
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::VertexAngle
- # retourne la valeur de l'angle formée par 3 points
- # ainsi que l'angle de la bisectrice
- #-----------------------------------------------------------------------------------
- proc VertexAngle {pt0 pt1 pt2} {
- set angle1 [LineAngle $pt1 $pt0]
- set angle2 [LineAngle $pt1 $pt2]
-
- if { $angle2 < $angle1 } {
- set angle2 [expr $angle2 + 360]
- }
- set alpha [expr {$angle2 - $angle1}]
- set bisectrice [expr {$angle1 + ($alpha/2.0)}]
-
- return [list $alpha $bisectrice]
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::ArcPts
- # calcul des points constitutif d'un arc
- # params : x,y centre, rayon, angle départ, delta angulaire, pas en degré
- #-----------------------------------------------------------------------------------
- proc ArcPts {x y rad angle extent step debug} {
- set pts {}
-
- if { $extent > 0 } {
- for {set alpha $angle} {$alpha <= ($angle + $extent)} {incr $alpha $step} {
- foreach {xn yn} [RadPoint $x $y $rad $alpha] {}
- lappend pts $xn $yn
- }
- } else {
- for {set alpha $angle} {$alpha >= ($angle + $extent)} {incr $alpha $step} {
- lappend pts [RadPoint $x $y $rad $alpha]
- }
- }
- return $pts
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::RadPoint
- # retourne le point circulaire défini par centre-rayon-angle
- #-----------------------------------------------------------------------------------
- proc RadPoint {x y rad angle} {
- set alpha [deg2rad $angle]
-
- set xpt [expr {$x + ($rad * cos($alpha))}]
- set ypt [expr {$y + ($rad * sin($alpha))}]
-
- return [list $xpt $ypt]
- }
-
-
- #-----------------------------------------------------------------------------------
- # TabBoxCoords
- # Calcul des shapes de boites à onglets
- #
- # coords : coordonnées rectangle de la bounding box
- #
- # options
- # -numpages <n> : nombre de pages (onglets) de la boite
- # -anchor [n|e|s|w] : ancrage des onglets
- # -alignment [left|center|right] : alignement des onglets sur le coté d'ancrage
- # -tabwidth [<n>|[<n1>,<n2>,<n3>...]|auto] : largeur des onglets
- # -tabheight [<n>|auto] : hauteur des onglets
- # -tabshift <n> : décalage onglet
- # -radius <n> : rayon des arrondis d'angle
- # -overlap <n> : distance de recouvrement des onglets
- #-----------------------------------------------------------------------------------
- proc TabBoxCoords args {
- set coords [lindex $args 0]
- set options [lrange $args 1 end]
- foreach {p0 p1} $coords break
- foreach {x0 y0} $p0 {xn yn} $p1 break
- set numPages [TLGet $options -numpages 0]
-
- if { $x0 eq "" || $y0 eq "" || $xn eq "" || $yn eq "" || !$numPages } {
- puts "Vous devez au minimum spécifier le rectangle englobant et le nombre de pages"
- return {}
- }
-
- set anchor [TLGet $options -anchor n]
- set alignment [TLGet $options -alignment left]
- set len [TLGet $options -tabwidth auto]
- set thick [TLGet $options -tabheight auto]
- set biso [TLGet $options -tabshift auto]
- set radius [TLGet $options -radius 0]
- set overlap [TLGet $options -overlap 0]
- set orientation [expr {($anchor eq "n" || $anchor eq "s") ? "horizontal" : "vertical"}]
- set maxwidth [expr {($orientation eq "horizontal") ? ($xn - $x0) : ($yn - $y0)}]
- set tabswidth 0
- set align 1
-
- if { $len eq "auto" } {
- set tabswidth $maxwidth
- set len [expr {($tabswidth + ($overlap * ($numPages - 1)))/$numPages}]
- } else {
- if { [llength $len] > 1 } {
- foreach w $len {
- set tabswidth [expr {$tabswidth + ($w - $overlap)}]
- }
- set tabswidth [expr {$tabswidth + $overlap}]
- } else {
- set tabswidth [expr {($len * $numPages) - ($overlap * ($numPages - 1))}]
- }
- if { $tabswidth > $maxwidth } {
- set tabswidth $maxwidth
- set len [expr {($tabswidth + ($overlap * ($numPages - 1)))/$numPages}]
- }
- if { $alignment eq "center" && (($maxwidth - $tabswidth) > $radius) } {
- set align 0
- }
- }
- if { $thick eq "auto" } {
- set thick [expr {($orientation eq "horizontal") ? \
- int(($yn - $y0)/10.0) : int(($xn - $y0)/10.0)}]
- if {$thick < 10 } {
- set thick 10
- } elseif {$thick > 40} {
- set thick 40
- }
- }
- if { $biso eq "auto" } {
- set biso [expr {int($thick/2.0)}]
- }
- if { ($alignment eq "right" && $anchor ne "w") || \
- ($anchor eq "w" && $alignment ne "right") } {
- if { [llength $len] > 1 } {
- for {set p 0} {$p < $numPages} {incr p} {
- lset len $p [expr {-[lindex $len $p]}]
- }
- } else {
- set len [expr {-$len}]
- }
- set biso [expr {-$biso}]
- set overlap [expr {-$overlap}]
- }
-
- if { $alignment eq "center" } {
- set biso1 [expr {$biso / 2.0}]
- set biso2 $biso1
- } else {
- set biso1 0
- set biso2 $biso
- }
-
- if { $orientation eq "vertical" } {
- if { $anchor eq "w" } {
- set thick [expr {-$thick}]
- set startx $x0
- set endx $xn
- } else {
- set startx $xn
- set endx $x0
- }
- if { ($anchor eq "w" && $alignment ne "right") || \
- ($anchor eq "e" && $alignment eq "right") } {
- set starty $yn
- set endy $y0
- } else {
- set starty $y0
- set endy $yn
- }
-
- set xref [expr {$startx - $thick}]
- set yref $starty
- if { $alignment eq "center" } {
- set ratio [expr {($anchor eq "w") ? -2 : 2}]
- set yref [expr {$yref + (($maxwidth - $tabswidth)/$ratio)}]
- }
-
- set cadre [list [list $xref $endy] [list $endx $endy] \
- [list $endx $starty] [list $xref $starty]]
- #
- # flag de retournement de la liste des pts de
- # curve si nécessaire -> sens anti-horaire
- set inverse [expr {$alignment ne "right"}]
- } else {
- if { $anchor eq "s" } {
- set thick [expr {-$thick}]
- }
- if { $alignment eq "right" } {
- set startx $xn
- set endx $x0
- } else {
- set startx $x0
- set endx $xn
- }
- if { $anchor eq "s" } {
- set starty $yn
- set endy $y0
- } else {
- set starty $y0
- set endy $yn
- }
-
- set yref [expr {$starty + $thick}]
- if { $alignment eq "center" } {
- set xref [expr {$x0 + (($maxwidth - $tabswidth)/2.0)}]
- } else {
- set xref $startx
- }
-
- set cadre [list [list $endx $yref] [list $endx $endy] \
- [list $startx $endy] [list $startx $yref]]
- #
- # flag de retournement de la liste des pts de
- # curve si nécessaire -> sens anti-horaire
- set inverse [expr {($anchor eq "n" && $alignment ne "right") || \
- ($anchor eq "s" && $alignment eq "right")}]
- }
-
- for {set i 0} {$i < $numPages} {incr i} {
- set pts {}
- #
- # décrochage onglet
- #push (@pts, ([$xref, $yref])) if $i > 0;
- #
- # cadre
- set pts [lrange $cadre 0 end]
- #
- # points onglets
- if { $i > 0 || ! $align } {
- lappend pts [list $xref $yref]
- }
- set tw [expr {([llength $len] > 1) ? [lindex $len $i] : $len}]
- if { $orientation eq "vertical" } {
- set tabdxy [list $thick $biso1 $thick [expr {$tw - $biso2}] 0 $tw]
- } else {
- set tabdxy [list $biso1 [expr {-$thick}] [expr {$tw - $biso2}] [expr {-$thick}] $tw 0]
- }
- foreach {dx dy} $tabdxy {
- lappend pts [list [expr {$xref + $dx}] [expr {$yref + $dy}]]
- }
-
- if { $radius } {
- if { $i > 0 || ! $align } {
- set corners [list 0 1 1 1 0 1 1 0]
- } else {
- set corners [list 0 1 1 0 1 1 0 0 0]
- }
- set curvePts [RoundedCurveCoords $pts [list -radius $radius -corners $corners]]
- if { $inverse } {
- set curvePts [lreverse $curvePts]
- }
- lappend shapes $curvePts
- } else {
- if { $inverse } {
- set pts [lreverse $pts]
- }
- lappend shapes $pts
- }
-
- if { $orientation eq "horizontal" } {
- lappend titlesCoords [list [expr {$xref + ($tw - ($biso2 - $biso1))/2.0}] \
- [expr {$yref - ($thick/2.0)}]]
- set xref [expr {$xref + ($tw - $overlap)}]
- } else {
- lappend titlesCoords [list [expr {$xref + ($thick/2.0)}] \
- [expr {$yref + ($len - (($biso2 - $biso1)/2.0))/2.0}]]
- set yref [expr {$yref + ($len - $overlap)}]
- }
- }
-
- return [list $shapes $titlesCoords $inverse]
- }
-
- #-----------------------------------------------------------------------------------
- # RESOURCES GRAPHIQUES GRADIENTS, PATTERNS, TEXTURES, IMAGES...
- #-----------------------------------------------------------------------------------
- #-----------------------------------------------------------------------------------
- # Graphics::SetGradients
- # création de gradient nommés Zinc
- #-----------------------------------------------------------------------------------
- proc SetGradients {zinc grads} {
- # initialise les gradients de taches
- if { ! [llength $v::Gradients] } {
- foreach {name gradient} $grads {
- # création des gradients nommés
- $zinc gname $gradient $name
- lappend v::Gradients $name
- }
- }
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::GetPattern
- # retourne la ressource bitmap en l'initialisant si première utilisation
- #-----------------------------------------------------------------------------------
- proc GetPattern {name} {
- global bitmaps imagePath
-
- if { ![info exists bitmaps($name)] } {
- set bitmap "@[file join $imagePath $name]"
- set bitmaps($name) $bitmap
- return $bitmap
- }
- return $bitmaps($name)
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::GetTexture
- # retourne l'image de texture en l'initialisant si première utilisation
- #-----------------------------------------------------------------------------------
- proc GetTexture {name} {
- global imagePath
-
- if { ![info exists v::textures($name)] } {
- set texture [image create photo -file [file join $imagePath $name]]
- if { $texture ne "" } {
- set v::textures($name) $texture
- }
- return $texture
- }
- return $v::textures($name)
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::GetImage
- # retourne la ressource image en l'initialisant si première utilisation
- #-----------------------------------------------------------------------------------
- proc GetImage {name} {
- global imagePath
-
- if { ![info exists v::images($name)] } {
- set image [image create photo -file [file join $imagePath $name]]
- if { $image ne "" } {
- set v::images($name) $image
- }
- return $image
- }
- return $v::images($name)
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::InitPixmaps
- # initialise une liste de fichier image
- #-----------------------------------------------------------------------------------
- proc InitPixmaps {pixFiles} {
- set imgs {}
- foreach f $pixFiles {
- lappend imgs [GetImage $f]
- }
- return $imgs
- }
-
-
- proc _min {n1 n2} {
- return [expr {($n1 > $n2) ? $n2 : $n1}]
- }
-
- proc _max {n1 n2} {
- return [expr {($n1 > $n2) ? $n1 : $n2}]
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::_trunc
- # fonction interne de troncature des nombres: n = position décimale
- #-----------------------------------------------------------------------------------
- proc _trunc {val n} {
- regexp {([0-9]+)\.?([0-9]*)} $val match ent dec
- set str [expr {($val < 0) ? -$ent : $ent}]
- if { ($dec ne "") && ($n != 0) } {
- set dec [string range $dec 0 [expr {$n-1}]]
- if { $dec != 0 } {
- set str "$str.$dec"
- }
- }
- return $str;
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::RGBdec2hex
- # conversion d'une couleur RGB (255,255,255) au format Zinc '#ffffff'
- #-----------------------------------------------------------------------------------
- proc RGBdec2hex {rgb} {
- return [eval "format {#%04x%04x%04x} $rgb"]
- }
-
- #-----------------------------------------------------------------------------------
- # zincGraphics::PathGraduate
- # création d'un jeu de couleurs dégradées pour item pathLine
- #-----------------------------------------------------------------------------------
- proc PathGraduate {numColors style} {
- set type [TLGet $style -type]
- set colors [TLGet $style -colors]
-
- if { $type eq "linear" } {
- return [CreateGraduate $numColors $colors 2]
-
- } elseif { $type eq "double" } {
- set colors1 [CreateGraduate [expr {$numColors/2+1}] [lindex $colors 0]]
- set colors2 [CreateGraduate [expr {$numColors/2+1}] [lindex $colors 1]]
- set clrs {}
- for {set i 0} {$i <= $numColors} {incr i} {
- lappend clrs [lindex $colors1 $i] [lindex $colors2 $i]
- }
- return $clrs
-
- } elseif { $type eq "transversal" } {
- foreach {c1 c2} $colors break
- set clrs [list $c1 $c2]
- for {set i 0} {$i < $numColors} {incr i} {
- lappend clrs $c1 $c2
- }
- return $clrs;
- }
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::CreateGraduate
- # création d'un jeu de couleurs intermédiaires (dégradé) entre n couleurs
- #-----------------------------------------------------------------------------------
- proc CreateGraduate {totalSteps refColors {repeat 1}} {
- set colors {}
- set numGraduates [expr {[llength $refColors] - 1}]
-
- if { $numGraduates < 1 } {
- puts "Le dégradé necessite au minimum 2 couleurs de référence..."
- return {}
- }
-
- set steps [expr {($numGraduates > 1) ? ($totalSteps/($numGraduates - 1.0)) : $totalSteps}]
-
- for {set c 0} {$c < $numGraduates} {incr c} {
- set c1 [lindex $refColors $c]
- set c2 [lindex $refColors [expr {$c+1}]]
-
- #
- # Pas de duplication de la couleur de raccord entre
- # deux segments
- set thisSteps $steps
- if { $c < [expr $numGraduates - 1] } {
- set thisSteps [expr $thisSteps - 1]
- }
- for {set i 0} {$i < $thisSteps} {incr i} {
- set color [ComputeColor $c1 $c2 [expr {$i/($steps-1.0)}]]
- for {set k 0} {$k < $repeat} {incr k} {
- lappend colors $color
- }
- }
- }
-
- return $colors
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::computeColor
- # calcul d'une couleur intermédiaire défini par un ratio ($ratio) entre 2 couleurs
- #-----------------------------------------------------------------------------------
- proc ComputeColor {color0 color1 ratio} {
- if { $ratio > 1.0 } {
- set ratio 1
- } elseif { $ratio < 0 } {
- set ratio 0
- }
-
- foreach {r0 g0 b0 a0} [ZnColorToRGB $color0] break
- foreach {r1 g1 b1 a1} [ZnColorToRGB $color1] break
-
- set r [expr {$r0 + int(($r1 - $r0) * $ratio)}]
- set g [expr {$g0 + int(($g1 - $g0) * $ratio)}]
- set b [expr {$b0 + int(($b1 - $b0) * $ratio)}]
- set a [expr {$a0 + int(($a1 - $a0) * $ratio)}]
- return [HexaRGBcolor $r $g $b $a]
- }
-
- proc ZnColorToRGB {znColor} {
- foreach {color alpha} [split $znColor ";"] break
- set pattern [expr {[string length $color] > 8 ? {#%4x%4x%4x} : {#%2x%2x%2x}}]
- scan $color $pattern r g b
-
- if {$alpha eq ""} {
- set alpha 100
- }
-
- return [list $r $g $b $alpha]
- }
-
- #-----------------------------------------------------------------------------------
- # Graphics::hexaRGBcolor
- # conversion d'une couleur RGB (255,255,255) au format Zinc '#ffffff'
- #-----------------------------------------------------------------------------------
- proc HexaRGBcolor {r g b args} {
- if { [llength $args] } {
- return [format {#%02x%02x%02x;%d} $r $g $b [lindex $args 0]]
- } else {
- return [format {#%02x%02x%02x} $r $g $b]
- }
- }
-}
-
-proc lreverse {l} {
- set res {}
- set i [llength $l]
- while {$i} {
- lappend res [lindex $l [incr i -1]]
- }
- return $res
-}
diff --git a/library/zincLogo.tcl b/library/zincLogo.tcl
deleted file mode 100644
index aeafb6f..0000000
--- a/library/zincLogo.tcl
+++ /dev/null
@@ -1,107 +0,0 @@
-#---------------------------------------------------------------
-# File : LogoZinc.pm
-#
-# Copyright (C) 2001-2002
-# Centre d'Études de la Navigation Aérienne
-# Authors: Vinot Jean-Luc <vinot@cena.fr>
-# $Id$
-#---------------------------------------------------------------
-
-package provide zincLogo 1.0
-
-namespace eval ::zincLogo:: {
-
- set letters(coords) {
- {0 0} {106 0} {106 58} {122 41} {156 41} {131 69}
- {153 99} {203 41} {155 41} {155 0} {218 0} {240 0 c}
- {252 17 c} {252 34} {252 40 c} {249 50 c} {244 56}
- {202 105} {246 105} {246 87} {246 60 c} {271 37 c} {297 37}
- {323 37 c} {342 57 c} {344 68} {347 64 c} {350 60 c}
- {353 56} {363 46 c} {375 37 c} {395 37} {395 79} {393 79}
- {385 79 c} {379 86 c} {379 93} {379 100 c} {385 107 c}
- {393 107} {409 107} {409 148} {397 148} {378 148 c} {364 144 c}
- {354 133} {346 124} {346 148} {305 148} {305 87} {305 83 c}
- {301 79 c} {297 79} {293 79 c} {289 83 c} {289 87} {289 150}
- {251 150} {251 130} {251 126 c} {247 122 c} {243 122} {239 122 c}
- {235 126 c} {235 130} {235 150} {176 150} {154 150 c} {146 131 c}
- {146 114} {148 105} {120 105} {104 81} {104 105} {74 105} {74 41} {52 41}
- {52 105} {20 105} {20 41} {0 41}}
- set letters(lineWidth) 3
- set letters(lineColor) {#000000;80}
- set letters(fillColor) {=axial 270|#ffffff;100 0 28|#66848c;100 96|#7192aa;100 100}
- set letters(shadow,dXy) {6 6}
- set letters(shadow,fillColor) {#000000;18}
-
- set point(pos) {240 96}
- set point(alpha) 80
- set point(lineWidth) 1
- set point(lineColor) {#a10000;100}
- set point(fillColor) {=radial -20 -20|#ffffff;100 0|#f70000;100 48|#900000;100 80|#ab0000;100 100}
- set point(shadow,dXy) {5 5}
- set point(shadow,fillColor) {=path 0 0|#770000;64 0|#770000;64 65|#770000;0 100}
-
-
-
- proc create {zinc parent priority x y scaleX scaleY} {
- variable letters
- variable point
- #
- # Create a group to hold the various parts
- set logoGroup [$zinc add group $parent -priority $priority]
-
- #
- # Move the group in the right place
- $zinc coords $logoGroup "$x $y"
-
- #
- # Add a sub-group to isolate the scaling
- set scaleGroup [$zinc add group $logoGroup]
- $zinc scale $scaleGroup $scaleX $scaleY
-
- foreach {dx dy} $letters(shadow,dXy) break
- #
- # Create a curve for the main form shadow
- set lShadow [$zinc add curve $scaleGroup $letters(coords) \
- -tags lettersShadow -closed 1 -filled 1 -linewidth 0 \
- -fillcolor $letters(shadow,fillColor)]
- $zinc translate $lShadow $dx $dy
-
- set lineWidth [adjustLineWidth $letters(lineWidth) $scaleX $scaleY]
-
- #
- # Create a curve for the main form
- $zinc add curve $scaleGroup $letters(coords) -tags letters -closed 0 \
- -filled 1 -fillcolor $letters(fillColor) -linewidth $lineWidth \
- -linecolor $letters(lineColor)
-
- #
- # Create a group to hold the point and its shadow
- set pointGroup [$zinc add group $scaleGroup -alpha $point(alpha)]
- $zinc coords $pointGroup $point(pos)
-
- foreach {dx dy} $point(shadow,dXy) break
- #
- # Create a curve for the dot shadow
- set pShadow [$zinc add arc $pointGroup {-20 -20 20 20} -tags pointShadow \
- -closed 1 -filled 1 -fillcolor $point(shadow,fillColor) \
- -linewidth 0]
- $zinc translate $pShadow $dx $dy
-
- #
- # Create a curve for the dot
- $zinc add arc $pointGroup {-20 -20 20 20} -tags point -closed 1 \
- -filled 1 -fillcolor $point(fillColor) -linewidth $point(lineWidth) \
- -linecolor $point(lineColor)
-
- return $logoGroup
- }
-
- proc adjustLineWidth {lineWidth scaleX scaleY} {
- if {$lineWidth != 0} {
- if {$lineWidth >= 2} {
- set ratio [expr ($scaleX > $scaleY) ? $scaleY : $scaleX]
- return [expr $lineWidth * $ratio]
- }
- }
- }
-}
diff --git a/library/zincText.tcl b/library/zincText.tcl
deleted file mode 100644
index 2e235c5..0000000
--- a/library/zincText.tcl
+++ /dev/null
@@ -1,191 +0,0 @@
-#
-# ZincText - Zinc extension for text input on text items and fields
-#
-# $Id$
-#
-# AUTHOR
-#
-# Patrick Lecoanet <lecoanet@cena.fr>
-# (and documentation by Christophe Mertz <mertz@cena.fr>)
-#
-# Copyright (c) 2002 - 2003 CENA, Patrick Lecoanet
-#
-# This code is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Library General Public
-# License as published by the Free Software Foundation; either
-# version 2 of the License, or (at your option) any later version.
-#
-# This code is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Library General Public License for more details.
-#
-# You should have received a copy of the GNU Library General Public
-# License along with this code; if not, write to the Free
-# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#
-#
-# SYNOPSIS
-#
-# package require zincText;
-#
-# zn_TextBindings $zinc
-#
-# $zinc addtag text withtag $a_text
-# $zinc addtag text withtag $a_track
-# $zinc addtag text withtag $a_waypoint
-# $zinc addtag text withtag $a_tabular
-#
-#
-# DESCRIPTION
-#
-# This module implements text input with the mouse and keyboard 'a la emacs'.
-# Text items must have the 'text' tag and must of course be sensitive.
-# Track, waypoint and tabular items have fields and these fields can
-# be edited the same way. Only sensitive fields can be edited. the following
-# interactions are supported:
-#
-# <click 1> To set the cursor position
-# <click 2> To paste the current selection
-# <drag 1> To make a selection
-# <shift drag 1> To extend the current selection
-# <shift 1> To extend the current selection
-# <left arrow>,
-# <right arrow> To move the cursor to the left or to the right
-# <up arrow>,
-# <down arrow> To move the cursor up or down a line
-# <ctrl+a>,
-# <home> To move the cursor at the begining of the line
-# <ctrl+e>
-# <end> To move the cursor at the end of the line
-# <meta+<>,
-# <meta+>> To move the cursor at the beginning / end of the text
-# <BackSpace>
-# <ctrl+h> To delete the char just before the cursor
-# <Delete> To delete the char just after the cursor
-# <Return> To insert a return char. This does not validate the input!
-#
-#
-
-proc zn_TextBindings {zinc} {
- $zinc bind text <1> "startSel $zinc %x %y"
- $zinc bind text <2> "pasteSel $zinc %x %y"
- $zinc bind text <B1-Motion> "extendSel $zinc %x %y"
- $zinc bind text <Shift-B1-Motion> "extendSel $zinc %x %y"
- $zinc bind text <Shift-1> "$zinc select adjust current @%x,%y"
- $zinc bind text <Left> "moveCur $zinc -1"
- $zinc bind text <Right> "moveCur $zinc 1"
- $zinc bind text <Up> "setCur $zinc up"
- $zinc bind text <Down> "setCur $zinc down"
- $zinc bind text <Control-a> "setCur $zinc bol"
- $zinc bind text <Home> "setCur $zinc bol"
- $zinc bind text <Control-e> "setCur $zinc eol"
- $zinc bind text <End> "setCur $zinc eol"
- $zinc bind text <Meta-less> "setCur $zinc 0"
- $zinc bind text <Meta-greater> "setCur $zinc end"
- $zinc bind text <KeyPress> "insertKey $zinc %A"
- $zinc bind text <Shift-KeyPress> "insertKey $zinc %A"
- $zinc bind text <Return> "insertChar $zinc \\n"
- $zinc bind text <BackSpace> "textDel $zinc -1"
- $zinc bind text <Control-h> "textDel $zinc -1"
- $zinc bind text <Delete> "textDel $zinc 0"
-}
-
-
-proc pasteSel {w x y} {
- set item [$w focus]
-
- if {[llength $item] != 0} {
- catch {$w insert [lindex $item 0] [lindex $item 1] @$x,$y [selection get]}
- }
-}
-
-
-proc insertChar {w c} {
- set item [$w focus]
- set selItem [$w select item]
-
- if {[llength $item] == 0} {
- return;
- }
-
- if {([llength $selItem]!= 0) &&
- ([lindex $selItem 0] == [lindex $item 0]) &&
- ([lindex $selItem 1] == [lindex $item 1])} {
- $w dchars [lindex $item 0] [lindex $item 1] sel.first sel.last
- }
- $w insert [lindex $item 0] [lindex $item 1] insert $c
-}
-
-
-proc insertKey {w c} {
- if {! [binary scan $c {c} code]} {
- return
- }
- set code [expr $code & 0xFF]
- if {($code < 32) || ($code == 128)} {
- puts "rejet $code"
- return
- }
-
- insertChar $w $c
-}
-
-
-proc setCur {w where} {
- set item [$w focus]
-
- if {[llength $item] != 0} {
- $w cursor [lindex $item 0] [lindex $item 1] $where
- }
-}
-
-
-proc moveCur {w dir} {
- set item [$w focus]
-
- if {[llength $item] != 0} {
- set index [$w index [lindex $item 0] [lindex $item 1] insert]
- $w cursor [lindex $item 0] [lindex $item 1] [expr $index + $dir]
- }
-}
-
-
-proc startSel {w x y} {
- set part [$w currentpart t]
-
- $w cursor current $part @$x,$y
- $w focus current $part
- focus $w
- $w select from current $part @$x,$y
-}
-
-
-proc extendSel {w x y} {
- set part [$w currentpart t]
-
- $w select to current $part @$x,$y
-}
-
-
-proc textDel {w dir} {
- set item [$w focus]
- set selItem [$w select item]
-
- if {[llength $item] == 0} {
- return;
- }
-
- if {([llength $selItem] != 0) &&
- ([lindex $selItem 0] == [lindex $item 0]) &&
- ([lindex $selItem 1] == [lindex $item 1])} {
- $w dchars [lindex $item 0] [lindex $item 1] sel.first sel.last
- } else {
- set ind [expr [$w index [lindex $item 0] [lindex $item 1] insert] + $dir]
- if { $ind >= 0 } {
- $w dchars [lindex $item 0] [lindex $item 1] $ind $ind
- }
- }
-}
-
-package provide zincText 1.0
diff --git a/libtess/GL/gl.h b/libtess/GL/gl.h
deleted file mode 100644
index 07612d1..0000000
--- a/libtess/GL/gl.h
+++ /dev/null
@@ -1,2585 +0,0 @@
-/* $Id$ */
-
-/*
- * Mesa 3-D graphics library
- * Version: 4.0.4
- *
- * Copyright (C) 1999-2002 Brian Paul All Rights Reserved.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a
- * copy of this software and associated documentation files (the "Software"),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sublicense,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included
- * in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
- * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
- * BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
- * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
- * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
- */
-
-
-#ifndef __gl_h_
-#define __gl_h_
-
-#if defined(USE_MGL_NAMESPACE)
-#include "gl_mangle.h"
-#endif
-
-/*#warning "local gl.h"*/
-
-/**********************************************************************
- * Begin system-specific stuff.
- */
-#if defined(__BEOS__)
-#include <stdlib.h> /* to get some BeOS-isms */
-#endif
-
-#if !defined(OPENSTEP) && (defined(NeXT) || defined(NeXT_PDO))
-#define OPENSTEP
-#endif
-
-#if defined(_WIN32) && !defined(__WIN32__) && !defined(__CYGWIN__)
-#define __WIN32__
-#endif
-
-#if !defined(OPENSTEP) && (defined(__WIN32__) && !defined(__CYGWIN__))
-# if defined(_MSC_VER) && defined(BUILD_GL32) /* tag specify we're building mesa as a DLL */
-# define GLAPI __declspec(dllexport)
-# elif defined(_MSC_VER) && defined(_DLL) /* tag specifying we're building for DLL runtime support */
-# define GLAPI __declspec(dllimport)
-# else /* for use with static link lib build of Win32 edition only */
-# define GLAPI extern
-# endif /* _STATIC_MESA support */
-# define GLAPIENTRY __stdcall
-#else
-/* non-Windows compilation */
-# define GLAPI extern
-# define GLAPIENTRY
-#endif /* WIN32 / CYGWIN bracket */
-
-#if (defined(__BEOS__) && defined(__POWERPC__)) || defined(__QUICKDRAW__)
-# define PRAGMA_EXPORT_SUPPORTED 1
-#endif
-
-#if defined(_WIN32) && !defined(_WINGDI_) && !defined(_GNU_H_WINDOWS32_DEFINES) && !defined(OPENSTEP) && !defined(__CYGWIN__)
-#include <gl/mesa_wgl.h>
-#endif
-
-#if defined(macintosh) && PRAGMA_IMPORT_SUPPORTED
-#pragma import on
-#endif
-/*
- * End system-specific stuff.
- **********************************************************************/
-
-
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-
-#define GL_VERSION_1_1 1
-#define GL_VERSION_1_2 1
-#define GL_VERSION_1_3 1
-#define GL_ARB_imaging 1
-
-
-/*
- *
- * Datatypes
- *
- */
-#ifdef CENTERLINE_CLPP
-#define signed
-#endif
-typedef unsigned int GLenum;
-typedef unsigned char GLboolean;
-typedef unsigned int GLbitfield;
-typedef void GLvoid;
-typedef signed char GLbyte; /* 1-byte signed */
-typedef short GLshort; /* 2-byte signed */
-typedef int GLint; /* 4-byte signed */
-typedef unsigned char GLubyte; /* 1-byte unsigned */
-typedef unsigned short GLushort; /* 2-byte unsigned */
-typedef unsigned int GLuint; /* 4-byte unsigned */
-typedef int GLsizei; /* 4-byte signed */
-typedef float GLfloat; /* single precision float */
-typedef float GLclampf; /* single precision float in [0,1] */
-typedef double GLdouble; /* double precision float */
-typedef double GLclampd; /* double precision float in [0,1] */
-
-
-
-/*
- *
- * Constants
- *
- */
-
-/* Boolean values */
-#define GL_FALSE 0x0
-#define GL_TRUE 0x1
-
-/* Data types */
-#define GL_BYTE 0x1400
-#define GL_UNSIGNED_BYTE 0x1401
-#define GL_SHORT 0x1402
-#define GL_UNSIGNED_SHORT 0x1403
-#define GL_INT 0x1404
-#define GL_UNSIGNED_INT 0x1405
-#define GL_FLOAT 0x1406
-#define GL_DOUBLE 0x140A
-#define GL_2_BYTES 0x1407
-#define GL_3_BYTES 0x1408
-#define GL_4_BYTES 0x1409
-
-/* Primitives */
-#define GL_POINTS 0x0000
-#define GL_LINES 0x0001
-#define GL_LINE_LOOP 0x0002
-#define GL_LINE_STRIP 0x0003
-#define GL_TRIANGLES 0x0004
-#define GL_TRIANGLE_STRIP 0x0005
-#define GL_TRIANGLE_FAN 0x0006
-#define GL_QUADS 0x0007
-#define GL_QUAD_STRIP 0x0008
-#define GL_POLYGON 0x0009
-
-/* Vertex Arrays */
-#define GL_VERTEX_ARRAY 0x8074
-#define GL_NORMAL_ARRAY 0x8075
-#define GL_COLOR_ARRAY 0x8076
-#define GL_INDEX_ARRAY 0x8077
-#define GL_TEXTURE_COORD_ARRAY 0x8078
-#define GL_EDGE_FLAG_ARRAY 0x8079
-#define GL_VERTEX_ARRAY_SIZE 0x807A
-#define GL_VERTEX_ARRAY_TYPE 0x807B
-#define GL_VERTEX_ARRAY_STRIDE 0x807C
-#define GL_NORMAL_ARRAY_TYPE 0x807E
-#define GL_NORMAL_ARRAY_STRIDE 0x807F
-#define GL_COLOR_ARRAY_SIZE 0x8081
-#define GL_COLOR_ARRAY_TYPE 0x8082
-#define GL_COLOR_ARRAY_STRIDE 0x8083
-#define GL_INDEX_ARRAY_TYPE 0x8085
-#define GL_INDEX_ARRAY_STRIDE 0x8086
-#define GL_TEXTURE_COORD_ARRAY_SIZE 0x8088
-#define GL_TEXTURE_COORD_ARRAY_TYPE 0x8089
-#define GL_TEXTURE_COORD_ARRAY_STRIDE 0x808A
-#define GL_EDGE_FLAG_ARRAY_STRIDE 0x808C
-#define GL_VERTEX_ARRAY_POINTER 0x808E
-#define GL_NORMAL_ARRAY_POINTER 0x808F
-#define GL_COLOR_ARRAY_POINTER 0x8090
-#define GL_INDEX_ARRAY_POINTER 0x8091
-#define GL_TEXTURE_COORD_ARRAY_POINTER 0x8092
-#define GL_EDGE_FLAG_ARRAY_POINTER 0x8093
-#define GL_V2F 0x2A20
-#define GL_V3F 0x2A21
-#define GL_C4UB_V2F 0x2A22
-#define GL_C4UB_V3F 0x2A23
-#define GL_C3F_V3F 0x2A24
-#define GL_N3F_V3F 0x2A25
-#define GL_C4F_N3F_V3F 0x2A26
-#define GL_T2F_V3F 0x2A27
-#define GL_T4F_V4F 0x2A28
-#define GL_T2F_C4UB_V3F 0x2A29
-#define GL_T2F_C3F_V3F 0x2A2A
-#define GL_T2F_N3F_V3F 0x2A2B
-#define GL_T2F_C4F_N3F_V3F 0x2A2C
-#define GL_T4F_C4F_N3F_V4F 0x2A2D
-
-/* Matrix Mode */
-#define GL_MATRIX_MODE 0x0BA0
-#define GL_MODELVIEW 0x1700
-#define GL_PROJECTION 0x1701
-#define GL_TEXTURE 0x1702
-
-/* Points */
-#define GL_POINT_SMOOTH 0x0B10
-#define GL_POINT_SIZE 0x0B11
-#define GL_POINT_SIZE_GRANULARITY 0x0B13
-#define GL_POINT_SIZE_RANGE 0x0B12
-
-/* Lines */
-#define GL_LINE_SMOOTH 0x0B20
-#define GL_LINE_STIPPLE 0x0B24
-#define GL_LINE_STIPPLE_PATTERN 0x0B25
-#define GL_LINE_STIPPLE_REPEAT 0x0B26
-#define GL_LINE_WIDTH 0x0B21
-#define GL_LINE_WIDTH_GRANULARITY 0x0B23
-#define GL_LINE_WIDTH_RANGE 0x0B22
-
-/* Polygons */
-#define GL_POINT 0x1B00
-#define GL_LINE 0x1B01
-#define GL_FILL 0x1B02
-#define GL_CW 0x0900
-#define GL_CCW 0x0901
-#define GL_FRONT 0x0404
-#define GL_BACK 0x0405
-#define GL_POLYGON_MODE 0x0B40
-#define GL_POLYGON_SMOOTH 0x0B41
-#define GL_POLYGON_STIPPLE 0x0B42
-#define GL_EDGE_FLAG 0x0B43
-#define GL_CULL_FACE 0x0B44
-#define GL_CULL_FACE_MODE 0x0B45
-#define GL_FRONT_FACE 0x0B46
-#define GL_POLYGON_OFFSET_FACTOR 0x8038
-#define GL_POLYGON_OFFSET_UNITS 0x2A00
-#define GL_POLYGON_OFFSET_POINT 0x2A01
-#define GL_POLYGON_OFFSET_LINE 0x2A02
-#define GL_POLYGON_OFFSET_FILL 0x8037
-
-/* Display Lists */
-#define GL_COMPILE 0x1300
-#define GL_COMPILE_AND_EXECUTE 0x1301
-#define GL_LIST_BASE 0x0B32
-#define GL_LIST_INDEX 0x0B33
-#define GL_LIST_MODE 0x0B30
-
-/* Depth buffer */
-#define GL_NEVER 0x0200
-#define GL_LESS 0x0201
-#define GL_EQUAL 0x0202
-#define GL_LEQUAL 0x0203
-#define GL_GREATER 0x0204
-#define GL_NOTEQUAL 0x0205
-#define GL_GEQUAL 0x0206
-#define GL_ALWAYS 0x0207
-#define GL_DEPTH_TEST 0x0B71
-#define GL_DEPTH_BITS 0x0D56
-#define GL_DEPTH_CLEAR_VALUE 0x0B73
-#define GL_DEPTH_FUNC 0x0B74
-#define GL_DEPTH_RANGE 0x0B70
-#define GL_DEPTH_WRITEMASK 0x0B72
-#define GL_DEPTH_COMPONENT 0x1902
-
-/* Lighting */
-#define GL_LIGHTING 0x0B50
-#define GL_LIGHT0 0x4000
-#define GL_LIGHT1 0x4001
-#define GL_LIGHT2 0x4002
-#define GL_LIGHT3 0x4003
-#define GL_LIGHT4 0x4004
-#define GL_LIGHT5 0x4005
-#define GL_LIGHT6 0x4006
-#define GL_LIGHT7 0x4007
-#define GL_SPOT_EXPONENT 0x1205
-#define GL_SPOT_CUTOFF 0x1206
-#define GL_CONSTANT_ATTENUATION 0x1207
-#define GL_LINEAR_ATTENUATION 0x1208
-#define GL_QUADRATIC_ATTENUATION 0x1209
-#define GL_AMBIENT 0x1200
-#define GL_DIFFUSE 0x1201
-#define GL_SPECULAR 0x1202
-#define GL_SHININESS 0x1601
-#define GL_EMISSION 0x1600
-#define GL_POSITION 0x1203
-#define GL_SPOT_DIRECTION 0x1204
-#define GL_AMBIENT_AND_DIFFUSE 0x1602
-#define GL_COLOR_INDEXES 0x1603
-#define GL_LIGHT_MODEL_TWO_SIDE 0x0B52
-#define GL_LIGHT_MODEL_LOCAL_VIEWER 0x0B51
-#define GL_LIGHT_MODEL_AMBIENT 0x0B53
-#define GL_FRONT_AND_BACK 0x0408
-#define GL_SHADE_MODEL 0x0B54
-#define GL_FLAT 0x1D00
-#define GL_SMOOTH 0x1D01
-#define GL_COLOR_MATERIAL 0x0B57
-#define GL_COLOR_MATERIAL_FACE 0x0B55
-#define GL_COLOR_MATERIAL_PARAMETER 0x0B56
-#define GL_NORMALIZE 0x0BA1
-
-/* User clipping planes */
-#define GL_CLIP_PLANE0 0x3000
-#define GL_CLIP_PLANE1 0x3001
-#define GL_CLIP_PLANE2 0x3002
-#define GL_CLIP_PLANE3 0x3003
-#define GL_CLIP_PLANE4 0x3004
-#define GL_CLIP_PLANE5 0x3005
-
-/* Accumulation buffer */
-#define GL_ACCUM_RED_BITS 0x0D58
-#define GL_ACCUM_GREEN_BITS 0x0D59
-#define GL_ACCUM_BLUE_BITS 0x0D5A
-#define GL_ACCUM_ALPHA_BITS 0x0D5B
-#define GL_ACCUM_CLEAR_VALUE 0x0B80
-#define GL_ACCUM 0x0100
-#define GL_ADD 0x0104
-#define GL_LOAD 0x0101
-#define GL_MULT 0x0103
-#define GL_RETURN 0x0102
-
-/* Alpha testing */
-#define GL_ALPHA_TEST 0x0BC0
-#define GL_ALPHA_TEST_REF 0x0BC2
-#define GL_ALPHA_TEST_FUNC 0x0BC1
-
-/* Blending */
-#define GL_BLEND 0x0BE2
-#define GL_BLEND_SRC 0x0BE1
-#define GL_BLEND_DST 0x0BE0
-#define GL_ZERO 0x0
-#define GL_ONE 0x1
-#define GL_SRC_COLOR 0x0300
-#define GL_ONE_MINUS_SRC_COLOR 0x0301
-#define GL_SRC_ALPHA 0x0302
-#define GL_ONE_MINUS_SRC_ALPHA 0x0303
-#define GL_DST_ALPHA 0x0304
-#define GL_ONE_MINUS_DST_ALPHA 0x0305
-#define GL_DST_COLOR 0x0306
-#define GL_ONE_MINUS_DST_COLOR 0x0307
-#define GL_SRC_ALPHA_SATURATE 0x0308
-#define GL_CONSTANT_COLOR 0x8001
-#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002
-#define GL_CONSTANT_ALPHA 0x8003
-#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004
-
-/* Render Mode */
-#define GL_FEEDBACK 0x1C01
-#define GL_RENDER 0x1C00
-#define GL_SELECT 0x1C02
-
-/* Feedback */
-#define GL_2D 0x0600
-#define GL_3D 0x0601
-#define GL_3D_COLOR 0x0602
-#define GL_3D_COLOR_TEXTURE 0x0603
-#define GL_4D_COLOR_TEXTURE 0x0604
-#define GL_POINT_TOKEN 0x0701
-#define GL_LINE_TOKEN 0x0702
-#define GL_LINE_RESET_TOKEN 0x0707
-#define GL_POLYGON_TOKEN 0x0703
-#define GL_BITMAP_TOKEN 0x0704
-#define GL_DRAW_PIXEL_TOKEN 0x0705
-#define GL_COPY_PIXEL_TOKEN 0x0706
-#define GL_PASS_THROUGH_TOKEN 0x0700
-#define GL_FEEDBACK_BUFFER_POINTER 0x0DF0
-#define GL_FEEDBACK_BUFFER_SIZE 0x0DF1
-#define GL_FEEDBACK_BUFFER_TYPE 0x0DF2
-
-/* Selection */
-#define GL_SELECTION_BUFFER_POINTER 0x0DF3
-#define GL_SELECTION_BUFFER_SIZE 0x0DF4
-
-/* Fog */
-#define GL_FOG 0x0B60
-#define GL_FOG_MODE 0x0B65
-#define GL_FOG_DENSITY 0x0B62
-#define GL_FOG_COLOR 0x0B66
-#define GL_FOG_INDEX 0x0B61
-#define GL_FOG_START 0x0B63
-#define GL_FOG_END 0x0B64
-#define GL_LINEAR 0x2601
-#define GL_EXP 0x0800
-#define GL_EXP2 0x0801
-
-/* Logic Ops */
-#define GL_LOGIC_OP 0x0BF1
-#define GL_INDEX_LOGIC_OP 0x0BF1
-#define GL_COLOR_LOGIC_OP 0x0BF2
-#define GL_LOGIC_OP_MODE 0x0BF0
-#define GL_CLEAR 0x1500
-#define GL_SET 0x150F
-#define GL_COPY 0x1503
-#define GL_COPY_INVERTED 0x150C
-#define GL_NOOP 0x1505
-#define GL_INVERT 0x150A
-#define GL_AND 0x1501
-#define GL_NAND 0x150E
-#define GL_OR 0x1507
-#define GL_NOR 0x1508
-#define GL_XOR 0x1506
-#define GL_EQUIV 0x1509
-#define GL_AND_REVERSE 0x1502
-#define GL_AND_INVERTED 0x1504
-#define GL_OR_REVERSE 0x150B
-#define GL_OR_INVERTED 0x150D
-
-/* Stencil */
-#define GL_STENCIL_TEST 0x0B90
-#define GL_STENCIL_WRITEMASK 0x0B98
-#define GL_STENCIL_BITS 0x0D57
-#define GL_STENCIL_FUNC 0x0B92
-#define GL_STENCIL_VALUE_MASK 0x0B93
-#define GL_STENCIL_REF 0x0B97
-#define GL_STENCIL_FAIL 0x0B94
-#define GL_STENCIL_PASS_DEPTH_PASS 0x0B96
-#define GL_STENCIL_PASS_DEPTH_FAIL 0x0B95
-#define GL_STENCIL_CLEAR_VALUE 0x0B91
-#define GL_STENCIL_INDEX 0x1901
-#define GL_KEEP 0x1E00
-#define GL_REPLACE 0x1E01
-#define GL_INCR 0x1E02
-#define GL_DECR 0x1E03
-
-/* Buffers, Pixel Drawing/Reading */
-#define GL_NONE 0x0
-#define GL_LEFT 0x0406
-#define GL_RIGHT 0x0407
-/*GL_FRONT 0x0404 */
-/*GL_BACK 0x0405 */
-/*GL_FRONT_AND_BACK 0x0408 */
-#define GL_FRONT_LEFT 0x0400
-#define GL_FRONT_RIGHT 0x0401
-#define GL_BACK_LEFT 0x0402
-#define GL_BACK_RIGHT 0x0403
-#define GL_AUX0 0x0409
-#define GL_AUX1 0x040A
-#define GL_AUX2 0x040B
-#define GL_AUX3 0x040C
-#define GL_COLOR_INDEX 0x1900
-#define GL_RED 0x1903
-#define GL_GREEN 0x1904
-#define GL_BLUE 0x1905
-#define GL_ALPHA 0x1906
-#define GL_LUMINANCE 0x1909
-#define GL_LUMINANCE_ALPHA 0x190A
-#define GL_ALPHA_BITS 0x0D55
-#define GL_RED_BITS 0x0D52
-#define GL_GREEN_BITS 0x0D53
-#define GL_BLUE_BITS 0x0D54
-#define GL_INDEX_BITS 0x0D51
-#define GL_SUBPIXEL_BITS 0x0D50
-#define GL_AUX_BUFFERS 0x0C00
-#define GL_READ_BUFFER 0x0C02
-#define GL_DRAW_BUFFER 0x0C01
-#define GL_DOUBLEBUFFER 0x0C32
-#define GL_STEREO 0x0C33
-#define GL_BITMAP 0x1A00
-#define GL_COLOR 0x1800
-#define GL_DEPTH 0x1801
-#define GL_STENCIL 0x1802
-#define GL_DITHER 0x0BD0
-#define GL_RGB 0x1907
-#define GL_RGBA 0x1908
-
-/* Implementation limits */
-#define GL_MAX_LIST_NESTING 0x0B31
-#define GL_MAX_ATTRIB_STACK_DEPTH 0x0D35
-#define GL_MAX_MODELVIEW_STACK_DEPTH 0x0D36
-#define GL_MAX_NAME_STACK_DEPTH 0x0D37
-#define GL_MAX_PROJECTION_STACK_DEPTH 0x0D38
-#define GL_MAX_TEXTURE_STACK_DEPTH 0x0D39
-#define GL_MAX_EVAL_ORDER 0x0D30
-#define GL_MAX_LIGHTS 0x0D31
-#define GL_MAX_CLIP_PLANES 0x0D32
-#define GL_MAX_TEXTURE_SIZE 0x0D33
-#define GL_MAX_PIXEL_MAP_TABLE 0x0D34
-#define GL_MAX_VIEWPORT_DIMS 0x0D3A
-#define GL_MAX_CLIENT_ATTRIB_STACK_DEPTH 0x0D3B
-
-/* Gets */
-#define GL_ATTRIB_STACK_DEPTH 0x0BB0
-#define GL_CLIENT_ATTRIB_STACK_DEPTH 0x0BB1
-#define GL_COLOR_CLEAR_VALUE 0x0C22
-#define GL_COLOR_WRITEMASK 0x0C23
-#define GL_CURRENT_INDEX 0x0B01
-#define GL_CURRENT_COLOR 0x0B00
-#define GL_CURRENT_NORMAL 0x0B02
-#define GL_CURRENT_RASTER_COLOR 0x0B04
-#define GL_CURRENT_RASTER_DISTANCE 0x0B09
-#define GL_CURRENT_RASTER_INDEX 0x0B05
-#define GL_CURRENT_RASTER_POSITION 0x0B07
-#define GL_CURRENT_RASTER_TEXTURE_COORDS 0x0B06
-#define GL_CURRENT_RASTER_POSITION_VALID 0x0B08
-#define GL_CURRENT_TEXTURE_COORDS 0x0B03
-#define GL_INDEX_CLEAR_VALUE 0x0C20
-#define GL_INDEX_MODE 0x0C30
-#define GL_INDEX_WRITEMASK 0x0C21
-#define GL_MODELVIEW_MATRIX 0x0BA6
-#define GL_MODELVIEW_STACK_DEPTH 0x0BA3
-#define GL_NAME_STACK_DEPTH 0x0D70
-#define GL_PROJECTION_MATRIX 0x0BA7
-#define GL_PROJECTION_STACK_DEPTH 0x0BA4
-#define GL_RENDER_MODE 0x0C40
-#define GL_RGBA_MODE 0x0C31
-#define GL_TEXTURE_MATRIX 0x0BA8
-#define GL_TEXTURE_STACK_DEPTH 0x0BA5
-#define GL_VIEWPORT 0x0BA2
-
-/* Evaluators */
-#define GL_AUTO_NORMAL 0x0D80
-#define GL_MAP1_COLOR_4 0x0D90
-#define GL_MAP1_GRID_DOMAIN 0x0DD0
-#define GL_MAP1_GRID_SEGMENTS 0x0DD1
-#define GL_MAP1_INDEX 0x0D91
-#define GL_MAP1_NORMAL 0x0D92
-#define GL_MAP1_TEXTURE_COORD_1 0x0D93
-#define GL_MAP1_TEXTURE_COORD_2 0x0D94
-#define GL_MAP1_TEXTURE_COORD_3 0x0D95
-#define GL_MAP1_TEXTURE_COORD_4 0x0D96
-#define GL_MAP1_VERTEX_3 0x0D97
-#define GL_MAP1_VERTEX_4 0x0D98
-#define GL_MAP2_COLOR_4 0x0DB0
-#define GL_MAP2_GRID_DOMAIN 0x0DD2
-#define GL_MAP2_GRID_SEGMENTS 0x0DD3
-#define GL_MAP2_INDEX 0x0DB1
-#define GL_MAP2_NORMAL 0x0DB2
-#define GL_MAP2_TEXTURE_COORD_1 0x0DB3
-#define GL_MAP2_TEXTURE_COORD_2 0x0DB4
-#define GL_MAP2_TEXTURE_COORD_3 0x0DB5
-#define GL_MAP2_TEXTURE_COORD_4 0x0DB6
-#define GL_MAP2_VERTEX_3 0x0DB7
-#define GL_MAP2_VERTEX_4 0x0DB8
-#define GL_COEFF 0x0A00
-#define GL_DOMAIN 0x0A02
-#define GL_ORDER 0x0A01
-
-/* Hints */
-#define GL_FOG_HINT 0x0C54
-#define GL_LINE_SMOOTH_HINT 0x0C52
-#define GL_PERSPECTIVE_CORRECTION_HINT 0x0C50
-#define GL_POINT_SMOOTH_HINT 0x0C51
-#define GL_POLYGON_SMOOTH_HINT 0x0C53
-#define GL_DONT_CARE 0x1100
-#define GL_FASTEST 0x1101
-#define GL_NICEST 0x1102
-
-/* Scissor box */
-#define GL_SCISSOR_TEST 0x0C11
-#define GL_SCISSOR_BOX 0x0C10
-
-/* Pixel Mode / Transfer */
-#define GL_MAP_COLOR 0x0D10
-#define GL_MAP_STENCIL 0x0D11
-#define GL_INDEX_SHIFT 0x0D12
-#define GL_INDEX_OFFSET 0x0D13
-#define GL_RED_SCALE 0x0D14
-#define GL_RED_BIAS 0x0D15
-#define GL_GREEN_SCALE 0x0D18
-#define GL_GREEN_BIAS 0x0D19
-#define GL_BLUE_SCALE 0x0D1A
-#define GL_BLUE_BIAS 0x0D1B
-#define GL_ALPHA_SCALE 0x0D1C
-#define GL_ALPHA_BIAS 0x0D1D
-#define GL_DEPTH_SCALE 0x0D1E
-#define GL_DEPTH_BIAS 0x0D1F
-#define GL_PIXEL_MAP_S_TO_S_SIZE 0x0CB1
-#define GL_PIXEL_MAP_I_TO_I_SIZE 0x0CB0
-#define GL_PIXEL_MAP_I_TO_R_SIZE 0x0CB2
-#define GL_PIXEL_MAP_I_TO_G_SIZE 0x0CB3
-#define GL_PIXEL_MAP_I_TO_B_SIZE 0x0CB4
-#define GL_PIXEL_MAP_I_TO_A_SIZE 0x0CB5
-#define GL_PIXEL_MAP_R_TO_R_SIZE 0x0CB6
-#define GL_PIXEL_MAP_G_TO_G_SIZE 0x0CB7
-#define GL_PIXEL_MAP_B_TO_B_SIZE 0x0CB8
-#define GL_PIXEL_MAP_A_TO_A_SIZE 0x0CB9
-#define GL_PIXEL_MAP_S_TO_S 0x0C71
-#define GL_PIXEL_MAP_I_TO_I 0x0C70
-#define GL_PIXEL_MAP_I_TO_R 0x0C72
-#define GL_PIXEL_MAP_I_TO_G 0x0C73
-#define GL_PIXEL_MAP_I_TO_B 0x0C74
-#define GL_PIXEL_MAP_I_TO_A 0x0C75
-#define GL_PIXEL_MAP_R_TO_R 0x0C76
-#define GL_PIXEL_MAP_G_TO_G 0x0C77
-#define GL_PIXEL_MAP_B_TO_B 0x0C78
-#define GL_PIXEL_MAP_A_TO_A 0x0C79
-#define GL_PACK_ALIGNMENT 0x0D05
-#define GL_PACK_LSB_FIRST 0x0D01
-#define GL_PACK_ROW_LENGTH 0x0D02
-#define GL_PACK_SKIP_PIXELS 0x0D04
-#define GL_PACK_SKIP_ROWS 0x0D03
-#define GL_PACK_SWAP_BYTES 0x0D00
-#define GL_UNPACK_ALIGNMENT 0x0CF5
-#define GL_UNPACK_LSB_FIRST 0x0CF1
-#define GL_UNPACK_ROW_LENGTH 0x0CF2
-#define GL_UNPACK_SKIP_PIXELS 0x0CF4
-#define GL_UNPACK_SKIP_ROWS 0x0CF3
-#define GL_UNPACK_SWAP_BYTES 0x0CF0
-#define GL_ZOOM_X 0x0D16
-#define GL_ZOOM_Y 0x0D17
-
-/* Texture mapping */
-#define GL_TEXTURE_ENV 0x2300
-#define GL_TEXTURE_ENV_MODE 0x2200
-#define GL_TEXTURE_1D 0x0DE0
-#define GL_TEXTURE_2D 0x0DE1
-#define GL_TEXTURE_WRAP_S 0x2802
-#define GL_TEXTURE_WRAP_T 0x2803
-#define GL_TEXTURE_MAG_FILTER 0x2800
-#define GL_TEXTURE_MIN_FILTER 0x2801
-#define GL_TEXTURE_ENV_COLOR 0x2201
-#define GL_TEXTURE_GEN_S 0x0C60
-#define GL_TEXTURE_GEN_T 0x0C61
-#define GL_TEXTURE_GEN_MODE 0x2500
-#define GL_TEXTURE_BORDER_COLOR 0x1004
-#define GL_TEXTURE_WIDTH 0x1000
-#define GL_TEXTURE_HEIGHT 0x1001
-#define GL_TEXTURE_BORDER 0x1005
-#define GL_TEXTURE_COMPONENTS 0x1003
-#define GL_TEXTURE_RED_SIZE 0x805C
-#define GL_TEXTURE_GREEN_SIZE 0x805D
-#define GL_TEXTURE_BLUE_SIZE 0x805E
-#define GL_TEXTURE_ALPHA_SIZE 0x805F
-#define GL_TEXTURE_LUMINANCE_SIZE 0x8060
-#define GL_TEXTURE_INTENSITY_SIZE 0x8061
-#define GL_NEAREST_MIPMAP_NEAREST 0x2700
-#define GL_NEAREST_MIPMAP_LINEAR 0x2702
-#define GL_LINEAR_MIPMAP_NEAREST 0x2701
-#define GL_LINEAR_MIPMAP_LINEAR 0x2703
-#define GL_OBJECT_LINEAR 0x2401
-#define GL_OBJECT_PLANE 0x2501
-#define GL_EYE_LINEAR 0x2400
-#define GL_EYE_PLANE 0x2502
-#define GL_SPHERE_MAP 0x2402
-#define GL_DECAL 0x2101
-#define GL_MODULATE 0x2100
-#define GL_NEAREST 0x2600
-#define GL_REPEAT 0x2901
-#define GL_CLAMP 0x2900
-#define GL_S 0x2000
-#define GL_T 0x2001
-#define GL_R 0x2002
-#define GL_Q 0x2003
-#define GL_TEXTURE_GEN_R 0x0C62
-#define GL_TEXTURE_GEN_Q 0x0C63
-
-/* Utility */
-#define GL_VENDOR 0x1F00
-#define GL_RENDERER 0x1F01
-#define GL_VERSION 0x1F02
-#define GL_EXTENSIONS 0x1F03
-
-/* Errors */
-#define GL_NO_ERROR 0x0
-#define GL_INVALID_VALUE 0x0501
-#define GL_INVALID_ENUM 0x0500
-#define GL_INVALID_OPERATION 0x0502
-#define GL_STACK_OVERFLOW 0x0503
-#define GL_STACK_UNDERFLOW 0x0504
-#define GL_OUT_OF_MEMORY 0x0505
-
-/* glPush/PopAttrib bits */
-#define GL_CURRENT_BIT 0x00000001
-#define GL_POINT_BIT 0x00000002
-#define GL_LINE_BIT 0x00000004
-#define GL_POLYGON_BIT 0x00000008
-#define GL_POLYGON_STIPPLE_BIT 0x00000010
-#define GL_PIXEL_MODE_BIT 0x00000020
-#define GL_LIGHTING_BIT 0x00000040
-#define GL_FOG_BIT 0x00000080
-#define GL_DEPTH_BUFFER_BIT 0x00000100
-#define GL_ACCUM_BUFFER_BIT 0x00000200
-#define GL_STENCIL_BUFFER_BIT 0x00000400
-#define GL_VIEWPORT_BIT 0x00000800
-#define GL_TRANSFORM_BIT 0x00001000
-#define GL_ENABLE_BIT 0x00002000
-#define GL_COLOR_BUFFER_BIT 0x00004000
-#define GL_HINT_BIT 0x00008000
-#define GL_EVAL_BIT 0x00010000
-#define GL_LIST_BIT 0x00020000
-#define GL_TEXTURE_BIT 0x00040000
-#define GL_SCISSOR_BIT 0x00080000
-#define GL_ALL_ATTRIB_BITS 0x000FFFFF
-
-
-/* OpenGL 1.1 */
-#define GL_PROXY_TEXTURE_1D 0x8063
-#define GL_PROXY_TEXTURE_2D 0x8064
-#define GL_TEXTURE_PRIORITY 0x8066
-#define GL_TEXTURE_RESIDENT 0x8067
-#define GL_TEXTURE_BINDING_1D 0x8068
-#define GL_TEXTURE_BINDING_2D 0x8069
-#define GL_TEXTURE_INTERNAL_FORMAT 0x1003
-#define GL_ALPHA4 0x803B
-#define GL_ALPHA8 0x803C
-#define GL_ALPHA12 0x803D
-#define GL_ALPHA16 0x803E
-#define GL_LUMINANCE4 0x803F
-#define GL_LUMINANCE8 0x8040
-#define GL_LUMINANCE12 0x8041
-#define GL_LUMINANCE16 0x8042
-#define GL_LUMINANCE4_ALPHA4 0x8043
-#define GL_LUMINANCE6_ALPHA2 0x8044
-#define GL_LUMINANCE8_ALPHA8 0x8045
-#define GL_LUMINANCE12_ALPHA4 0x8046
-#define GL_LUMINANCE12_ALPHA12 0x8047
-#define GL_LUMINANCE16_ALPHA16 0x8048
-#define GL_INTENSITY 0x8049
-#define GL_INTENSITY4 0x804A
-#define GL_INTENSITY8 0x804B
-#define GL_INTENSITY12 0x804C
-#define GL_INTENSITY16 0x804D
-#define GL_R3_G3_B2 0x2A10
-#define GL_RGB4 0x804F
-#define GL_RGB5 0x8050
-#define GL_RGB8 0x8051
-#define GL_RGB10 0x8052
-#define GL_RGB12 0x8053
-#define GL_RGB16 0x8054
-#define GL_RGBA2 0x8055
-#define GL_RGBA4 0x8056
-#define GL_RGB5_A1 0x8057
-#define GL_RGBA8 0x8058
-#define GL_RGB10_A2 0x8059
-#define GL_RGBA12 0x805A
-#define GL_RGBA16 0x805B
-#define GL_CLIENT_PIXEL_STORE_BIT 0x00000001
-#define GL_CLIENT_VERTEX_ARRAY_BIT 0x00000002
-#define GL_ALL_CLIENT_ATTRIB_BITS 0xFFFFFFFF
-#define GL_CLIENT_ALL_ATTRIB_BITS 0xFFFFFFFF
-
-
-/* OpenGL 1.2 */
-#define GL_RESCALE_NORMAL 0x803A
-#define GL_CLAMP_TO_EDGE 0x812F
-#define GL_MAX_ELEMENTS_VERTICES 0x80E8
-#define GL_MAX_ELEMENTS_INDICES 0x80E9
-#define GL_BGR 0x80E0
-#define GL_BGRA 0x80E1
-#define GL_UNSIGNED_BYTE_3_3_2 0x8032
-#define GL_UNSIGNED_BYTE_2_3_3_REV 0x8362
-#define GL_UNSIGNED_SHORT_5_6_5 0x8363
-#define GL_UNSIGNED_SHORT_5_6_5_REV 0x8364
-#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033
-#define GL_UNSIGNED_SHORT_4_4_4_4_REV 0x8365
-#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034
-#define GL_UNSIGNED_SHORT_1_5_5_5_REV 0x8366
-#define GL_UNSIGNED_INT_8_8_8_8 0x8035
-#define GL_UNSIGNED_INT_8_8_8_8_REV 0x8367
-#define GL_UNSIGNED_INT_10_10_10_2 0x8036
-#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368
-#define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8
-#define GL_SINGLE_COLOR 0x81F9
-#define GL_SEPARATE_SPECULAR_COLOR 0x81FA
-#define GL_TEXTURE_MIN_LOD 0x813A
-#define GL_TEXTURE_MAX_LOD 0x813B
-#define GL_TEXTURE_BASE_LEVEL 0x813C
-#define GL_TEXTURE_MAX_LEVEL 0x813D
-#define GL_SMOOTH_POINT_SIZE_RANGE 0x0B12
-#define GL_SMOOTH_POINT_SIZE_GRANULARITY 0x0B13
-#define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22
-#define GL_SMOOTH_LINE_WIDTH_GRANULARITY 0x0B23
-#define GL_ALIASED_POINT_SIZE_RANGE 0x846D
-#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E
-#define GL_PACK_SKIP_IMAGES 0x806B
-#define GL_PACK_IMAGE_HEIGHT 0x806C
-#define GL_UNPACK_SKIP_IMAGES 0x806D
-#define GL_UNPACK_IMAGE_HEIGHT 0x806E
-#define GL_TEXTURE_3D 0x806F
-#define GL_PROXY_TEXTURE_3D 0x8070
-#define GL_TEXTURE_DEPTH 0x8071
-#define GL_TEXTURE_WRAP_R 0x8072
-#define GL_MAX_3D_TEXTURE_SIZE 0x8073
-#define GL_TEXTURE_BINDING_3D 0x806A
-
-
-/*
- * OpenGL 1.2 imaging subset
- */
-/* GL_EXT_color_table */
-#define GL_COLOR_TABLE 0x80D0
-#define GL_POST_CONVOLUTION_COLOR_TABLE 0x80D1
-#define GL_POST_COLOR_MATRIX_COLOR_TABLE 0x80D2
-#define GL_PROXY_COLOR_TABLE 0x80D3
-#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE 0x80D4
-#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE 0x80D5
-#define GL_COLOR_TABLE_SCALE 0x80D6
-#define GL_COLOR_TABLE_BIAS 0x80D7
-#define GL_COLOR_TABLE_FORMAT 0x80D8
-#define GL_COLOR_TABLE_WIDTH 0x80D9
-#define GL_COLOR_TABLE_RED_SIZE 0x80DA
-#define GL_COLOR_TABLE_GREEN_SIZE 0x80DB
-#define GL_COLOR_TABLE_BLUE_SIZE 0x80DC
-#define GL_COLOR_TABLE_ALPHA_SIZE 0x80DD
-#define GL_COLOR_TABLE_LUMINANCE_SIZE 0x80DE
-#define GL_COLOR_TABLE_INTENSITY_SIZE 0x80DF
-/* GL_EXT_convolution and GL_HP_convolution_border_modes */
-#define GL_CONVOLUTION_1D 0x8010
-#define GL_CONVOLUTION_2D 0x8011
-#define GL_SEPARABLE_2D 0x8012
-#define GL_CONVOLUTION_BORDER_MODE 0x8013
-#define GL_CONVOLUTION_FILTER_SCALE 0x8014
-#define GL_CONVOLUTION_FILTER_BIAS 0x8015
-#define GL_REDUCE 0x8016
-#define GL_CONVOLUTION_FORMAT 0x8017
-#define GL_CONVOLUTION_WIDTH 0x8018
-#define GL_CONVOLUTION_HEIGHT 0x8019
-#define GL_MAX_CONVOLUTION_WIDTH 0x801A
-#define GL_MAX_CONVOLUTION_HEIGHT 0x801B
-#define GL_POST_CONVOLUTION_RED_SCALE 0x801C
-#define GL_POST_CONVOLUTION_GREEN_SCALE 0x801D
-#define GL_POST_CONVOLUTION_BLUE_SCALE 0x801E
-#define GL_POST_CONVOLUTION_ALPHA_SCALE 0x801F
-#define GL_POST_CONVOLUTION_RED_BIAS 0x8020
-#define GL_POST_CONVOLUTION_GREEN_BIAS 0x8021
-#define GL_POST_CONVOLUTION_BLUE_BIAS 0x8022
-#define GL_POST_CONVOLUTION_ALPHA_BIAS 0x8023
-#define GL_CONSTANT_BORDER 0x8151
-#define GL_REPLICATE_BORDER 0x8153
-#define GL_CONVOLUTION_BORDER_COLOR 0x8154
-/* GL_SGI_color_matrix */
-#define GL_COLOR_MATRIX 0x80B1
-#define GL_COLOR_MATRIX_STACK_DEPTH 0x80B2
-#define GL_MAX_COLOR_MATRIX_STACK_DEPTH 0x80B3
-#define GL_POST_COLOR_MATRIX_RED_SCALE 0x80B4
-#define GL_POST_COLOR_MATRIX_GREEN_SCALE 0x80B5
-#define GL_POST_COLOR_MATRIX_BLUE_SCALE 0x80B6
-#define GL_POST_COLOR_MATRIX_ALPHA_SCALE 0x80B7
-#define GL_POST_COLOR_MATRIX_RED_BIAS 0x80B8
-#define GL_POST_COLOR_MATRIX_GREEN_BIAS 0x80B9
-#define GL_POST_COLOR_MATRIX_BLUE_BIAS 0x80BA
-#define GL_POST_COLOR_MATRIX_ALPHA_BIAS 0x80BB
-/* GL_EXT_histogram */
-#define GL_HISTOGRAM 0x8024
-#define GL_PROXY_HISTOGRAM 0x8025
-#define GL_HISTOGRAM_WIDTH 0x8026
-#define GL_HISTOGRAM_FORMAT 0x8027
-#define GL_HISTOGRAM_RED_SIZE 0x8028
-#define GL_HISTOGRAM_GREEN_SIZE 0x8029
-#define GL_HISTOGRAM_BLUE_SIZE 0x802A
-#define GL_HISTOGRAM_ALPHA_SIZE 0x802B
-#define GL_HISTOGRAM_LUMINANCE_SIZE 0x802C
-#define GL_HISTOGRAM_SINK 0x802D
-#define GL_MINMAX 0x802E
-#define GL_MINMAX_FORMAT 0x802F
-#define GL_MINMAX_SINK 0x8030
-#define GL_TABLE_TOO_LARGE 0x8031
-/* GL_EXT_blend_color, GL_EXT_blend_minmax */
-#define GL_BLEND_EQUATION 0x8009
-#define GL_MIN 0x8007
-#define GL_MAX 0x8008
-#define GL_FUNC_ADD 0x8006
-#define GL_FUNC_SUBTRACT 0x800A
-#define GL_FUNC_REVERSE_SUBTRACT 0x800B
-#define GL_BLEND_COLOR 0x8005
-
-
-/* OpenGL 1.3 */
-/* multitexture */
-#define GL_TEXTURE0 0x84C0
-#define GL_TEXTURE1 0x84C1
-#define GL_TEXTURE2 0x84C2
-#define GL_TEXTURE3 0x84C3
-#define GL_TEXTURE4 0x84C4
-#define GL_TEXTURE5 0x84C5
-#define GL_TEXTURE6 0x84C6
-#define GL_TEXTURE7 0x84C7
-#define GL_TEXTURE8 0x84C8
-#define GL_TEXTURE9 0x84C9
-#define GL_TEXTURE10 0x84CA
-#define GL_TEXTURE11 0x84CB
-#define GL_TEXTURE12 0x84CC
-#define GL_TEXTURE13 0x84CD
-#define GL_TEXTURE14 0x84CE
-#define GL_TEXTURE15 0x84CF
-#define GL_TEXTURE16 0x84D0
-#define GL_TEXTURE17 0x84D1
-#define GL_TEXTURE18 0x84D2
-#define GL_TEXTURE19 0x84D3
-#define GL_TEXTURE20 0x84D4
-#define GL_TEXTURE21 0x84D5
-#define GL_TEXTURE22 0x84D6
-#define GL_TEXTURE23 0x84D7
-#define GL_TEXTURE24 0x84D8
-#define GL_TEXTURE25 0x84D9
-#define GL_TEXTURE26 0x84DA
-#define GL_TEXTURE27 0x84DB
-#define GL_TEXTURE28 0x84DC
-#define GL_TEXTURE29 0x84DD
-#define GL_TEXTURE30 0x84DE
-#define GL_TEXTURE31 0x84DF
-#define GL_ACTIVE_TEXTURE 0x84E0
-#define GL_CLIENT_ACTIVE_TEXTURE 0x84E1
-#define GL_MAX_TEXTURE_UNITS 0x84E2
-/* texture_cube_map */
-#define GL_NORMAL_MAP 0x8511
-#define GL_REFLECTION_MAP 0x8512
-#define GL_TEXTURE_CUBE_MAP 0x8513
-#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A
-#define GL_PROXY_TEXTURE_CUBE_MAP 0x851B
-#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C
-/* texture_compression */
-#define GL_COMPRESSED_ALPHA 0x84E9
-#define GL_COMPRESSED_LUMINANCE 0x84EA
-#define GL_COMPRESSED_LUMINANCE_ALPHA 0x84EB
-#define GL_COMPRESSED_INTENSITY 0x84EC
-#define GL_COMPRESSED_RGB 0x84ED
-#define GL_COMPRESSED_RGBA 0x84EE
-#define GL_TEXTURE_COMPRESSION_HINT 0x84EF
-#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE 0x86A0
-#define GL_TEXTURE_COMPRESSED 0x86A1
-#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2
-#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3
-/* multisample */
-#define GL_MULTISAMPLE 0x809D
-#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E
-#define GL_SAMPLE_ALPHA_TO_ONE 0x809F
-#define GL_SAMPLE_COVERAGE 0x80A0
-#define GL_SAMPLE_BUFFERS 0x80A8
-#define GL_SAMPLES 0x80A9
-#define GL_SAMPLE_COVERAGE_VALUE 0x80AA
-#define GL_SAMPLE_COVERAGE_INVERT 0x80AB
-#define GL_MULTISAMPLE_BIT 0x20000000
-/* transpose_matrix */
-#define GL_TRANSPOSE_MODELVIEW_MATRIX 0x84E3
-#define GL_TRANSPOSE_PROJECTION_MATRIX 0x84E4
-#define GL_TRANSPOSE_TEXTURE_MATRIX 0x84E5
-#define GL_TRANSPOSE_COLOR_MATRIX 0x84E6
-/* texture_env_combine */
-#define GL_COMBINE 0x8570
-#define GL_COMBINE_RGB 0x8571
-#define GL_COMBINE_ALPHA 0x8572
-#define GL_SOURCE0_RGB 0x8580
-#define GL_SOURCE1_RGB 0x8581
-#define GL_SOURCE2_RGB 0x8582
-#define GL_SOURCE0_ALPHA 0x8588
-#define GL_SOURCE1_ALPHA 0x8589
-#define GL_SOURCE2_ALPHA 0x858A
-#define GL_OPERAND0_RGB 0x8590
-#define GL_OPERAND1_RGB 0x8591
-#define GL_OPERAND2_RGB 0x8592
-#define GL_OPERAND0_ALPHA 0x8598
-#define GL_OPERAND1_ALPHA 0x8599
-#define GL_OPERAND2_ALPHA 0x859A
-#define GL_RGB_SCALE 0x8573
-#define GL_ADD_SIGNED 0x8574
-#define GL_INTERPOLATE 0x8575
-#define GL_SUBTRACT 0x84E7
-#define GL_CONSTANT 0x8576
-#define GL_PRIMARY_COLOR 0x8577
-#define GL_PREVIOUS 0x8578
-/* texture_env_dot3 */
-#define GL_DOT3_RGB 0x86AE
-#define GL_DOT3_RGBA 0x86AF
-/* texture_border_clamp */
-#define GL_CLAMP_TO_BORDER 0x812D
-
-
-
-#if defined(__BEOS__) || defined(__QUICKDRAW__)
-#pragma export on
-#endif
-
-
-/*
- * Miscellaneous
- */
-
-GLAPI void GLAPIENTRY glClearIndex( GLfloat c );
-
-GLAPI void GLAPIENTRY glClearColor( GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha );
-
-GLAPI void GLAPIENTRY glClear( GLbitfield mask );
-
-GLAPI void GLAPIENTRY glIndexMask( GLuint mask );
-
-GLAPI void GLAPIENTRY glColorMask( GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha );
-
-GLAPI void GLAPIENTRY glAlphaFunc( GLenum func, GLclampf ref );
-
-GLAPI void GLAPIENTRY glBlendFunc( GLenum sfactor, GLenum dfactor );
-
-GLAPI void GLAPIENTRY glLogicOp( GLenum opcode );
-
-GLAPI void GLAPIENTRY glCullFace( GLenum mode );
-
-GLAPI void GLAPIENTRY glFrontFace( GLenum mode );
-
-GLAPI void GLAPIENTRY glPointSize( GLfloat size );
-
-GLAPI void GLAPIENTRY glLineWidth( GLfloat width );
-
-GLAPI void GLAPIENTRY glLineStipple( GLint factor, GLushort pattern );
-
-GLAPI void GLAPIENTRY glPolygonMode( GLenum face, GLenum mode );
-
-GLAPI void GLAPIENTRY glPolygonOffset( GLfloat factor, GLfloat units );
-
-GLAPI void GLAPIENTRY glPolygonStipple( const GLubyte *mask );
-
-GLAPI void GLAPIENTRY glGetPolygonStipple( GLubyte *mask );
-
-GLAPI void GLAPIENTRY glEdgeFlag( GLboolean flag );
-
-GLAPI void GLAPIENTRY glEdgeFlagv( const GLboolean *flag );
-
-GLAPI void GLAPIENTRY glScissor( GLint x, GLint y, GLsizei width, GLsizei height);
-
-GLAPI void GLAPIENTRY glClipPlane( GLenum plane, const GLdouble *equation );
-
-GLAPI void GLAPIENTRY glGetClipPlane( GLenum plane, GLdouble *equation );
-
-GLAPI void GLAPIENTRY glDrawBuffer( GLenum mode );
-
-GLAPI void GLAPIENTRY glReadBuffer( GLenum mode );
-
-GLAPI void GLAPIENTRY glEnable( GLenum cap );
-
-GLAPI void GLAPIENTRY glDisable( GLenum cap );
-
-GLAPI GLboolean GLAPIENTRY glIsEnabled( GLenum cap );
-
-
-GLAPI void GLAPIENTRY glEnableClientState( GLenum cap ); /* 1.1 */
-
-GLAPI void GLAPIENTRY glDisableClientState( GLenum cap ); /* 1.1 */
-
-
-GLAPI void GLAPIENTRY glGetBooleanv( GLenum pname, GLboolean *params );
-
-GLAPI void GLAPIENTRY glGetDoublev( GLenum pname, GLdouble *params );
-
-GLAPI void GLAPIENTRY glGetFloatv( GLenum pname, GLfloat *params );
-
-GLAPI void GLAPIENTRY glGetIntegerv( GLenum pname, GLint *params );
-
-
-GLAPI void GLAPIENTRY glPushAttrib( GLbitfield mask );
-
-GLAPI void GLAPIENTRY glPopAttrib( void );
-
-
-GLAPI void GLAPIENTRY glPushClientAttrib( GLbitfield mask ); /* 1.1 */
-
-GLAPI void GLAPIENTRY glPopClientAttrib( void ); /* 1.1 */
-
-
-GLAPI GLint GLAPIENTRY glRenderMode( GLenum mode );
-
-GLAPI GLenum GLAPIENTRY glGetError( void );
-
-GLAPI const GLubyte* GLAPIENTRY glGetString( GLenum name );
-
-GLAPI void GLAPIENTRY glFinish( void );
-
-GLAPI void GLAPIENTRY glFlush( void );
-
-GLAPI void GLAPIENTRY glHint( GLenum target, GLenum mode );
-
-
-
-/*
- * Depth Buffer
- */
-
-GLAPI void GLAPIENTRY glClearDepth( GLclampd depth );
-
-GLAPI void GLAPIENTRY glDepthFunc( GLenum func );
-
-GLAPI void GLAPIENTRY glDepthMask( GLboolean flag );
-
-GLAPI void GLAPIENTRY glDepthRange( GLclampd near_val, GLclampd far_val );
-
-
-/*
- * Accumulation Buffer
- */
-
-GLAPI void GLAPIENTRY glClearAccum( GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha );
-
-GLAPI void GLAPIENTRY glAccum( GLenum op, GLfloat value );
-
-
-
-/*
- * Transformation
- */
-
-GLAPI void GLAPIENTRY glMatrixMode( GLenum mode );
-
-GLAPI void GLAPIENTRY glOrtho( GLdouble left, GLdouble right,
- GLdouble bottom, GLdouble top,
- GLdouble near_val, GLdouble far_val );
-
-GLAPI void GLAPIENTRY glFrustum( GLdouble left, GLdouble right,
- GLdouble bottom, GLdouble top,
- GLdouble near_val, GLdouble far_val );
-
-GLAPI void GLAPIENTRY glViewport( GLint x, GLint y,
- GLsizei width, GLsizei height );
-
-GLAPI void GLAPIENTRY glPushMatrix( void );
-
-GLAPI void GLAPIENTRY glPopMatrix( void );
-
-GLAPI void GLAPIENTRY glLoadIdentity( void );
-
-GLAPI void GLAPIENTRY glLoadMatrixd( const GLdouble *m );
-GLAPI void GLAPIENTRY glLoadMatrixf( const GLfloat *m );
-
-GLAPI void GLAPIENTRY glMultMatrixd( const GLdouble *m );
-GLAPI void GLAPIENTRY glMultMatrixf( const GLfloat *m );
-
-GLAPI void GLAPIENTRY glRotated( GLdouble angle,
- GLdouble x, GLdouble y, GLdouble z );
-GLAPI void GLAPIENTRY glRotatef( GLfloat angle,
- GLfloat x, GLfloat y, GLfloat z );
-
-GLAPI void GLAPIENTRY glScaled( GLdouble x, GLdouble y, GLdouble z );
-GLAPI void GLAPIENTRY glScalef( GLfloat x, GLfloat y, GLfloat z );
-
-GLAPI void GLAPIENTRY glTranslated( GLdouble x, GLdouble y, GLdouble z );
-GLAPI void GLAPIENTRY glTranslatef( GLfloat x, GLfloat y, GLfloat z );
-
-
-
-/*
- * Display Lists
- */
-
-GLAPI GLboolean GLAPIENTRY glIsList( GLuint list );
-
-GLAPI void GLAPIENTRY glDeleteLists( GLuint list, GLsizei range );
-
-GLAPI GLuint GLAPIENTRY glGenLists( GLsizei range );
-
-GLAPI void GLAPIENTRY glNewList( GLuint list, GLenum mode );
-
-GLAPI void GLAPIENTRY glEndList( void );
-
-GLAPI void GLAPIENTRY glCallList( GLuint list );
-
-GLAPI void GLAPIENTRY glCallLists( GLsizei n, GLenum type,
- const GLvoid *lists );
-
-GLAPI void GLAPIENTRY glListBase( GLuint base );
-
-
-
-/*
- * Drawing Functions
- */
-
-GLAPI void GLAPIENTRY glBegin( GLenum mode );
-
-GLAPI void GLAPIENTRY glEnd( void );
-
-
-GLAPI void GLAPIENTRY glVertex2d( GLdouble x, GLdouble y );
-GLAPI void GLAPIENTRY glVertex2f( GLfloat x, GLfloat y );
-GLAPI void GLAPIENTRY glVertex2i( GLint x, GLint y );
-GLAPI void GLAPIENTRY glVertex2s( GLshort x, GLshort y );
-
-GLAPI void GLAPIENTRY glVertex3d( GLdouble x, GLdouble y, GLdouble z );
-GLAPI void GLAPIENTRY glVertex3f( GLfloat x, GLfloat y, GLfloat z );
-GLAPI void GLAPIENTRY glVertex3i( GLint x, GLint y, GLint z );
-GLAPI void GLAPIENTRY glVertex3s( GLshort x, GLshort y, GLshort z );
-
-GLAPI void GLAPIENTRY glVertex4d( GLdouble x, GLdouble y, GLdouble z, GLdouble w );
-GLAPI void GLAPIENTRY glVertex4f( GLfloat x, GLfloat y, GLfloat z, GLfloat w );
-GLAPI void GLAPIENTRY glVertex4i( GLint x, GLint y, GLint z, GLint w );
-GLAPI void GLAPIENTRY glVertex4s( GLshort x, GLshort y, GLshort z, GLshort w );
-
-GLAPI void GLAPIENTRY glVertex2dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glVertex2fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glVertex2iv( const GLint *v );
-GLAPI void GLAPIENTRY glVertex2sv( const GLshort *v );
-
-GLAPI void GLAPIENTRY glVertex3dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glVertex3fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glVertex3iv( const GLint *v );
-GLAPI void GLAPIENTRY glVertex3sv( const GLshort *v );
-
-GLAPI void GLAPIENTRY glVertex4dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glVertex4fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glVertex4iv( const GLint *v );
-GLAPI void GLAPIENTRY glVertex4sv( const GLshort *v );
-
-
-GLAPI void GLAPIENTRY glNormal3b( GLbyte nx, GLbyte ny, GLbyte nz );
-GLAPI void GLAPIENTRY glNormal3d( GLdouble nx, GLdouble ny, GLdouble nz );
-GLAPI void GLAPIENTRY glNormal3f( GLfloat nx, GLfloat ny, GLfloat nz );
-GLAPI void GLAPIENTRY glNormal3i( GLint nx, GLint ny, GLint nz );
-GLAPI void GLAPIENTRY glNormal3s( GLshort nx, GLshort ny, GLshort nz );
-
-GLAPI void GLAPIENTRY glNormal3bv( const GLbyte *v );
-GLAPI void GLAPIENTRY glNormal3dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glNormal3fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glNormal3iv( const GLint *v );
-GLAPI void GLAPIENTRY glNormal3sv( const GLshort *v );
-
-
-GLAPI void GLAPIENTRY glIndexd( GLdouble c );
-GLAPI void GLAPIENTRY glIndexf( GLfloat c );
-GLAPI void GLAPIENTRY glIndexi( GLint c );
-GLAPI void GLAPIENTRY glIndexs( GLshort c );
-GLAPI void GLAPIENTRY glIndexub( GLubyte c ); /* 1.1 */
-
-GLAPI void GLAPIENTRY glIndexdv( const GLdouble *c );
-GLAPI void GLAPIENTRY glIndexfv( const GLfloat *c );
-GLAPI void GLAPIENTRY glIndexiv( const GLint *c );
-GLAPI void GLAPIENTRY glIndexsv( const GLshort *c );
-GLAPI void GLAPIENTRY glIndexubv( const GLubyte *c ); /* 1.1 */
-
-GLAPI void GLAPIENTRY glColor3b( GLbyte red, GLbyte green, GLbyte blue );
-GLAPI void GLAPIENTRY glColor3d( GLdouble red, GLdouble green, GLdouble blue );
-GLAPI void GLAPIENTRY glColor3f( GLfloat red, GLfloat green, GLfloat blue );
-GLAPI void GLAPIENTRY glColor3i( GLint red, GLint green, GLint blue );
-GLAPI void GLAPIENTRY glColor3s( GLshort red, GLshort green, GLshort blue );
-GLAPI void GLAPIENTRY glColor3ub( GLubyte red, GLubyte green, GLubyte blue );
-GLAPI void GLAPIENTRY glColor3ui( GLuint red, GLuint green, GLuint blue );
-GLAPI void GLAPIENTRY glColor3us( GLushort red, GLushort green, GLushort blue );
-
-GLAPI void GLAPIENTRY glColor4b( GLbyte red, GLbyte green,
- GLbyte blue, GLbyte alpha );
-GLAPI void GLAPIENTRY glColor4d( GLdouble red, GLdouble green,
- GLdouble blue, GLdouble alpha );
-GLAPI void GLAPIENTRY glColor4f( GLfloat red, GLfloat green,
- GLfloat blue, GLfloat alpha );
-GLAPI void GLAPIENTRY glColor4i( GLint red, GLint green,
- GLint blue, GLint alpha );
-GLAPI void GLAPIENTRY glColor4s( GLshort red, GLshort green,
- GLshort blue, GLshort alpha );
-GLAPI void GLAPIENTRY glColor4ub( GLubyte red, GLubyte green,
- GLubyte blue, GLubyte alpha );
-GLAPI void GLAPIENTRY glColor4ui( GLuint red, GLuint green,
- GLuint blue, GLuint alpha );
-GLAPI void GLAPIENTRY glColor4us( GLushort red, GLushort green,
- GLushort blue, GLushort alpha );
-
-
-GLAPI void GLAPIENTRY glColor3bv( const GLbyte *v );
-GLAPI void GLAPIENTRY glColor3dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glColor3fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glColor3iv( const GLint *v );
-GLAPI void GLAPIENTRY glColor3sv( const GLshort *v );
-GLAPI void GLAPIENTRY glColor3ubv( const GLubyte *v );
-GLAPI void GLAPIENTRY glColor3uiv( const GLuint *v );
-GLAPI void GLAPIENTRY glColor3usv( const GLushort *v );
-
-GLAPI void GLAPIENTRY glColor4bv( const GLbyte *v );
-GLAPI void GLAPIENTRY glColor4dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glColor4fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glColor4iv( const GLint *v );
-GLAPI void GLAPIENTRY glColor4sv( const GLshort *v );
-GLAPI void GLAPIENTRY glColor4ubv( const GLubyte *v );
-GLAPI void GLAPIENTRY glColor4uiv( const GLuint *v );
-GLAPI void GLAPIENTRY glColor4usv( const GLushort *v );
-
-
-GLAPI void GLAPIENTRY glTexCoord1d( GLdouble s );
-GLAPI void GLAPIENTRY glTexCoord1f( GLfloat s );
-GLAPI void GLAPIENTRY glTexCoord1i( GLint s );
-GLAPI void GLAPIENTRY glTexCoord1s( GLshort s );
-
-GLAPI void GLAPIENTRY glTexCoord2d( GLdouble s, GLdouble t );
-GLAPI void GLAPIENTRY glTexCoord2f( GLfloat s, GLfloat t );
-GLAPI void GLAPIENTRY glTexCoord2i( GLint s, GLint t );
-GLAPI void GLAPIENTRY glTexCoord2s( GLshort s, GLshort t );
-
-GLAPI void GLAPIENTRY glTexCoord3d( GLdouble s, GLdouble t, GLdouble r );
-GLAPI void GLAPIENTRY glTexCoord3f( GLfloat s, GLfloat t, GLfloat r );
-GLAPI void GLAPIENTRY glTexCoord3i( GLint s, GLint t, GLint r );
-GLAPI void GLAPIENTRY glTexCoord3s( GLshort s, GLshort t, GLshort r );
-
-GLAPI void GLAPIENTRY glTexCoord4d( GLdouble s, GLdouble t, GLdouble r, GLdouble q );
-GLAPI void GLAPIENTRY glTexCoord4f( GLfloat s, GLfloat t, GLfloat r, GLfloat q );
-GLAPI void GLAPIENTRY glTexCoord4i( GLint s, GLint t, GLint r, GLint q );
-GLAPI void GLAPIENTRY glTexCoord4s( GLshort s, GLshort t, GLshort r, GLshort q );
-
-GLAPI void GLAPIENTRY glTexCoord1dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glTexCoord1fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glTexCoord1iv( const GLint *v );
-GLAPI void GLAPIENTRY glTexCoord1sv( const GLshort *v );
-
-GLAPI void GLAPIENTRY glTexCoord2dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glTexCoord2fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glTexCoord2iv( const GLint *v );
-GLAPI void GLAPIENTRY glTexCoord2sv( const GLshort *v );
-
-GLAPI void GLAPIENTRY glTexCoord3dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glTexCoord3fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glTexCoord3iv( const GLint *v );
-GLAPI void GLAPIENTRY glTexCoord3sv( const GLshort *v );
-
-GLAPI void GLAPIENTRY glTexCoord4dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glTexCoord4fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glTexCoord4iv( const GLint *v );
-GLAPI void GLAPIENTRY glTexCoord4sv( const GLshort *v );
-
-
-GLAPI void GLAPIENTRY glRasterPos2d( GLdouble x, GLdouble y );
-GLAPI void GLAPIENTRY glRasterPos2f( GLfloat x, GLfloat y );
-GLAPI void GLAPIENTRY glRasterPos2i( GLint x, GLint y );
-GLAPI void GLAPIENTRY glRasterPos2s( GLshort x, GLshort y );
-
-GLAPI void GLAPIENTRY glRasterPos3d( GLdouble x, GLdouble y, GLdouble z );
-GLAPI void GLAPIENTRY glRasterPos3f( GLfloat x, GLfloat y, GLfloat z );
-GLAPI void GLAPIENTRY glRasterPos3i( GLint x, GLint y, GLint z );
-GLAPI void GLAPIENTRY glRasterPos3s( GLshort x, GLshort y, GLshort z );
-
-GLAPI void GLAPIENTRY glRasterPos4d( GLdouble x, GLdouble y, GLdouble z, GLdouble w );
-GLAPI void GLAPIENTRY glRasterPos4f( GLfloat x, GLfloat y, GLfloat z, GLfloat w );
-GLAPI void GLAPIENTRY glRasterPos4i( GLint x, GLint y, GLint z, GLint w );
-GLAPI void GLAPIENTRY glRasterPos4s( GLshort x, GLshort y, GLshort z, GLshort w );
-
-GLAPI void GLAPIENTRY glRasterPos2dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glRasterPos2fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glRasterPos2iv( const GLint *v );
-GLAPI void GLAPIENTRY glRasterPos2sv( const GLshort *v );
-
-GLAPI void GLAPIENTRY glRasterPos3dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glRasterPos3fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glRasterPos3iv( const GLint *v );
-GLAPI void GLAPIENTRY glRasterPos3sv( const GLshort *v );
-
-GLAPI void GLAPIENTRY glRasterPos4dv( const GLdouble *v );
-GLAPI void GLAPIENTRY glRasterPos4fv( const GLfloat *v );
-GLAPI void GLAPIENTRY glRasterPos4iv( const GLint *v );
-GLAPI void GLAPIENTRY glRasterPos4sv( const GLshort *v );
-
-
-GLAPI void GLAPIENTRY glRectd( GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2 );
-GLAPI void GLAPIENTRY glRectf( GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2 );
-GLAPI void GLAPIENTRY glRecti( GLint x1, GLint y1, GLint x2, GLint y2 );
-GLAPI void GLAPIENTRY glRects( GLshort x1, GLshort y1, GLshort x2, GLshort y2 );
-
-
-GLAPI void GLAPIENTRY glRectdv( const GLdouble *v1, const GLdouble *v2 );
-GLAPI void GLAPIENTRY glRectfv( const GLfloat *v1, const GLfloat *v2 );
-GLAPI void GLAPIENTRY glRectiv( const GLint *v1, const GLint *v2 );
-GLAPI void GLAPIENTRY glRectsv( const GLshort *v1, const GLshort *v2 );
-
-
-
-/*
- * Vertex Arrays (1.1)
- */
-
-GLAPI void GLAPIENTRY glVertexPointer( GLint size, GLenum type,
- GLsizei stride, const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glNormalPointer( GLenum type, GLsizei stride,
- const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glColorPointer( GLint size, GLenum type,
- GLsizei stride, const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glIndexPointer( GLenum type, GLsizei stride,
- const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glTexCoordPointer( GLint size, GLenum type,
- GLsizei stride, const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glEdgeFlagPointer( GLsizei stride, const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glGetPointerv( GLenum pname, GLvoid **params );
-
-GLAPI void GLAPIENTRY glArrayElement( GLint i );
-
-GLAPI void GLAPIENTRY glDrawArrays( GLenum mode, GLint first, GLsizei count );
-
-GLAPI void GLAPIENTRY glDrawElements( GLenum mode, GLsizei count,
- GLenum type, const GLvoid *indices );
-
-GLAPI void GLAPIENTRY glInterleavedArrays( GLenum format, GLsizei stride,
- const GLvoid *pointer );
-
-
-/*
- * Lighting
- */
-
-GLAPI void GLAPIENTRY glShadeModel( GLenum mode );
-
-GLAPI void GLAPIENTRY glLightf( GLenum light, GLenum pname, GLfloat param );
-GLAPI void GLAPIENTRY glLighti( GLenum light, GLenum pname, GLint param );
-GLAPI void GLAPIENTRY glLightfv( GLenum light, GLenum pname,
- const GLfloat *params );
-GLAPI void GLAPIENTRY glLightiv( GLenum light, GLenum pname,
- const GLint *params );
-
-GLAPI void GLAPIENTRY glGetLightfv( GLenum light, GLenum pname,
- GLfloat *params );
-GLAPI void GLAPIENTRY glGetLightiv( GLenum light, GLenum pname,
- GLint *params );
-
-GLAPI void GLAPIENTRY glLightModelf( GLenum pname, GLfloat param );
-GLAPI void GLAPIENTRY glLightModeli( GLenum pname, GLint param );
-GLAPI void GLAPIENTRY glLightModelfv( GLenum pname, const GLfloat *params );
-GLAPI void GLAPIENTRY glLightModeliv( GLenum pname, const GLint *params );
-
-GLAPI void GLAPIENTRY glMaterialf( GLenum face, GLenum pname, GLfloat param );
-GLAPI void GLAPIENTRY glMateriali( GLenum face, GLenum pname, GLint param );
-GLAPI void GLAPIENTRY glMaterialfv( GLenum face, GLenum pname, const GLfloat *params );
-GLAPI void GLAPIENTRY glMaterialiv( GLenum face, GLenum pname, const GLint *params );
-
-GLAPI void GLAPIENTRY glGetMaterialfv( GLenum face, GLenum pname, GLfloat *params );
-GLAPI void GLAPIENTRY glGetMaterialiv( GLenum face, GLenum pname, GLint *params );
-
-GLAPI void GLAPIENTRY glColorMaterial( GLenum face, GLenum mode );
-
-
-
-
-/*
- * Raster functions
- */
-
-GLAPI void GLAPIENTRY glPixelZoom( GLfloat xfactor, GLfloat yfactor );
-
-GLAPI void GLAPIENTRY glPixelStoref( GLenum pname, GLfloat param );
-GLAPI void GLAPIENTRY glPixelStorei( GLenum pname, GLint param );
-
-GLAPI void GLAPIENTRY glPixelTransferf( GLenum pname, GLfloat param );
-GLAPI void GLAPIENTRY glPixelTransferi( GLenum pname, GLint param );
-
-GLAPI void GLAPIENTRY glPixelMapfv( GLenum map, GLint mapsize,
- const GLfloat *values );
-GLAPI void GLAPIENTRY glPixelMapuiv( GLenum map, GLint mapsize,
- const GLuint *values );
-GLAPI void GLAPIENTRY glPixelMapusv( GLenum map, GLint mapsize,
- const GLushort *values );
-
-GLAPI void GLAPIENTRY glGetPixelMapfv( GLenum map, GLfloat *values );
-GLAPI void GLAPIENTRY glGetPixelMapuiv( GLenum map, GLuint *values );
-GLAPI void GLAPIENTRY glGetPixelMapusv( GLenum map, GLushort *values );
-
-GLAPI void GLAPIENTRY glBitmap( GLsizei width, GLsizei height,
- GLfloat xorig, GLfloat yorig,
- GLfloat xmove, GLfloat ymove,
- const GLubyte *bitmap );
-
-GLAPI void GLAPIENTRY glReadPixels( GLint x, GLint y,
- GLsizei width, GLsizei height,
- GLenum format, GLenum type,
- GLvoid *pixels );
-
-GLAPI void GLAPIENTRY glDrawPixels( GLsizei width, GLsizei height,
- GLenum format, GLenum type,
- const GLvoid *pixels );
-
-GLAPI void GLAPIENTRY glCopyPixels( GLint x, GLint y,
- GLsizei width, GLsizei height,
- GLenum type );
-
-
-
-/*
- * Stenciling
- */
-
-GLAPI void GLAPIENTRY glStencilFunc( GLenum func, GLint ref, GLuint mask );
-
-GLAPI void GLAPIENTRY glStencilMask( GLuint mask );
-
-GLAPI void GLAPIENTRY glStencilOp( GLenum fail, GLenum zfail, GLenum zpass );
-
-GLAPI void GLAPIENTRY glClearStencil( GLint s );
-
-
-
-/*
- * Texture mapping
- */
-
-GLAPI void GLAPIENTRY glTexGend( GLenum coord, GLenum pname, GLdouble param );
-GLAPI void GLAPIENTRY glTexGenf( GLenum coord, GLenum pname, GLfloat param );
-GLAPI void GLAPIENTRY glTexGeni( GLenum coord, GLenum pname, GLint param );
-
-GLAPI void GLAPIENTRY glTexGendv( GLenum coord, GLenum pname, const GLdouble *params );
-GLAPI void GLAPIENTRY glTexGenfv( GLenum coord, GLenum pname, const GLfloat *params );
-GLAPI void GLAPIENTRY glTexGeniv( GLenum coord, GLenum pname, const GLint *params );
-
-GLAPI void GLAPIENTRY glGetTexGendv( GLenum coord, GLenum pname, GLdouble *params );
-GLAPI void GLAPIENTRY glGetTexGenfv( GLenum coord, GLenum pname, GLfloat *params );
-GLAPI void GLAPIENTRY glGetTexGeniv( GLenum coord, GLenum pname, GLint *params );
-
-
-GLAPI void GLAPIENTRY glTexEnvf( GLenum target, GLenum pname, GLfloat param );
-GLAPI void GLAPIENTRY glTexEnvi( GLenum target, GLenum pname, GLint param );
-
-GLAPI void GLAPIENTRY glTexEnvfv( GLenum target, GLenum pname, const GLfloat *params );
-GLAPI void GLAPIENTRY glTexEnviv( GLenum target, GLenum pname, const GLint *params );
-
-GLAPI void GLAPIENTRY glGetTexEnvfv( GLenum target, GLenum pname, GLfloat *params );
-GLAPI void GLAPIENTRY glGetTexEnviv( GLenum target, GLenum pname, GLint *params );
-
-
-GLAPI void GLAPIENTRY glTexParameterf( GLenum target, GLenum pname, GLfloat param );
-GLAPI void GLAPIENTRY glTexParameteri( GLenum target, GLenum pname, GLint param );
-
-GLAPI void GLAPIENTRY glTexParameterfv( GLenum target, GLenum pname,
- const GLfloat *params );
-GLAPI void GLAPIENTRY glTexParameteriv( GLenum target, GLenum pname,
- const GLint *params );
-
-GLAPI void GLAPIENTRY glGetTexParameterfv( GLenum target,
- GLenum pname, GLfloat *params);
-GLAPI void GLAPIENTRY glGetTexParameteriv( GLenum target,
- GLenum pname, GLint *params );
-
-GLAPI void GLAPIENTRY glGetTexLevelParameterfv( GLenum target, GLint level,
- GLenum pname, GLfloat *params );
-GLAPI void GLAPIENTRY glGetTexLevelParameteriv( GLenum target, GLint level,
- GLenum pname, GLint *params );
-
-
-GLAPI void GLAPIENTRY glTexImage1D( GLenum target, GLint level,
- GLint internalFormat,
- GLsizei width, GLint border,
- GLenum format, GLenum type,
- const GLvoid *pixels );
-
-GLAPI void GLAPIENTRY glTexImage2D( GLenum target, GLint level,
- GLint internalFormat,
- GLsizei width, GLsizei height,
- GLint border, GLenum format, GLenum type,
- const GLvoid *pixels );
-
-GLAPI void GLAPIENTRY glGetTexImage( GLenum target, GLint level,
- GLenum format, GLenum type,
- GLvoid *pixels );
-
-
-
-/* 1.1 functions */
-
-GLAPI void GLAPIENTRY glGenTextures( GLsizei n, GLuint *textures );
-
-GLAPI void GLAPIENTRY glDeleteTextures( GLsizei n, const GLuint *textures);
-
-GLAPI void GLAPIENTRY glBindTexture( GLenum target, GLuint texture );
-
-GLAPI void GLAPIENTRY glPrioritizeTextures( GLsizei n,
- const GLuint *textures,
- const GLclampf *priorities );
-
-GLAPI GLboolean GLAPIENTRY glAreTexturesResident( GLsizei n,
- const GLuint *textures,
- GLboolean *residences );
-
-GLAPI GLboolean GLAPIENTRY glIsTexture( GLuint texture );
-
-
-GLAPI void GLAPIENTRY glTexSubImage1D( GLenum target, GLint level,
- GLint xoffset,
- GLsizei width, GLenum format,
- GLenum type, const GLvoid *pixels );
-
-
-GLAPI void GLAPIENTRY glTexSubImage2D( GLenum target, GLint level,
- GLint xoffset, GLint yoffset,
- GLsizei width, GLsizei height,
- GLenum format, GLenum type,
- const GLvoid *pixels );
-
-
-GLAPI void GLAPIENTRY glCopyTexImage1D( GLenum target, GLint level,
- GLenum internalformat,
- GLint x, GLint y,
- GLsizei width, GLint border );
-
-
-GLAPI void GLAPIENTRY glCopyTexImage2D( GLenum target, GLint level,
- GLenum internalformat,
- GLint x, GLint y,
- GLsizei width, GLsizei height,
- GLint border );
-
-
-GLAPI void GLAPIENTRY glCopyTexSubImage1D( GLenum target, GLint level,
- GLint xoffset, GLint x, GLint y,
- GLsizei width );
-
-
-GLAPI void GLAPIENTRY glCopyTexSubImage2D( GLenum target, GLint level,
- GLint xoffset, GLint yoffset,
- GLint x, GLint y,
- GLsizei width, GLsizei height );
-
-
-
-
-/*
- * Evaluators
- */
-
-GLAPI void GLAPIENTRY glMap1d( GLenum target, GLdouble u1, GLdouble u2,
- GLint stride,
- GLint order, const GLdouble *points );
-GLAPI void GLAPIENTRY glMap1f( GLenum target, GLfloat u1, GLfloat u2,
- GLint stride,
- GLint order, const GLfloat *points );
-
-GLAPI void GLAPIENTRY glMap2d( GLenum target,
- GLdouble u1, GLdouble u2, GLint ustride, GLint uorder,
- GLdouble v1, GLdouble v2, GLint vstride, GLint vorder,
- const GLdouble *points );
-GLAPI void GLAPIENTRY glMap2f( GLenum target,
- GLfloat u1, GLfloat u2, GLint ustride, GLint uorder,
- GLfloat v1, GLfloat v2, GLint vstride, GLint vorder,
- const GLfloat *points );
-
-GLAPI void GLAPIENTRY glGetMapdv( GLenum target, GLenum query, GLdouble *v );
-GLAPI void GLAPIENTRY glGetMapfv( GLenum target, GLenum query, GLfloat *v );
-GLAPI void GLAPIENTRY glGetMapiv( GLenum target, GLenum query, GLint *v );
-
-GLAPI void GLAPIENTRY glEvalCoord1d( GLdouble u );
-GLAPI void GLAPIENTRY glEvalCoord1f( GLfloat u );
-
-GLAPI void GLAPIENTRY glEvalCoord1dv( const GLdouble *u );
-GLAPI void GLAPIENTRY glEvalCoord1fv( const GLfloat *u );
-
-GLAPI void GLAPIENTRY glEvalCoord2d( GLdouble u, GLdouble v );
-GLAPI void GLAPIENTRY glEvalCoord2f( GLfloat u, GLfloat v );
-
-GLAPI void GLAPIENTRY glEvalCoord2dv( const GLdouble *u );
-GLAPI void GLAPIENTRY glEvalCoord2fv( const GLfloat *u );
-
-GLAPI void GLAPIENTRY glMapGrid1d( GLint un, GLdouble u1, GLdouble u2 );
-GLAPI void GLAPIENTRY glMapGrid1f( GLint un, GLfloat u1, GLfloat u2 );
-
-GLAPI void GLAPIENTRY glMapGrid2d( GLint un, GLdouble u1, GLdouble u2,
- GLint vn, GLdouble v1, GLdouble v2 );
-GLAPI void GLAPIENTRY glMapGrid2f( GLint un, GLfloat u1, GLfloat u2,
- GLint vn, GLfloat v1, GLfloat v2 );
-
-GLAPI void GLAPIENTRY glEvalPoint1( GLint i );
-
-GLAPI void GLAPIENTRY glEvalPoint2( GLint i, GLint j );
-
-GLAPI void GLAPIENTRY glEvalMesh1( GLenum mode, GLint i1, GLint i2 );
-
-GLAPI void GLAPIENTRY glEvalMesh2( GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2 );
-
-
-
-/*
- * Fog
- */
-
-GLAPI void GLAPIENTRY glFogf( GLenum pname, GLfloat param );
-
-GLAPI void GLAPIENTRY glFogi( GLenum pname, GLint param );
-
-GLAPI void GLAPIENTRY glFogfv( GLenum pname, const GLfloat *params );
-
-GLAPI void GLAPIENTRY glFogiv( GLenum pname, const GLint *params );
-
-
-
-/*
- * Selection and Feedback
- */
-
-GLAPI void GLAPIENTRY glFeedbackBuffer( GLsizei size, GLenum type, GLfloat *buffer );
-
-GLAPI void GLAPIENTRY glPassThrough( GLfloat token );
-
-GLAPI void GLAPIENTRY glSelectBuffer( GLsizei size, GLuint *buffer );
-
-GLAPI void GLAPIENTRY glInitNames( void );
-
-GLAPI void GLAPIENTRY glLoadName( GLuint name );
-
-GLAPI void GLAPIENTRY glPushName( GLuint name );
-
-GLAPI void GLAPIENTRY glPopName( void );
-
-
-
-/* 1.2 functions */
-GLAPI void GLAPIENTRY glDrawRangeElements( GLenum mode, GLuint start,
- GLuint end, GLsizei count, GLenum type, const GLvoid *indices );
-
-GLAPI void GLAPIENTRY glTexImage3D( GLenum target, GLint level,
- GLenum internalFormat,
- GLsizei width, GLsizei height,
- GLsizei depth, GLint border,
- GLenum format, GLenum type,
- const GLvoid *pixels );
-
-GLAPI void GLAPIENTRY glTexSubImage3D( GLenum target, GLint level,
- GLint xoffset, GLint yoffset,
- GLint zoffset, GLsizei width,
- GLsizei height, GLsizei depth,
- GLenum format,
- GLenum type, const GLvoid *pixels);
-
-GLAPI void GLAPIENTRY glCopyTexSubImage3D( GLenum target, GLint level,
- GLint xoffset, GLint yoffset,
- GLint zoffset, GLint x,
- GLint y, GLsizei width,
- GLsizei height );
-
-
-/* 1.2 imaging extension functions */
-
-GLAPI void GLAPIENTRY glColorTable( GLenum target, GLenum internalformat,
- GLsizei width, GLenum format,
- GLenum type, const GLvoid *table );
-
-GLAPI void GLAPIENTRY glColorSubTable( GLenum target,
- GLsizei start, GLsizei count,
- GLenum format, GLenum type,
- const GLvoid *data );
-
-GLAPI void GLAPIENTRY glColorTableParameteriv(GLenum target, GLenum pname,
- const GLint *params);
-
-GLAPI void GLAPIENTRY glColorTableParameterfv(GLenum target, GLenum pname,
- const GLfloat *params);
-
-GLAPI void GLAPIENTRY glCopyColorSubTable( GLenum target, GLsizei start,
- GLint x, GLint y, GLsizei width );
-
-GLAPI void GLAPIENTRY glCopyColorTable( GLenum target, GLenum internalformat,
- GLint x, GLint y, GLsizei width );
-
-GLAPI void GLAPIENTRY glGetColorTable( GLenum target, GLenum format,
- GLenum type, GLvoid *table );
-
-GLAPI void GLAPIENTRY glGetColorTableParameterfv( GLenum target, GLenum pname,
- GLfloat *params );
-
-GLAPI void GLAPIENTRY glGetColorTableParameteriv( GLenum target, GLenum pname,
- GLint *params );
-
-GLAPI void GLAPIENTRY glBlendEquation( GLenum mode );
-
-GLAPI void GLAPIENTRY glBlendColor( GLclampf red, GLclampf green,
- GLclampf blue, GLclampf alpha );
-
-GLAPI void GLAPIENTRY glHistogram( GLenum target, GLsizei width,
- GLenum internalformat, GLboolean sink );
-
-GLAPI void GLAPIENTRY glResetHistogram( GLenum target );
-
-GLAPI void GLAPIENTRY glGetHistogram( GLenum target, GLboolean reset,
- GLenum format, GLenum type,
- GLvoid *values );
-
-GLAPI void GLAPIENTRY glGetHistogramParameterfv( GLenum target, GLenum pname,
- GLfloat *params );
-
-GLAPI void GLAPIENTRY glGetHistogramParameteriv( GLenum target, GLenum pname,
- GLint *params );
-
-GLAPI void GLAPIENTRY glMinmax( GLenum target, GLenum internalformat,
- GLboolean sink );
-
-GLAPI void GLAPIENTRY glResetMinmax( GLenum target );
-
-GLAPI void GLAPIENTRY glGetMinmax( GLenum target, GLboolean reset,
- GLenum format, GLenum types,
- GLvoid *values );
-
-GLAPI void GLAPIENTRY glGetMinmaxParameterfv( GLenum target, GLenum pname,
- GLfloat *params );
-
-GLAPI void GLAPIENTRY glGetMinmaxParameteriv( GLenum target, GLenum pname,
- GLint *params );
-
-GLAPI void GLAPIENTRY glConvolutionFilter1D( GLenum target,
- GLenum internalformat, GLsizei width, GLenum format, GLenum type,
- const GLvoid *image );
-
-GLAPI void GLAPIENTRY glConvolutionFilter2D( GLenum target,
- GLenum internalformat, GLsizei width, GLsizei height, GLenum format,
- GLenum type, const GLvoid *image );
-
-GLAPI void GLAPIENTRY glConvolutionParameterf( GLenum target, GLenum pname,
- GLfloat params );
-
-GLAPI void GLAPIENTRY glConvolutionParameterfv( GLenum target, GLenum pname,
- const GLfloat *params );
-
-GLAPI void GLAPIENTRY glConvolutionParameteri( GLenum target, GLenum pname,
- GLint params );
-
-GLAPI void GLAPIENTRY glConvolutionParameteriv( GLenum target, GLenum pname,
- const GLint *params );
-
-GLAPI void GLAPIENTRY glCopyConvolutionFilter1D( GLenum target,
- GLenum internalformat, GLint x, GLint y, GLsizei width );
-
-GLAPI void GLAPIENTRY glCopyConvolutionFilter2D( GLenum target,
- GLenum internalformat, GLint x, GLint y, GLsizei width,
- GLsizei height);
-
-GLAPI void GLAPIENTRY glGetConvolutionFilter( GLenum target, GLenum format,
- GLenum type, GLvoid *image );
-
-GLAPI void GLAPIENTRY glGetConvolutionParameterfv( GLenum target, GLenum pname,
- GLfloat *params );
-
-GLAPI void GLAPIENTRY glGetConvolutionParameteriv( GLenum target, GLenum pname,
- GLint *params );
-
-GLAPI void GLAPIENTRY glSeparableFilter2D( GLenum target,
- GLenum internalformat, GLsizei width, GLsizei height, GLenum format,
- GLenum type, const GLvoid *row, const GLvoid *column );
-
-GLAPI void GLAPIENTRY glGetSeparableFilter( GLenum target, GLenum format,
- GLenum type, GLvoid *row, GLvoid *column, GLvoid *span );
-
-
-
-/* 1.3 functions */
-
-GLAPI void GLAPIENTRY glActiveTexture( GLenum texture );
-
-GLAPI void GLAPIENTRY glClientActiveTexture( GLenum texture );
-
-GLAPI void GLAPIENTRY glCompressedTexImage1D( GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data );
-
-GLAPI void GLAPIENTRY glCompressedTexImage2D( GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data );
-
-GLAPI void GLAPIENTRY glCompressedTexImage3D( GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data );
-
-GLAPI void GLAPIENTRY glCompressedTexSubImage1D( GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data );
-
-GLAPI void GLAPIENTRY glCompressedTexSubImage2D( GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data );
-
-GLAPI void GLAPIENTRY glCompressedTexSubImage3D( GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data );
-
-GLAPI void GLAPIENTRY glGetCompressedTexImage( GLenum target, GLint lod, GLvoid *img );
-
-GLAPI void GLAPIENTRY glMultiTexCoord1d( GLenum target, GLdouble s );
-
-GLAPI void GLAPIENTRY glMultiTexCoord1dv( GLenum target, const GLdouble *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord1f( GLenum target, GLfloat s );
-
-GLAPI void GLAPIENTRY glMultiTexCoord1fv( GLenum target, const GLfloat *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord1i( GLenum target, GLint s );
-
-GLAPI void GLAPIENTRY glMultiTexCoord1iv( GLenum target, const GLint *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord1s( GLenum target, GLshort s );
-
-GLAPI void GLAPIENTRY glMultiTexCoord1sv( GLenum target, const GLshort *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord2d( GLenum target, GLdouble s, GLdouble t );
-
-GLAPI void GLAPIENTRY glMultiTexCoord2dv( GLenum target, const GLdouble *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord2f( GLenum target, GLfloat s, GLfloat t );
-
-GLAPI void GLAPIENTRY glMultiTexCoord2fv( GLenum target, const GLfloat *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord2i( GLenum target, GLint s, GLint t );
-
-GLAPI void GLAPIENTRY glMultiTexCoord2iv( GLenum target, const GLint *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord2s( GLenum target, GLshort s, GLshort t );
-
-GLAPI void GLAPIENTRY glMultiTexCoord2sv( GLenum target, const GLshort *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord3d( GLenum target, GLdouble s, GLdouble t, GLdouble r );
-
-GLAPI void GLAPIENTRY glMultiTexCoord3dv( GLenum target, const GLdouble *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord3f( GLenum target, GLfloat s, GLfloat t, GLfloat r );
-
-GLAPI void GLAPIENTRY glMultiTexCoord3fv( GLenum target, const GLfloat *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord3i( GLenum target, GLint s, GLint t, GLint r );
-
-GLAPI void GLAPIENTRY glMultiTexCoord3iv( GLenum target, const GLint *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord3s( GLenum target, GLshort s, GLshort t, GLshort r );
-
-GLAPI void GLAPIENTRY glMultiTexCoord3sv( GLenum target, const GLshort *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord4d( GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q );
-
-GLAPI void GLAPIENTRY glMultiTexCoord4dv( GLenum target, const GLdouble *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord4f( GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q );
-
-GLAPI void GLAPIENTRY glMultiTexCoord4fv( GLenum target, const GLfloat *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord4i( GLenum target, GLint s, GLint t, GLint r, GLint q );
-
-GLAPI void GLAPIENTRY glMultiTexCoord4iv( GLenum target, const GLint *v );
-
-GLAPI void GLAPIENTRY glMultiTexCoord4s( GLenum target, GLshort s, GLshort t, GLshort r, GLshort q );
-
-GLAPI void GLAPIENTRY glMultiTexCoord4sv( GLenum target, const GLshort *v );
-
-
-GLAPI void GLAPIENTRY glLoadTransposeMatrixd( const GLdouble m[16] );
-
-GLAPI void GLAPIENTRY glLoadTransposeMatrixf( const GLfloat m[16] );
-
-GLAPI void GLAPIENTRY glMultTransposeMatrixd( const GLdouble m[16] );
-
-GLAPI void GLAPIENTRY glMultTransposeMatrixf( const GLfloat m[16] );
-
-GLAPI void GLAPIENTRY glSampleCoverage( GLclampf value, GLboolean invert );
-
-
-#if defined(GL_GLEXT_LEGACY)
-
-
-/*
- * GL_ARB_multitexture (ARB extension 1 and OpenGL 1.2.1)
- */
-#ifndef GL_ARB_multitexture
-#define GL_ARB_multitexture 1
-
-#define GL_TEXTURE0_ARB 0x84C0
-#define GL_TEXTURE1_ARB 0x84C1
-#define GL_TEXTURE2_ARB 0x84C2
-#define GL_TEXTURE3_ARB 0x84C3
-#define GL_TEXTURE4_ARB 0x84C4
-#define GL_TEXTURE5_ARB 0x84C5
-#define GL_TEXTURE6_ARB 0x84C6
-#define GL_TEXTURE7_ARB 0x84C7
-#define GL_TEXTURE8_ARB 0x84C8
-#define GL_TEXTURE9_ARB 0x84C9
-#define GL_TEXTURE10_ARB 0x84CA
-#define GL_TEXTURE11_ARB 0x84CB
-#define GL_TEXTURE12_ARB 0x84CC
-#define GL_TEXTURE13_ARB 0x84CD
-#define GL_TEXTURE14_ARB 0x84CE
-#define GL_TEXTURE15_ARB 0x84CF
-#define GL_TEXTURE16_ARB 0x84D0
-#define GL_TEXTURE17_ARB 0x84D1
-#define GL_TEXTURE18_ARB 0x84D2
-#define GL_TEXTURE19_ARB 0x84D3
-#define GL_TEXTURE20_ARB 0x84D4
-#define GL_TEXTURE21_ARB 0x84D5
-#define GL_TEXTURE22_ARB 0x84D6
-#define GL_TEXTURE23_ARB 0x84D7
-#define GL_TEXTURE24_ARB 0x84D8
-#define GL_TEXTURE25_ARB 0x84D9
-#define GL_TEXTURE26_ARB 0x84DA
-#define GL_TEXTURE27_ARB 0x84DB
-#define GL_TEXTURE28_ARB 0x84DC
-#define GL_TEXTURE29_ARB 0x84DD
-#define GL_TEXTURE30_ARB 0x84DE
-#define GL_TEXTURE31_ARB 0x84DF
-#define GL_ACTIVE_TEXTURE_ARB 0x84E0
-#define GL_CLIENT_ACTIVE_TEXTURE_ARB 0x84E1
-#define GL_MAX_TEXTURE_UNITS_ARB 0x84E2
-
-GLAPI void GLAPIENTRY glActiveTextureARB(GLenum texture);
-GLAPI void GLAPIENTRY glClientActiveTextureARB(GLenum texture);
-GLAPI void GLAPIENTRY glMultiTexCoord1dARB(GLenum target, GLdouble s);
-GLAPI void GLAPIENTRY glMultiTexCoord1dvARB(GLenum target, const GLdouble *v);
-GLAPI void GLAPIENTRY glMultiTexCoord1fARB(GLenum target, GLfloat s);
-GLAPI void GLAPIENTRY glMultiTexCoord1fvARB(GLenum target, const GLfloat *v);
-GLAPI void GLAPIENTRY glMultiTexCoord1iARB(GLenum target, GLint s);
-GLAPI void GLAPIENTRY glMultiTexCoord1ivARB(GLenum target, const GLint *v);
-GLAPI void GLAPIENTRY glMultiTexCoord1sARB(GLenum target, GLshort s);
-GLAPI void GLAPIENTRY glMultiTexCoord1svARB(GLenum target, const GLshort *v);
-GLAPI void GLAPIENTRY glMultiTexCoord2dARB(GLenum target, GLdouble s, GLdouble t);
-GLAPI void GLAPIENTRY glMultiTexCoord2dvARB(GLenum target, const GLdouble *v);
-GLAPI void GLAPIENTRY glMultiTexCoord2fARB(GLenum target, GLfloat s, GLfloat t);
-GLAPI void GLAPIENTRY glMultiTexCoord2fvARB(GLenum target, const GLfloat *v);
-GLAPI void GLAPIENTRY glMultiTexCoord2iARB(GLenum target, GLint s, GLint t);
-GLAPI void GLAPIENTRY glMultiTexCoord2ivARB(GLenum target, const GLint *v);
-GLAPI void GLAPIENTRY glMultiTexCoord2sARB(GLenum target, GLshort s, GLshort t);
-GLAPI void GLAPIENTRY glMultiTexCoord2svARB(GLenum target, const GLshort *v);
-GLAPI void GLAPIENTRY glMultiTexCoord3dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r);
-GLAPI void GLAPIENTRY glMultiTexCoord3dvARB(GLenum target, const GLdouble *v);
-GLAPI void GLAPIENTRY glMultiTexCoord3fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r);
-GLAPI void GLAPIENTRY glMultiTexCoord3fvARB(GLenum target, const GLfloat *v);
-GLAPI void GLAPIENTRY glMultiTexCoord3iARB(GLenum target, GLint s, GLint t, GLint r);
-GLAPI void GLAPIENTRY glMultiTexCoord3ivARB(GLenum target, const GLint *v);
-GLAPI void GLAPIENTRY glMultiTexCoord3sARB(GLenum target, GLshort s, GLshort t, GLshort r);
-GLAPI void GLAPIENTRY glMultiTexCoord3svARB(GLenum target, const GLshort *v);
-GLAPI void GLAPIENTRY glMultiTexCoord4dARB(GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
-GLAPI void GLAPIENTRY glMultiTexCoord4dvARB(GLenum target, const GLdouble *v);
-GLAPI void GLAPIENTRY glMultiTexCoord4fARB(GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
-GLAPI void GLAPIENTRY glMultiTexCoord4fvARB(GLenum target, const GLfloat *v);
-GLAPI void GLAPIENTRY glMultiTexCoord4iARB(GLenum target, GLint s, GLint t, GLint r, GLint q);
-GLAPI void GLAPIENTRY glMultiTexCoord4ivARB(GLenum target, const GLint *v);
-GLAPI void GLAPIENTRY glMultiTexCoord4sARB(GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
-GLAPI void GLAPIENTRY glMultiTexCoord4svARB(GLenum target, const GLshort *v);
-
-typedef void (GLAPIENTRY * PFNGLACTIVETEXTUREARBPROC) (GLenum texture);
-typedef void (GLAPIENTRY * PFNGLCLIENTACTIVETEXTUREARBPROC) (GLenum texture);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD1DARBPROC) (GLenum target, GLdouble s);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD1DVARBPROC) (GLenum target, const GLdouble *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD1FARBPROC) (GLenum target, GLfloat s);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD1FVARBPROC) (GLenum target, const GLfloat *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD1IARBPROC) (GLenum target, GLint s);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD1IVARBPROC) (GLenum target, const GLint *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD1SARBPROC) (GLenum target, GLshort s);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD1SVARBPROC) (GLenum target, const GLshort *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD2DARBPROC) (GLenum target, GLdouble s, GLdouble t);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD2DVARBPROC) (GLenum target, const GLdouble *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD2FARBPROC) (GLenum target, GLfloat s, GLfloat t);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD2FVARBPROC) (GLenum target, const GLfloat *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD2IARBPROC) (GLenum target, GLint s, GLint t);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD2IVARBPROC) (GLenum target, const GLint *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD2SARBPROC) (GLenum target, GLshort s, GLshort t);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD2SVARBPROC) (GLenum target, const GLshort *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD3DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD3DVARBPROC) (GLenum target, const GLdouble *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD3FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD3FVARBPROC) (GLenum target, const GLfloat *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD3IARBPROC) (GLenum target, GLint s, GLint t, GLint r);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD3IVARBPROC) (GLenum target, const GLint *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD3SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD3SVARBPROC) (GLenum target, const GLshort *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD4DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD4DVARBPROC) (GLenum target, const GLdouble *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD4FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD4FVARBPROC) (GLenum target, const GLfloat *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD4IARBPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD4IVARBPROC) (GLenum target, const GLint *v);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD4SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
-typedef void (GLAPIENTRY * PFNGLMULTITEXCOORD4SVARBPROC) (GLenum target, const GLshort *v);
-
-#endif /* GL_ARB_multitexture */
-
-
-
-/*
- * 1. GL_EXT_abgr
- */
-#ifndef GL_EXT_abgr
-#define GL_EXT_abgr 1
-
-#define GL_ABGR_EXT 0x8000
-
-#endif /* GL_EXT_abgr */
-
-
-
-/*
- * 2. GL_EXT_blend_color
- */
-#ifndef GL_EXT_blend_color
-#define GL_EXT_blend_color 1
-
-#define GL_CONSTANT_COLOR_EXT 0x8001
-#define GL_ONE_MINUS_CONSTANT_COLOR_EXT 0x8002
-#define GL_CONSTANT_ALPHA_EXT 0x8003
-#define GL_ONE_MINUS_CONSTANT_ALPHA_EXT 0x8004
-#define GL_BLEND_COLOR_EXT 0x8005
-
-GLAPI void GLAPIENTRY glBlendColorEXT( GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha );
-
-#endif /* GL_EXT_blend_color */
-
-
-
-/*
- * 3. GL_EXT_polygon_offset
- */
-#ifndef GL_EXT_polygon_offset
-#define GL_EXT_polygon_offset 1
-
-#define GL_POLYGON_OFFSET_EXT 0x8037
-#define GL_POLYGON_OFFSET_FACTOR_EXT 0x8038
-#define GL_POLYGON_OFFSET_BIAS_EXT 0x8039
-
-GLAPI void GLAPIENTRY glPolygonOffsetEXT( GLfloat factor, GLfloat bias );
-
-#endif /* GL_EXT_polygon_offset */
-
-
-
-/*
- * 6. GL_EXT_texture3D
- */
-#ifndef GL_EXT_texture3D
-#define GL_EXT_texture3D 1
-
-#define GL_PACK_SKIP_IMAGES_EXT 0x806B
-#define GL_PACK_IMAGE_HEIGHT_EXT 0x806C
-#define GL_UNPACK_SKIP_IMAGES_EXT 0x806D
-#define GL_UNPACK_IMAGE_HEIGHT_EXT 0x806E
-#define GL_TEXTURE_3D_EXT 0x806F
-#define GL_PROXY_TEXTURE_3D_EXT 0x8070
-#define GL_TEXTURE_DEPTH_EXT 0x8071
-#define GL_TEXTURE_WRAP_R_EXT 0x8072
-#define GL_MAX_3D_TEXTURE_SIZE_EXT 0x8073
-#define GL_TEXTURE_3D_BINDING_EXT 0x806A
-
-GLAPI void GLAPIENTRY glTexImage3DEXT( GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels );
-
-GLAPI void GLAPIENTRY glTexSubImage3DEXT( GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
-
-GLAPI void GLAPIENTRY glCopyTexSubImage3DEXT( GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height );
-
-#endif /* GL_EXT_texture3D */
-
-
-
-/*
- * 20. GL_EXT_texture_object
- */
-#ifndef GL_EXT_texture_object
-#define GL_EXT_texture_object 1
-
-#define GL_TEXTURE_PRIORITY_EXT 0x8066
-#define GL_TEXTURE_RESIDENT_EXT 0x8067
-#define GL_TEXTURE_1D_BINDING_EXT 0x8068
-#define GL_TEXTURE_2D_BINDING_EXT 0x8069
-
-GLAPI void GLAPIENTRY glGenTexturesEXT( GLsizei n, GLuint *textures );
-
-GLAPI void GLAPIENTRY glDeleteTexturesEXT( GLsizei n, const GLuint *textures);
-
-GLAPI void GLAPIENTRY glBindTextureEXT( GLenum target, GLuint texture );
-
-GLAPI void GLAPIENTRY glPrioritizeTexturesEXT( GLsizei n, const GLuint *textures, const GLclampf *priorities );
-
-GLAPI GLboolean GLAPIENTRY glAreTexturesResidentEXT( GLsizei n, const GLuint *textures, GLboolean *residences );
-
-GLAPI GLboolean GLAPIENTRY glIsTextureEXT( GLuint texture );
-
-#endif /* GL_EXT_texture_object */
-
-
-
-/*
- * 27. GL_EXT_rescale_normal
- */
-#ifndef GL_EXT_rescale_normal
-#define GL_EXT_rescale_normal 1
-
-#define GL_RESCALE_NORMAL_EXT 0x803A
-
-#endif /* GL_EXT_rescale_normal */
-
-
-
-/*
- * 30. GL_EXT_vertex_array
- */
-#ifndef GL_EXT_vertex_array
-#define GL_EXT_vertex_array 1
-
-#define GL_VERTEX_ARRAY_EXT 0x8074
-#define GL_NORMAL_ARRAY_EXT 0x8075
-#define GL_COLOR_ARRAY_EXT 0x8076
-#define GL_INDEX_ARRAY_EXT 0x8077
-#define GL_TEXTURE_COORD_ARRAY_EXT 0x8078
-#define GL_EDGE_FLAG_ARRAY_EXT 0x8079
-#define GL_VERTEX_ARRAY_SIZE_EXT 0x807A
-#define GL_VERTEX_ARRAY_TYPE_EXT 0x807B
-#define GL_VERTEX_ARRAY_STRIDE_EXT 0x807C
-#define GL_VERTEX_ARRAY_COUNT_EXT 0x807D
-#define GL_NORMAL_ARRAY_TYPE_EXT 0x807E
-#define GL_NORMAL_ARRAY_STRIDE_EXT 0x807F
-#define GL_NORMAL_ARRAY_COUNT_EXT 0x8080
-#define GL_COLOR_ARRAY_SIZE_EXT 0x8081
-#define GL_COLOR_ARRAY_TYPE_EXT 0x8082
-#define GL_COLOR_ARRAY_STRIDE_EXT 0x8083
-#define GL_COLOR_ARRAY_COUNT_EXT 0x8084
-#define GL_INDEX_ARRAY_TYPE_EXT 0x8085
-#define GL_INDEX_ARRAY_STRIDE_EXT 0x8086
-#define GL_INDEX_ARRAY_COUNT_EXT 0x8087
-#define GL_TEXTURE_COORD_ARRAY_SIZE_EXT 0x8088
-#define GL_TEXTURE_COORD_ARRAY_TYPE_EXT 0x8089
-#define GL_TEXTURE_COORD_ARRAY_STRIDE_EXT 0x808A
-#define GL_TEXTURE_COORD_ARRAY_COUNT_EXT 0x808B
-#define GL_EDGE_FLAG_ARRAY_STRIDE_EXT 0x808C
-#define GL_EDGE_FLAG_ARRAY_COUNT_EXT 0x808D
-#define GL_VERTEX_ARRAY_POINTER_EXT 0x808E
-#define GL_NORMAL_ARRAY_POINTER_EXT 0x808F
-#define GL_COLOR_ARRAY_POINTER_EXT 0x8090
-#define GL_INDEX_ARRAY_POINTER_EXT 0x8091
-#define GL_TEXTURE_COORD_ARRAY_POINTER_EXT 0x8092
-#define GL_EDGE_FLAG_ARRAY_POINTER_EXT 0x8093
-
-GLAPI void GLAPIENTRY glVertexPointerEXT( GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glNormalPointerEXT( GLenum type, GLsizei stride, GLsizei count, const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glColorPointerEXT( GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glIndexPointerEXT( GLenum type, GLsizei stride, GLsizei count, const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glTexCoordPointerEXT( GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *ptr );
-
-GLAPI void GLAPIENTRY glEdgeFlagPointerEXT( GLsizei stride, GLsizei count, const GLboolean *ptr );
-
-GLAPI void GLAPIENTRY glGetPointervEXT( GLenum pname, GLvoid **params );
-
-GLAPI void GLAPIENTRY glArrayElementEXT( GLint i );
-
-GLAPI void GLAPIENTRY glDrawArraysEXT( GLenum mode, GLint first, GLsizei count );
-
-#endif /* GL_EXT_vertex_array */
-
-
-
-/*
- * 35. GL_SGIS_texture_edge_clamp
- */
-#ifndef GL_SGIS_texture_edge_clamp
-#define GL_SGIS_texture_edge_clamp 1
-
-#define GL_CLAMP_TO_EDGE_SGIS 0x812F
-
-#endif /* GL_SGIS_texture_edge_clamp */
-
-
-
-/*
- * 37. GL_EXT_blend_minmax
- */
-#ifndef GL_EXT_blend_minmax
-#define GL_EXT_blend_minmax 1
-
-#define GL_FUNC_ADD_EXT 0x8006
-#define GL_MIN_EXT 0x8007
-#define GL_MAX_EXT 0x8008
-#define GL_BLEND_EQUATION_EXT 0x8009
-
-GLAPI void GLAPIENTRY glBlendEquationEXT( GLenum mode );
-
-#endif /* GL_EXT_blend_minmax */
-
-
-
-/*
- * 38. GL_EXT_blend_subtract (requires GL_EXT_blend_max )
- */
-#ifndef GL_EXT_blend_subtract
-#define GL_EXT_blend_subtract 1
-
-#define GL_FUNC_SUBTRACT_EXT 0x800A
-#define GL_FUNC_REVERSE_SUBTRACT_EXT 0x800B
-
-#endif /* GL_EXT_blend_subtract */
-
-
-
-/*
- * 39. GL_EXT_blend_logic_op
- */
-#ifndef GL_EXT_blend_logic_op
-#define GL_EXT_blend_logic_op 1
-
-/* No new tokens or functions */
-
-#endif /* GL_EXT_blend_logic_op */
-
-
-
-/*
- * 54. GL_EXT_point_parameters
- */
-#ifndef GL_EXT_point_parameters
-#define GL_EXT_point_parameters 1
-
-#define GL_POINT_SIZE_MIN_EXT 0x8126
-#define GL_POINT_SIZE_MAX_EXT 0x8127
-#define GL_POINT_FADE_THRESHOLD_SIZE_EXT 0x8128
-#define GL_DISTANCE_ATTENUATION_EXT 0x8129
-
-GLAPI void GLAPIENTRY glPointParameterfEXT( GLenum pname, GLfloat param );
-GLAPI void GLAPIENTRY glPointParameterfvEXT( GLenum pname, const GLfloat *params );
-GLAPI void GLAPIENTRY glPointParameterfSGIS(GLenum pname, GLfloat param);
-GLAPI void GLAPIENTRY glPointParameterfvSGIS(GLenum pname, const GLfloat *params);
-
-#endif /* GL_EXT_point_parameters */
-
-
-
-/*
- * 78. GL_EXT_paletted_texture
- */
-#ifndef GL_EXT_paletted_texture
-#define GL_EXT_paletted_texture 1
-
-#define GL_TABLE_TOO_LARGE_EXT 0x8031
-#define GL_COLOR_TABLE_FORMAT_EXT 0x80D8
-#define GL_COLOR_TABLE_WIDTH_EXT 0x80D9
-#define GL_COLOR_TABLE_RED_SIZE_EXT 0x80DA
-#define GL_COLOR_TABLE_GREEN_SIZE_EXT 0x80DB
-#define GL_COLOR_TABLE_BLUE_SIZE_EXT 0x80DC
-#define GL_COLOR_TABLE_ALPHA_SIZE_EXT 0x80DD
-#define GL_COLOR_TABLE_LUMINANCE_SIZE_EXT 0x80DE
-#define GL_COLOR_TABLE_INTENSITY_SIZE_EXT 0x80DF
-#define GL_TEXTURE_INDEX_SIZE_EXT 0x80ED
-#define GL_COLOR_INDEX1_EXT 0x80E2
-#define GL_COLOR_INDEX2_EXT 0x80E3
-#define GL_COLOR_INDEX4_EXT 0x80E4
-#define GL_COLOR_INDEX8_EXT 0x80E5
-#define GL_COLOR_INDEX12_EXT 0x80E6
-#define GL_COLOR_INDEX16_EXT 0x80E7
-
-GLAPI void GLAPIENTRY glColorTableEXT( GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table );
-
-GLAPI void GLAPIENTRY glColorSubTableEXT( GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data );
-
-GLAPI void GLAPIENTRY glGetColorTableEXT( GLenum target, GLenum format, GLenum type, GLvoid *table );
-
-GLAPI void GLAPIENTRY glGetColorTableParameterfvEXT( GLenum target, GLenum pname, GLfloat *params );
-
-GLAPI void GLAPIENTRY glGetColorTableParameterivEXT( GLenum target, GLenum pname, GLint *params );
-
-#endif /* GL_EXT_paletted_texture */
-
-
-
-/*
- * 79. GL_EXT_clip_volume_hint
- */
-#ifndef GL_EXT_clip_volume_hint
-#define GL_EXT_clip_volume_hint 1
-
-#define GL_CLIP_VOLUME_CLIPPING_HINT_EXT 0x80F0
-
-#endif /* GL_EXT_clip_volume_hint */
-
-
-
-/*
- * 97. GL_EXT_compiled_vertex_array
- */
-#ifndef GL_EXT_compiled_vertex_array
-#define GL_EXT_compiled_vertex_array 1
-
-#define GL_ARRAY_ELEMENT_LOCK_FIRST_EXT 0x81A8
-#define GL_ARRAY_ELEMENT_LOCK_COUNT_EXT 0x81A9
-
-GLAPI void GLAPIENTRY glLockArraysEXT( GLint first, GLsizei count );
-GLAPI void GLAPIENTRY glUnlockArraysEXT( void );
-
-#endif /* GL_EXT_compiled_vertex_array */
-
-/*
- * 137. GL_HP_occlusion_test
- */
-#ifndef GL_HP_occlusion_test
-#define GL_HP_occlusion_test 1
-
-#define GL_OCCLUSION_TEST_HP 0x8165
-#define GL_OCCLUSION_TEST_RESULT_HP 0x8166
-
-#endif /* GL_HP_occlusion_test */
-
-
-/*
- * 141. GL_EXT_shared_texture_palette (req's GL_EXT_paletted_texture)
- */
-#ifndef GL_EXT_shared_texture_palette
-#define GL_EXT_shared_texture_palette 1
-
-#define GL_SHARED_TEXTURE_PALETTE_EXT 0x81FB
-
-#endif /* GL_EXT_shared_texture_palette */
-
-
-
-/*
- * 176. GL_EXT_stencil_wrap
- */
-#ifndef GL_EXT_stencil_wrap
-#define GL_EXT_stencil_wrap 1
-
-#define GL_INCR_WRAP_EXT 0x8507
-#define GL_DECR_WRAP_EXT 0x8508
-
-#endif /* GL_EXT_stencil_wrap */
-
-
-
-/*
- * 179. GL_NV_texgen_reflection
- */
-#ifndef GL_NV_texgen_reflection
-#define GL_NV_texgen_reflection 1
-
-#define GL_NORMAL_MAP_NV 0x8511
-#define GL_REFLECTION_MAP_NV 0x8512
-
-#endif /* GL_NV_texgen_reflection */
-
-
-
-/*
- * 185. GL_EXT_texture_env_add
- */
-#ifndef GL_EXT_texture_env_add
-#define GL_EXT_texture_env_add 1
-
-/* No new tokens or functions */
-
-#endif /* GL_EXT_texture_env_add */
-
-
-
-/*
- * 197. GL_MESA_window_pos
- */
-#ifndef GL_MESA_window_pos
-#define GL_MESA_window_pos 1
-
-GLAPI void GLAPIENTRY glWindowPos2iMESA( GLint x, GLint y );
-GLAPI void GLAPIENTRY glWindowPos2sMESA( GLshort x, GLshort y );
-GLAPI void GLAPIENTRY glWindowPos2fMESA( GLfloat x, GLfloat y );
-GLAPI void GLAPIENTRY glWindowPos2dMESA( GLdouble x, GLdouble y );
-GLAPI void GLAPIENTRY glWindowPos2ivMESA( const GLint *p );
-GLAPI void GLAPIENTRY glWindowPos2svMESA( const GLshort *p );
-GLAPI void GLAPIENTRY glWindowPos2fvMESA( const GLfloat *p );
-GLAPI void GLAPIENTRY glWindowPos2dvMESA( const GLdouble *p );
-GLAPI void GLAPIENTRY glWindowPos3iMESA( GLint x, GLint y, GLint z );
-GLAPI void GLAPIENTRY glWindowPos3sMESA( GLshort x, GLshort y, GLshort z );
-GLAPI void GLAPIENTRY glWindowPos3fMESA( GLfloat x, GLfloat y, GLfloat z );
-GLAPI void GLAPIENTRY glWindowPos3dMESA( GLdouble x, GLdouble y, GLdouble z );
-GLAPI void GLAPIENTRY glWindowPos3ivMESA( const GLint *p );
-GLAPI void GLAPIENTRY glWindowPos3svMESA( const GLshort *p );
-GLAPI void GLAPIENTRY glWindowPos3fvMESA( const GLfloat *p );
-GLAPI void GLAPIENTRY glWindowPos3dvMESA( const GLdouble *p );
-GLAPI void GLAPIENTRY glWindowPos4iMESA( GLint x, GLint y, GLint z, GLint w );
-GLAPI void GLAPIENTRY glWindowPos4sMESA( GLshort x, GLshort y, GLshort z, GLshort w );
-GLAPI void GLAPIENTRY glWindowPos4fMESA( GLfloat x, GLfloat y, GLfloat z, GLfloat w );
-GLAPI void GLAPIENTRY glWindowPos4dMESA( GLdouble x, GLdouble y, GLdouble z, GLdouble w);
-GLAPI void GLAPIENTRY glWindowPos4ivMESA( const GLint *p );
-GLAPI void GLAPIENTRY glWindowPos4svMESA( const GLshort *p );
-GLAPI void GLAPIENTRY glWindowPos4fvMESA( const GLfloat *p );
-GLAPI void GLAPIENTRY glWindowPos4dvMESA( const GLdouble *p );
-
-#endif /* GL_MESA_window_pos */
-
-
-
-/*
- * 196. GL_MESA_resize_bufffers
- */
-#ifndef GL_MESA_resize_bufffers
-#define GL_MESA_resize_buffers 1
-
-GLAPI void GLAPIENTRY glResizeBuffersMESA( void );
-
-#endif /* GL_MESA_resize_bufffers */
-
-
-
-/*
- * 220. GL_EXT_texture_env_dot3
- */
-#ifndef GL_EXT_texture_env_dot3
-#define GL_EXT_texture_env_dot3 1
-
-#define GL_DOT3_RGB_EXT 0x8740
-#define GL_DOT3_RGBA_EXT 0x8741
-
-#endif /* GL_EXT_texture_env_dot3 */
-
-
-#else /* GL_GLEXT_LEGACY */
-
-#include <GL/glext.h>
-
-#endif /* GL_GLEXT_LEGACY */
-
-
-
-/*
- * ???. GL_MESA_trace
- * XXX this should go into glext.h at some point
- */
-#ifndef GL_MESA_trace
-#define GL_MESA_trace 1
-
-#define GL_TRACE_ALL_BITS_MESA 0xFFFF
-#define GL_TRACE_OPERATIONS_BIT_MESA 0x0001
-#define GL_TRACE_PRIMITIVES_BIT_MESA 0x0002
-#define GL_TRACE_ARRAYS_BIT_MESA 0x0004
-#define GL_TRACE_TEXTURES_BIT_MESA 0x0008
-#define GL_TRACE_PIXELS_BIT_MESA 0x0010
-#define GL_TRACE_ERRORS_BIT_MESA 0x0020
-#define GL_TRACE_MASK_MESA 0x8755
-#define GL_TRACE_NAME_MESA 0x8756
-
-GLAPI void GLAPIENTRY glEnableTraceMESA( GLbitfield mask );
-GLAPI void GLAPIENTRY glDisableTraceMESA( GLbitfield mask );
-GLAPI void GLAPIENTRY glNewTraceMESA( GLbitfield mask, const GLubyte * traceName );
-GLAPI void GLAPIENTRY glEndTraceMESA( void );
-GLAPI void GLAPIENTRY glTraceAssertAttribMESA( GLbitfield attribMask );
-GLAPI void GLAPIENTRY glTraceCommentMESA( const GLubyte * comment );
-GLAPI void GLAPIENTRY glTraceTextureMESA( GLuint name, const GLubyte* comment );
-GLAPI void GLAPIENTRY glTraceListMESA( GLuint name, const GLubyte* comment );
-GLAPI void GLAPIENTRY glTracePointerMESA( GLvoid* pointer, const GLubyte* comment );
-GLAPI void GLAPIENTRY glTracePointerRangeMESA( const GLvoid* first, const GLvoid* last, const GLubyte* comment );
-
-#endif /* GL_MESA_trace */
-
-
-/*
- * ???. GL_MESA_packed_depth_stencil
- * XXX this will be in glext.h someday
- */
-#ifndef GL_MESA_packed_depth_stencil
-#define GL_MESA_packed_depth_stencil 1
-
-#define GL_DEPTH_STENCIL_MESA 0x8750
-#define GL_UNSIGNED_INT_24_8_MESA 0x8751
-#define GL_UNSIGNED_INT_8_24_REV_MESA 0x8752
-#define GL_UNSIGNED_SHORT_15_1_MESA 0x8753
-#define GL_UNSIGNED_SHORT_1_15_REV_MESA 0x8754
-
-#endif /* GL_MESA_packed_depth_stencil */
-
-
-
-#ifndef GL_MESA_ycbcr_texture
-#define GL_MESA_ycbcr_texture 1
-
-#define GL_YCBCR_MESA 0x8757
-#define GL_UNSIGNED_SHORT_8_8_MESA 0x85BA /* same as Apple */
-#define GL_UNSIGNED_SHORT_8_8_REV_MESA 0x85BB /* same as Apple */
-
-#endif /* GL_MESA_texture_ycbcr */
-
-
-
-#ifndef GL_MESA_pack_invert
-#define GL_MESA_pack_invert 1
-
-#define GL_PACK_INVERT_MESA 0x8758
-
-#endif /* GL_MESA_pack_invert */
-
-
-
-#ifndef GL_APPLE_client_storage
-#define GL_APPLE_client_storage 1
-
-#define GL_UNPACK_CLIENT_STORAGE_APPLE 0x85B2
-
-#endif /* GL_APPLE_client_storage */
-
-
-
-#ifndef GL_APPLE_ycbcr_422
-#define GL_APPLE_ycbcr_422 1
-
-#define GL_YCBCR_422_APPLE 0x85B9
-#define GL_UNSIGNED_SHORT_8_8_APPLE 0x85BA
-#define GL_UNSIGNED_SHORT_8_8_REV_APPLE 0x85BB
-
-#endif /* GL_APPLE_ycbcr_422 */
-
-
-/**********************************************************************
- * Begin system-specific stuff
- */
-#if defined(PRAGMA_EXPORT_SUPPORTED)
-#pragma export off
-#endif
-
-#if defined(macintosh) && PRAGMA_IMPORT_SUPPORTED
-#pragma import off
-#endif
-/*
- * End system-specific stuff
- **********************************************************************/
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __gl_h_ */
diff --git a/libtess/GL/glext.h b/libtess/GL/glext.h
deleted file mode 100644
index b9dbca7..0000000
--- a/libtess/GL/glext.h
+++ /dev/null
@@ -1,5024 +0,0 @@
-#ifndef __glext_h_
-#define __glext_h_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
- /*#warning "local glext.h"*/
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2002 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: This software was created using the
-** OpenGL(R) version 1.2.1 Sample Implementation published by SGI, but has
-** not been independently verified as being compliant with the OpenGL(R)
-** version 1.2.1 Specification.
-*/
-
-#if defined(_WIN32) && !defined(APIENTRY) && !defined(__CYGWIN__)
-#define WIN32_LEAN_AND_MEAN 1
-#include <windows.h>
-#endif
-
-#ifndef APIENTRY
-#define APIENTRY
-#endif
-#ifndef GLAPI
-#define GLAPI extern
-#endif
-
-/*************************************************************/
-
-/* Header file version number, required by OpenGL ABI for Linux */
-/* glext.h last updated 2002/08/21 */
-/* Current version at http://oss.sgi.com/projects/ogl-sample/registry/ */
-#define GL_GLEXT_VERSION 17
-
-#ifndef GL_VERSION_1_2
-#define GL_UNSIGNED_BYTE_3_3_2 0x8032
-#define GL_UNSIGNED_SHORT_4_4_4_4 0x8033
-#define GL_UNSIGNED_SHORT_5_5_5_1 0x8034
-#define GL_UNSIGNED_INT_8_8_8_8 0x8035
-#define GL_UNSIGNED_INT_10_10_10_2 0x8036
-#define GL_RESCALE_NORMAL 0x803A
-#define GL_TEXTURE_BINDING_3D 0x806A
-#define GL_PACK_SKIP_IMAGES 0x806B
-#define GL_PACK_IMAGE_HEIGHT 0x806C
-#define GL_UNPACK_SKIP_IMAGES 0x806D
-#define GL_UNPACK_IMAGE_HEIGHT 0x806E
-#define GL_TEXTURE_3D 0x806F
-#define GL_PROXY_TEXTURE_3D 0x8070
-#define GL_TEXTURE_DEPTH 0x8071
-#define GL_TEXTURE_WRAP_R 0x8072
-#define GL_MAX_3D_TEXTURE_SIZE 0x8073
-#define GL_UNSIGNED_BYTE_2_3_3_REV 0x8362
-#define GL_UNSIGNED_SHORT_5_6_5 0x8363
-#define GL_UNSIGNED_SHORT_5_6_5_REV 0x8364
-#define GL_UNSIGNED_SHORT_4_4_4_4_REV 0x8365
-#define GL_UNSIGNED_SHORT_1_5_5_5_REV 0x8366
-#define GL_UNSIGNED_INT_8_8_8_8_REV 0x8367
-#define GL_UNSIGNED_INT_2_10_10_10_REV 0x8368
-#define GL_BGR 0x80E0
-#define GL_BGRA 0x80E1
-#define GL_MAX_ELEMENTS_VERTICES 0x80E8
-#define GL_MAX_ELEMENTS_INDICES 0x80E9
-#define GL_CLAMP_TO_EDGE 0x812F
-#define GL_TEXTURE_MIN_LOD 0x813A
-#define GL_TEXTURE_MAX_LOD 0x813B
-#define GL_TEXTURE_BASE_LEVEL 0x813C
-#define GL_TEXTURE_MAX_LEVEL 0x813D
-#define GL_LIGHT_MODEL_COLOR_CONTROL 0x81F8
-#define GL_SINGLE_COLOR 0x81F9
-#define GL_SEPARATE_SPECULAR_COLOR 0x81FA
-#define GL_SMOOTH_POINT_SIZE_RANGE 0x0B12
-#define GL_SMOOTH_POINT_SIZE_GRANULARITY 0x0B13
-#define GL_SMOOTH_LINE_WIDTH_RANGE 0x0B22
-#define GL_SMOOTH_LINE_WIDTH_GRANULARITY 0x0B23
-#define GL_ALIASED_POINT_SIZE_RANGE 0x846D
-#define GL_ALIASED_LINE_WIDTH_RANGE 0x846E
-#endif
-
-#ifndef GL_ARB_imaging
-#define GL_CONSTANT_COLOR 0x8001
-#define GL_ONE_MINUS_CONSTANT_COLOR 0x8002
-#define GL_CONSTANT_ALPHA 0x8003
-#define GL_ONE_MINUS_CONSTANT_ALPHA 0x8004
-#define GL_BLEND_COLOR 0x8005
-#define GL_FUNC_ADD 0x8006
-#define GL_MIN 0x8007
-#define GL_MAX 0x8008
-#define GL_BLEND_EQUATION 0x8009
-#define GL_FUNC_SUBTRACT 0x800A
-#define GL_FUNC_REVERSE_SUBTRACT 0x800B
-#define GL_CONVOLUTION_1D 0x8010
-#define GL_CONVOLUTION_2D 0x8011
-#define GL_SEPARABLE_2D 0x8012
-#define GL_CONVOLUTION_BORDER_MODE 0x8013
-#define GL_CONVOLUTION_FILTER_SCALE 0x8014
-#define GL_CONVOLUTION_FILTER_BIAS 0x8015
-#define GL_REDUCE 0x8016
-#define GL_CONVOLUTION_FORMAT 0x8017
-#define GL_CONVOLUTION_WIDTH 0x8018
-#define GL_CONVOLUTION_HEIGHT 0x8019
-#define GL_MAX_CONVOLUTION_WIDTH 0x801A
-#define GL_MAX_CONVOLUTION_HEIGHT 0x801B
-#define GL_POST_CONVOLUTION_RED_SCALE 0x801C
-#define GL_POST_CONVOLUTION_GREEN_SCALE 0x801D
-#define GL_POST_CONVOLUTION_BLUE_SCALE 0x801E
-#define GL_POST_CONVOLUTION_ALPHA_SCALE 0x801F
-#define GL_POST_CONVOLUTION_RED_BIAS 0x8020
-#define GL_POST_CONVOLUTION_GREEN_BIAS 0x8021
-#define GL_POST_CONVOLUTION_BLUE_BIAS 0x8022
-#define GL_POST_CONVOLUTION_ALPHA_BIAS 0x8023
-#define GL_HISTOGRAM 0x8024
-#define GL_PROXY_HISTOGRAM 0x8025
-#define GL_HISTOGRAM_WIDTH 0x8026
-#define GL_HISTOGRAM_FORMAT 0x8027
-#define GL_HISTOGRAM_RED_SIZE 0x8028
-#define GL_HISTOGRAM_GREEN_SIZE 0x8029
-#define GL_HISTOGRAM_BLUE_SIZE 0x802A
-#define GL_HISTOGRAM_ALPHA_SIZE 0x802B
-#define GL_HISTOGRAM_LUMINANCE_SIZE 0x802C
-#define GL_HISTOGRAM_SINK 0x802D
-#define GL_MINMAX 0x802E
-#define GL_MINMAX_FORMAT 0x802F
-#define GL_MINMAX_SINK 0x8030
-#define GL_TABLE_TOO_LARGE 0x8031
-#define GL_COLOR_MATRIX 0x80B1
-#define GL_COLOR_MATRIX_STACK_DEPTH 0x80B2
-#define GL_MAX_COLOR_MATRIX_STACK_DEPTH 0x80B3
-#define GL_POST_COLOR_MATRIX_RED_SCALE 0x80B4
-#define GL_POST_COLOR_MATRIX_GREEN_SCALE 0x80B5
-#define GL_POST_COLOR_MATRIX_BLUE_SCALE 0x80B6
-#define GL_POST_COLOR_MATRIX_ALPHA_SCALE 0x80B7
-#define GL_POST_COLOR_MATRIX_RED_BIAS 0x80B8
-#define GL_POST_COLOR_MATRIX_GREEN_BIAS 0x80B9
-#define GL_POST_COLOR_MATRIX_BLUE_BIAS 0x80BA
-#define GL_POST_COLOR_MATRIX_ALPHA_BIAS 0x80BB
-#define GL_COLOR_TABLE 0x80D0
-#define GL_POST_CONVOLUTION_COLOR_TABLE 0x80D1
-#define GL_POST_COLOR_MATRIX_COLOR_TABLE 0x80D2
-#define GL_PROXY_COLOR_TABLE 0x80D3
-#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE 0x80D4
-#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE 0x80D5
-#define GL_COLOR_TABLE_SCALE 0x80D6
-#define GL_COLOR_TABLE_BIAS 0x80D7
-#define GL_COLOR_TABLE_FORMAT 0x80D8
-#define GL_COLOR_TABLE_WIDTH 0x80D9
-#define GL_COLOR_TABLE_RED_SIZE 0x80DA
-#define GL_COLOR_TABLE_GREEN_SIZE 0x80DB
-#define GL_COLOR_TABLE_BLUE_SIZE 0x80DC
-#define GL_COLOR_TABLE_ALPHA_SIZE 0x80DD
-#define GL_COLOR_TABLE_LUMINANCE_SIZE 0x80DE
-#define GL_COLOR_TABLE_INTENSITY_SIZE 0x80DF
-#define GL_CONSTANT_BORDER 0x8151
-#define GL_REPLICATE_BORDER 0x8153
-#define GL_CONVOLUTION_BORDER_COLOR 0x8154
-#endif
-
-#ifndef GL_VERSION_1_3
-#define GL_TEXTURE0 0x84C0
-#define GL_TEXTURE1 0x84C1
-#define GL_TEXTURE2 0x84C2
-#define GL_TEXTURE3 0x84C3
-#define GL_TEXTURE4 0x84C4
-#define GL_TEXTURE5 0x84C5
-#define GL_TEXTURE6 0x84C6
-#define GL_TEXTURE7 0x84C7
-#define GL_TEXTURE8 0x84C8
-#define GL_TEXTURE9 0x84C9
-#define GL_TEXTURE10 0x84CA
-#define GL_TEXTURE11 0x84CB
-#define GL_TEXTURE12 0x84CC
-#define GL_TEXTURE13 0x84CD
-#define GL_TEXTURE14 0x84CE
-#define GL_TEXTURE15 0x84CF
-#define GL_TEXTURE16 0x84D0
-#define GL_TEXTURE17 0x84D1
-#define GL_TEXTURE18 0x84D2
-#define GL_TEXTURE19 0x84D3
-#define GL_TEXTURE20 0x84D4
-#define GL_TEXTURE21 0x84D5
-#define GL_TEXTURE22 0x84D6
-#define GL_TEXTURE23 0x84D7
-#define GL_TEXTURE24 0x84D8
-#define GL_TEXTURE25 0x84D9
-#define GL_TEXTURE26 0x84DA
-#define GL_TEXTURE27 0x84DB
-#define GL_TEXTURE28 0x84DC
-#define GL_TEXTURE29 0x84DD
-#define GL_TEXTURE30 0x84DE
-#define GL_TEXTURE31 0x84DF
-#define GL_ACTIVE_TEXTURE 0x84E0
-#define GL_CLIENT_ACTIVE_TEXTURE 0x84E1
-#define GL_MAX_TEXTURE_UNITS 0x84E2
-#define GL_TRANSPOSE_MODELVIEW_MATRIX 0x84E3
-#define GL_TRANSPOSE_PROJECTION_MATRIX 0x84E4
-#define GL_TRANSPOSE_TEXTURE_MATRIX 0x84E5
-#define GL_TRANSPOSE_COLOR_MATRIX 0x84E6
-#define GL_MULTISAMPLE 0x809D
-#define GL_SAMPLE_ALPHA_TO_COVERAGE 0x809E
-#define GL_SAMPLE_ALPHA_TO_ONE 0x809F
-#define GL_SAMPLE_COVERAGE 0x80A0
-#define GL_SAMPLE_BUFFERS 0x80A8
-#define GL_SAMPLES 0x80A9
-#define GL_SAMPLE_COVERAGE_VALUE 0x80AA
-#define GL_SAMPLE_COVERAGE_INVERT 0x80AB
-#define GL_MULTISAMPLE_BIT 0x20000000
-#define GL_NORMAL_MAP 0x8511
-#define GL_REFLECTION_MAP 0x8512
-#define GL_TEXTURE_CUBE_MAP 0x8513
-#define GL_TEXTURE_BINDING_CUBE_MAP 0x8514
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x8515
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x8516
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x8517
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x8518
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x8519
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x851A
-#define GL_PROXY_TEXTURE_CUBE_MAP 0x851B
-#define GL_MAX_CUBE_MAP_TEXTURE_SIZE 0x851C
-#define GL_COMPRESSED_ALPHA 0x84E9
-#define GL_COMPRESSED_LUMINANCE 0x84EA
-#define GL_COMPRESSED_LUMINANCE_ALPHA 0x84EB
-#define GL_COMPRESSED_INTENSITY 0x84EC
-#define GL_COMPRESSED_RGB 0x84ED
-#define GL_COMPRESSED_RGBA 0x84EE
-#define GL_TEXTURE_COMPRESSION_HINT 0x84EF
-#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE 0x86A0
-#define GL_TEXTURE_COMPRESSED 0x86A1
-#define GL_NUM_COMPRESSED_TEXTURE_FORMATS 0x86A2
-#define GL_COMPRESSED_TEXTURE_FORMATS 0x86A3
-#define GL_CLAMP_TO_BORDER 0x812D
-#define GL_CLAMP_TO_BORDER_SGIS 0x812D
-#define GL_COMBINE 0x8570
-#define GL_COMBINE_RGB 0x8571
-#define GL_COMBINE_ALPHA 0x8572
-#define GL_SOURCE0_RGB 0x8580
-#define GL_SOURCE1_RGB 0x8581
-#define GL_SOURCE2_RGB 0x8582
-#define GL_SOURCE0_ALPHA 0x8588
-#define GL_SOURCE1_ALPHA 0x8589
-#define GL_SOURCE2_ALPHA 0x858A
-#define GL_OPERAND0_RGB 0x8590
-#define GL_OPERAND1_RGB 0x8591
-#define GL_OPERAND2_RGB 0x8592
-#define GL_OPERAND0_ALPHA 0x8598
-#define GL_OPERAND1_ALPHA 0x8599
-#define GL_OPERAND2_ALPHA 0x859A
-#define GL_RGB_SCALE 0x8573
-#define GL_ADD_SIGNED 0x8574
-#define GL_INTERPOLATE 0x8575
-#define GL_SUBTRACT 0x84E7
-#define GL_CONSTANT 0x8576
-#define GL_PRIMARY_COLOR 0x8577
-#define GL_PREVIOUS 0x8578
-#define GL_DOT3_RGB 0x86AE
-#define GL_DOT3_RGBA 0x86AF
-#endif
-
-#ifndef GL_VERSION_1_4
-#define GL_BLEND_DST_RGB 0x80C8
-#define GL_BLEND_SRC_RGB 0x80C9
-#define GL_BLEND_DST_ALPHA 0x80CA
-#define GL_BLEND_SRC_ALPHA 0x80CB
-#define GL_POINT_SIZE_MIN 0x8126
-#define GL_POINT_SIZE_MAX 0x8127
-#define GL_POINT_FADE_THRESHOLD_SIZE 0x8128
-#define GL_POINT_DISTANCE_ATTENUATION 0x8129
-#define GL_GENERATE_MIPMAP 0x8191
-#define GL_GENERATE_MIPMAP_HINT 0x8192
-#define GL_DEPTH_COMPONENT16 0x81A5
-#define GL_DEPTH_COMPONENT24 0x81A6
-#define GL_DEPTH_COMPONENT32 0x81A7
-#define GL_MIRRORED_REPEAT 0x8370
-#define GL_FOG_COORDINATE_SOURCE 0x8450
-#define GL_FOG_COORDINATE 0x8451
-#define GL_FRAGMENT_DEPTH 0x8452
-#define GL_CURRENT_FOG_COORDINATE 0x8453
-#define GL_FOG_COORDINATE_ARRAY_TYPE 0x8454
-#define GL_FOG_COORDINATE_ARRAY_STRIDE 0x8455
-#define GL_FOG_COORDINATE_ARRAY_POINTER 0x8456
-#define GL_FOG_COORDINATE_ARRAY 0x8457
-#define GL_COLOR_SUM 0x8458
-#define GL_CURRENT_SECONDARY_COLOR 0x8459
-#define GL_SECONDARY_COLOR_ARRAY_SIZE 0x845A
-#define GL_SECONDARY_COLOR_ARRAY_TYPE 0x845B
-#define GL_SECONDARY_COLOR_ARRAY_STRIDE 0x845C
-#define GL_SECONDARY_COLOR_ARRAY_POINTER 0x845D
-#define GL_SECONDARY_COLOR_ARRAY 0x845E
-#define GL_MAX_TEXTURE_LOD_BIAS 0x84FD
-#define GL_TEXTURE_FILTER_CONTROL 0x8500
-#define GL_TEXTURE_LOD_BIAS 0x8501
-#define GL_INCR_WRAP 0x8507
-#define GL_DECR_WRAP 0x8508
-#define GL_TEXTURE_DEPTH_SIZE 0x884A
-#define GL_DEPTH_TEXTURE_MODE 0x884B
-#define GL_TEXTURE_COMPARE_MODE 0x884C
-#define GL_TEXTURE_COMPARE_FUNC 0x884D
-#define GL_COMPARE_R_TO_TEXTURE 0x884E
-#endif
-
-#ifndef GL_ARB_multitexture
-#define GL_TEXTURE0_ARB 0x84C0
-#define GL_TEXTURE1_ARB 0x84C1
-#define GL_TEXTURE2_ARB 0x84C2
-#define GL_TEXTURE3_ARB 0x84C3
-#define GL_TEXTURE4_ARB 0x84C4
-#define GL_TEXTURE5_ARB 0x84C5
-#define GL_TEXTURE6_ARB 0x84C6
-#define GL_TEXTURE7_ARB 0x84C7
-#define GL_TEXTURE8_ARB 0x84C8
-#define GL_TEXTURE9_ARB 0x84C9
-#define GL_TEXTURE10_ARB 0x84CA
-#define GL_TEXTURE11_ARB 0x84CB
-#define GL_TEXTURE12_ARB 0x84CC
-#define GL_TEXTURE13_ARB 0x84CD
-#define GL_TEXTURE14_ARB 0x84CE
-#define GL_TEXTURE15_ARB 0x84CF
-#define GL_TEXTURE16_ARB 0x84D0
-#define GL_TEXTURE17_ARB 0x84D1
-#define GL_TEXTURE18_ARB 0x84D2
-#define GL_TEXTURE19_ARB 0x84D3
-#define GL_TEXTURE20_ARB 0x84D4
-#define GL_TEXTURE21_ARB 0x84D5
-#define GL_TEXTURE22_ARB 0x84D6
-#define GL_TEXTURE23_ARB 0x84D7
-#define GL_TEXTURE24_ARB 0x84D8
-#define GL_TEXTURE25_ARB 0x84D9
-#define GL_TEXTURE26_ARB 0x84DA
-#define GL_TEXTURE27_ARB 0x84DB
-#define GL_TEXTURE28_ARB 0x84DC
-#define GL_TEXTURE29_ARB 0x84DD
-#define GL_TEXTURE30_ARB 0x84DE
-#define GL_TEXTURE31_ARB 0x84DF
-#define GL_ACTIVE_TEXTURE_ARB 0x84E0
-#define GL_CLIENT_ACTIVE_TEXTURE_ARB 0x84E1
-#define GL_MAX_TEXTURE_UNITS_ARB 0x84E2
-#endif
-
-#ifndef GL_ARB_transpose_matrix
-#define GL_TRANSPOSE_MODELVIEW_MATRIX_ARB 0x84E3
-#define GL_TRANSPOSE_PROJECTION_MATRIX_ARB 0x84E4
-#define GL_TRANSPOSE_TEXTURE_MATRIX_ARB 0x84E5
-#define GL_TRANSPOSE_COLOR_MATRIX_ARB 0x84E6
-#endif
-
-#ifndef GL_ARB_multisample
-#define GL_MULTISAMPLE_ARB 0x809D
-#define GL_SAMPLE_ALPHA_TO_COVERAGE_ARB 0x809E
-#define GL_SAMPLE_ALPHA_TO_ONE_ARB 0x809F
-#define GL_SAMPLE_COVERAGE_ARB 0x80A0
-#define GL_SAMPLE_BUFFERS_ARB 0x80A8
-#define GL_SAMPLES_ARB 0x80A9
-#define GL_SAMPLE_COVERAGE_VALUE_ARB 0x80AA
-#define GL_SAMPLE_COVERAGE_INVERT_ARB 0x80AB
-#define GL_MULTISAMPLE_BIT_ARB 0x20000000
-#endif
-
-#ifndef GL_ARB_texture_env_add
-#endif
-
-#ifndef GL_ARB_texture_cube_map
-#define GL_NORMAL_MAP_ARB 0x8511
-#define GL_REFLECTION_MAP_ARB 0x8512
-#define GL_TEXTURE_CUBE_MAP_ARB 0x8513
-#define GL_TEXTURE_BINDING_CUBE_MAP_ARB 0x8514
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB 0x8515
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB 0x8516
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB 0x8517
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB 0x8518
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB 0x8519
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB 0x851A
-#define GL_PROXY_TEXTURE_CUBE_MAP_ARB 0x851B
-#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB 0x851C
-#endif
-
-#ifndef GL_ARB_texture_compression
-#define GL_COMPRESSED_ALPHA_ARB 0x84E9
-#define GL_COMPRESSED_LUMINANCE_ARB 0x84EA
-#define GL_COMPRESSED_LUMINANCE_ALPHA_ARB 0x84EB
-#define GL_COMPRESSED_INTENSITY_ARB 0x84EC
-#define GL_COMPRESSED_RGB_ARB 0x84ED
-#define GL_COMPRESSED_RGBA_ARB 0x84EE
-#define GL_TEXTURE_COMPRESSION_HINT_ARB 0x84EF
-#define GL_TEXTURE_COMPRESSED_IMAGE_SIZE_ARB 0x86A0
-#define GL_TEXTURE_COMPRESSED_ARB 0x86A1
-#define GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A2
-#define GL_COMPRESSED_TEXTURE_FORMATS_ARB 0x86A3
-#endif
-
-#ifndef GL_ARB_texture_border_clamp
-#define GL_CLAMP_TO_BORDER_ARB 0x812D
-#endif
-
-#ifndef GL_ARB_point_parameters
-#define GL_POINT_SIZE_MIN_ARB 0x8126
-#define GL_POINT_SIZE_MAX_ARB 0x8127
-#define GL_POINT_FADE_THRESHOLD_SIZE_ARB 0x8128
-#define GL_POINT_DISTANCE_ATTENUATION_ARB 0x8129
-#endif
-
-#ifndef GL_ARB_vertex_blend
-#define GL_MAX_VERTEX_UNITS_ARB 0x86A4
-#define GL_ACTIVE_VERTEX_UNITS_ARB 0x86A5
-#define GL_WEIGHT_SUM_UNITY_ARB 0x86A6
-#define GL_VERTEX_BLEND_ARB 0x86A7
-#define GL_CURRENT_WEIGHT_ARB 0x86A8
-#define GL_WEIGHT_ARRAY_TYPE_ARB 0x86A9
-#define GL_WEIGHT_ARRAY_STRIDE_ARB 0x86AA
-#define GL_WEIGHT_ARRAY_SIZE_ARB 0x86AB
-#define GL_WEIGHT_ARRAY_POINTER_ARB 0x86AC
-#define GL_WEIGHT_ARRAY_ARB 0x86AD
-#define GL_MODELVIEW0_ARB 0x1700
-#define GL_MODELVIEW1_ARB 0x850A
-#define GL_MODELVIEW2_ARB 0x8722
-#define GL_MODELVIEW3_ARB 0x8723
-#define GL_MODELVIEW4_ARB 0x8724
-#define GL_MODELVIEW5_ARB 0x8725
-#define GL_MODELVIEW6_ARB 0x8726
-#define GL_MODELVIEW7_ARB 0x8727
-#define GL_MODELVIEW8_ARB 0x8728
-#define GL_MODELVIEW9_ARB 0x8729
-#define GL_MODELVIEW10_ARB 0x872A
-#define GL_MODELVIEW11_ARB 0x872B
-#define GL_MODELVIEW12_ARB 0x872C
-#define GL_MODELVIEW13_ARB 0x872D
-#define GL_MODELVIEW14_ARB 0x872E
-#define GL_MODELVIEW15_ARB 0x872F
-#define GL_MODELVIEW16_ARB 0x8730
-#define GL_MODELVIEW17_ARB 0x8731
-#define GL_MODELVIEW18_ARB 0x8732
-#define GL_MODELVIEW19_ARB 0x8733
-#define GL_MODELVIEW20_ARB 0x8734
-#define GL_MODELVIEW21_ARB 0x8735
-#define GL_MODELVIEW22_ARB 0x8736
-#define GL_MODELVIEW23_ARB 0x8737
-#define GL_MODELVIEW24_ARB 0x8738
-#define GL_MODELVIEW25_ARB 0x8739
-#define GL_MODELVIEW26_ARB 0x873A
-#define GL_MODELVIEW27_ARB 0x873B
-#define GL_MODELVIEW28_ARB 0x873C
-#define GL_MODELVIEW29_ARB 0x873D
-#define GL_MODELVIEW30_ARB 0x873E
-#define GL_MODELVIEW31_ARB 0x873F
-#endif
-
-#ifndef GL_ARB_matrix_palette
-#define GL_MATRIX_PALETTE_ARB 0x8840
-#define GL_MAX_MATRIX_PALETTE_STACK_DEPTH_ARB 0x8841
-#define GL_MAX_PALETTE_MATRICES_ARB 0x8842
-#define GL_CURRENT_PALETTE_MATRIX_ARB 0x8843
-#define GL_MATRIX_INDEX_ARRAY_ARB 0x8844
-#define GL_CURRENT_MATRIX_INDEX_ARB 0x8845
-#define GL_MATRIX_INDEX_ARRAY_SIZE_ARB 0x8846
-#define GL_MATRIX_INDEX_ARRAY_TYPE_ARB 0x8847
-#define GL_MATRIX_INDEX_ARRAY_STRIDE_ARB 0x8848
-#define GL_MATRIX_INDEX_ARRAY_POINTER_ARB 0x8849
-#endif
-
-#ifndef GL_ARB_texture_env_combine
-#define GL_COMBINE_ARB 0x8570
-#define GL_COMBINE_RGB_ARB 0x8571
-#define GL_COMBINE_ALPHA_ARB 0x8572
-#define GL_SOURCE0_RGB_ARB 0x8580
-#define GL_SOURCE1_RGB_ARB 0x8581
-#define GL_SOURCE2_RGB_ARB 0x8582
-#define GL_SOURCE0_ALPHA_ARB 0x8588
-#define GL_SOURCE1_ALPHA_ARB 0x8589
-#define GL_SOURCE2_ALPHA_ARB 0x858A
-#define GL_OPERAND0_RGB_ARB 0x8590
-#define GL_OPERAND1_RGB_ARB 0x8591
-#define GL_OPERAND2_RGB_ARB 0x8592
-#define GL_OPERAND0_ALPHA_ARB 0x8598
-#define GL_OPERAND1_ALPHA_ARB 0x8599
-#define GL_OPERAND2_ALPHA_ARB 0x859A
-#define GL_RGB_SCALE_ARB 0x8573
-#define GL_ADD_SIGNED_ARB 0x8574
-#define GL_INTERPOLATE_ARB 0x8575
-#define GL_SUBTRACT_ARB 0x84E7
-#define GL_CONSTANT_ARB 0x8576
-#define GL_PRIMARY_COLOR_ARB 0x8577
-#define GL_PREVIOUS_ARB 0x8578
-#endif
-
-#ifndef GL_ARB_texture_env_crossbar
-#endif
-
-#ifndef GL_ARB_texture_env_dot3
-#define GL_DOT3_RGB_ARB 0x86AE
-#define GL_DOT3_RGBA_ARB 0x86AF
-#endif
-
-#ifndef GL_ARB_texture_mirrored_repeat
-#define GL_MIRRORED_REPEAT_ARB 0x8370
-#endif
-
-#ifndef GL_ARB_depth_texture
-#define GL_DEPTH_COMPONENT16_ARB 0x81A5
-#define GL_DEPTH_COMPONENT24_ARB 0x81A6
-#define GL_DEPTH_COMPONENT32_ARB 0x81A7
-#define GL_TEXTURE_DEPTH_SIZE_ARB 0x884A
-#define GL_DEPTH_TEXTURE_MODE_ARB 0x884B
-#endif
-
-#ifndef GL_ARB_shadow
-#define GL_TEXTURE_COMPARE_MODE_ARB 0x884C
-#define GL_TEXTURE_COMPARE_FUNC_ARB 0x884D
-#define GL_COMPARE_R_TO_TEXTURE_ARB 0x884E
-#endif
-
-#ifndef GL_ARB_shadow_ambient
-#define GL_TEXTURE_COMPARE_FAIL_VALUE_ARB 0x80BF
-#endif
-
-#ifndef GL_ARB_window_pos
-#endif
-
-#ifndef GL_ARB_vertex_program
-#define GL_VERTEX_PROGRAM_ARB 0x8620
-#define GL_VERTEX_PROGRAM_POINT_SIZE_ARB 0x8642
-#define GL_VERTEX_PROGRAM_TWO_SIDE_ARB 0x8643
-#define GL_COLOR_SUM_ARB 0x8458
-#define GL_PROGRAM_FORMAT_ASCII_ARB 0x8875
-#define GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB 0x8622
-#define GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB 0x8623
-#define GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB 0x8624
-#define GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB 0x8625
-#define GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB 0x886A
-#define GL_CURRENT_VERTEX_ATTRIB_ARB 0x8626
-#define GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB 0x8645
-#define GL_PROGRAM_LENGTH_ARB 0x8627
-#define GL_PROGRAM_FORMAT_ARB 0x8876
-#define GL_PROGRAM_BINDING_ARB 0x8677
-#define GL_PROGRAM_INSTRUCTIONS_ARB 0x88A0
-#define GL_MAX_PROGRAM_INSTRUCTIONS_ARB 0x88A1
-#define GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A2
-#define GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB 0x88A3
-#define GL_PROGRAM_TEMPORARIES_ARB 0x88A4
-#define GL_MAX_PROGRAM_TEMPORARIES_ARB 0x88A5
-#define GL_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A6
-#define GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB 0x88A7
-#define GL_PROGRAM_PARAMETERS_ARB 0x88A8
-#define GL_MAX_PROGRAM_PARAMETERS_ARB 0x88A9
-#define GL_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AA
-#define GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB 0x88AB
-#define GL_PROGRAM_ATTRIBS_ARB 0x88AC
-#define GL_MAX_PROGRAM_ATTRIBS_ARB 0x88AD
-#define GL_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AE
-#define GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB 0x88AF
-#define GL_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B0
-#define GL_MAX_PROGRAM_ADDRESS_REGISTERS_ARB 0x88B1
-#define GL_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B2
-#define GL_MAX_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB 0x88B3
-#define GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB 0x88B4
-#define GL_MAX_PROGRAM_ENV_PARAMETERS_ARB 0x88B5
-#define GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB 0x88B6
-#define GL_PROGRAM_STRING_ARB 0x8628
-#define GL_PROGRAM_ERROR_POSITION_ARB 0x864B
-#define GL_CURRENT_MATRIX_ARB 0x8641
-#define GL_TRANSPOSE_CURRENT_MATRIX_ARB 0x88B7
-#define GL_CURRENT_MATRIX_STACK_DEPTH_ARB 0x8640
-#define GL_MAX_VERTEX_ATTRIBS_ARB 0x8869
-#define GL_MAX_PROGRAM_MATRICES_ARB 0x862F
-#define GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB 0x862E
-#define GL_PROGRAM_ERROR_STRING_ARB 0x8874
-#define GL_MATRIX0_ARB 0x88C0
-#define GL_MATRIX1_ARB 0x88C1
-#define GL_MATRIX2_ARB 0x88C2
-#define GL_MATRIX3_ARB 0x88C3
-#define GL_MATRIX4_ARB 0x88C4
-#define GL_MATRIX5_ARB 0x88C5
-#define GL_MATRIX6_ARB 0x88C6
-#define GL_MATRIX7_ARB 0x88C7
-#define GL_MATRIX8_ARB 0x88C8
-#define GL_MATRIX9_ARB 0x88C9
-#define GL_MATRIX10_ARB 0x88CA
-#define GL_MATRIX11_ARB 0x88CB
-#define GL_MATRIX12_ARB 0x88CC
-#define GL_MATRIX13_ARB 0x88CD
-#define GL_MATRIX14_ARB 0x88CE
-#define GL_MATRIX15_ARB 0x88CF
-#define GL_MATRIX16_ARB 0x88D0
-#define GL_MATRIX17_ARB 0x88D1
-#define GL_MATRIX18_ARB 0x88D2
-#define GL_MATRIX19_ARB 0x88D3
-#define GL_MATRIX20_ARB 0x88D4
-#define GL_MATRIX21_ARB 0x88D5
-#define GL_MATRIX22_ARB 0x88D6
-#define GL_MATRIX23_ARB 0x88D7
-#define GL_MATRIX24_ARB 0x88D8
-#define GL_MATRIX25_ARB 0x88D9
-#define GL_MATRIX26_ARB 0x88DA
-#define GL_MATRIX27_ARB 0x88DB
-#define GL_MATRIX28_ARB 0x88DC
-#define GL_MATRIX29_ARB 0x88DD
-#define GL_MATRIX30_ARB 0x88DE
-#define GL_MATRIX31_ARB 0x88DF
-#endif
-
-#ifndef GL_EXT_abgr
-#define GL_ABGR_EXT 0x8000
-#endif
-
-#ifndef GL_EXT_blend_color
-#define GL_CONSTANT_COLOR_EXT 0x8001
-#define GL_ONE_MINUS_CONSTANT_COLOR_EXT 0x8002
-#define GL_CONSTANT_ALPHA_EXT 0x8003
-#define GL_ONE_MINUS_CONSTANT_ALPHA_EXT 0x8004
-#define GL_BLEND_COLOR_EXT 0x8005
-#endif
-
-#ifndef GL_EXT_polygon_offset
-#define GL_POLYGON_OFFSET_EXT 0x8037
-#define GL_POLYGON_OFFSET_FACTOR_EXT 0x8038
-#define GL_POLYGON_OFFSET_BIAS_EXT 0x8039
-#endif
-
-#ifndef GL_EXT_texture
-#define GL_ALPHA4_EXT 0x803B
-#define GL_ALPHA8_EXT 0x803C
-#define GL_ALPHA12_EXT 0x803D
-#define GL_ALPHA16_EXT 0x803E
-#define GL_LUMINANCE4_EXT 0x803F
-#define GL_LUMINANCE8_EXT 0x8040
-#define GL_LUMINANCE12_EXT 0x8041
-#define GL_LUMINANCE16_EXT 0x8042
-#define GL_LUMINANCE4_ALPHA4_EXT 0x8043
-#define GL_LUMINANCE6_ALPHA2_EXT 0x8044
-#define GL_LUMINANCE8_ALPHA8_EXT 0x8045
-#define GL_LUMINANCE12_ALPHA4_EXT 0x8046
-#define GL_LUMINANCE12_ALPHA12_EXT 0x8047
-#define GL_LUMINANCE16_ALPHA16_EXT 0x8048
-#define GL_INTENSITY_EXT 0x8049
-#define GL_INTENSITY4_EXT 0x804A
-#define GL_INTENSITY8_EXT 0x804B
-#define GL_INTENSITY12_EXT 0x804C
-#define GL_INTENSITY16_EXT 0x804D
-#define GL_RGB2_EXT 0x804E
-#define GL_RGB4_EXT 0x804F
-#define GL_RGB5_EXT 0x8050
-#define GL_RGB8_EXT 0x8051
-#define GL_RGB10_EXT 0x8052
-#define GL_RGB12_EXT 0x8053
-#define GL_RGB16_EXT 0x8054
-#define GL_RGBA2_EXT 0x8055
-#define GL_RGBA4_EXT 0x8056
-#define GL_RGB5_A1_EXT 0x8057
-#define GL_RGBA8_EXT 0x8058
-#define GL_RGB10_A2_EXT 0x8059
-#define GL_RGBA12_EXT 0x805A
-#define GL_RGBA16_EXT 0x805B
-#define GL_TEXTURE_RED_SIZE_EXT 0x805C
-#define GL_TEXTURE_GREEN_SIZE_EXT 0x805D
-#define GL_TEXTURE_BLUE_SIZE_EXT 0x805E
-#define GL_TEXTURE_ALPHA_SIZE_EXT 0x805F
-#define GL_TEXTURE_LUMINANCE_SIZE_EXT 0x8060
-#define GL_TEXTURE_INTENSITY_SIZE_EXT 0x8061
-#define GL_REPLACE_EXT 0x8062
-#define GL_PROXY_TEXTURE_1D_EXT 0x8063
-#define GL_PROXY_TEXTURE_2D_EXT 0x8064
-#define GL_TEXTURE_TOO_LARGE_EXT 0x8065
-#endif
-
-#ifndef GL_EXT_texture3D
-#define GL_PACK_SKIP_IMAGES_EXT 0x806B
-#define GL_PACK_IMAGE_HEIGHT_EXT 0x806C
-#define GL_UNPACK_SKIP_IMAGES_EXT 0x806D
-#define GL_UNPACK_IMAGE_HEIGHT_EXT 0x806E
-#define GL_TEXTURE_3D_EXT 0x806F
-#define GL_PROXY_TEXTURE_3D_EXT 0x8070
-#define GL_TEXTURE_DEPTH_EXT 0x8071
-#define GL_TEXTURE_WRAP_R_EXT 0x8072
-#define GL_MAX_3D_TEXTURE_SIZE_EXT 0x8073
-#endif
-
-#ifndef GL_SGIS_texture_filter4
-#define GL_FILTER4_SGIS 0x8146
-#define GL_TEXTURE_FILTER4_SIZE_SGIS 0x8147
-#endif
-
-#ifndef GL_EXT_subtexture
-#endif
-
-#ifndef GL_EXT_copy_texture
-#endif
-
-#ifndef GL_EXT_histogram
-#define GL_HISTOGRAM_EXT 0x8024
-#define GL_PROXY_HISTOGRAM_EXT 0x8025
-#define GL_HISTOGRAM_WIDTH_EXT 0x8026
-#define GL_HISTOGRAM_FORMAT_EXT 0x8027
-#define GL_HISTOGRAM_RED_SIZE_EXT 0x8028
-#define GL_HISTOGRAM_GREEN_SIZE_EXT 0x8029
-#define GL_HISTOGRAM_BLUE_SIZE_EXT 0x802A
-#define GL_HISTOGRAM_ALPHA_SIZE_EXT 0x802B
-#define GL_HISTOGRAM_LUMINANCE_SIZE_EXT 0x802C
-#define GL_HISTOGRAM_SINK_EXT 0x802D
-#define GL_MINMAX_EXT 0x802E
-#define GL_MINMAX_FORMAT_EXT 0x802F
-#define GL_MINMAX_SINK_EXT 0x8030
-#define GL_TABLE_TOO_LARGE_EXT 0x8031
-#endif
-
-#ifndef GL_EXT_convolution
-#define GL_CONVOLUTION_1D_EXT 0x8010
-#define GL_CONVOLUTION_2D_EXT 0x8011
-#define GL_SEPARABLE_2D_EXT 0x8012
-#define GL_CONVOLUTION_BORDER_MODE_EXT 0x8013
-#define GL_CONVOLUTION_FILTER_SCALE_EXT 0x8014
-#define GL_CONVOLUTION_FILTER_BIAS_EXT 0x8015
-#define GL_REDUCE_EXT 0x8016
-#define GL_CONVOLUTION_FORMAT_EXT 0x8017
-#define GL_CONVOLUTION_WIDTH_EXT 0x8018
-#define GL_CONVOLUTION_HEIGHT_EXT 0x8019
-#define GL_MAX_CONVOLUTION_WIDTH_EXT 0x801A
-#define GL_MAX_CONVOLUTION_HEIGHT_EXT 0x801B
-#define GL_POST_CONVOLUTION_RED_SCALE_EXT 0x801C
-#define GL_POST_CONVOLUTION_GREEN_SCALE_EXT 0x801D
-#define GL_POST_CONVOLUTION_BLUE_SCALE_EXT 0x801E
-#define GL_POST_CONVOLUTION_ALPHA_SCALE_EXT 0x801F
-#define GL_POST_CONVOLUTION_RED_BIAS_EXT 0x8020
-#define GL_POST_CONVOLUTION_GREEN_BIAS_EXT 0x8021
-#define GL_POST_CONVOLUTION_BLUE_BIAS_EXT 0x8022
-#define GL_POST_CONVOLUTION_ALPHA_BIAS_EXT 0x8023
-#endif
-
-#ifndef GL_SGI_color_matrix
-#define GL_COLOR_MATRIX_SGI 0x80B1
-#define GL_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B2
-#define GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI 0x80B3
-#define GL_POST_COLOR_MATRIX_RED_SCALE_SGI 0x80B4
-#define GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI 0x80B5
-#define GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI 0x80B6
-#define GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI 0x80B7
-#define GL_POST_COLOR_MATRIX_RED_BIAS_SGI 0x80B8
-#define GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI 0x80B9
-#define GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI 0x80BA
-#define GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI 0x80BB
-#endif
-
-#ifndef GL_SGI_color_table
-#define GL_COLOR_TABLE_SGI 0x80D0
-#define GL_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D1
-#define GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D2
-#define GL_PROXY_COLOR_TABLE_SGI 0x80D3
-#define GL_PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI 0x80D4
-#define GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI 0x80D5
-#define GL_COLOR_TABLE_SCALE_SGI 0x80D6
-#define GL_COLOR_TABLE_BIAS_SGI 0x80D7
-#define GL_COLOR_TABLE_FORMAT_SGI 0x80D8
-#define GL_COLOR_TABLE_WIDTH_SGI 0x80D9
-#define GL_COLOR_TABLE_RED_SIZE_SGI 0x80DA
-#define GL_COLOR_TABLE_GREEN_SIZE_SGI 0x80DB
-#define GL_COLOR_TABLE_BLUE_SIZE_SGI 0x80DC
-#define GL_COLOR_TABLE_ALPHA_SIZE_SGI 0x80DD
-#define GL_COLOR_TABLE_LUMINANCE_SIZE_SGI 0x80DE
-#define GL_COLOR_TABLE_INTENSITY_SIZE_SGI 0x80DF
-#endif
-
-#ifndef GL_SGIS_pixel_texture
-#define GL_PIXEL_TEXTURE_SGIS 0x8353
-#define GL_PIXEL_FRAGMENT_RGB_SOURCE_SGIS 0x8354
-#define GL_PIXEL_FRAGMENT_ALPHA_SOURCE_SGIS 0x8355
-#define GL_PIXEL_GROUP_COLOR_SGIS 0x8356
-#endif
-
-#ifndef GL_SGIX_pixel_texture
-#define GL_PIXEL_TEX_GEN_SGIX 0x8139
-#define GL_PIXEL_TEX_GEN_MODE_SGIX 0x832B
-#endif
-
-#ifndef GL_SGIS_texture4D
-#define GL_PACK_SKIP_VOLUMES_SGIS 0x8130
-#define GL_PACK_IMAGE_DEPTH_SGIS 0x8131
-#define GL_UNPACK_SKIP_VOLUMES_SGIS 0x8132
-#define GL_UNPACK_IMAGE_DEPTH_SGIS 0x8133
-#define GL_TEXTURE_4D_SGIS 0x8134
-#define GL_PROXY_TEXTURE_4D_SGIS 0x8135
-#define GL_TEXTURE_4DSIZE_SGIS 0x8136
-#define GL_TEXTURE_WRAP_Q_SGIS 0x8137
-#define GL_MAX_4D_TEXTURE_SIZE_SGIS 0x8138
-#define GL_TEXTURE_4D_BINDING_SGIS 0x814F
-#endif
-
-#ifndef GL_SGI_texture_color_table
-#define GL_TEXTURE_COLOR_TABLE_SGI 0x80BC
-#define GL_PROXY_TEXTURE_COLOR_TABLE_SGI 0x80BD
-#endif
-
-#ifndef GL_EXT_cmyka
-#define GL_CMYK_EXT 0x800C
-#define GL_CMYKA_EXT 0x800D
-#define GL_PACK_CMYK_HINT_EXT 0x800E
-#define GL_UNPACK_CMYK_HINT_EXT 0x800F
-#endif
-
-#ifndef GL_EXT_texture_object
-#define GL_TEXTURE_PRIORITY_EXT 0x8066
-#define GL_TEXTURE_RESIDENT_EXT 0x8067
-#define GL_TEXTURE_1D_BINDING_EXT 0x8068
-#define GL_TEXTURE_2D_BINDING_EXT 0x8069
-#define GL_TEXTURE_3D_BINDING_EXT 0x806A
-#endif
-
-#ifndef GL_SGIS_detail_texture
-#define GL_DETAIL_TEXTURE_2D_SGIS 0x8095
-#define GL_DETAIL_TEXTURE_2D_BINDING_SGIS 0x8096
-#define GL_LINEAR_DETAIL_SGIS 0x8097
-#define GL_LINEAR_DETAIL_ALPHA_SGIS 0x8098
-#define GL_LINEAR_DETAIL_COLOR_SGIS 0x8099
-#define GL_DETAIL_TEXTURE_LEVEL_SGIS 0x809A
-#define GL_DETAIL_TEXTURE_MODE_SGIS 0x809B
-#define GL_DETAIL_TEXTURE_FUNC_POINTS_SGIS 0x809C
-#endif
-
-#ifndef GL_SGIS_sharpen_texture
-#define GL_LINEAR_SHARPEN_SGIS 0x80AD
-#define GL_LINEAR_SHARPEN_ALPHA_SGIS 0x80AE
-#define GL_LINEAR_SHARPEN_COLOR_SGIS 0x80AF
-#define GL_SHARPEN_TEXTURE_FUNC_POINTS_SGIS 0x80B0
-#endif
-
-#ifndef GL_EXT_packed_pixels
-#define GL_UNSIGNED_BYTE_3_3_2_EXT 0x8032
-#define GL_UNSIGNED_SHORT_4_4_4_4_EXT 0x8033
-#define GL_UNSIGNED_SHORT_5_5_5_1_EXT 0x8034
-#define GL_UNSIGNED_INT_8_8_8_8_EXT 0x8035
-#define GL_UNSIGNED_INT_10_10_10_2_EXT 0x8036
-#endif
-
-#ifndef GL_SGIS_texture_lod
-#define GL_TEXTURE_MIN_LOD_SGIS 0x813A
-#define GL_TEXTURE_MAX_LOD_SGIS 0x813B
-#define GL_TEXTURE_BASE_LEVEL_SGIS 0x813C
-#define GL_TEXTURE_MAX_LEVEL_SGIS 0x813D
-#endif
-
-#ifndef GL_SGIS_multisample
-#define GL_MULTISAMPLE_SGIS 0x809D
-#define GL_SAMPLE_ALPHA_TO_MASK_SGIS 0x809E
-#define GL_SAMPLE_ALPHA_TO_ONE_SGIS 0x809F
-#define GL_SAMPLE_MASK_SGIS 0x80A0
-#define GL_1PASS_SGIS 0x80A1
-#define GL_2PASS_0_SGIS 0x80A2
-#define GL_2PASS_1_SGIS 0x80A3
-#define GL_4PASS_0_SGIS 0x80A4
-#define GL_4PASS_1_SGIS 0x80A5
-#define GL_4PASS_2_SGIS 0x80A6
-#define GL_4PASS_3_SGIS 0x80A7
-#define GL_SAMPLE_BUFFERS_SGIS 0x80A8
-#define GL_SAMPLES_SGIS 0x80A9
-#define GL_SAMPLE_MASK_VALUE_SGIS 0x80AA
-#define GL_SAMPLE_MASK_INVERT_SGIS 0x80AB
-#define GL_SAMPLE_PATTERN_SGIS 0x80AC
-#endif
-
-#ifndef GL_EXT_rescale_normal
-#define GL_RESCALE_NORMAL_EXT 0x803A
-#endif
-
-#ifndef GL_EXT_vertex_array
-#define GL_VERTEX_ARRAY_EXT 0x8074
-#define GL_NORMAL_ARRAY_EXT 0x8075
-#define GL_COLOR_ARRAY_EXT 0x8076
-#define GL_INDEX_ARRAY_EXT 0x8077
-#define GL_TEXTURE_COORD_ARRAY_EXT 0x8078
-#define GL_EDGE_FLAG_ARRAY_EXT 0x8079
-#define GL_VERTEX_ARRAY_SIZE_EXT 0x807A
-#define GL_VERTEX_ARRAY_TYPE_EXT 0x807B
-#define GL_VERTEX_ARRAY_STRIDE_EXT 0x807C
-#define GL_VERTEX_ARRAY_COUNT_EXT 0x807D
-#define GL_NORMAL_ARRAY_TYPE_EXT 0x807E
-#define GL_NORMAL_ARRAY_STRIDE_EXT 0x807F
-#define GL_NORMAL_ARRAY_COUNT_EXT 0x8080
-#define GL_COLOR_ARRAY_SIZE_EXT 0x8081
-#define GL_COLOR_ARRAY_TYPE_EXT 0x8082
-#define GL_COLOR_ARRAY_STRIDE_EXT 0x8083
-#define GL_COLOR_ARRAY_COUNT_EXT 0x8084
-#define GL_INDEX_ARRAY_TYPE_EXT 0x8085
-#define GL_INDEX_ARRAY_STRIDE_EXT 0x8086
-#define GL_INDEX_ARRAY_COUNT_EXT 0x8087
-#define GL_TEXTURE_COORD_ARRAY_SIZE_EXT 0x8088
-#define GL_TEXTURE_COORD_ARRAY_TYPE_EXT 0x8089
-#define GL_TEXTURE_COORD_ARRAY_STRIDE_EXT 0x808A
-#define GL_TEXTURE_COORD_ARRAY_COUNT_EXT 0x808B
-#define GL_EDGE_FLAG_ARRAY_STRIDE_EXT 0x808C
-#define GL_EDGE_FLAG_ARRAY_COUNT_EXT 0x808D
-#define GL_VERTEX_ARRAY_POINTER_EXT 0x808E
-#define GL_NORMAL_ARRAY_POINTER_EXT 0x808F
-#define GL_COLOR_ARRAY_POINTER_EXT 0x8090
-#define GL_INDEX_ARRAY_POINTER_EXT 0x8091
-#define GL_TEXTURE_COORD_ARRAY_POINTER_EXT 0x8092
-#define GL_EDGE_FLAG_ARRAY_POINTER_EXT 0x8093
-#endif
-
-#ifndef GL_EXT_misc_attribute
-#endif
-
-#ifndef GL_SGIS_generate_mipmap
-#define GL_GENERATE_MIPMAP_SGIS 0x8191
-#define GL_GENERATE_MIPMAP_HINT_SGIS 0x8192
-#endif
-
-#ifndef GL_SGIX_clipmap
-#define GL_LINEAR_CLIPMAP_LINEAR_SGIX 0x8170
-#define GL_TEXTURE_CLIPMAP_CENTER_SGIX 0x8171
-#define GL_TEXTURE_CLIPMAP_FRAME_SGIX 0x8172
-#define GL_TEXTURE_CLIPMAP_OFFSET_SGIX 0x8173
-#define GL_TEXTURE_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8174
-#define GL_TEXTURE_CLIPMAP_LOD_OFFSET_SGIX 0x8175
-#define GL_TEXTURE_CLIPMAP_DEPTH_SGIX 0x8176
-#define GL_MAX_CLIPMAP_DEPTH_SGIX 0x8177
-#define GL_MAX_CLIPMAP_VIRTUAL_DEPTH_SGIX 0x8178
-#define GL_NEAREST_CLIPMAP_NEAREST_SGIX 0x844D
-#define GL_NEAREST_CLIPMAP_LINEAR_SGIX 0x844E
-#define GL_LINEAR_CLIPMAP_NEAREST_SGIX 0x844F
-#endif
-
-#ifndef GL_SGIX_shadow
-#define GL_TEXTURE_COMPARE_SGIX 0x819A
-#define GL_TEXTURE_COMPARE_OPERATOR_SGIX 0x819B
-#define GL_TEXTURE_LEQUAL_R_SGIX 0x819C
-#define GL_TEXTURE_GEQUAL_R_SGIX 0x819D
-#endif
-
-#ifndef GL_SGIS_texture_edge_clamp
-#define GL_CLAMP_TO_EDGE_SGIS 0x812F
-#endif
-
-#ifndef GL_EXT_blend_minmax
-#define GL_FUNC_ADD_EXT 0x8006
-#define GL_MIN_EXT 0x8007
-#define GL_MAX_EXT 0x8008
-#define GL_BLEND_EQUATION_EXT 0x8009
-#endif
-
-#ifndef GL_EXT_blend_subtract
-#define GL_FUNC_SUBTRACT_EXT 0x800A
-#define GL_FUNC_REVERSE_SUBTRACT_EXT 0x800B
-#endif
-
-#ifndef GL_EXT_blend_logic_op
-#endif
-
-#ifndef GL_SGIX_interlace
-#define GL_INTERLACE_SGIX 0x8094
-#endif
-
-#ifndef GL_SGIX_pixel_tiles
-#define GL_PIXEL_TILE_BEST_ALIGNMENT_SGIX 0x813E
-#define GL_PIXEL_TILE_CACHE_INCREMENT_SGIX 0x813F
-#define GL_PIXEL_TILE_WIDTH_SGIX 0x8140
-#define GL_PIXEL_TILE_HEIGHT_SGIX 0x8141
-#define GL_PIXEL_TILE_GRID_WIDTH_SGIX 0x8142
-#define GL_PIXEL_TILE_GRID_HEIGHT_SGIX 0x8143
-#define GL_PIXEL_TILE_GRID_DEPTH_SGIX 0x8144
-#define GL_PIXEL_TILE_CACHE_SIZE_SGIX 0x8145
-#endif
-
-#ifndef GL_SGIS_texture_select
-#define GL_DUAL_ALPHA4_SGIS 0x8110
-#define GL_DUAL_ALPHA8_SGIS 0x8111
-#define GL_DUAL_ALPHA12_SGIS 0x8112
-#define GL_DUAL_ALPHA16_SGIS 0x8113
-#define GL_DUAL_LUMINANCE4_SGIS 0x8114
-#define GL_DUAL_LUMINANCE8_SGIS 0x8115
-#define GL_DUAL_LUMINANCE12_SGIS 0x8116
-#define GL_DUAL_LUMINANCE16_SGIS 0x8117
-#define GL_DUAL_INTENSITY4_SGIS 0x8118
-#define GL_DUAL_INTENSITY8_SGIS 0x8119
-#define GL_DUAL_INTENSITY12_SGIS 0x811A
-#define GL_DUAL_INTENSITY16_SGIS 0x811B
-#define GL_DUAL_LUMINANCE_ALPHA4_SGIS 0x811C
-#define GL_DUAL_LUMINANCE_ALPHA8_SGIS 0x811D
-#define GL_QUAD_ALPHA4_SGIS 0x811E
-#define GL_QUAD_ALPHA8_SGIS 0x811F
-#define GL_QUAD_LUMINANCE4_SGIS 0x8120
-#define GL_QUAD_LUMINANCE8_SGIS 0x8121
-#define GL_QUAD_INTENSITY4_SGIS 0x8122
-#define GL_QUAD_INTENSITY8_SGIS 0x8123
-#define GL_DUAL_TEXTURE_SELECT_SGIS 0x8124
-#define GL_QUAD_TEXTURE_SELECT_SGIS 0x8125
-#endif
-
-#ifndef GL_SGIX_sprite
-#define GL_SPRITE_SGIX 0x8148
-#define GL_SPRITE_MODE_SGIX 0x8149
-#define GL_SPRITE_AXIS_SGIX 0x814A
-#define GL_SPRITE_TRANSLATION_SGIX 0x814B
-#define GL_SPRITE_AXIAL_SGIX 0x814C
-#define GL_SPRITE_OBJECT_ALIGNED_SGIX 0x814D
-#define GL_SPRITE_EYE_ALIGNED_SGIX 0x814E
-#endif
-
-#ifndef GL_SGIX_texture_multi_buffer
-#define GL_TEXTURE_MULTI_BUFFER_HINT_SGIX 0x812E
-#endif
-
-#ifndef GL_EXT_point_parameters
-#define GL_POINT_SIZE_MIN_EXT 0x8126
-#define GL_POINT_SIZE_MAX_EXT 0x8127
-#define GL_POINT_FADE_THRESHOLD_SIZE_EXT 0x8128
-#define GL_DISTANCE_ATTENUATION_EXT 0x8129
-#endif
-
-#ifndef GL_SGIS_point_parameters
-#define GL_POINT_SIZE_MIN_SGIS 0x8126
-#define GL_POINT_SIZE_MAX_SGIS 0x8127
-#define GL_POINT_FADE_THRESHOLD_SIZE_SGIS 0x8128
-#define GL_DISTANCE_ATTENUATION_SGIS 0x8129
-#endif
-
-#ifndef GL_SGIX_instruments
-#define GL_INSTRUMENT_BUFFER_POINTER_SGIX 0x8180
-#define GL_INSTRUMENT_MEASUREMENTS_SGIX 0x8181
-#endif
-
-#ifndef GL_SGIX_texture_scale_bias
-#define GL_POST_TEXTURE_FILTER_BIAS_SGIX 0x8179
-#define GL_POST_TEXTURE_FILTER_SCALE_SGIX 0x817A
-#define GL_POST_TEXTURE_FILTER_BIAS_RANGE_SGIX 0x817B
-#define GL_POST_TEXTURE_FILTER_SCALE_RANGE_SGIX 0x817C
-#endif
-
-#ifndef GL_SGIX_framezoom
-#define GL_FRAMEZOOM_SGIX 0x818B
-#define GL_FRAMEZOOM_FACTOR_SGIX 0x818C
-#define GL_MAX_FRAMEZOOM_FACTOR_SGIX 0x818D
-#endif
-
-#ifndef GL_SGIX_tag_sample_buffer
-#endif
-
-#ifndef GL_FfdMaskSGIX
-#define GL_TEXTURE_DEFORMATION_BIT_SGIX 0x00000001
-#define GL_GEOMETRY_DEFORMATION_BIT_SGIX 0x00000002
-#endif
-
-#ifndef GL_SGIX_polynomial_ffd
-#define GL_GEOMETRY_DEFORMATION_SGIX 0x8194
-#define GL_TEXTURE_DEFORMATION_SGIX 0x8195
-#define GL_DEFORMATIONS_MASK_SGIX 0x8196
-#define GL_MAX_DEFORMATION_ORDER_SGIX 0x8197
-#endif
-
-#ifndef GL_SGIX_reference_plane
-#define GL_REFERENCE_PLANE_SGIX 0x817D
-#define GL_REFERENCE_PLANE_EQUATION_SGIX 0x817E
-#endif
-
-#ifndef GL_SGIX_flush_raster
-#endif
-
-#ifndef GL_SGIX_depth_texture
-#define GL_DEPTH_COMPONENT16_SGIX 0x81A5
-#define GL_DEPTH_COMPONENT24_SGIX 0x81A6
-#define GL_DEPTH_COMPONENT32_SGIX 0x81A7
-#endif
-
-#ifndef GL_SGIS_fog_function
-#define GL_FOG_FUNC_SGIS 0x812A
-#define GL_FOG_FUNC_POINTS_SGIS 0x812B
-#define GL_MAX_FOG_FUNC_POINTS_SGIS 0x812C
-#endif
-
-#ifndef GL_SGIX_fog_offset
-#define GL_FOG_OFFSET_SGIX 0x8198
-#define GL_FOG_OFFSET_VALUE_SGIX 0x8199
-#endif
-
-#ifndef GL_HP_image_transform
-#define GL_IMAGE_SCALE_X_HP 0x8155
-#define GL_IMAGE_SCALE_Y_HP 0x8156
-#define GL_IMAGE_TRANSLATE_X_HP 0x8157
-#define GL_IMAGE_TRANSLATE_Y_HP 0x8158
-#define GL_IMAGE_ROTATE_ANGLE_HP 0x8159
-#define GL_IMAGE_ROTATE_ORIGIN_X_HP 0x815A
-#define GL_IMAGE_ROTATE_ORIGIN_Y_HP 0x815B
-#define GL_IMAGE_MAG_FILTER_HP 0x815C
-#define GL_IMAGE_MIN_FILTER_HP 0x815D
-#define GL_IMAGE_CUBIC_WEIGHT_HP 0x815E
-#define GL_CUBIC_HP 0x815F
-#define GL_AVERAGE_HP 0x8160
-#define GL_IMAGE_TRANSFORM_2D_HP 0x8161
-#define GL_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8162
-#define GL_PROXY_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP 0x8163
-#endif
-
-#ifndef GL_HP_convolution_border_modes
-#define GL_IGNORE_BORDER_HP 0x8150
-#define GL_CONSTANT_BORDER_HP 0x8151
-#define GL_REPLICATE_BORDER_HP 0x8153
-#define GL_CONVOLUTION_BORDER_COLOR_HP 0x8154
-#endif
-
-#ifndef GL_INGR_palette_buffer
-#endif
-
-#ifndef GL_SGIX_texture_add_env
-#define GL_TEXTURE_ENV_BIAS_SGIX 0x80BE
-#endif
-
-#ifndef GL_EXT_color_subtable
-#endif
-
-#ifndef GL_PGI_vertex_hints
-#define GL_VERTEX_DATA_HINT_PGI 0x1A22A
-#define GL_VERTEX_CONSISTENT_HINT_PGI 0x1A22B
-#define GL_MATERIAL_SIDE_HINT_PGI 0x1A22C
-#define GL_MAX_VERTEX_HINT_PGI 0x1A22D
-#define GL_COLOR3_BIT_PGI 0x00010000
-#define GL_COLOR4_BIT_PGI 0x00020000
-#define GL_EDGEFLAG_BIT_PGI 0x00040000
-#define GL_INDEX_BIT_PGI 0x00080000
-#define GL_MAT_AMBIENT_BIT_PGI 0x00100000
-#define GL_MAT_AMBIENT_AND_DIFFUSE_BIT_PGI 0x00200000
-#define GL_MAT_DIFFUSE_BIT_PGI 0x00400000
-#define GL_MAT_EMISSION_BIT_PGI 0x00800000
-#define GL_MAT_COLOR_INDEXES_BIT_PGI 0x01000000
-#define GL_MAT_SHININESS_BIT_PGI 0x02000000
-#define GL_MAT_SPECULAR_BIT_PGI 0x04000000
-#define GL_NORMAL_BIT_PGI 0x08000000
-#define GL_TEXCOORD1_BIT_PGI 0x10000000
-#define GL_TEXCOORD2_BIT_PGI 0x20000000
-#define GL_TEXCOORD3_BIT_PGI 0x40000000
-#define GL_TEXCOORD4_BIT_PGI 0x80000000
-#define GL_VERTEX23_BIT_PGI 0x00000004
-#define GL_VERTEX4_BIT_PGI 0x00000008
-#endif
-
-#ifndef GL_PGI_misc_hints
-#define GL_PREFER_DOUBLEBUFFER_HINT_PGI 0x1A1F8
-#define GL_CONSERVE_MEMORY_HINT_PGI 0x1A1FD
-#define GL_RECLAIM_MEMORY_HINT_PGI 0x1A1FE
-#define GL_NATIVE_GRAPHICS_HANDLE_PGI 0x1A202
-#define GL_NATIVE_GRAPHICS_BEGIN_HINT_PGI 0x1A203
-#define GL_NATIVE_GRAPHICS_END_HINT_PGI 0x1A204
-#define GL_ALWAYS_FAST_HINT_PGI 0x1A20C
-#define GL_ALWAYS_SOFT_HINT_PGI 0x1A20D
-#define GL_ALLOW_DRAW_OBJ_HINT_PGI 0x1A20E
-#define GL_ALLOW_DRAW_WIN_HINT_PGI 0x1A20F
-#define GL_ALLOW_DRAW_FRG_HINT_PGI 0x1A210
-#define GL_ALLOW_DRAW_MEM_HINT_PGI 0x1A211
-#define GL_STRICT_DEPTHFUNC_HINT_PGI 0x1A216
-#define GL_STRICT_LIGHTING_HINT_PGI 0x1A217
-#define GL_STRICT_SCISSOR_HINT_PGI 0x1A218
-#define GL_FULL_STIPPLE_HINT_PGI 0x1A219
-#define GL_CLIP_NEAR_HINT_PGI 0x1A220
-#define GL_CLIP_FAR_HINT_PGI 0x1A221
-#define GL_WIDE_LINE_HINT_PGI 0x1A222
-#define GL_BACK_NORMALS_HINT_PGI 0x1A223
-#endif
-
-#ifndef GL_EXT_paletted_texture
-#define GL_COLOR_INDEX1_EXT 0x80E2
-#define GL_COLOR_INDEX2_EXT 0x80E3
-#define GL_COLOR_INDEX4_EXT 0x80E4
-#define GL_COLOR_INDEX8_EXT 0x80E5
-#define GL_COLOR_INDEX12_EXT 0x80E6
-#define GL_COLOR_INDEX16_EXT 0x80E7
-#define GL_TEXTURE_INDEX_SIZE_EXT 0x80ED
-#endif
-
-#ifndef GL_EXT_clip_volume_hint
-#define GL_CLIP_VOLUME_CLIPPING_HINT_EXT 0x80F0
-#endif
-
-#ifndef GL_SGIX_list_priority
-#define GL_LIST_PRIORITY_SGIX 0x8182
-#endif
-
-#ifndef GL_SGIX_ir_instrument1
-#define GL_IR_INSTRUMENT1_SGIX 0x817F
-#endif
-
-#ifndef GL_SGIX_calligraphic_fragment
-#define GL_CALLIGRAPHIC_FRAGMENT_SGIX 0x8183
-#endif
-
-#ifndef GL_SGIX_texture_lod_bias
-#define GL_TEXTURE_LOD_BIAS_S_SGIX 0x818E
-#define GL_TEXTURE_LOD_BIAS_T_SGIX 0x818F
-#define GL_TEXTURE_LOD_BIAS_R_SGIX 0x8190
-#endif
-
-#ifndef GL_SGIX_shadow_ambient
-#define GL_SHADOW_AMBIENT_SGIX 0x80BF
-#endif
-
-#ifndef GL_EXT_index_texture
-#endif
-
-#ifndef GL_EXT_index_material
-#define GL_INDEX_MATERIAL_EXT 0x81B8
-#define GL_INDEX_MATERIAL_PARAMETER_EXT 0x81B9
-#define GL_INDEX_MATERIAL_FACE_EXT 0x81BA
-#endif
-
-#ifndef GL_EXT_index_func
-#define GL_INDEX_TEST_EXT 0x81B5
-#define GL_INDEX_TEST_FUNC_EXT 0x81B6
-#define GL_INDEX_TEST_REF_EXT 0x81B7
-#endif
-
-#ifndef GL_EXT_index_array_formats
-#define GL_IUI_V2F_EXT 0x81AD
-#define GL_IUI_V3F_EXT 0x81AE
-#define GL_IUI_N3F_V2F_EXT 0x81AF
-#define GL_IUI_N3F_V3F_EXT 0x81B0
-#define GL_T2F_IUI_V2F_EXT 0x81B1
-#define GL_T2F_IUI_V3F_EXT 0x81B2
-#define GL_T2F_IUI_N3F_V2F_EXT 0x81B3
-#define GL_T2F_IUI_N3F_V3F_EXT 0x81B4
-#endif
-
-#ifndef GL_EXT_compiled_vertex_array
-#define GL_ARRAY_ELEMENT_LOCK_FIRST_EXT 0x81A8
-#define GL_ARRAY_ELEMENT_LOCK_COUNT_EXT 0x81A9
-#endif
-
-#ifndef GL_EXT_cull_vertex
-#define GL_CULL_VERTEX_EXT 0x81AA
-#define GL_CULL_VERTEX_EYE_POSITION_EXT 0x81AB
-#define GL_CULL_VERTEX_OBJECT_POSITION_EXT 0x81AC
-#endif
-
-#ifndef GL_SGIX_ycrcb
-#define GL_YCRCB_422_SGIX 0x81BB
-#define GL_YCRCB_444_SGIX 0x81BC
-#endif
-
-#ifndef GL_SGIX_fragment_lighting
-#define GL_FRAGMENT_LIGHTING_SGIX 0x8400
-#define GL_FRAGMENT_COLOR_MATERIAL_SGIX 0x8401
-#define GL_FRAGMENT_COLOR_MATERIAL_FACE_SGIX 0x8402
-#define GL_FRAGMENT_COLOR_MATERIAL_PARAMETER_SGIX 0x8403
-#define GL_MAX_FRAGMENT_LIGHTS_SGIX 0x8404
-#define GL_MAX_ACTIVE_LIGHTS_SGIX 0x8405
-#define GL_CURRENT_RASTER_NORMAL_SGIX 0x8406
-#define GL_LIGHT_ENV_MODE_SGIX 0x8407
-#define GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_SGIX 0x8408
-#define GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_SGIX 0x8409
-#define GL_FRAGMENT_LIGHT_MODEL_AMBIENT_SGIX 0x840A
-#define GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_SGIX 0x840B
-#define GL_FRAGMENT_LIGHT0_SGIX 0x840C
-#define GL_FRAGMENT_LIGHT1_SGIX 0x840D
-#define GL_FRAGMENT_LIGHT2_SGIX 0x840E
-#define GL_FRAGMENT_LIGHT3_SGIX 0x840F
-#define GL_FRAGMENT_LIGHT4_SGIX 0x8410
-#define GL_FRAGMENT_LIGHT5_SGIX 0x8411
-#define GL_FRAGMENT_LIGHT6_SGIX 0x8412
-#define GL_FRAGMENT_LIGHT7_SGIX 0x8413
-#endif
-
-#ifndef GL_IBM_rasterpos_clip
-#define GL_RASTER_POSITION_UNCLIPPED_IBM 0x19262
-#endif
-
-#ifndef GL_HP_texture_lighting
-#define GL_TEXTURE_LIGHTING_MODE_HP 0x8167
-#define GL_TEXTURE_POST_SPECULAR_HP 0x8168
-#define GL_TEXTURE_PRE_SPECULAR_HP 0x8169
-#endif
-
-#ifndef GL_EXT_draw_range_elements
-#define GL_MAX_ELEMENTS_VERTICES_EXT 0x80E8
-#define GL_MAX_ELEMENTS_INDICES_EXT 0x80E9
-#endif
-
-#ifndef GL_WIN_phong_shading
-#define GL_PHONG_WIN 0x80EA
-#define GL_PHONG_HINT_WIN 0x80EB
-#endif
-
-#ifndef GL_WIN_specular_fog
-#define GL_FOG_SPECULAR_TEXTURE_WIN 0x80EC
-#endif
-
-#ifndef GL_EXT_light_texture
-#define GL_FRAGMENT_MATERIAL_EXT 0x8349
-#define GL_FRAGMENT_NORMAL_EXT 0x834A
-#define GL_FRAGMENT_COLOR_EXT 0x834C
-#define GL_ATTENUATION_EXT 0x834D
-#define GL_SHADOW_ATTENUATION_EXT 0x834E
-#define GL_TEXTURE_APPLICATION_MODE_EXT 0x834F
-#define GL_TEXTURE_LIGHT_EXT 0x8350
-#define GL_TEXTURE_MATERIAL_FACE_EXT 0x8351
-#define GL_TEXTURE_MATERIAL_PARAMETER_EXT 0x8352
-/* reuse GL_FRAGMENT_DEPTH_EXT */
-#endif
-
-#ifndef GL_SGIX_blend_alpha_minmax
-#define GL_ALPHA_MIN_SGIX 0x8320
-#define GL_ALPHA_MAX_SGIX 0x8321
-#endif
-
-#ifndef GL_SGIX_impact_pixel_texture
-#define GL_PIXEL_TEX_GEN_Q_CEILING_SGIX 0x8184
-#define GL_PIXEL_TEX_GEN_Q_ROUND_SGIX 0x8185
-#define GL_PIXEL_TEX_GEN_Q_FLOOR_SGIX 0x8186
-#define GL_PIXEL_TEX_GEN_ALPHA_REPLACE_SGIX 0x8187
-#define GL_PIXEL_TEX_GEN_ALPHA_NO_REPLACE_SGIX 0x8188
-#define GL_PIXEL_TEX_GEN_ALPHA_LS_SGIX 0x8189
-#define GL_PIXEL_TEX_GEN_ALPHA_MS_SGIX 0x818A
-#endif
-
-#ifndef GL_EXT_bgra
-#define GL_BGR_EXT 0x80E0
-#define GL_BGRA_EXT 0x80E1
-#endif
-
-#ifndef GL_SGIX_async
-#define GL_ASYNC_MARKER_SGIX 0x8329
-#endif
-
-#ifndef GL_SGIX_async_pixel
-#define GL_ASYNC_TEX_IMAGE_SGIX 0x835C
-#define GL_ASYNC_DRAW_PIXELS_SGIX 0x835D
-#define GL_ASYNC_READ_PIXELS_SGIX 0x835E
-#define GL_MAX_ASYNC_TEX_IMAGE_SGIX 0x835F
-#define GL_MAX_ASYNC_DRAW_PIXELS_SGIX 0x8360
-#define GL_MAX_ASYNC_READ_PIXELS_SGIX 0x8361
-#endif
-
-#ifndef GL_SGIX_async_histogram
-#define GL_ASYNC_HISTOGRAM_SGIX 0x832C
-#define GL_MAX_ASYNC_HISTOGRAM_SGIX 0x832D
-#endif
-
-#ifndef GL_INTEL_texture_scissor
-#endif
-
-#ifndef GL_INTEL_parallel_arrays
-#define GL_PARALLEL_ARRAYS_INTEL 0x83F4
-#define GL_VERTEX_ARRAY_PARALLEL_POINTERS_INTEL 0x83F5
-#define GL_NORMAL_ARRAY_PARALLEL_POINTERS_INTEL 0x83F6
-#define GL_COLOR_ARRAY_PARALLEL_POINTERS_INTEL 0x83F7
-#define GL_TEXTURE_COORD_ARRAY_PARALLEL_POINTERS_INTEL 0x83F8
-#endif
-
-#ifndef GL_HP_occlusion_test
-#define GL_OCCLUSION_TEST_HP 0x8165
-#define GL_OCCLUSION_TEST_RESULT_HP 0x8166
-#endif
-
-#ifndef GL_EXT_pixel_transform
-#define GL_PIXEL_TRANSFORM_2D_EXT 0x8330
-#define GL_PIXEL_MAG_FILTER_EXT 0x8331
-#define GL_PIXEL_MIN_FILTER_EXT 0x8332
-#define GL_PIXEL_CUBIC_WEIGHT_EXT 0x8333
-#define GL_CUBIC_EXT 0x8334
-#define GL_AVERAGE_EXT 0x8335
-#define GL_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8336
-#define GL_MAX_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT 0x8337
-#define GL_PIXEL_TRANSFORM_2D_MATRIX_EXT 0x8338
-#endif
-
-#ifndef GL_EXT_pixel_transform_color_table
-#endif
-
-#ifndef GL_EXT_shared_texture_palette
-#define GL_SHARED_TEXTURE_PALETTE_EXT 0x81FB
-#endif
-
-#ifndef GL_EXT_separate_specular_color
-#define GL_LIGHT_MODEL_COLOR_CONTROL_EXT 0x81F8
-#define GL_SINGLE_COLOR_EXT 0x81F9
-#define GL_SEPARATE_SPECULAR_COLOR_EXT 0x81FA
-#endif
-
-#ifndef GL_EXT_secondary_color
-#define GL_COLOR_SUM_EXT 0x8458
-#define GL_CURRENT_SECONDARY_COLOR_EXT 0x8459
-#define GL_SECONDARY_COLOR_ARRAY_SIZE_EXT 0x845A
-#define GL_SECONDARY_COLOR_ARRAY_TYPE_EXT 0x845B
-#define GL_SECONDARY_COLOR_ARRAY_STRIDE_EXT 0x845C
-#define GL_SECONDARY_COLOR_ARRAY_POINTER_EXT 0x845D
-#define GL_SECONDARY_COLOR_ARRAY_EXT 0x845E
-#endif
-
-#ifndef GL_EXT_texture_perturb_normal
-#define GL_PERTURB_EXT 0x85AE
-#define GL_TEXTURE_NORMAL_EXT 0x85AF
-#endif
-
-#ifndef GL_EXT_multi_draw_arrays
-#endif
-
-#ifndef GL_EXT_fog_coord
-#define GL_FOG_COORDINATE_SOURCE_EXT 0x8450
-#define GL_FOG_COORDINATE_EXT 0x8451
-#define GL_FRAGMENT_DEPTH_EXT 0x8452
-#define GL_CURRENT_FOG_COORDINATE_EXT 0x8453
-#define GL_FOG_COORDINATE_ARRAY_TYPE_EXT 0x8454
-#define GL_FOG_COORDINATE_ARRAY_STRIDE_EXT 0x8455
-#define GL_FOG_COORDINATE_ARRAY_POINTER_EXT 0x8456
-#define GL_FOG_COORDINATE_ARRAY_EXT 0x8457
-#endif
-
-#ifndef GL_REND_screen_coordinates
-#define GL_SCREEN_COORDINATES_REND 0x8490
-#define GL_INVERTED_SCREEN_W_REND 0x8491
-#endif
-
-#ifndef GL_EXT_coordinate_frame
-#define GL_TANGENT_ARRAY_EXT 0x8439
-#define GL_BINORMAL_ARRAY_EXT 0x843A
-#define GL_CURRENT_TANGENT_EXT 0x843B
-#define GL_CURRENT_BINORMAL_EXT 0x843C
-#define GL_TANGENT_ARRAY_TYPE_EXT 0x843E
-#define GL_TANGENT_ARRAY_STRIDE_EXT 0x843F
-#define GL_BINORMAL_ARRAY_TYPE_EXT 0x8440
-#define GL_BINORMAL_ARRAY_STRIDE_EXT 0x8441
-#define GL_TANGENT_ARRAY_POINTER_EXT 0x8442
-#define GL_BINORMAL_ARRAY_POINTER_EXT 0x8443
-#define GL_MAP1_TANGENT_EXT 0x8444
-#define GL_MAP2_TANGENT_EXT 0x8445
-#define GL_MAP1_BINORMAL_EXT 0x8446
-#define GL_MAP2_BINORMAL_EXT 0x8447
-#endif
-
-#ifndef GL_EXT_texture_env_combine
-#define GL_COMBINE_EXT 0x8570
-#define GL_COMBINE_RGB_EXT 0x8571
-#define GL_COMBINE_ALPHA_EXT 0x8572
-#define GL_RGB_SCALE_EXT 0x8573
-#define GL_ADD_SIGNED_EXT 0x8574
-#define GL_INTERPOLATE_EXT 0x8575
-#define GL_CONSTANT_EXT 0x8576
-#define GL_PRIMARY_COLOR_EXT 0x8577
-#define GL_PREVIOUS_EXT 0x8578
-#define GL_SOURCE0_RGB_EXT 0x8580
-#define GL_SOURCE1_RGB_EXT 0x8581
-#define GL_SOURCE2_RGB_EXT 0x8582
-#define GL_SOURCE0_ALPHA_EXT 0x8588
-#define GL_SOURCE1_ALPHA_EXT 0x8589
-#define GL_SOURCE2_ALPHA_EXT 0x858A
-#define GL_OPERAND0_RGB_EXT 0x8590
-#define GL_OPERAND1_RGB_EXT 0x8591
-#define GL_OPERAND2_RGB_EXT 0x8592
-#define GL_OPERAND0_ALPHA_EXT 0x8598
-#define GL_OPERAND1_ALPHA_EXT 0x8599
-#define GL_OPERAND2_ALPHA_EXT 0x859A
-#endif
-
-#ifndef GL_APPLE_specular_vector
-#define GL_LIGHT_MODEL_SPECULAR_VECTOR_APPLE 0x85B0
-#endif
-
-#ifndef GL_APPLE_transform_hint
-#define GL_TRANSFORM_HINT_APPLE 0x85B1
-#endif
-
-#ifndef GL_SGIX_fog_scale
-#define GL_FOG_SCALE_SGIX 0x81FC
-#define GL_FOG_SCALE_VALUE_SGIX 0x81FD
-#endif
-
-#ifndef GL_SUNX_constant_data
-#define GL_UNPACK_CONSTANT_DATA_SUNX 0x81D5
-#define GL_TEXTURE_CONSTANT_DATA_SUNX 0x81D6
-#endif
-
-#ifndef GL_SUN_global_alpha
-#define GL_GLOBAL_ALPHA_SUN 0x81D9
-#define GL_GLOBAL_ALPHA_FACTOR_SUN 0x81DA
-#endif
-
-#ifndef GL_SUN_triangle_list
-#define GL_RESTART_SUN 0x0001
-#define GL_REPLACE_MIDDLE_SUN 0x0002
-#define GL_REPLACE_OLDEST_SUN 0x0003
-#define GL_TRIANGLE_LIST_SUN 0x81D7
-#define GL_REPLACEMENT_CODE_SUN 0x81D8
-#define GL_REPLACEMENT_CODE_ARRAY_SUN 0x85C0
-#define GL_REPLACEMENT_CODE_ARRAY_TYPE_SUN 0x85C1
-#define GL_REPLACEMENT_CODE_ARRAY_STRIDE_SUN 0x85C2
-#define GL_REPLACEMENT_CODE_ARRAY_POINTER_SUN 0x85C3
-#define GL_R1UI_V3F_SUN 0x85C4
-#define GL_R1UI_C4UB_V3F_SUN 0x85C5
-#define GL_R1UI_C3F_V3F_SUN 0x85C6
-#define GL_R1UI_N3F_V3F_SUN 0x85C7
-#define GL_R1UI_C4F_N3F_V3F_SUN 0x85C8
-#define GL_R1UI_T2F_V3F_SUN 0x85C9
-#define GL_R1UI_T2F_N3F_V3F_SUN 0x85CA
-#define GL_R1UI_T2F_C4F_N3F_V3F_SUN 0x85CB
-#endif
-
-#ifndef GL_SUN_vertex
-#endif
-
-#ifndef GL_EXT_blend_func_separate
-#define GL_BLEND_DST_RGB_EXT 0x80C8
-#define GL_BLEND_SRC_RGB_EXT 0x80C9
-#define GL_BLEND_DST_ALPHA_EXT 0x80CA
-#define GL_BLEND_SRC_ALPHA_EXT 0x80CB
-#endif
-
-#ifndef GL_INGR_color_clamp
-#define GL_RED_MIN_CLAMP_INGR 0x8560
-#define GL_GREEN_MIN_CLAMP_INGR 0x8561
-#define GL_BLUE_MIN_CLAMP_INGR 0x8562
-#define GL_ALPHA_MIN_CLAMP_INGR 0x8563
-#define GL_RED_MAX_CLAMP_INGR 0x8564
-#define GL_GREEN_MAX_CLAMP_INGR 0x8565
-#define GL_BLUE_MAX_CLAMP_INGR 0x8566
-#define GL_ALPHA_MAX_CLAMP_INGR 0x8567
-#endif
-
-#ifndef GL_INGR_interlace_read
-#define GL_INTERLACE_READ_INGR 0x8568
-#endif
-
-#ifndef GL_EXT_stencil_wrap
-#define GL_INCR_WRAP_EXT 0x8507
-#define GL_DECR_WRAP_EXT 0x8508
-#endif
-
-#ifndef GL_EXT_422_pixels
-#define GL_422_EXT 0x80CC
-#define GL_422_REV_EXT 0x80CD
-#define GL_422_AVERAGE_EXT 0x80CE
-#define GL_422_REV_AVERAGE_EXT 0x80CF
-#endif
-
-#ifndef GL_NV_texgen_reflection
-#define GL_NORMAL_MAP_NV 0x8511
-#define GL_REFLECTION_MAP_NV 0x8512
-#endif
-
-#ifndef GL_EXT_texture_cube_map
-#define GL_NORMAL_MAP_EXT 0x8511
-#define GL_REFLECTION_MAP_EXT 0x8512
-#define GL_TEXTURE_CUBE_MAP_EXT 0x8513
-#define GL_TEXTURE_BINDING_CUBE_MAP_EXT 0x8514
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_X_EXT 0x8515
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_X_EXT 0x8516
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_Y_EXT 0x8517
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_EXT 0x8518
-#define GL_TEXTURE_CUBE_MAP_POSITIVE_Z_EXT 0x8519
-#define GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_EXT 0x851A
-#define GL_PROXY_TEXTURE_CUBE_MAP_EXT 0x851B
-#define GL_MAX_CUBE_MAP_TEXTURE_SIZE_EXT 0x851C
-#endif
-
-#ifndef GL_SUN_convolution_border_modes
-#define GL_WRAP_BORDER_SUN 0x81D4
-#endif
-
-#ifndef GL_EXT_texture_env_add
-#endif
-
-#ifndef GL_EXT_texture_lod_bias
-#define GL_MAX_TEXTURE_LOD_BIAS_EXT 0x84FD
-#define GL_TEXTURE_FILTER_CONTROL_EXT 0x8500
-#define GL_TEXTURE_LOD_BIAS_EXT 0x8501
-#endif
-
-#ifndef GL_EXT_texture_filter_anisotropic
-#define GL_TEXTURE_MAX_ANISOTROPY_EXT 0x84FE
-#define GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT 0x84FF
-#endif
-
-#ifndef GL_EXT_vertex_weighting
-#define GL_MODELVIEW0_STACK_DEPTH_EXT GL_MODELVIEW_STACK_DEPTH
-#define GL_MODELVIEW1_STACK_DEPTH_EXT 0x8502
-#define GL_MODELVIEW0_MATRIX_EXT GL_MODELVIEW_MATRIX
-#define GL_MODELVIEW1_MATRIX_EXT 0x8506
-#define GL_VERTEX_WEIGHTING_EXT 0x8509
-#define GL_MODELVIEW0_EXT GL_MODELVIEW
-#define GL_MODELVIEW1_EXT 0x850A
-#define GL_CURRENT_VERTEX_WEIGHT_EXT 0x850B
-#define GL_VERTEX_WEIGHT_ARRAY_EXT 0x850C
-#define GL_VERTEX_WEIGHT_ARRAY_SIZE_EXT 0x850D
-#define GL_VERTEX_WEIGHT_ARRAY_TYPE_EXT 0x850E
-#define GL_VERTEX_WEIGHT_ARRAY_STRIDE_EXT 0x850F
-#define GL_VERTEX_WEIGHT_ARRAY_POINTER_EXT 0x8510
-#endif
-
-#ifndef GL_NV_light_max_exponent
-#define GL_MAX_SHININESS_NV 0x8504
-#define GL_MAX_SPOT_EXPONENT_NV 0x8505
-#endif
-
-#ifndef GL_NV_vertex_array_range
-#define GL_VERTEX_ARRAY_RANGE_NV 0x851D
-#define GL_VERTEX_ARRAY_RANGE_LENGTH_NV 0x851E
-#define GL_VERTEX_ARRAY_RANGE_VALID_NV 0x851F
-#define GL_MAX_VERTEX_ARRAY_RANGE_ELEMENT_NV 0x8520
-#define GL_VERTEX_ARRAY_RANGE_POINTER_NV 0x8521
-#endif
-
-#ifndef GL_NV_register_combiners
-#define GL_REGISTER_COMBINERS_NV 0x8522
-#define GL_VARIABLE_A_NV 0x8523
-#define GL_VARIABLE_B_NV 0x8524
-#define GL_VARIABLE_C_NV 0x8525
-#define GL_VARIABLE_D_NV 0x8526
-#define GL_VARIABLE_E_NV 0x8527
-#define GL_VARIABLE_F_NV 0x8528
-#define GL_VARIABLE_G_NV 0x8529
-#define GL_CONSTANT_COLOR0_NV 0x852A
-#define GL_CONSTANT_COLOR1_NV 0x852B
-#define GL_PRIMARY_COLOR_NV 0x852C
-#define GL_SECONDARY_COLOR_NV 0x852D
-#define GL_SPARE0_NV 0x852E
-#define GL_SPARE1_NV 0x852F
-#define GL_DISCARD_NV 0x8530
-#define GL_E_TIMES_F_NV 0x8531
-#define GL_SPARE0_PLUS_SECONDARY_COLOR_NV 0x8532
-#define GL_UNSIGNED_IDENTITY_NV 0x8536
-#define GL_UNSIGNED_INVERT_NV 0x8537
-#define GL_EXPAND_NORMAL_NV 0x8538
-#define GL_EXPAND_NEGATE_NV 0x8539
-#define GL_HALF_BIAS_NORMAL_NV 0x853A
-#define GL_HALF_BIAS_NEGATE_NV 0x853B
-#define GL_SIGNED_IDENTITY_NV 0x853C
-#define GL_SIGNED_NEGATE_NV 0x853D
-#define GL_SCALE_BY_TWO_NV 0x853E
-#define GL_SCALE_BY_FOUR_NV 0x853F
-#define GL_SCALE_BY_ONE_HALF_NV 0x8540
-#define GL_BIAS_BY_NEGATIVE_ONE_HALF_NV 0x8541
-#define GL_COMBINER_INPUT_NV 0x8542
-#define GL_COMBINER_MAPPING_NV 0x8543
-#define GL_COMBINER_COMPONENT_USAGE_NV 0x8544
-#define GL_COMBINER_AB_DOT_PRODUCT_NV 0x8545
-#define GL_COMBINER_CD_DOT_PRODUCT_NV 0x8546
-#define GL_COMBINER_MUX_SUM_NV 0x8547
-#define GL_COMBINER_SCALE_NV 0x8548
-#define GL_COMBINER_BIAS_NV 0x8549
-#define GL_COMBINER_AB_OUTPUT_NV 0x854A
-#define GL_COMBINER_CD_OUTPUT_NV 0x854B
-#define GL_COMBINER_SUM_OUTPUT_NV 0x854C
-#define GL_MAX_GENERAL_COMBINERS_NV 0x854D
-#define GL_NUM_GENERAL_COMBINERS_NV 0x854E
-#define GL_COLOR_SUM_CLAMP_NV 0x854F
-#define GL_COMBINER0_NV 0x8550
-#define GL_COMBINER1_NV 0x8551
-#define GL_COMBINER2_NV 0x8552
-#define GL_COMBINER3_NV 0x8553
-#define GL_COMBINER4_NV 0x8554
-#define GL_COMBINER5_NV 0x8555
-#define GL_COMBINER6_NV 0x8556
-#define GL_COMBINER7_NV 0x8557
-/* reuse GL_TEXTURE0_ARB */
-/* reuse GL_TEXTURE1_ARB */
-/* reuse GL_ZERO */
-/* reuse GL_NONE */
-/* reuse GL_FOG */
-#endif
-
-#ifndef GL_NV_fog_distance
-#define GL_FOG_DISTANCE_MODE_NV 0x855A
-#define GL_EYE_RADIAL_NV 0x855B
-#define GL_EYE_PLANE_ABSOLUTE_NV 0x855C
-/* reuse GL_EYE_PLANE */
-#endif
-
-#ifndef GL_NV_texgen_emboss
-#define GL_EMBOSS_LIGHT_NV 0x855D
-#define GL_EMBOSS_CONSTANT_NV 0x855E
-#define GL_EMBOSS_MAP_NV 0x855F
-#endif
-
-#ifndef GL_NV_blend_square
-#endif
-
-#ifndef GL_NV_texture_env_combine4
-#define GL_COMBINE4_NV 0x8503
-#define GL_SOURCE3_RGB_NV 0x8583
-#define GL_SOURCE3_ALPHA_NV 0x858B
-#define GL_OPERAND3_RGB_NV 0x8593
-#define GL_OPERAND3_ALPHA_NV 0x859B
-#endif
-
-#ifndef GL_MESA_resize_buffers
-#endif
-
-#ifndef GL_MESA_window_pos
-#endif
-
-#ifndef GL_EXT_texture_compression_s3tc
-#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT 0x83F0
-#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT 0x83F1
-#define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT 0x83F2
-#define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT 0x83F3
-#endif
-
-#ifndef GL_IBM_cull_vertex
-#define GL_CULL_VERTEX_IBM 103050
-#endif
-
-#ifndef GL_IBM_multimode_draw_arrays
-#endif
-
-#ifndef GL_IBM_vertex_array_lists
-#define GL_VERTEX_ARRAY_LIST_IBM 103070
-#define GL_NORMAL_ARRAY_LIST_IBM 103071
-#define GL_COLOR_ARRAY_LIST_IBM 103072
-#define GL_INDEX_ARRAY_LIST_IBM 103073
-#define GL_TEXTURE_COORD_ARRAY_LIST_IBM 103074
-#define GL_EDGE_FLAG_ARRAY_LIST_IBM 103075
-#define GL_FOG_COORDINATE_ARRAY_LIST_IBM 103076
-#define GL_SECONDARY_COLOR_ARRAY_LIST_IBM 103077
-#define GL_VERTEX_ARRAY_LIST_STRIDE_IBM 103080
-#define GL_NORMAL_ARRAY_LIST_STRIDE_IBM 103081
-#define GL_COLOR_ARRAY_LIST_STRIDE_IBM 103082
-#define GL_INDEX_ARRAY_LIST_STRIDE_IBM 103083
-#define GL_TEXTURE_COORD_ARRAY_LIST_STRIDE_IBM 103084
-#define GL_EDGE_FLAG_ARRAY_LIST_STRIDE_IBM 103085
-#define GL_FOG_COORDINATE_ARRAY_LIST_STRIDE_IBM 103086
-#define GL_SECONDARY_COLOR_ARRAY_LIST_STRIDE_IBM 103087
-#endif
-
-#ifndef GL_SGIX_subsample
-#define GL_PACK_SUBSAMPLE_RATE_SGIX 0x85A0
-#define GL_UNPACK_SUBSAMPLE_RATE_SGIX 0x85A1
-#define GL_PIXEL_SUBSAMPLE_4444_SGIX 0x85A2
-#define GL_PIXEL_SUBSAMPLE_2424_SGIX 0x85A3
-#define GL_PIXEL_SUBSAMPLE_4242_SGIX 0x85A4
-#endif
-
-#ifndef GL_SGIX_ycrcb_subsample
-#endif
-
-#ifndef GL_SGIX_ycrcba
-#define GL_YCRCB_SGIX 0x8318
-#define GL_YCRCBA_SGIX 0x8319
-#endif
-
-#ifndef GL_SGI_depth_pass_instrument
-#define GL_DEPTH_PASS_INSTRUMENT_SGIX 0x8310
-#define GL_DEPTH_PASS_INSTRUMENT_COUNTERS_SGIX 0x8311
-#define GL_DEPTH_PASS_INSTRUMENT_MAX_SGIX 0x8312
-#endif
-
-#ifndef GL_3DFX_texture_compression_FXT1
-#define GL_COMPRESSED_RGB_FXT1_3DFX 0x86B0
-#define GL_COMPRESSED_RGBA_FXT1_3DFX 0x86B1
-#endif
-
-#ifndef GL_3DFX_multisample
-#define GL_MULTISAMPLE_3DFX 0x86B2
-#define GL_SAMPLE_BUFFERS_3DFX 0x86B3
-#define GL_SAMPLES_3DFX 0x86B4
-#define GL_MULTISAMPLE_BIT_3DFX 0x20000000
-#endif
-
-#ifndef GL_3DFX_tbuffer
-#endif
-
-#ifndef GL_EXT_multisample
-#define GL_MULTISAMPLE_EXT 0x809D
-#define GL_SAMPLE_ALPHA_TO_MASK_EXT 0x809E
-#define GL_SAMPLE_ALPHA_TO_ONE_EXT 0x809F
-#define GL_SAMPLE_MASK_EXT 0x80A0
-#define GL_1PASS_EXT 0x80A1
-#define GL_2PASS_0_EXT 0x80A2
-#define GL_2PASS_1_EXT 0x80A3
-#define GL_4PASS_0_EXT 0x80A4
-#define GL_4PASS_1_EXT 0x80A5
-#define GL_4PASS_2_EXT 0x80A6
-#define GL_4PASS_3_EXT 0x80A7
-#define GL_SAMPLE_BUFFERS_EXT 0x80A8
-#define GL_SAMPLES_EXT 0x80A9
-#define GL_SAMPLE_MASK_VALUE_EXT 0x80AA
-#define GL_SAMPLE_MASK_INVERT_EXT 0x80AB
-#define GL_SAMPLE_PATTERN_EXT 0x80AC
-#define GL_MULTISAMPLE_BIT_EXT 0x20000000
-#endif
-
-#ifndef GL_SGIX_vertex_preclip
-#define GL_VERTEX_PRECLIP_SGIX 0x83EE
-#define GL_VERTEX_PRECLIP_HINT_SGIX 0x83EF
-#endif
-
-#ifndef GL_SGIX_convolution_accuracy
-#define GL_CONVOLUTION_HINT_SGIX 0x8316
-#endif
-
-#ifndef GL_SGIX_resample
-#define GL_PACK_RESAMPLE_SGIX 0x842C
-#define GL_UNPACK_RESAMPLE_SGIX 0x842D
-#define GL_RESAMPLE_REPLICATE_SGIX 0x842E
-#define GL_RESAMPLE_ZERO_FILL_SGIX 0x842F
-#define GL_RESAMPLE_DECIMATE_SGIX 0x8430
-#endif
-
-#ifndef GL_SGIS_point_line_texgen
-#define GL_EYE_DISTANCE_TO_POINT_SGIS 0x81F0
-#define GL_OBJECT_DISTANCE_TO_POINT_SGIS 0x81F1
-#define GL_EYE_DISTANCE_TO_LINE_SGIS 0x81F2
-#define GL_OBJECT_DISTANCE_TO_LINE_SGIS 0x81F3
-#define GL_EYE_POINT_SGIS 0x81F4
-#define GL_OBJECT_POINT_SGIS 0x81F5
-#define GL_EYE_LINE_SGIS 0x81F6
-#define GL_OBJECT_LINE_SGIS 0x81F7
-#endif
-
-#ifndef GL_SGIS_texture_color_mask
-#define GL_TEXTURE_COLOR_WRITEMASK_SGIS 0x81EF
-#endif
-
-#ifndef GL_EXT_texture_env_dot3
-#define GL_DOT3_RGB_EXT 0x8740
-#define GL_DOT3_RGBA_EXT 0x8741
-#endif
-
-#ifndef GL_ATI_texture_mirror_once
-#define GL_MIRROR_CLAMP_ATI 0x8742
-#define GL_MIRROR_CLAMP_TO_EDGE_ATI 0x8743
-#endif
-
-#ifndef GL_NV_fence
-#define GL_ALL_COMPLETED_NV 0x84F2
-#define GL_FENCE_STATUS_NV 0x84F3
-#define GL_FENCE_CONDITION_NV 0x84F4
-#endif
-
-#ifndef GL_IBM_texture_mirrored_repeat
-#define GL_MIRRORED_REPEAT_IBM 0x8370
-#endif
-
-#ifndef GL_NV_evaluators
-#define GL_EVAL_2D_NV 0x86C0
-#define GL_EVAL_TRIANGULAR_2D_NV 0x86C1
-#define GL_MAP_TESSELLATION_NV 0x86C2
-#define GL_MAP_ATTRIB_U_ORDER_NV 0x86C3
-#define GL_MAP_ATTRIB_V_ORDER_NV 0x86C4
-#define GL_EVAL_FRACTIONAL_TESSELLATION_NV 0x86C5
-#define GL_EVAL_VERTEX_ATTRIB0_NV 0x86C6
-#define GL_EVAL_VERTEX_ATTRIB1_NV 0x86C7
-#define GL_EVAL_VERTEX_ATTRIB2_NV 0x86C8
-#define GL_EVAL_VERTEX_ATTRIB3_NV 0x86C9
-#define GL_EVAL_VERTEX_ATTRIB4_NV 0x86CA
-#define GL_EVAL_VERTEX_ATTRIB5_NV 0x86CB
-#define GL_EVAL_VERTEX_ATTRIB6_NV 0x86CC
-#define GL_EVAL_VERTEX_ATTRIB7_NV 0x86CD
-#define GL_EVAL_VERTEX_ATTRIB8_NV 0x86CE
-#define GL_EVAL_VERTEX_ATTRIB9_NV 0x86CF
-#define GL_EVAL_VERTEX_ATTRIB10_NV 0x86D0
-#define GL_EVAL_VERTEX_ATTRIB11_NV 0x86D1
-#define GL_EVAL_VERTEX_ATTRIB12_NV 0x86D2
-#define GL_EVAL_VERTEX_ATTRIB13_NV 0x86D3
-#define GL_EVAL_VERTEX_ATTRIB14_NV 0x86D4
-#define GL_EVAL_VERTEX_ATTRIB15_NV 0x86D5
-#define GL_MAX_MAP_TESSELLATION_NV 0x86D6
-#define GL_MAX_RATIONAL_EVAL_ORDER_NV 0x86D7
-#endif
-
-#ifndef GL_NV_packed_depth_stencil
-#define GL_DEPTH_STENCIL_NV 0x84F9
-#define GL_UNSIGNED_INT_24_8_NV 0x84FA
-#endif
-
-#ifndef GL_NV_register_combiners2
-#define GL_PER_STAGE_CONSTANTS_NV 0x8535
-#endif
-
-#ifndef GL_NV_texture_compression_vtc
-#endif
-
-#ifndef GL_NV_texture_rectangle
-#define GL_TEXTURE_RECTANGLE_NV 0x84F5
-#define GL_TEXTURE_BINDING_RECTANGLE_NV 0x84F6
-#define GL_PROXY_TEXTURE_RECTANGLE_NV 0x84F7
-#define GL_MAX_RECTANGLE_TEXTURE_SIZE_NV 0x84F8
-#endif
-
-#ifndef GL_NV_texture_shader
-#define GL_OFFSET_TEXTURE_RECTANGLE_NV 0x864C
-#define GL_OFFSET_TEXTURE_RECTANGLE_SCALE_NV 0x864D
-#define GL_DOT_PRODUCT_TEXTURE_RECTANGLE_NV 0x864E
-#define GL_RGBA_UNSIGNED_DOT_PRODUCT_MAPPING_NV 0x86D9
-#define GL_UNSIGNED_INT_S8_S8_8_8_NV 0x86DA
-#define GL_UNSIGNED_INT_8_8_S8_S8_REV_NV 0x86DB
-#define GL_DSDT_MAG_INTENSITY_NV 0x86DC
-#define GL_SHADER_CONSISTENT_NV 0x86DD
-#define GL_TEXTURE_SHADER_NV 0x86DE
-#define GL_SHADER_OPERATION_NV 0x86DF
-#define GL_CULL_MODES_NV 0x86E0
-#define GL_OFFSET_TEXTURE_MATRIX_NV 0x86E1
-#define GL_OFFSET_TEXTURE_SCALE_NV 0x86E2
-#define GL_OFFSET_TEXTURE_BIAS_NV 0x86E3
-#define GL_OFFSET_TEXTURE_2D_MATRIX_NV GL_OFFSET_TEXTURE_MATRIX_NV
-#define GL_OFFSET_TEXTURE_2D_SCALE_NV GL_OFFSET_TEXTURE_SCALE_NV
-#define GL_OFFSET_TEXTURE_2D_BIAS_NV GL_OFFSET_TEXTURE_BIAS_NV
-#define GL_PREVIOUS_TEXTURE_INPUT_NV 0x86E4
-#define GL_CONST_EYE_NV 0x86E5
-#define GL_PASS_THROUGH_NV 0x86E6
-#define GL_CULL_FRAGMENT_NV 0x86E7
-#define GL_OFFSET_TEXTURE_2D_NV 0x86E8
-#define GL_DEPENDENT_AR_TEXTURE_2D_NV 0x86E9
-#define GL_DEPENDENT_GB_TEXTURE_2D_NV 0x86EA
-#define GL_DOT_PRODUCT_NV 0x86EC
-#define GL_DOT_PRODUCT_DEPTH_REPLACE_NV 0x86ED
-#define GL_DOT_PRODUCT_TEXTURE_2D_NV 0x86EE
-#define GL_DOT_PRODUCT_TEXTURE_CUBE_MAP_NV 0x86F0
-#define GL_DOT_PRODUCT_DIFFUSE_CUBE_MAP_NV 0x86F1
-#define GL_DOT_PRODUCT_REFLECT_CUBE_MAP_NV 0x86F2
-#define GL_DOT_PRODUCT_CONST_EYE_REFLECT_CUBE_MAP_NV 0x86F3
-#define GL_HILO_NV 0x86F4
-#define GL_DSDT_NV 0x86F5
-#define GL_DSDT_MAG_NV 0x86F6
-#define GL_DSDT_MAG_VIB_NV 0x86F7
-#define GL_HILO16_NV 0x86F8
-#define GL_SIGNED_HILO_NV 0x86F9
-#define GL_SIGNED_HILO16_NV 0x86FA
-#define GL_SIGNED_RGBA_NV 0x86FB
-#define GL_SIGNED_RGBA8_NV 0x86FC
-#define GL_SIGNED_RGB_NV 0x86FE
-#define GL_SIGNED_RGB8_NV 0x86FF
-#define GL_SIGNED_LUMINANCE_NV 0x8701
-#define GL_SIGNED_LUMINANCE8_NV 0x8702
-#define GL_SIGNED_LUMINANCE_ALPHA_NV 0x8703
-#define GL_SIGNED_LUMINANCE8_ALPHA8_NV 0x8704
-#define GL_SIGNED_ALPHA_NV 0x8705
-#define GL_SIGNED_ALPHA8_NV 0x8706
-#define GL_SIGNED_INTENSITY_NV 0x8707
-#define GL_SIGNED_INTENSITY8_NV 0x8708
-#define GL_DSDT8_NV 0x8709
-#define GL_DSDT8_MAG8_NV 0x870A
-#define GL_DSDT8_MAG8_INTENSITY8_NV 0x870B
-#define GL_SIGNED_RGB_UNSIGNED_ALPHA_NV 0x870C
-#define GL_SIGNED_RGB8_UNSIGNED_ALPHA8_NV 0x870D
-#define GL_HI_SCALE_NV 0x870E
-#define GL_LO_SCALE_NV 0x870F
-#define GL_DS_SCALE_NV 0x8710
-#define GL_DT_SCALE_NV 0x8711
-#define GL_MAGNITUDE_SCALE_NV 0x8712
-#define GL_VIBRANCE_SCALE_NV 0x8713
-#define GL_HI_BIAS_NV 0x8714
-#define GL_LO_BIAS_NV 0x8715
-#define GL_DS_BIAS_NV 0x8716
-#define GL_DT_BIAS_NV 0x8717
-#define GL_MAGNITUDE_BIAS_NV 0x8718
-#define GL_VIBRANCE_BIAS_NV 0x8719
-#define GL_TEXTURE_BORDER_VALUES_NV 0x871A
-#define GL_TEXTURE_HI_SIZE_NV 0x871B
-#define GL_TEXTURE_LO_SIZE_NV 0x871C
-#define GL_TEXTURE_DS_SIZE_NV 0x871D
-#define GL_TEXTURE_DT_SIZE_NV 0x871E
-#define GL_TEXTURE_MAG_SIZE_NV 0x871F
-#endif
-
-#ifndef GL_NV_texture_shader2
-#define GL_DOT_PRODUCT_TEXTURE_3D_NV 0x86EF
-#endif
-
-#ifndef GL_NV_vertex_array_range2
-#define GL_VERTEX_ARRAY_RANGE_WITHOUT_FLUSH_NV 0x8533
-#endif
-
-#ifndef GL_NV_vertex_program
-#define GL_VERTEX_PROGRAM_NV 0x8620
-#define GL_VERTEX_STATE_PROGRAM_NV 0x8621
-#define GL_ATTRIB_ARRAY_SIZE_NV 0x8623
-#define GL_ATTRIB_ARRAY_STRIDE_NV 0x8624
-#define GL_ATTRIB_ARRAY_TYPE_NV 0x8625
-#define GL_CURRENT_ATTRIB_NV 0x8626
-#define GL_PROGRAM_LENGTH_NV 0x8627
-#define GL_PROGRAM_STRING_NV 0x8628
-#define GL_MODELVIEW_PROJECTION_NV 0x8629
-#define GL_IDENTITY_NV 0x862A
-#define GL_INVERSE_NV 0x862B
-#define GL_TRANSPOSE_NV 0x862C
-#define GL_INVERSE_TRANSPOSE_NV 0x862D
-#define GL_MAX_TRACK_MATRIX_STACK_DEPTH_NV 0x862E
-#define GL_MAX_TRACK_MATRICES_NV 0x862F
-#define GL_MATRIX0_NV 0x8630
-#define GL_MATRIX1_NV 0x8631
-#define GL_MATRIX2_NV 0x8632
-#define GL_MATRIX3_NV 0x8633
-#define GL_MATRIX4_NV 0x8634
-#define GL_MATRIX5_NV 0x8635
-#define GL_MATRIX6_NV 0x8636
-#define GL_MATRIX7_NV 0x8637
-#define GL_CURRENT_MATRIX_STACK_DEPTH_NV 0x8640
-#define GL_CURRENT_MATRIX_NV 0x8641
-#define GL_VERTEX_PROGRAM_POINT_SIZE_NV 0x8642
-#define GL_VERTEX_PROGRAM_TWO_SIDE_NV 0x8643
-#define GL_PROGRAM_PARAMETER_NV 0x8644
-#define GL_ATTRIB_ARRAY_POINTER_NV 0x8645
-#define GL_PROGRAM_TARGET_NV 0x8646
-#define GL_PROGRAM_RESIDENT_NV 0x8647
-#define GL_TRACK_MATRIX_NV 0x8648
-#define GL_TRACK_MATRIX_TRANSFORM_NV 0x8649
-#define GL_VERTEX_PROGRAM_BINDING_NV 0x864A
-#define GL_PROGRAM_ERROR_POSITION_NV 0x864B
-#define GL_VERTEX_ATTRIB_ARRAY0_NV 0x8650
-#define GL_VERTEX_ATTRIB_ARRAY1_NV 0x8651
-#define GL_VERTEX_ATTRIB_ARRAY2_NV 0x8652
-#define GL_VERTEX_ATTRIB_ARRAY3_NV 0x8653
-#define GL_VERTEX_ATTRIB_ARRAY4_NV 0x8654
-#define GL_VERTEX_ATTRIB_ARRAY5_NV 0x8655
-#define GL_VERTEX_ATTRIB_ARRAY6_NV 0x8656
-#define GL_VERTEX_ATTRIB_ARRAY7_NV 0x8657
-#define GL_VERTEX_ATTRIB_ARRAY8_NV 0x8658
-#define GL_VERTEX_ATTRIB_ARRAY9_NV 0x8659
-#define GL_VERTEX_ATTRIB_ARRAY10_NV 0x865A
-#define GL_VERTEX_ATTRIB_ARRAY11_NV 0x865B
-#define GL_VERTEX_ATTRIB_ARRAY12_NV 0x865C
-#define GL_VERTEX_ATTRIB_ARRAY13_NV 0x865D
-#define GL_VERTEX_ATTRIB_ARRAY14_NV 0x865E
-#define GL_VERTEX_ATTRIB_ARRAY15_NV 0x865F
-#define GL_MAP1_VERTEX_ATTRIB0_4_NV 0x8660
-#define GL_MAP1_VERTEX_ATTRIB1_4_NV 0x8661
-#define GL_MAP1_VERTEX_ATTRIB2_4_NV 0x8662
-#define GL_MAP1_VERTEX_ATTRIB3_4_NV 0x8663
-#define GL_MAP1_VERTEX_ATTRIB4_4_NV 0x8664
-#define GL_MAP1_VERTEX_ATTRIB5_4_NV 0x8665
-#define GL_MAP1_VERTEX_ATTRIB6_4_NV 0x8666
-#define GL_MAP1_VERTEX_ATTRIB7_4_NV 0x8667
-#define GL_MAP1_VERTEX_ATTRIB8_4_NV 0x8668
-#define GL_MAP1_VERTEX_ATTRIB9_4_NV 0x8669
-#define GL_MAP1_VERTEX_ATTRIB10_4_NV 0x866A
-#define GL_MAP1_VERTEX_ATTRIB11_4_NV 0x866B
-#define GL_MAP1_VERTEX_ATTRIB12_4_NV 0x866C
-#define GL_MAP1_VERTEX_ATTRIB13_4_NV 0x866D
-#define GL_MAP1_VERTEX_ATTRIB14_4_NV 0x866E
-#define GL_MAP1_VERTEX_ATTRIB15_4_NV 0x866F
-#define GL_MAP2_VERTEX_ATTRIB0_4_NV 0x8670
-#define GL_MAP2_VERTEX_ATTRIB1_4_NV 0x8671
-#define GL_MAP2_VERTEX_ATTRIB2_4_NV 0x8672
-#define GL_MAP2_VERTEX_ATTRIB3_4_NV 0x8673
-#define GL_MAP2_VERTEX_ATTRIB4_4_NV 0x8674
-#define GL_MAP2_VERTEX_ATTRIB5_4_NV 0x8675
-#define GL_MAP2_VERTEX_ATTRIB6_4_NV 0x8676
-#define GL_MAP2_VERTEX_ATTRIB7_4_NV 0x8677
-#define GL_MAP2_VERTEX_ATTRIB8_4_NV 0x8678
-#define GL_MAP2_VERTEX_ATTRIB9_4_NV 0x8679
-#define GL_MAP2_VERTEX_ATTRIB10_4_NV 0x867A
-#define GL_MAP2_VERTEX_ATTRIB11_4_NV 0x867B
-#define GL_MAP2_VERTEX_ATTRIB12_4_NV 0x867C
-#define GL_MAP2_VERTEX_ATTRIB13_4_NV 0x867D
-#define GL_MAP2_VERTEX_ATTRIB14_4_NV 0x867E
-#define GL_MAP2_VERTEX_ATTRIB15_4_NV 0x867F
-#endif
-
-#ifndef GL_SGIX_texture_coordinate_clamp
-#define GL_TEXTURE_MAX_CLAMP_S_SGIX 0x8369
-#define GL_TEXTURE_MAX_CLAMP_T_SGIX 0x836A
-#define GL_TEXTURE_MAX_CLAMP_R_SGIX 0x836B
-#endif
-
-#ifndef GL_SGIX_scalebias_hint
-#define GL_SCALEBIAS_HINT_SGIX 0x8322
-#endif
-
-#ifndef GL_OML_interlace
-#define GL_INTERLACE_OML 0x8980
-#define GL_INTERLACE_READ_OML 0x8981
-#endif
-
-#ifndef GL_OML_subsample
-#define GL_FORMAT_SUBSAMPLE_24_24_OML 0x8982
-#define GL_FORMAT_SUBSAMPLE_244_244_OML 0x8983
-#endif
-
-#ifndef GL_OML_resample
-#define GL_PACK_RESAMPLE_OML 0x8984
-#define GL_UNPACK_RESAMPLE_OML 0x8985
-#define GL_RESAMPLE_REPLICATE_OML 0x8986
-#define GL_RESAMPLE_ZERO_FILL_OML 0x8987
-#define GL_RESAMPLE_AVERAGE_OML 0x8988
-#define GL_RESAMPLE_DECIMATE_OML 0x8989
-#endif
-
-#ifndef GL_NV_copy_depth_to_color
-#define GL_DEPTH_STENCIL_TO_RGBA_NV 0x886E
-#define GL_DEPTH_STENCIL_TO_BGRA_NV 0x886F
-#endif
-
-#ifndef GL_ATI_envmap_bumpmap
-#define GL_BUMP_ROT_MATRIX_ATI 0x8775
-#define GL_BUMP_ROT_MATRIX_SIZE_ATI 0x8776
-#define GL_BUMP_NUM_TEX_UNITS_ATI 0x8777
-#define GL_BUMP_TEX_UNITS_ATI 0x8778
-#define GL_DUDV_ATI 0x8779
-#define GL_DU8DV8_ATI 0x877A
-#define GL_BUMP_ENVMAP_ATI 0x877B
-#define GL_BUMP_TARGET_ATI 0x877C
-#endif
-
-#ifndef GL_ATI_fragment_shader
-#define GL_FRAGMENT_SHADER_ATI 0x8920
-#define GL_REG_0_ATI 0x8921
-#define GL_REG_1_ATI 0x8922
-#define GL_REG_2_ATI 0x8923
-#define GL_REG_3_ATI 0x8924
-#define GL_REG_4_ATI 0x8925
-#define GL_REG_5_ATI 0x8926
-#define GL_REG_6_ATI 0x8927
-#define GL_REG_7_ATI 0x8928
-#define GL_REG_8_ATI 0x8929
-#define GL_REG_9_ATI 0x892A
-#define GL_REG_10_ATI 0x892B
-#define GL_REG_11_ATI 0x892C
-#define GL_REG_12_ATI 0x892D
-#define GL_REG_13_ATI 0x892E
-#define GL_REG_14_ATI 0x892F
-#define GL_REG_15_ATI 0x8930
-#define GL_REG_16_ATI 0x8931
-#define GL_REG_17_ATI 0x8932
-#define GL_REG_18_ATI 0x8933
-#define GL_REG_19_ATI 0x8934
-#define GL_REG_20_ATI 0x8935
-#define GL_REG_21_ATI 0x8936
-#define GL_REG_22_ATI 0x8937
-#define GL_REG_23_ATI 0x8938
-#define GL_REG_24_ATI 0x8939
-#define GL_REG_25_ATI 0x893A
-#define GL_REG_26_ATI 0x893B
-#define GL_REG_27_ATI 0x893C
-#define GL_REG_28_ATI 0x893D
-#define GL_REG_29_ATI 0x893E
-#define GL_REG_30_ATI 0x893F
-#define GL_REG_31_ATI 0x8940
-#define GL_CON_0_ATI 0x8941
-#define GL_CON_1_ATI 0x8942
-#define GL_CON_2_ATI 0x8943
-#define GL_CON_3_ATI 0x8944
-#define GL_CON_4_ATI 0x8945
-#define GL_CON_5_ATI 0x8946
-#define GL_CON_6_ATI 0x8947
-#define GL_CON_7_ATI 0x8948
-#define GL_CON_8_ATI 0x8949
-#define GL_CON_9_ATI 0x894A
-#define GL_CON_10_ATI 0x894B
-#define GL_CON_11_ATI 0x894C
-#define GL_CON_12_ATI 0x894D
-#define GL_CON_13_ATI 0x894E
-#define GL_CON_14_ATI 0x894F
-#define GL_CON_15_ATI 0x8950
-#define GL_CON_16_ATI 0x8951
-#define GL_CON_17_ATI 0x8952
-#define GL_CON_18_ATI 0x8953
-#define GL_CON_19_ATI 0x8954
-#define GL_CON_20_ATI 0x8955
-#define GL_CON_21_ATI 0x8956
-#define GL_CON_22_ATI 0x8957
-#define GL_CON_23_ATI 0x8958
-#define GL_CON_24_ATI 0x8959
-#define GL_CON_25_ATI 0x895A
-#define GL_CON_26_ATI 0x895B
-#define GL_CON_27_ATI 0x895C
-#define GL_CON_28_ATI 0x895D
-#define GL_CON_29_ATI 0x895E
-#define GL_CON_30_ATI 0x895F
-#define GL_CON_31_ATI 0x8960
-#define GL_MOV_ATI 0x8961
-#define GL_ADD_ATI 0x8963
-#define GL_MUL_ATI 0x8964
-#define GL_SUB_ATI 0x8965
-#define GL_DOT3_ATI 0x8966
-#define GL_DOT4_ATI 0x8967
-#define GL_MAD_ATI 0x8968
-#define GL_LERP_ATI 0x8969
-#define GL_CND_ATI 0x896A
-#define GL_CND0_ATI 0x896B
-#define GL_DOT2_ADD_ATI 0x896C
-#define GL_SECONDARY_INTERPOLATOR_ATI 0x896D
-#define GL_NUM_FRAGMENT_REGISTERS_ATI 0x896E
-#define GL_NUM_FRAGMENT_CONSTANTS_ATI 0x896F
-#define GL_NUM_PASSES_ATI 0x8970
-#define GL_NUM_INSTRUCTIONS_PER_PASS_ATI 0x8971
-#define GL_NUM_INSTRUCTIONS_TOTAL_ATI 0x8972
-#define GL_NUM_INPUT_INTERPOLATOR_COMPONENTS_ATI 0x8973
-#define GL_NUM_LOOPBACK_COMPONENTS_ATI 0x8974
-#define GL_COLOR_ALPHA_PAIRING_ATI 0x8975
-#define GL_SWIZZLE_STR_ATI 0x8976
-#define GL_SWIZZLE_STQ_ATI 0x8977
-#define GL_SWIZZLE_STR_DR_ATI 0x8978
-#define GL_SWIZZLE_STQ_DQ_ATI 0x8979
-#define GL_SWIZZLE_STRQ_ATI 0x897A
-#define GL_SWIZZLE_STRQ_DQ_ATI 0x897B
-#define GL_RED_BIT_ATI 0x00000001
-#define GL_GREEN_BIT_ATI 0x00000002
-#define GL_BLUE_BIT_ATI 0x00000004
-#define GL_2X_BIT_ATI 0x00000001
-#define GL_4X_BIT_ATI 0x00000002
-#define GL_8X_BIT_ATI 0x00000004
-#define GL_HALF_BIT_ATI 0x00000008
-#define GL_QUARTER_BIT_ATI 0x00000010
-#define GL_EIGHTH_BIT_ATI 0x00000020
-#define GL_SATURATE_BIT_ATI 0x00000040
-#define GL_COMP_BIT_ATI 0x00000002
-#define GL_NEGATE_BIT_ATI 0x00000004
-#define GL_BIAS_BIT_ATI 0x00000008
-#endif
-
-#ifndef GL_ATI_pn_triangles
-#define GL_PN_TRIANGLES_ATI 0x87F0
-#define GL_MAX_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F1
-#define GL_PN_TRIANGLES_POINT_MODE_ATI 0x87F2
-#define GL_PN_TRIANGLES_NORMAL_MODE_ATI 0x87F3
-#define GL_PN_TRIANGLES_TESSELATION_LEVEL_ATI 0x87F4
-#define GL_PN_TRIANGLES_POINT_MODE_LINEAR_ATI 0x87F5
-#define GL_PN_TRIANGLES_POINT_MODE_CUBIC_ATI 0x87F6
-#define GL_PN_TRIANGLES_NORMAL_MODE_LINEAR_ATI 0x87F7
-#define GL_PN_TRIANGLES_NORMAL_MODE_QUADRATIC_ATI 0x87F8
-#endif
-
-#ifndef GL_ATI_vertex_array_object
-#define GL_STATIC_ATI 0x8760
-#define GL_DYNAMIC_ATI 0x8761
-#define GL_PRESERVE_ATI 0x8762
-#define GL_DISCARD_ATI 0x8763
-#define GL_OBJECT_BUFFER_SIZE_ATI 0x8764
-#define GL_OBJECT_BUFFER_USAGE_ATI 0x8765
-#define GL_ARRAY_OBJECT_BUFFER_ATI 0x8766
-#define GL_ARRAY_OBJECT_OFFSET_ATI 0x8767
-#endif
-
-#ifndef GL_EXT_vertex_shader
-#define GL_VERTEX_SHADER_EXT 0x8780
-#define GL_VERTEX_SHADER_BINDING_EXT 0x8781
-#define GL_OP_INDEX_EXT 0x8782
-#define GL_OP_NEGATE_EXT 0x8783
-#define GL_OP_DOT3_EXT 0x8784
-#define GL_OP_DOT4_EXT 0x8785
-#define GL_OP_MUL_EXT 0x8786
-#define GL_OP_ADD_EXT 0x8787
-#define GL_OP_MADD_EXT 0x8788
-#define GL_OP_FRAC_EXT 0x8789
-#define GL_OP_MAX_EXT 0x878A
-#define GL_OP_MIN_EXT 0x878B
-#define GL_OP_SET_GE_EXT 0x878C
-#define GL_OP_SET_LT_EXT 0x878D
-#define GL_OP_CLAMP_EXT 0x878E
-#define GL_OP_FLOOR_EXT 0x878F
-#define GL_OP_ROUND_EXT 0x8790
-#define GL_OP_EXP_BASE_2_EXT 0x8791
-#define GL_OP_LOG_BASE_2_EXT 0x8792
-#define GL_OP_POWER_EXT 0x8793
-#define GL_OP_RECIP_EXT 0x8794
-#define GL_OP_RECIP_SQRT_EXT 0x8795
-#define GL_OP_SUB_EXT 0x8796
-#define GL_OP_CROSS_PRODUCT_EXT 0x8797
-#define GL_OP_MULTIPLY_MATRIX_EXT 0x8798
-#define GL_OP_MOV_EXT 0x8799
-#define GL_OUTPUT_VERTEX_EXT 0x879A
-#define GL_OUTPUT_COLOR0_EXT 0x879B
-#define GL_OUTPUT_COLOR1_EXT 0x879C
-#define GL_OUTPUT_TEXTURE_COORD0_EXT 0x879D
-#define GL_OUTPUT_TEXTURE_COORD1_EXT 0x879E
-#define GL_OUTPUT_TEXTURE_COORD2_EXT 0x879F
-#define GL_OUTPUT_TEXTURE_COORD3_EXT 0x87A0
-#define GL_OUTPUT_TEXTURE_COORD4_EXT 0x87A1
-#define GL_OUTPUT_TEXTURE_COORD5_EXT 0x87A2
-#define GL_OUTPUT_TEXTURE_COORD6_EXT 0x87A3
-#define GL_OUTPUT_TEXTURE_COORD7_EXT 0x87A4
-#define GL_OUTPUT_TEXTURE_COORD8_EXT 0x87A5
-#define GL_OUTPUT_TEXTURE_COORD9_EXT 0x87A6
-#define GL_OUTPUT_TEXTURE_COORD10_EXT 0x87A7
-#define GL_OUTPUT_TEXTURE_COORD11_EXT 0x87A8
-#define GL_OUTPUT_TEXTURE_COORD12_EXT 0x87A9
-#define GL_OUTPUT_TEXTURE_COORD13_EXT 0x87AA
-#define GL_OUTPUT_TEXTURE_COORD14_EXT 0x87AB
-#define GL_OUTPUT_TEXTURE_COORD15_EXT 0x87AC
-#define GL_OUTPUT_TEXTURE_COORD16_EXT 0x87AD
-#define GL_OUTPUT_TEXTURE_COORD17_EXT 0x87AE
-#define GL_OUTPUT_TEXTURE_COORD18_EXT 0x87AF
-#define GL_OUTPUT_TEXTURE_COORD19_EXT 0x87B0
-#define GL_OUTPUT_TEXTURE_COORD20_EXT 0x87B1
-#define GL_OUTPUT_TEXTURE_COORD21_EXT 0x87B2
-#define GL_OUTPUT_TEXTURE_COORD22_EXT 0x87B3
-#define GL_OUTPUT_TEXTURE_COORD23_EXT 0x87B4
-#define GL_OUTPUT_TEXTURE_COORD24_EXT 0x87B5
-#define GL_OUTPUT_TEXTURE_COORD25_EXT 0x87B6
-#define GL_OUTPUT_TEXTURE_COORD26_EXT 0x87B7
-#define GL_OUTPUT_TEXTURE_COORD27_EXT 0x87B8
-#define GL_OUTPUT_TEXTURE_COORD28_EXT 0x87B9
-#define GL_OUTPUT_TEXTURE_COORD29_EXT 0x87BA
-#define GL_OUTPUT_TEXTURE_COORD30_EXT 0x87BB
-#define GL_OUTPUT_TEXTURE_COORD31_EXT 0x87BC
-#define GL_OUTPUT_FOG_EXT 0x87BD
-#define GL_SCALAR_EXT 0x87BE
-#define GL_VECTOR_EXT 0x87BF
-#define GL_MATRIX_EXT 0x87C0
-#define GL_VARIANT_EXT 0x87C1
-#define GL_INVARIANT_EXT 0x87C2
-#define GL_LOCAL_CONSTANT_EXT 0x87C3
-#define GL_LOCAL_EXT 0x87C4
-#define GL_MAX_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87C5
-#define GL_MAX_VERTEX_SHADER_VARIANTS_EXT 0x87C6
-#define GL_MAX_VERTEX_SHADER_INVARIANTS_EXT 0x87C7
-#define GL_MAX_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87C8
-#define GL_MAX_VERTEX_SHADER_LOCALS_EXT 0x87C9
-#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CA
-#define GL_MAX_OPTIMIZED_VERTEX_SHADER_VARIANTS_EXT 0x87CB
-#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87CC
-#define GL_MAX_OPTIMIZED_VERTEX_SHADER_INARIANTS_EXT 0x87CD
-#define GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCALS_EXT 0x87CE
-#define GL_VERTEX_SHADER_INSTRUCTIONS_EXT 0x87CF
-#define GL_VERTEX_SHADER_VARIANTS_EXT 0x87D0
-#define GL_VERTEX_SHADER_INVARIANTS_EXT 0x87D1
-#define GL_VERTEX_SHADER_LOCAL_CONSTANTS_EXT 0x87D2
-#define GL_VERTEX_SHADER_LOCALS_EXT 0x87D3
-#define GL_VERTEX_SHADER_OPTIMIZED_EXT 0x87D4
-#define GL_X_EXT 0x87D5
-#define GL_Y_EXT 0x87D6
-#define GL_Z_EXT 0x87D7
-#define GL_W_EXT 0x87D8
-#define GL_NEGATIVE_X_EXT 0x87D9
-#define GL_NEGATIVE_Y_EXT 0x87DA
-#define GL_NEGATIVE_Z_EXT 0x87DB
-#define GL_NEGATIVE_W_EXT 0x87DC
-#define GL_ZERO_EXT 0x87DD
-#define GL_ONE_EXT 0x87DE
-#define GL_NEGATIVE_ONE_EXT 0x87DF
-#define GL_NORMALIZED_RANGE_EXT 0x87E0
-#define GL_FULL_RANGE_EXT 0x87E1
-#define GL_CURRENT_VERTEX_EXT 0x87E2
-#define GL_MVP_MATRIX_EXT 0x87E3
-#define GL_VARIANT_VALUE_EXT 0x87E4
-#define GL_VARIANT_DATATYPE_EXT 0x87E5
-#define GL_VARIANT_ARRAY_STRIDE_EXT 0x87E6
-#define GL_VARIANT_ARRAY_TYPE_EXT 0x87E7
-#define GL_VARIANT_ARRAY_EXT 0x87E8
-#define GL_VARIANT_ARRAY_POINTER_EXT 0x87E9
-#define GL_INVARIANT_VALUE_EXT 0x87EA
-#define GL_INVARIANT_DATATYPE_EXT 0x87EB
-#define GL_LOCAL_CONSTANT_VALUE_EXT 0x87EC
-#define GL_LOCAL_CONSTANT_DATATYPE_EXT 0x87ED
-#endif
-
-#ifndef GL_ATI_vertex_streams
-#define GL_MAX_VERTEX_STREAMS_ATI 0x876B
-#define GL_VERTEX_STREAM0_ATI 0x876C
-#define GL_VERTEX_STREAM1_ATI 0x876D
-#define GL_VERTEX_STREAM2_ATI 0x876E
-#define GL_VERTEX_STREAM3_ATI 0x876F
-#define GL_VERTEX_STREAM4_ATI 0x8770
-#define GL_VERTEX_STREAM5_ATI 0x8771
-#define GL_VERTEX_STREAM6_ATI 0x8772
-#define GL_VERTEX_STREAM7_ATI 0x8773
-#define GL_VERTEX_SOURCE_ATI 0x8774
-#endif
-
-#ifndef GL_ATI_element_array
-#define GL_ELEMENT_ARRAY_ATI 0x8768
-#define GL_ELEMENT_ARRAY_TYPE_ATI 0x8769
-#define GL_ELEMENT_ARRAY_POINTER_ATI 0x876A
-#endif
-
-#ifndef GL_SUN_mesh_array
-#define GL_QUAD_MESH_SUN 0x8614
-#define GL_TRIANGLE_MESH_SUN 0x8615
-#endif
-
-#ifndef GL_SUN_slice_accum
-#define GL_SLICE_ACCUM_SUN 0x85CC
-#endif
-
-#ifndef GL_NV_multisample_filter_hint
-#define GL_MULTISAMPLE_FILTER_HINT_NV 0x8534
-#endif
-
-#ifndef GL_NV_depth_clamp
-#define GL_DEPTH_CLAMP_NV 0x864F
-#endif
-
-#ifndef GL_NV_occlusion_query
-#define GL_PIXEL_COUNTER_BITS_NV 0x8864
-#define GL_CURRENT_OCCLUSION_QUERY_ID_NV 0x8865
-#define GL_PIXEL_COUNT_NV 0x8866
-#define GL_PIXEL_COUNT_AVAILABLE_NV 0x8867
-#endif
-
-#ifndef GL_NV_point_sprite
-#define GL_POINT_SPRITE_NV 0x8861
-#define GL_COORD_REPLACE_NV 0x8862
-#define GL_POINT_SPRITE_R_MODE_NV 0x8863
-#endif
-
-#ifndef GL_NV_texture_shader3
-#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_NV 0x8850
-#define GL_OFFSET_PROJECTIVE_TEXTURE_2D_SCALE_NV 0x8851
-#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8852
-#define GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_SCALE_NV 0x8853
-#define GL_OFFSET_HILO_TEXTURE_2D_NV 0x8854
-#define GL_OFFSET_HILO_TEXTURE_RECTANGLE_NV 0x8855
-#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_2D_NV 0x8856
-#define GL_OFFSET_HILO_PROJECTIVE_TEXTURE_RECTANGLE_NV 0x8857
-#define GL_DEPENDENT_HILO_TEXTURE_2D_NV 0x8858
-#define GL_DEPENDENT_RGB_TEXTURE_3D_NV 0x8859
-#define GL_DEPENDENT_RGB_TEXTURE_CUBE_MAP_NV 0x885A
-#define GL_DOT_PRODUCT_PASS_THROUGH_NV 0x885B
-#define GL_DOT_PRODUCT_TEXTURE_1D_NV 0x885C
-#define GL_DOT_PRODUCT_AFFINE_DEPTH_REPLACE_NV 0x885D
-#define GL_HILO8_NV 0x885E
-#define GL_SIGNED_HILO8_NV 0x885F
-#define GL_FORCE_BLUE_TO_ONE_NV 0x8860
-#endif
-
-#ifndef GL_NV_vertex_program1_1
-#endif
-
-#ifndef GL_EXT_shadow_funcs
-#endif
-
-#ifndef GL_EXT_stencil_two_side
-#define GL_STENCIL_TEST_TWO_SIDE_EXT 0x8910
-#define GL_ACTIVE_STENCIL_FACE_EXT 0x8911
-#endif
-
-
-/*************************************************************/
-
-#ifndef GL_VERSION_1_2
-#define GL_VERSION_1_2 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glBlendColor (GLclampf, GLclampf, GLclampf, GLclampf);
-GLAPI void APIENTRY glBlendEquation (GLenum);
-GLAPI void APIENTRY glDrawRangeElements (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *);
-GLAPI void APIENTRY glColorTable (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glColorTableParameterfv (GLenum, GLenum, const GLfloat *);
-GLAPI void APIENTRY glColorTableParameteriv (GLenum, GLenum, const GLint *);
-GLAPI void APIENTRY glCopyColorTable (GLenum, GLenum, GLint, GLint, GLsizei);
-GLAPI void APIENTRY glGetColorTable (GLenum, GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetColorTableParameterfv (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetColorTableParameteriv (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glColorSubTable (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glCopyColorSubTable (GLenum, GLsizei, GLint, GLint, GLsizei);
-GLAPI void APIENTRY glConvolutionFilter1D (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glConvolutionFilter2D (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glConvolutionParameterf (GLenum, GLenum, GLfloat);
-GLAPI void APIENTRY glConvolutionParameterfv (GLenum, GLenum, const GLfloat *);
-GLAPI void APIENTRY glConvolutionParameteri (GLenum, GLenum, GLint);
-GLAPI void APIENTRY glConvolutionParameteriv (GLenum, GLenum, const GLint *);
-GLAPI void APIENTRY glCopyConvolutionFilter1D (GLenum, GLenum, GLint, GLint, GLsizei);
-GLAPI void APIENTRY glCopyConvolutionFilter2D (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei);
-GLAPI void APIENTRY glGetConvolutionFilter (GLenum, GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetConvolutionParameterfv (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetConvolutionParameteriv (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetSeparableFilter (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *);
-GLAPI void APIENTRY glSeparableFilter2D (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *);
-GLAPI void APIENTRY glGetHistogram (GLenum, GLboolean, GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetHistogramParameterfv (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetHistogramParameteriv (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetMinmax (GLenum, GLboolean, GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetMinmaxParameterfv (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetMinmaxParameteriv (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glHistogram (GLenum, GLsizei, GLenum, GLboolean);
-GLAPI void APIENTRY glMinmax (GLenum, GLenum, GLboolean);
-GLAPI void APIENTRY glResetHistogram (GLenum);
-GLAPI void APIENTRY glResetMinmax (GLenum);
-GLAPI void APIENTRY glTexImage3D (GLenum, GLint, GLint, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glCopyTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLBLENDCOLORPROC) (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
-typedef void (APIENTRY * PFNGLBLENDEQUATIONPROC) (GLenum mode);
-typedef void (APIENTRY * PFNGLDRAWRANGEELEMENTSPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
-typedef void (APIENTRY * PFNGLCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
-typedef void (APIENTRY * PFNGLCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLCOPYCOLORTABLEPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
-typedef void (APIENTRY * PFNGLGETCOLORTABLEPROC) (GLenum target, GLenum format, GLenum type, GLvoid *table);
-typedef void (APIENTRY * PFNGLGETCOLORTABLEPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETCOLORTABLEPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLCOLORSUBTABLEPROC) (GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOPYCOLORSUBTABLEPROC) (GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
-typedef void (APIENTRY * PFNGLCONVOLUTIONFILTER1DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
-typedef void (APIENTRY * PFNGLCONVOLUTIONFILTER2DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
-typedef void (APIENTRY * PFNGLCONVOLUTIONPARAMETERFPROC) (GLenum target, GLenum pname, GLfloat params);
-typedef void (APIENTRY * PFNGLCONVOLUTIONPARAMETERFVPROC) (GLenum target, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLCONVOLUTIONPARAMETERIPROC) (GLenum target, GLenum pname, GLint params);
-typedef void (APIENTRY * PFNGLCONVOLUTIONPARAMETERIVPROC) (GLenum target, GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLCOPYCONVOLUTIONFILTER1DPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
-typedef void (APIENTRY * PFNGLCOPYCONVOLUTIONFILTER2DPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
-typedef void (APIENTRY * PFNGLGETCONVOLUTIONFILTERPROC) (GLenum target, GLenum format, GLenum type, GLvoid *image);
-typedef void (APIENTRY * PFNGLGETCONVOLUTIONPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETCONVOLUTIONPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETSEPARABLEFILTERPROC) (GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
-typedef void (APIENTRY * PFNGLSEPARABLEFILTER2DPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
-typedef void (APIENTRY * PFNGLGETHISTOGRAMPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
-typedef void (APIENTRY * PFNGLGETHISTOGRAMPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETHISTOGRAMPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETMINMAXPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
-typedef void (APIENTRY * PFNGLGETMINMAXPARAMETERFVPROC) (GLenum target, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETMINMAXPARAMETERIVPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLHISTOGRAMPROC) (GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
-typedef void (APIENTRY * PFNGLMINMAXPROC) (GLenum target, GLenum internalformat, GLboolean sink);
-typedef void (APIENTRY * PFNGLRESETHISTOGRAMPROC) (GLenum target);
-typedef void (APIENTRY * PFNGLRESETMINMAXPROC) (GLenum target);
-typedef void (APIENTRY * PFNGLTEXIMAGE3DPROC) (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
-typedef void (APIENTRY * PFNGLTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
-typedef void (APIENTRY * PFNGLCOPYTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
-#endif
-
-#ifndef GL_VERSION_1_3
-#define GL_VERSION_1_3 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glActiveTexture (GLenum);
-GLAPI void APIENTRY glClientActiveTexture (GLenum);
-GLAPI void APIENTRY glMultiTexCoord1d (GLenum, GLdouble);
-GLAPI void APIENTRY glMultiTexCoord1dv (GLenum, const GLdouble *);
-GLAPI void APIENTRY glMultiTexCoord1f (GLenum, GLfloat);
-GLAPI void APIENTRY glMultiTexCoord1fv (GLenum, const GLfloat *);
-GLAPI void APIENTRY glMultiTexCoord1i (GLenum, GLint);
-GLAPI void APIENTRY glMultiTexCoord1iv (GLenum, const GLint *);
-GLAPI void APIENTRY glMultiTexCoord1s (GLenum, GLshort);
-GLAPI void APIENTRY glMultiTexCoord1sv (GLenum, const GLshort *);
-GLAPI void APIENTRY glMultiTexCoord2d (GLenum, GLdouble, GLdouble);
-GLAPI void APIENTRY glMultiTexCoord2dv (GLenum, const GLdouble *);
-GLAPI void APIENTRY glMultiTexCoord2f (GLenum, GLfloat, GLfloat);
-GLAPI void APIENTRY glMultiTexCoord2fv (GLenum, const GLfloat *);
-GLAPI void APIENTRY glMultiTexCoord2i (GLenum, GLint, GLint);
-GLAPI void APIENTRY glMultiTexCoord2iv (GLenum, const GLint *);
-GLAPI void APIENTRY glMultiTexCoord2s (GLenum, GLshort, GLshort);
-GLAPI void APIENTRY glMultiTexCoord2sv (GLenum, const GLshort *);
-GLAPI void APIENTRY glMultiTexCoord3d (GLenum, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glMultiTexCoord3dv (GLenum, const GLdouble *);
-GLAPI void APIENTRY glMultiTexCoord3f (GLenum, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glMultiTexCoord3fv (GLenum, const GLfloat *);
-GLAPI void APIENTRY glMultiTexCoord3i (GLenum, GLint, GLint, GLint);
-GLAPI void APIENTRY glMultiTexCoord3iv (GLenum, const GLint *);
-GLAPI void APIENTRY glMultiTexCoord3s (GLenum, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glMultiTexCoord3sv (GLenum, const GLshort *);
-GLAPI void APIENTRY glMultiTexCoord4d (GLenum, GLdouble, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glMultiTexCoord4dv (GLenum, const GLdouble *);
-GLAPI void APIENTRY glMultiTexCoord4f (GLenum, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glMultiTexCoord4fv (GLenum, const GLfloat *);
-GLAPI void APIENTRY glMultiTexCoord4i (GLenum, GLint, GLint, GLint, GLint);
-GLAPI void APIENTRY glMultiTexCoord4iv (GLenum, const GLint *);
-GLAPI void APIENTRY glMultiTexCoord4s (GLenum, GLshort, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glMultiTexCoord4sv (GLenum, const GLshort *);
-GLAPI void APIENTRY glLoadTransposeMatrixf (const GLfloat *);
-GLAPI void APIENTRY glLoadTransposeMatrixd (const GLdouble *);
-GLAPI void APIENTRY glMultTransposeMatrixf (const GLfloat *);
-GLAPI void APIENTRY glMultTransposeMatrixd (const GLdouble *);
-GLAPI void APIENTRY glSampleCoverage (GLclampf, GLboolean);
-GLAPI void APIENTRY glCompressedTexImage3D (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexImage2D (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexImage1D (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexSubImage3D (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexSubImage2D (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexSubImage1D (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glGetCompressedTexImage (GLenum, GLint, void *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLACTIVETEXTUREPROC) (GLenum texture);
-typedef void (APIENTRY * PFNGLCLIENTACTIVETEXTUREPROC) (GLenum texture);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1DPROC) (GLenum target, GLdouble s);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1DVPROC) (GLenum target, const GLdouble *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1FPROC) (GLenum target, GLfloat s);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1FVPROC) (GLenum target, const GLfloat *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1IPROC) (GLenum target, GLint s);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1IVPROC) (GLenum target, const GLint *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1SPROC) (GLenum target, GLshort s);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1SVPROC) (GLenum target, const GLshort *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2DPROC) (GLenum target, GLdouble s, GLdouble t);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2DVPROC) (GLenum target, const GLdouble *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2FPROC) (GLenum target, GLfloat s, GLfloat t);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2FVPROC) (GLenum target, const GLfloat *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2IPROC) (GLenum target, GLint s, GLint t);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2IVPROC) (GLenum target, const GLint *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2SPROC) (GLenum target, GLshort s, GLshort t);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2SVPROC) (GLenum target, const GLshort *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3DPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3DVPROC) (GLenum target, const GLdouble *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3FPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3FVPROC) (GLenum target, const GLfloat *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3IPROC) (GLenum target, GLint s, GLint t, GLint r);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3IVPROC) (GLenum target, const GLint *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3SPROC) (GLenum target, GLshort s, GLshort t, GLshort r);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3SVPROC) (GLenum target, const GLshort *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4DPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4DVPROC) (GLenum target, const GLdouble *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4FPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4FVPROC) (GLenum target, const GLfloat *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4IPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4IVPROC) (GLenum target, const GLint *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4SPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4SVPROC) (GLenum target, const GLshort *v);
-typedef void (APIENTRY * PFNGLLOADTRANSPOSEMATRIXFPROC) (const GLfloat *m);
-typedef void (APIENTRY * PFNGLLOADTRANSPOSEMATRIXDPROC) (const GLdouble *m);
-typedef void (APIENTRY * PFNGLMULTTRANSPOSEMATRIXFPROC) (const GLfloat *m);
-typedef void (APIENTRY * PFNGLMULTTRANSPOSEMATRIXDPROC) (const GLdouble *m);
-typedef void (APIENTRY * PFNGLSAMPLECOVERAGEPROC) (GLclampf value, GLboolean invert);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXIMAGE3DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXIMAGE2DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXIMAGE1DPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXSUBIMAGE3DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXSUBIMAGE2DPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXSUBIMAGE1DPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLGETCOMPRESSEDTEXIMAGEPROC) (GLenum target, GLint level, void *img);
-#endif
-
-#ifndef GL_VERSION_1_4
-#define GL_VERSION_1_4 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glBlendFuncSeparate (GLenum, GLenum, GLenum, GLenum);
-GLAPI void APIENTRY glFogCoordf (GLfloat);
-GLAPI void APIENTRY glFogCoordfv (const GLfloat *);
-GLAPI void APIENTRY glFogCoordd (GLdouble);
-GLAPI void APIENTRY glFogCoorddv (const GLdouble *);
-GLAPI void APIENTRY glFogCoordPointer (GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glMultiDrawArrays (GLenum, GLint *, GLsizei *, GLsizei);
-GLAPI void APIENTRY glMultiDrawElements (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei);
-GLAPI void APIENTRY glPointParameterf (GLenum, GLfloat);
-GLAPI void APIENTRY glPointParameterfv (GLenum, const GLfloat *);
-GLAPI void APIENTRY glPointParameteri (GLenum, GLint);
-GLAPI void APIENTRY glPointParameteriv (GLenum, const GLint *);
-GLAPI void APIENTRY glSecondaryColor3b (GLbyte, GLbyte, GLbyte);
-GLAPI void APIENTRY glSecondaryColor3bv (const GLbyte *);
-GLAPI void APIENTRY glSecondaryColor3d (GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glSecondaryColor3dv (const GLdouble *);
-GLAPI void APIENTRY glSecondaryColor3f (GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glSecondaryColor3fv (const GLfloat *);
-GLAPI void APIENTRY glSecondaryColor3i (GLint, GLint, GLint);
-GLAPI void APIENTRY glSecondaryColor3iv (const GLint *);
-GLAPI void APIENTRY glSecondaryColor3s (GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glSecondaryColor3sv (const GLshort *);
-GLAPI void APIENTRY glSecondaryColor3ub (GLubyte, GLubyte, GLubyte);
-GLAPI void APIENTRY glSecondaryColor3ubv (const GLubyte *);
-GLAPI void APIENTRY glSecondaryColor3ui (GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glSecondaryColor3uiv (const GLuint *);
-GLAPI void APIENTRY glSecondaryColor3us (GLushort, GLushort, GLushort);
-GLAPI void APIENTRY glSecondaryColor3usv (const GLushort *);
-GLAPI void APIENTRY glSecondaryColorPointer (GLint, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glWindowPos2d (GLdouble, GLdouble);
-GLAPI void APIENTRY glWindowPos2dv (const GLdouble *);
-GLAPI void APIENTRY glWindowPos2f (GLfloat, GLfloat);
-GLAPI void APIENTRY glWindowPos2fv (const GLfloat *);
-GLAPI void APIENTRY glWindowPos2i (GLint, GLint);
-GLAPI void APIENTRY glWindowPos2iv (const GLint *);
-GLAPI void APIENTRY glWindowPos2s (GLshort, GLshort);
-GLAPI void APIENTRY glWindowPos2sv (const GLshort *);
-GLAPI void APIENTRY glWindowPos3d (GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glWindowPos3dv (const GLdouble *);
-GLAPI void APIENTRY glWindowPos3f (GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glWindowPos3fv (const GLfloat *);
-GLAPI void APIENTRY glWindowPos3i (GLint, GLint, GLint);
-GLAPI void APIENTRY glWindowPos3iv (const GLint *);
-GLAPI void APIENTRY glWindowPos3s (GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glWindowPos3sv (const GLshort *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLBLENDFUNCSEPARATEPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
-typedef void (APIENTRY * PFNGLFOGCOORDFPROC) (GLfloat coord);
-typedef void (APIENTRY * PFNGLFOGCOORDFVPROC) (const GLfloat *coord);
-typedef void (APIENTRY * PFNGLFOGCOORDDPROC) (GLdouble coord);
-typedef void (APIENTRY * PFNGLFOGCOORDDVPROC) (const GLdouble *coord);
-typedef void (APIENTRY * PFNGLFOGCOORDPOINTERPROC) (GLenum type, GLsizei stride, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLMULTIDRAWARRAYSPROC) (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount);
-typedef void (APIENTRY * PFNGLMULTIDRAWELEMENTSPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount);
-typedef void (APIENTRY * PFNGLPOINTPARAMETERFPROC) (GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLPOINTPARAMETERFVPROC) (GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLPOINTPARAMETERIPROC) (GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLPOINTPARAMETERIVPROC) (GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3BPROC) (GLbyte red, GLbyte green, GLbyte blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3BVPROC) (const GLbyte *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3DPROC) (GLdouble red, GLdouble green, GLdouble blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3DVPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3FPROC) (GLfloat red, GLfloat green, GLfloat blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3FVPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3IPROC) (GLint red, GLint green, GLint blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3IVPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3SPROC) (GLshort red, GLshort green, GLshort blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3SVPROC) (const GLshort *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3UBPROC) (GLubyte red, GLubyte green, GLubyte blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3UBVPROC) (const GLubyte *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3UIPROC) (GLuint red, GLuint green, GLuint blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3UIVPROC) (const GLuint *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3USPROC) (GLushort red, GLushort green, GLushort blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3USVPROC) (const GLushort *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLORPOINTERPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLWINDOWPOS2DPROC) (GLdouble x, GLdouble y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2DVPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS2FPROC) (GLfloat x, GLfloat y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2FVPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS2IPROC) (GLint x, GLint y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2IVPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS2SPROC) (GLshort x, GLshort y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2SVPROC) (const GLshort *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3DPROC) (GLdouble x, GLdouble y, GLdouble z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3DVPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3FPROC) (GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3FVPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3IPROC) (GLint x, GLint y, GLint z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3IVPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3SPROC) (GLshort x, GLshort y, GLshort z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3SVPROC) (const GLshort *v);
-#endif
-
-#ifndef GL_ARB_multitexture
-#define GL_ARB_multitexture 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glActiveTextureARB (GLenum);
-GLAPI void APIENTRY glClientActiveTextureARB (GLenum);
-GLAPI void APIENTRY glMultiTexCoord1dARB (GLenum, GLdouble);
-GLAPI void APIENTRY glMultiTexCoord1dvARB (GLenum, const GLdouble *);
-GLAPI void APIENTRY glMultiTexCoord1fARB (GLenum, GLfloat);
-GLAPI void APIENTRY glMultiTexCoord1fvARB (GLenum, const GLfloat *);
-GLAPI void APIENTRY glMultiTexCoord1iARB (GLenum, GLint);
-GLAPI void APIENTRY glMultiTexCoord1ivARB (GLenum, const GLint *);
-GLAPI void APIENTRY glMultiTexCoord1sARB (GLenum, GLshort);
-GLAPI void APIENTRY glMultiTexCoord1svARB (GLenum, const GLshort *);
-GLAPI void APIENTRY glMultiTexCoord2dARB (GLenum, GLdouble, GLdouble);
-GLAPI void APIENTRY glMultiTexCoord2dvARB (GLenum, const GLdouble *);
-GLAPI void APIENTRY glMultiTexCoord2fARB (GLenum, GLfloat, GLfloat);
-GLAPI void APIENTRY glMultiTexCoord2fvARB (GLenum, const GLfloat *);
-GLAPI void APIENTRY glMultiTexCoord2iARB (GLenum, GLint, GLint);
-GLAPI void APIENTRY glMultiTexCoord2ivARB (GLenum, const GLint *);
-GLAPI void APIENTRY glMultiTexCoord2sARB (GLenum, GLshort, GLshort);
-GLAPI void APIENTRY glMultiTexCoord2svARB (GLenum, const GLshort *);
-GLAPI void APIENTRY glMultiTexCoord3dARB (GLenum, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glMultiTexCoord3dvARB (GLenum, const GLdouble *);
-GLAPI void APIENTRY glMultiTexCoord3fARB (GLenum, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glMultiTexCoord3fvARB (GLenum, const GLfloat *);
-GLAPI void APIENTRY glMultiTexCoord3iARB (GLenum, GLint, GLint, GLint);
-GLAPI void APIENTRY glMultiTexCoord3ivARB (GLenum, const GLint *);
-GLAPI void APIENTRY glMultiTexCoord3sARB (GLenum, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glMultiTexCoord3svARB (GLenum, const GLshort *);
-GLAPI void APIENTRY glMultiTexCoord4dARB (GLenum, GLdouble, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glMultiTexCoord4dvARB (GLenum, const GLdouble *);
-GLAPI void APIENTRY glMultiTexCoord4fARB (GLenum, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glMultiTexCoord4fvARB (GLenum, const GLfloat *);
-GLAPI void APIENTRY glMultiTexCoord4iARB (GLenum, GLint, GLint, GLint, GLint);
-GLAPI void APIENTRY glMultiTexCoord4ivARB (GLenum, const GLint *);
-GLAPI void APIENTRY glMultiTexCoord4sARB (GLenum, GLshort, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glMultiTexCoord4svARB (GLenum, const GLshort *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLACTIVETEXTUREARBPROC) (GLenum texture);
-typedef void (APIENTRY * PFNGLCLIENTACTIVETEXTUREARBPROC) (GLenum texture);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1DARBPROC) (GLenum target, GLdouble s);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1DVARBPROC) (GLenum target, const GLdouble *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1FARBPROC) (GLenum target, GLfloat s);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1FVARBPROC) (GLenum target, const GLfloat *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1IARBPROC) (GLenum target, GLint s);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1IVARBPROC) (GLenum target, const GLint *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1SARBPROC) (GLenum target, GLshort s);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD1SVARBPROC) (GLenum target, const GLshort *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2DARBPROC) (GLenum target, GLdouble s, GLdouble t);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2DVARBPROC) (GLenum target, const GLdouble *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2FARBPROC) (GLenum target, GLfloat s, GLfloat t);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2FVARBPROC) (GLenum target, const GLfloat *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2IARBPROC) (GLenum target, GLint s, GLint t);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2IVARBPROC) (GLenum target, const GLint *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2SARBPROC) (GLenum target, GLshort s, GLshort t);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD2SVARBPROC) (GLenum target, const GLshort *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3DVARBPROC) (GLenum target, const GLdouble *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3FVARBPROC) (GLenum target, const GLfloat *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3IARBPROC) (GLenum target, GLint s, GLint t, GLint r);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3IVARBPROC) (GLenum target, const GLint *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD3SVARBPROC) (GLenum target, const GLshort *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4DVARBPROC) (GLenum target, const GLdouble *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4FVARBPROC) (GLenum target, const GLfloat *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4IARBPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4IVARBPROC) (GLenum target, const GLint *v);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
-typedef void (APIENTRY * PFNGLMULTITEXCOORD4SVARBPROC) (GLenum target, const GLshort *v);
-#endif
-
-#ifndef GL_ARB_transpose_matrix
-#define GL_ARB_transpose_matrix 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glLoadTransposeMatrixfARB (const GLfloat *);
-GLAPI void APIENTRY glLoadTransposeMatrixdARB (const GLdouble *);
-GLAPI void APIENTRY glMultTransposeMatrixfARB (const GLfloat *);
-GLAPI void APIENTRY glMultTransposeMatrixdARB (const GLdouble *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLLOADTRANSPOSEMATRIXFARBPROC) (const GLfloat *m);
-typedef void (APIENTRY * PFNGLLOADTRANSPOSEMATRIXDARBPROC) (const GLdouble *m);
-typedef void (APIENTRY * PFNGLMULTTRANSPOSEMATRIXFARBPROC) (const GLfloat *m);
-typedef void (APIENTRY * PFNGLMULTTRANSPOSEMATRIXDARBPROC) (const GLdouble *m);
-#endif
-
-#ifndef GL_ARB_multisample
-#define GL_ARB_multisample 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glSampleCoverageARB (GLclampf, GLboolean);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLSAMPLECOVERAGEARBPROC) (GLclampf value, GLboolean invert);
-#endif
-
-#ifndef GL_ARB_texture_env_add
-#define GL_ARB_texture_env_add 1
-#endif
-
-#ifndef GL_ARB_texture_cube_map
-#define GL_ARB_texture_cube_map 1
-#endif
-
-#ifndef GL_ARB_texture_compression
-#define GL_ARB_texture_compression 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glCompressedTexImage3DARB (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexImage2DARB (GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexImage1DARB (GLenum, GLint, GLenum, GLsizei, GLint, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexSubImage3DARB (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexSubImage2DARB (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glCompressedTexSubImage1DARB (GLenum, GLint, GLint, GLsizei, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glGetCompressedTexImageARB (GLenum, GLint, void *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXIMAGE3DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXIMAGE2DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXIMAGE1DARBPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXSUBIMAGE3DARBPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXSUBIMAGE2DARBPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOMPRESSEDTEXSUBIMAGE1DARBPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid *data);
-typedef void (APIENTRY * PFNGLGETCOMPRESSEDTEXIMAGEARBPROC) (GLenum target, GLint level, void *img);
-#endif
-
-#ifndef GL_ARB_texture_border_clamp
-#define GL_ARB_texture_border_clamp 1
-#endif
-
-#ifndef GL_ARB_point_parameters
-#define GL_ARB_point_parameters 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPointParameterfARB (GLenum, GLfloat);
-GLAPI void APIENTRY glPointParameterfvARB (GLenum, const GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLPOINTPARAMETERFARBPROC) (GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLPOINTPARAMETERFVARBPROC) (GLenum pname, const GLfloat *params);
-#endif
-
-#ifndef GL_ARB_vertex_blend
-#define GL_ARB_vertex_blend 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glWeightbvARB (GLint, const GLbyte *);
-GLAPI void APIENTRY glWeightsvARB (GLint, const GLshort *);
-GLAPI void APIENTRY glWeightivARB (GLint, const GLint *);
-GLAPI void APIENTRY glWeightfvARB (GLint, const GLfloat *);
-GLAPI void APIENTRY glWeightdvARB (GLint, const GLdouble *);
-GLAPI void APIENTRY glWeightubvARB (GLint, const GLubyte *);
-GLAPI void APIENTRY glWeightusvARB (GLint, const GLushort *);
-GLAPI void APIENTRY glWeightuivARB (GLint, const GLuint *);
-GLAPI void APIENTRY glWeightPointerARB (GLint, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glVertexBlendARB (GLint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLWEIGHTBVARBPROC) (GLint size, const GLbyte *weights);
-typedef void (APIENTRY * PFNGLWEIGHTSVARBPROC) (GLint size, const GLshort *weights);
-typedef void (APIENTRY * PFNGLWEIGHTIVARBPROC) (GLint size, const GLint *weights);
-typedef void (APIENTRY * PFNGLWEIGHTFVARBPROC) (GLint size, const GLfloat *weights);
-typedef void (APIENTRY * PFNGLWEIGHTDVARBPROC) (GLint size, const GLdouble *weights);
-typedef void (APIENTRY * PFNGLWEIGHTUBVARBPROC) (GLint size, const GLubyte *weights);
-typedef void (APIENTRY * PFNGLWEIGHTUSVARBPROC) (GLint size, const GLushort *weights);
-typedef void (APIENTRY * PFNGLWEIGHTUIVARBPROC) (GLint size, const GLuint *weights);
-typedef void (APIENTRY * PFNGLWEIGHTPOINTERARBPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLVERTEXBLENDARBPROC) (GLint count);
-#endif
-
-#ifndef GL_ARB_matrix_palette
-#define GL_ARB_matrix_palette 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glCurrentPaletteMatrixARB (GLint);
-GLAPI void APIENTRY glMatrixIndexubvARB (GLint, const GLubyte *);
-GLAPI void APIENTRY glMatrixIndexusvARB (GLint, const GLushort *);
-GLAPI void APIENTRY glMatrixIndexuivARB (GLint, const GLuint *);
-GLAPI void APIENTRY glMatrixIndexPointerARB (GLint, GLenum, GLsizei, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCURRENTPALETTEMATRIXARBPROC) (GLint index);
-typedef void (APIENTRY * PFNGLMATRIXINDEXUBVARBPROC) (GLint size, const GLubyte *indices);
-typedef void (APIENTRY * PFNGLMATRIXINDEXUSVARBPROC) (GLint size, const GLushort *indices);
-typedef void (APIENTRY * PFNGLMATRIXINDEXUIVARBPROC) (GLint size, const GLuint *indices);
-typedef void (APIENTRY * PFNGLMATRIXINDEXPOINTERARBPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
-#endif
-
-#ifndef GL_ARB_texture_env_combine
-#define GL_ARB_texture_env_combine 1
-#endif
-
-#ifndef GL_ARB_texture_env_crossbar
-#define GL_ARB_texture_env_crossbar 1
-#endif
-
-#ifndef GL_ARB_texture_env_dot3
-#define GL_ARB_texture_env_dot3 1
-#endif
-
-#ifndef GL_ARB_texture_mirror_repeat
-#define GL_ARB_texture_mirror_repeat 1
-#endif
-
-#ifndef GL_ARB_depth_texture
-#define GL_ARB_depth_texture 1
-#endif
-
-#ifndef GL_ARB_shadow
-#define GL_ARB_shadow 1
-#endif
-
-#ifndef GL_ARB_shadow_ambient
-#define GL_ARB_shadow_ambient 1
-#endif
-
-#ifndef GL_ARB_window_pos
-#define GL_ARB_window_pos 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glWindowPos2dARB (GLdouble, GLdouble);
-GLAPI void APIENTRY glWindowPos2dvARB (const GLdouble *);
-GLAPI void APIENTRY glWindowPos2fARB (GLfloat, GLfloat);
-GLAPI void APIENTRY glWindowPos2fvARB (const GLfloat *);
-GLAPI void APIENTRY glWindowPos2iARB (GLint, GLint);
-GLAPI void APIENTRY glWindowPos2ivARB (const GLint *);
-GLAPI void APIENTRY glWindowPos2sARB (GLshort, GLshort);
-GLAPI void APIENTRY glWindowPos2svARB (const GLshort *);
-GLAPI void APIENTRY glWindowPos3dARB (GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glWindowPos3dvARB (const GLdouble *);
-GLAPI void APIENTRY glWindowPos3fARB (GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glWindowPos3fvARB (const GLfloat *);
-GLAPI void APIENTRY glWindowPos3iARB (GLint, GLint, GLint);
-GLAPI void APIENTRY glWindowPos3ivARB (const GLint *);
-GLAPI void APIENTRY glWindowPos3sARB (GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glWindowPos3svARB (const GLshort *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLWINDOWPOS2DARBPROC) (GLdouble x, GLdouble y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2DVARBPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS2FARBPROC) (GLfloat x, GLfloat y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2FVARBPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS2IARBPROC) (GLint x, GLint y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2IVARBPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS2SARBPROC) (GLshort x, GLshort y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2SVARBPROC) (const GLshort *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3DARBPROC) (GLdouble x, GLdouble y, GLdouble z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3DVARBPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3FARBPROC) (GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3FVARBPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3IARBPROC) (GLint x, GLint y, GLint z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3IVARBPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3SARBPROC) (GLshort x, GLshort y, GLshort z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3SVARBPROC) (const GLshort *v);
-#endif
-
-#ifndef GL_ARB_vertex_program
-#define GL_ARB_vertex_program 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glVertexAttrib1dARB (GLuint, GLdouble);
-GLAPI void APIENTRY glVertexAttrib1dvARB (GLuint, const GLdouble *);
-GLAPI void APIENTRY glVertexAttrib1fARB (GLuint, GLfloat);
-GLAPI void APIENTRY glVertexAttrib1fvARB (GLuint, const GLfloat *);
-GLAPI void APIENTRY glVertexAttrib1sARB (GLuint, GLshort);
-GLAPI void APIENTRY glVertexAttrib1svARB (GLuint, const GLshort *);
-GLAPI void APIENTRY glVertexAttrib2dARB (GLuint, GLdouble, GLdouble);
-GLAPI void APIENTRY glVertexAttrib2dvARB (GLuint, const GLdouble *);
-GLAPI void APIENTRY glVertexAttrib2fARB (GLuint, GLfloat, GLfloat);
-GLAPI void APIENTRY glVertexAttrib2fvARB (GLuint, const GLfloat *);
-GLAPI void APIENTRY glVertexAttrib2sARB (GLuint, GLshort, GLshort);
-GLAPI void APIENTRY glVertexAttrib2svARB (GLuint, const GLshort *);
-GLAPI void APIENTRY glVertexAttrib3dARB (GLuint, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glVertexAttrib3dvARB (GLuint, const GLdouble *);
-GLAPI void APIENTRY glVertexAttrib3fARB (GLuint, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glVertexAttrib3fvARB (GLuint, const GLfloat *);
-GLAPI void APIENTRY glVertexAttrib3sARB (GLuint, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glVertexAttrib3svARB (GLuint, const GLshort *);
-GLAPI void APIENTRY glVertexAttrib4NbvARB (GLuint, const GLbyte *);
-GLAPI void APIENTRY glVertexAttrib4NivARB (GLuint, const GLint *);
-GLAPI void APIENTRY glVertexAttrib4NsvARB (GLuint, const GLshort *);
-GLAPI void APIENTRY glVertexAttrib4NubARB (GLuint, GLubyte, GLubyte, GLubyte, GLubyte);
-GLAPI void APIENTRY glVertexAttrib4NubvARB (GLuint, const GLubyte *);
-GLAPI void APIENTRY glVertexAttrib4NuivARB (GLuint, const GLuint *);
-GLAPI void APIENTRY glVertexAttrib4NusvARB (GLuint, const GLushort *);
-GLAPI void APIENTRY glVertexAttrib4bvARB (GLuint, const GLbyte *);
-GLAPI void APIENTRY glVertexAttrib4dARB (GLuint, GLdouble, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glVertexAttrib4dvARB (GLuint, const GLdouble *);
-GLAPI void APIENTRY glVertexAttrib4fARB (GLuint, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glVertexAttrib4fvARB (GLuint, const GLfloat *);
-GLAPI void APIENTRY glVertexAttrib4ivARB (GLuint, const GLint *);
-GLAPI void APIENTRY glVertexAttrib4sARB (GLuint, GLshort, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glVertexAttrib4svARB (GLuint, const GLshort *);
-GLAPI void APIENTRY glVertexAttrib4ubvARB (GLuint, const GLubyte *);
-GLAPI void APIENTRY glVertexAttrib4uivARB (GLuint, const GLuint *);
-GLAPI void APIENTRY glVertexAttrib4usvARB (GLuint, const GLushort *);
-GLAPI void APIENTRY glVertexAttribPointerARB (GLuint, GLint, GLenum, GLboolean, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glEnableVertexAttribArrayARB (GLuint);
-GLAPI void APIENTRY glDisableVertexAttribArrayARB (GLuint);
-GLAPI void APIENTRY glProgramStringARB (GLenum, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glBindProgramARB (GLenum, GLuint);
-GLAPI void APIENTRY glDeleteProgramsARB (GLsizei, const GLuint *);
-GLAPI void APIENTRY glGenProgramsARB (GLsizei, GLuint *);
-GLAPI void APIENTRY glProgramEnvParameter4dARB (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glProgramEnvParameter4dvARB (GLenum, GLuint, const GLdouble *);
-GLAPI void APIENTRY glProgramEnvParameter4fARB (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glProgramEnvParameter4fvARB (GLenum, GLuint, const GLfloat *);
-GLAPI void APIENTRY glProgramLocalParameter4dARB (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glProgramLocalParameter4dvARB (GLenum, GLuint, const GLdouble *);
-GLAPI void APIENTRY glProgramLocalParameter4fARB (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glProgramLocalParameter4fvARB (GLenum, GLuint, const GLfloat *);
-GLAPI void APIENTRY glGetProgramEnvParameterdvARB (GLenum, GLuint, GLdouble *);
-GLAPI void APIENTRY glGetProgramEnvParameterfvARB (GLenum, GLuint, GLfloat *);
-GLAPI void APIENTRY glGetProgramLocalParameterdvARB (GLenum, GLuint, GLdouble *);
-GLAPI void APIENTRY glGetProgramLocalParameterfvARB (GLenum, GLuint, GLfloat *);
-GLAPI void APIENTRY glGetProgramivARB (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetProgramStringARB (GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetVertexAttribdvARB (GLuint, GLenum, GLdouble *);
-GLAPI void APIENTRY glGetVertexAttribfvARB (GLuint, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetVertexAttribivARB (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glGetVertexAttribPointervARB (GLuint, GLenum, GLvoid* *);
-GLAPI GLboolean APIENTRY glIsProgramARB (GLuint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1DARBPROC) (GLuint index, GLdouble x);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1DVARBPROC) (GLuint index, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1FARBPROC) (GLuint index, GLfloat x);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1FVARBPROC) (GLuint index, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1SARBPROC) (GLuint index, GLshort x);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1SVARBPROC) (GLuint index, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2DARBPROC) (GLuint index, GLdouble x, GLdouble y);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2DVARBPROC) (GLuint index, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2FARBPROC) (GLuint index, GLfloat x, GLfloat y);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2FVARBPROC) (GLuint index, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2SARBPROC) (GLuint index, GLshort x, GLshort y);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2SVARBPROC) (GLuint index, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3DARBPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3DVARBPROC) (GLuint index, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3FARBPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3FVARBPROC) (GLuint index, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3SARBPROC) (GLuint index, GLshort x, GLshort y, GLshort z);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3SVARBPROC) (GLuint index, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4NBVARBPROC) (GLuint index, const GLbyte *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4NIVARBPROC) (GLuint index, const GLint *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4NSVARBPROC) (GLuint index, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4NUBARBPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4NUBVARBPROC) (GLuint index, const GLubyte *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4NUIVARBPROC) (GLuint index, const GLuint *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4NUSVARBPROC) (GLuint index, const GLushort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4BVARBPROC) (GLuint index, const GLbyte *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4DARBPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4DVARBPROC) (GLuint index, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4FARBPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4FVARBPROC) (GLuint index, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4IVARBPROC) (GLuint index, const GLint *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4SARBPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4SVARBPROC) (GLuint index, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4UBVARBPROC) (GLuint index, const GLubyte *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4UIVARBPROC) (GLuint index, const GLuint *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4USVARBPROC) (GLuint index, const GLushort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBPOINTERARBPROC) (GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLENABLEVERTEXATTRIBARRAYARBPROC) (GLuint index);
-typedef void (APIENTRY * PFNGLDISABLEVERTEXATTRIBARRAYARBPROC) (GLuint index);
-typedef void (APIENTRY * PFNGLPROGRAMSTRINGARBPROC) (GLenum target, GLenum format, GLsizei len, const GLvoid *string);
-typedef void (APIENTRY * PFNGLBINDPROGRAMARBPROC) (GLenum target, GLuint program);
-typedef void (APIENTRY * PFNGLDELETEPROGRAMSARBPROC) (GLsizei n, const GLuint *programs);
-typedef void (APIENTRY * PFNGLGENPROGRAMSARBPROC) (GLsizei n, GLuint *programs);
-typedef void (APIENTRY * PFNGLPROGRAMENVPARAMETER4DARBPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
-typedef void (APIENTRY * PFNGLPROGRAMENVPARAMETER4DVARBPROC) (GLenum target, GLuint index, const GLdouble *params);
-typedef void (APIENTRY * PFNGLPROGRAMENVPARAMETER4FARBPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRY * PFNGLPROGRAMENVPARAMETER4FVARBPROC) (GLenum target, GLuint index, const GLfloat *params);
-typedef void (APIENTRY * PFNGLPROGRAMLOCALPARAMETER4DARBPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
-typedef void (APIENTRY * PFNGLPROGRAMLOCALPARAMETER4DVARBPROC) (GLenum target, GLuint index, const GLdouble *params);
-typedef void (APIENTRY * PFNGLPROGRAMLOCALPARAMETER4FARBPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRY * PFNGLPROGRAMLOCALPARAMETER4FVARBPROC) (GLenum target, GLuint index, const GLfloat *params);
-typedef void (APIENTRY * PFNGLGETPROGRAMENVPARAMETERDVARBPROC) (GLenum target, GLuint index, GLdouble *params);
-typedef void (APIENTRY * PFNGLGETPROGRAMENVPARAMETERFVARBPROC) (GLenum target, GLuint index, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETPROGRAMLOCALPARAMETERDVARBPROC) (GLenum target, GLuint index, GLdouble *params);
-typedef void (APIENTRY * PFNGLGETPROGRAMLOCALPARAMETERFVARBPROC) (GLenum target, GLuint index, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETPROGRAMIVARBPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETPROGRAMSTRINGARBPROC) (GLenum target, GLenum pname, GLvoid *string);
-typedef void (APIENTRY * PFNGLGETVERTEXATTRIBDVARBPROC) (GLuint index, GLenum pname, GLdouble *params);
-typedef void (APIENTRY * PFNGLGETVERTEXATTRIBFVARBPROC) (GLuint index, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETVERTEXATTRIBIVARBPROC) (GLuint index, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETVERTEXATTRIBPOINTERVARBPROC) (GLuint index, GLenum pname, GLvoid* *pointer);
-typedef GLboolean (APIENTRY * PFNGLISPROGRAMARBPROC) (GLuint program);
-#endif
-
-#ifndef GL_EXT_abgr
-#define GL_EXT_abgr 1
-#endif
-
-#ifndef GL_EXT_blend_color
-#define GL_EXT_blend_color 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glBlendColorEXT (GLclampf, GLclampf, GLclampf, GLclampf);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLBLENDCOLOREXTPROC) (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
-#endif
-
-#ifndef GL_EXT_polygon_offset
-#define GL_EXT_polygon_offset 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPolygonOffsetEXT (GLfloat, GLfloat);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLPOLYGONOFFSETEXTPROC) (GLfloat factor, GLfloat bias);
-#endif
-
-#ifndef GL_EXT_texture
-#define GL_EXT_texture 1
-#endif
-
-#ifndef GL_EXT_texture3D
-#define GL_EXT_texture3D 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glTexImage3DEXT (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glTexSubImage3DEXT (GLenum, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLTEXIMAGE3DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
-typedef void (APIENTRY * PFNGLTEXSUBIMAGE3DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const GLvoid *pixels);
-#endif
-
-#ifndef GL_SGIS_texture_filter4
-#define GL_SGIS_texture_filter4 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glGetTexFilterFuncSGIS (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glTexFilterFuncSGIS (GLenum, GLenum, GLsizei, const GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLGETTEXFILTERFUNCSGISPROC) (GLenum target, GLenum filter, GLfloat *weights);
-typedef void (APIENTRY * PFNGLTEXFILTERFUNCSGISPROC) (GLenum target, GLenum filter, GLsizei n, const GLfloat *weights);
-#endif
-
-#ifndef GL_EXT_subtexture
-#define GL_EXT_subtexture 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glTexSubImage1DEXT (GLenum, GLint, GLint, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glTexSubImage2DEXT (GLenum, GLint, GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLTEXSUBIMAGE1DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, const GLvoid *pixels);
-typedef void (APIENTRY * PFNGLTEXSUBIMAGE2DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *pixels);
-#endif
-
-#ifndef GL_EXT_copy_texture
-#define GL_EXT_copy_texture 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glCopyTexImage1DEXT (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLint);
-GLAPI void APIENTRY glCopyTexImage2DEXT (GLenum, GLint, GLenum, GLint, GLint, GLsizei, GLsizei, GLint);
-GLAPI void APIENTRY glCopyTexSubImage1DEXT (GLenum, GLint, GLint, GLint, GLint, GLsizei);
-GLAPI void APIENTRY glCopyTexSubImage2DEXT (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei);
-GLAPI void APIENTRY glCopyTexSubImage3DEXT (GLenum, GLint, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCOPYTEXIMAGE1DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLint border);
-typedef void (APIENTRY * PFNGLCOPYTEXIMAGE2DEXTPROC) (GLenum target, GLint level, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
-typedef void (APIENTRY * PFNGLCOPYTEXSUBIMAGE1DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
-typedef void (APIENTRY * PFNGLCOPYTEXSUBIMAGE2DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
-typedef void (APIENTRY * PFNGLCOPYTEXSUBIMAGE3DEXTPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
-#endif
-
-#ifndef GL_EXT_histogram
-#define GL_EXT_histogram 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glGetHistogramEXT (GLenum, GLboolean, GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetHistogramParameterfvEXT (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetHistogramParameterivEXT (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetMinmaxEXT (GLenum, GLboolean, GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetMinmaxParameterfvEXT (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetMinmaxParameterivEXT (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glHistogramEXT (GLenum, GLsizei, GLenum, GLboolean);
-GLAPI void APIENTRY glMinmaxEXT (GLenum, GLenum, GLboolean);
-GLAPI void APIENTRY glResetHistogramEXT (GLenum);
-GLAPI void APIENTRY glResetMinmaxEXT (GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLGETHISTOGRAMEXTPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
-typedef void (APIENTRY * PFNGLGETHISTOGRAMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETHISTOGRAMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETMINMAXEXTPROC) (GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid *values);
-typedef void (APIENTRY * PFNGLGETMINMAXPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETMINMAXPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLHISTOGRAMEXTPROC) (GLenum target, GLsizei width, GLenum internalformat, GLboolean sink);
-typedef void (APIENTRY * PFNGLMINMAXEXTPROC) (GLenum target, GLenum internalformat, GLboolean sink);
-typedef void (APIENTRY * PFNGLRESETHISTOGRAMEXTPROC) (GLenum target);
-typedef void (APIENTRY * PFNGLRESETMINMAXEXTPROC) (GLenum target);
-#endif
-
-#ifndef GL_EXT_convolution
-#define GL_EXT_convolution 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glConvolutionFilter1DEXT (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glConvolutionFilter2DEXT (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glConvolutionParameterfEXT (GLenum, GLenum, GLfloat);
-GLAPI void APIENTRY glConvolutionParameterfvEXT (GLenum, GLenum, const GLfloat *);
-GLAPI void APIENTRY glConvolutionParameteriEXT (GLenum, GLenum, GLint);
-GLAPI void APIENTRY glConvolutionParameterivEXT (GLenum, GLenum, const GLint *);
-GLAPI void APIENTRY glCopyConvolutionFilter1DEXT (GLenum, GLenum, GLint, GLint, GLsizei);
-GLAPI void APIENTRY glCopyConvolutionFilter2DEXT (GLenum, GLenum, GLint, GLint, GLsizei, GLsizei);
-GLAPI void APIENTRY glGetConvolutionFilterEXT (GLenum, GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetConvolutionParameterfvEXT (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetConvolutionParameterivEXT (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetSeparableFilterEXT (GLenum, GLenum, GLenum, GLvoid *, GLvoid *, GLvoid *);
-GLAPI void APIENTRY glSeparableFilter2DEXT (GLenum, GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCONVOLUTIONFILTER1DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *image);
-typedef void (APIENTRY * PFNGLCONVOLUTIONFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *image);
-typedef void (APIENTRY * PFNGLCONVOLUTIONPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat params);
-typedef void (APIENTRY * PFNGLCONVOLUTIONPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLCONVOLUTIONPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint params);
-typedef void (APIENTRY * PFNGLCONVOLUTIONPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLCOPYCONVOLUTIONFILTER1DEXTPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
-typedef void (APIENTRY * PFNGLCOPYCONVOLUTIONFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width, GLsizei height);
-typedef void (APIENTRY * PFNGLGETCONVOLUTIONFILTEREXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *image);
-typedef void (APIENTRY * PFNGLGETCONVOLUTIONPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETCONVOLUTIONPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETSEPARABLEFILTEREXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *row, GLvoid *column, GLvoid *span);
-typedef void (APIENTRY * PFNGLSEPARABLEFILTER2DEXTPROC) (GLenum target, GLenum internalformat, GLsizei width, GLsizei height, GLenum format, GLenum type, const GLvoid *row, const GLvoid *column);
-#endif
-
-#ifndef GL_EXT_color_matrix
-#define GL_EXT_color_matrix 1
-#endif
-
-#ifndef GL_SGI_color_table
-#define GL_SGI_color_table 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glColorTableSGI (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glColorTableParameterfvSGI (GLenum, GLenum, const GLfloat *);
-GLAPI void APIENTRY glColorTableParameterivSGI (GLenum, GLenum, const GLint *);
-GLAPI void APIENTRY glCopyColorTableSGI (GLenum, GLenum, GLint, GLint, GLsizei);
-GLAPI void APIENTRY glGetColorTableSGI (GLenum, GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetColorTableParameterfvSGI (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetColorTableParameterivSGI (GLenum, GLenum, GLint *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCOLORTABLESGIPROC) (GLenum target, GLenum internalformat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
-typedef void (APIENTRY * PFNGLCOLORTABLEPARAMETERFVSGIPROC) (GLenum target, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLCOLORTABLEPARAMETERIVSGIPROC) (GLenum target, GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLCOPYCOLORTABLESGIPROC) (GLenum target, GLenum internalformat, GLint x, GLint y, GLsizei width);
-typedef void (APIENTRY * PFNGLGETCOLORTABLESGIPROC) (GLenum target, GLenum format, GLenum type, GLvoid *table);
-typedef void (APIENTRY * PFNGLGETCOLORTABLEPARAMETERFVSGIPROC) (GLenum target, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETCOLORTABLEPARAMETERIVSGIPROC) (GLenum target, GLenum pname, GLint *params);
-#endif
-
-#ifndef GL_SGIX_pixel_texture
-#define GL_SGIX_pixel_texture 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPixelTexGenSGIX (GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLPIXELTEXGENSGIXPROC) (GLenum mode);
-#endif
-
-#ifndef GL_SGIS_pixel_texture
-#define GL_SGIS_pixel_texture 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPixelTexGenParameteriSGIS (GLenum, GLint);
-GLAPI void APIENTRY glPixelTexGenParameterivSGIS (GLenum, const GLint *);
-GLAPI void APIENTRY glPixelTexGenParameterfSGIS (GLenum, GLfloat);
-GLAPI void APIENTRY glPixelTexGenParameterfvSGIS (GLenum, const GLfloat *);
-GLAPI void APIENTRY glGetPixelTexGenParameterivSGIS (GLenum, GLint *);
-GLAPI void APIENTRY glGetPixelTexGenParameterfvSGIS (GLenum, GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLPIXELTEXGENPARAMETERISGISPROC) (GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLPIXELTEXGENPARAMETERIVSGISPROC) (GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLPIXELTEXGENPARAMETERFSGISPROC) (GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLPIXELTEXGENPARAMETERFVSGISPROC) (GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLGETPIXELTEXGENPARAMETERIVSGISPROC) (GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETPIXELTEXGENPARAMETERFVSGISPROC) (GLenum pname, GLfloat *params);
-#endif
-
-#ifndef GL_SGIS_texture4D
-#define GL_SGIS_texture4D 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glTexImage4DSGIS (GLenum, GLint, GLenum, GLsizei, GLsizei, GLsizei, GLsizei, GLint, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glTexSubImage4DSGIS (GLenum, GLint, GLint, GLint, GLint, GLint, GLsizei, GLsizei, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLTEXIMAGE4DSGISPROC) (GLenum target, GLint level, GLenum internalformat, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
-typedef void (APIENTRY * PFNGLTEXSUBIMAGE4DSGISPROC) (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint woffset, GLsizei width, GLsizei height, GLsizei depth, GLsizei size4d, GLenum format, GLenum type, const GLvoid *pixels);
-#endif
-
-#ifndef GL_SGI_texture_color_table
-#define GL_SGI_texture_color_table 1
-#endif
-
-#ifndef GL_EXT_cmyka
-#define GL_EXT_cmyka 1
-#endif
-
-#ifndef GL_EXT_texture_object
-#define GL_EXT_texture_object 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI GLboolean APIENTRY glAreTexturesResidentEXT (GLsizei, const GLuint *, GLboolean *);
-GLAPI void APIENTRY glBindTextureEXT (GLenum, GLuint);
-GLAPI void APIENTRY glDeleteTexturesEXT (GLsizei, const GLuint *);
-GLAPI void APIENTRY glGenTexturesEXT (GLsizei, GLuint *);
-GLAPI GLboolean APIENTRY glIsTextureEXT (GLuint);
-GLAPI void APIENTRY glPrioritizeTexturesEXT (GLsizei, const GLuint *, const GLclampf *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef GLboolean (APIENTRY * PFNGLARETEXTURESRESIDENTEXTPROC) (GLsizei n, const GLuint *textures, GLboolean *residences);
-typedef void (APIENTRY * PFNGLBINDTEXTUREEXTPROC) (GLenum target, GLuint texture);
-typedef void (APIENTRY * PFNGLDELETETEXTURESEXTPROC) (GLsizei n, const GLuint *textures);
-typedef void (APIENTRY * PFNGLGENTEXTURESEXTPROC) (GLsizei n, GLuint *textures);
-typedef GLboolean (APIENTRY * PFNGLISTEXTUREEXTPROC) (GLuint texture);
-typedef void (APIENTRY * PFNGLPRIORITIZETEXTURESEXTPROC) (GLsizei n, const GLuint *textures, const GLclampf *priorities);
-#endif
-
-#ifndef GL_SGIS_detail_texture
-#define GL_SGIS_detail_texture 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glDetailTexFuncSGIS (GLenum, GLsizei, const GLfloat *);
-GLAPI void APIENTRY glGetDetailTexFuncSGIS (GLenum, GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLDETAILTEXFUNCSGISPROC) (GLenum target, GLsizei n, const GLfloat *points);
-typedef void (APIENTRY * PFNGLGETDETAILTEXFUNCSGISPROC) (GLenum target, GLfloat *points);
-#endif
-
-#ifndef GL_SGIS_sharpen_texture
-#define GL_SGIS_sharpen_texture 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glSharpenTexFuncSGIS (GLenum, GLsizei, const GLfloat *);
-GLAPI void APIENTRY glGetSharpenTexFuncSGIS (GLenum, GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLSHARPENTEXFUNCSGISPROC) (GLenum target, GLsizei n, const GLfloat *points);
-typedef void (APIENTRY * PFNGLGETSHARPENTEXFUNCSGISPROC) (GLenum target, GLfloat *points);
-#endif
-
-#ifndef GL_EXT_packed_pixels
-#define GL_EXT_packed_pixels 1
-#endif
-
-#ifndef GL_SGIS_texture_lod
-#define GL_SGIS_texture_lod 1
-#endif
-
-#ifndef GL_SGIS_multisample
-#define GL_SGIS_multisample 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glSampleMaskSGIS (GLclampf, GLboolean);
-GLAPI void APIENTRY glSamplePatternSGIS (GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLSAMPLEMASKSGISPROC) (GLclampf value, GLboolean invert);
-typedef void (APIENTRY * PFNGLSAMPLEPATTERNSGISPROC) (GLenum pattern);
-#endif
-
-#ifndef GL_EXT_rescale_normal
-#define GL_EXT_rescale_normal 1
-#endif
-
-#ifndef GL_EXT_vertex_array
-#define GL_EXT_vertex_array 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glArrayElementEXT (GLint);
-GLAPI void APIENTRY glColorPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glDrawArraysEXT (GLenum, GLint, GLsizei);
-GLAPI void APIENTRY glEdgeFlagPointerEXT (GLsizei, GLsizei, const GLboolean *);
-GLAPI void APIENTRY glGetPointervEXT (GLenum, GLvoid* *);
-GLAPI void APIENTRY glIndexPointerEXT (GLenum, GLsizei, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glNormalPointerEXT (GLenum, GLsizei, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glTexCoordPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glVertexPointerEXT (GLint, GLenum, GLsizei, GLsizei, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLARRAYELEMENTEXTPROC) (GLint i);
-typedef void (APIENTRY * PFNGLCOLORPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLDRAWARRAYSEXTPROC) (GLenum mode, GLint first, GLsizei count);
-typedef void (APIENTRY * PFNGLEDGEFLAGPOINTEREXTPROC) (GLsizei stride, GLsizei count, const GLboolean *pointer);
-typedef void (APIENTRY * PFNGLGETPOINTERVEXTPROC) (GLenum pname, GLvoid* *params);
-typedef void (APIENTRY * PFNGLINDEXPOINTEREXTPROC) (GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLNORMALPOINTEREXTPROC) (GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLTEXCOORDPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLVERTEXPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer);
-#endif
-
-#ifndef GL_EXT_misc_attribute
-#define GL_EXT_misc_attribute 1
-#endif
-
-#ifndef GL_SGIS_generate_mipmap
-#define GL_SGIS_generate_mipmap 1
-#endif
-
-#ifndef GL_SGIX_clipmap
-#define GL_SGIX_clipmap 1
-#endif
-
-#ifndef GL_SGIX_shadow
-#define GL_SGIX_shadow 1
-#endif
-
-#ifndef GL_SGIS_texture_edge_clamp
-#define GL_SGIS_texture_edge_clamp 1
-#endif
-
-#ifndef GL_SGIS_texture_border_clamp
-#define GL_SGIS_texture_border_clamp 1
-#endif
-
-#ifndef GL_EXT_blend_minmax
-#define GL_EXT_blend_minmax 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glBlendEquationEXT (GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLBLENDEQUATIONEXTPROC) (GLenum mode);
-#endif
-
-#ifndef GL_EXT_blend_subtract
-#define GL_EXT_blend_subtract 1
-#endif
-
-#ifndef GL_EXT_blend_logic_op
-#define GL_EXT_blend_logic_op 1
-#endif
-
-#ifndef GL_SGIX_interlace
-#define GL_SGIX_interlace 1
-#endif
-
-#ifndef GL_SGIX_pixel_tiles
-#define GL_SGIX_pixel_tiles 1
-#endif
-
-#ifndef GL_SGIX_texture_select
-#define GL_SGIX_texture_select 1
-#endif
-
-#ifndef GL_SGIX_sprite
-#define GL_SGIX_sprite 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glSpriteParameterfSGIX (GLenum, GLfloat);
-GLAPI void APIENTRY glSpriteParameterfvSGIX (GLenum, const GLfloat *);
-GLAPI void APIENTRY glSpriteParameteriSGIX (GLenum, GLint);
-GLAPI void APIENTRY glSpriteParameterivSGIX (GLenum, const GLint *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLSPRITEPARAMETERFSGIXPROC) (GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLSPRITEPARAMETERFVSGIXPROC) (GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLSPRITEPARAMETERISGIXPROC) (GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLSPRITEPARAMETERIVSGIXPROC) (GLenum pname, const GLint *params);
-#endif
-
-#ifndef GL_SGIX_texture_multi_buffer
-#define GL_SGIX_texture_multi_buffer 1
-#endif
-
-#ifndef GL_EXT_point_parameters
-#define GL_EXT_point_parameters 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPointParameterfEXT (GLenum, GLfloat);
-GLAPI void APIENTRY glPointParameterfvEXT (GLenum, const GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLPOINTPARAMETERFEXTPROC) (GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLPOINTPARAMETERFVEXTPROC) (GLenum pname, const GLfloat *params);
-#endif
-
-#ifndef GL_SGIS_point_parameters
-#define GL_SGIS_point_parameters 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPointParameterfSGIS (GLenum, GLfloat);
-GLAPI void APIENTRY glPointParameterfvSGIS (GLenum, const GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLPOINTPARAMETERFSGISPROC) (GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLPOINTPARAMETERFVSGISPROC) (GLenum pname, const GLfloat *params);
-#endif
-
-#ifndef GL_SGIX_instruments
-#define GL_SGIX_instruments 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI GLint APIENTRY glGetInstrumentsSGIX (void);
-GLAPI void APIENTRY glInstrumentsBufferSGIX (GLsizei, GLint *);
-GLAPI GLint APIENTRY glPollInstrumentsSGIX (GLint *);
-GLAPI void APIENTRY glReadInstrumentsSGIX (GLint);
-GLAPI void APIENTRY glStartInstrumentsSGIX (void);
-GLAPI void APIENTRY glStopInstrumentsSGIX (GLint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef GLint (APIENTRY * PFNGLGETINSTRUMENTSSGIXPROC) (void);
-typedef void (APIENTRY * PFNGLINSTRUMENTSBUFFERSGIXPROC) (GLsizei size, GLint *buffer);
-typedef GLint (APIENTRY * PFNGLPOLLINSTRUMENTSSGIXPROC) (GLint *marker_p);
-typedef void (APIENTRY * PFNGLREADINSTRUMENTSSGIXPROC) (GLint marker);
-typedef void (APIENTRY * PFNGLSTARTINSTRUMENTSSGIXPROC) (void);
-typedef void (APIENTRY * PFNGLSTOPINSTRUMENTSSGIXPROC) (GLint marker);
-#endif
-
-#ifndef GL_SGIX_texture_scale_bias
-#define GL_SGIX_texture_scale_bias 1
-#endif
-
-#ifndef GL_SGIX_framezoom
-#define GL_SGIX_framezoom 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glFrameZoomSGIX (GLint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLFRAMEZOOMSGIXPROC) (GLint factor);
-#endif
-
-#ifndef GL_SGIX_tag_sample_buffer
-#define GL_SGIX_tag_sample_buffer 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glTagSampleBufferSGIX (void);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLTAGSAMPLEBUFFERSGIXPROC) (void);
-#endif
-
-#ifndef GL_SGIX_polynomial_ffd
-#define GL_SGIX_polynomial_ffd 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glDeformationMap3dSGIX (GLenum, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, GLdouble, GLdouble, GLint, GLint, const GLdouble *);
-GLAPI void APIENTRY glDeformationMap3fSGIX (GLenum, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, GLfloat, GLfloat, GLint, GLint, const GLfloat *);
-GLAPI void APIENTRY glDeformSGIX (GLbitfield);
-GLAPI void APIENTRY glLoadIdentityDeformationMapSGIX (GLbitfield);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLDEFORMATIONMAP3DSGIXPROC) (GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble w1, GLdouble w2, GLint wstride, GLint worder, const GLdouble *points);
-typedef void (APIENTRY * PFNGLDEFORMATIONMAP3FSGIXPROC) (GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat w1, GLfloat w2, GLint wstride, GLint worder, const GLfloat *points);
-typedef void (APIENTRY * PFNGLDEFORMSGIXPROC) (GLbitfield mask);
-typedef void (APIENTRY * PFNGLLOADIDENTITYDEFORMATIONMAPSGIXPROC) (GLbitfield mask);
-#endif
-
-#ifndef GL_SGIX_reference_plane
-#define GL_SGIX_reference_plane 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glReferencePlaneSGIX (const GLdouble *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLREFERENCEPLANESGIXPROC) (const GLdouble *equation);
-#endif
-
-#ifndef GL_SGIX_flush_raster
-#define GL_SGIX_flush_raster 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glFlushRasterSGIX (void);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLFLUSHRASTERSGIXPROC) (void);
-#endif
-
-#ifndef GL_SGIX_depth_texture
-#define GL_SGIX_depth_texture 1
-#endif
-
-#ifndef GL_SGIS_fog_function
-#define GL_SGIS_fog_function 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glFogFuncSGIS (GLsizei, const GLfloat *);
-GLAPI void APIENTRY glGetFogFuncSGIS (GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLFOGFUNCSGISPROC) (GLsizei n, const GLfloat *points);
-typedef void (APIENTRY * PFNGLGETFOGFUNCSGISPROC) (GLfloat *points);
-#endif
-
-#ifndef GL_SGIX_fog_offset
-#define GL_SGIX_fog_offset 1
-#endif
-
-#ifndef GL_HP_image_transform
-#define GL_HP_image_transform 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glImageTransformParameteriHP (GLenum, GLenum, GLint);
-GLAPI void APIENTRY glImageTransformParameterfHP (GLenum, GLenum, GLfloat);
-GLAPI void APIENTRY glImageTransformParameterivHP (GLenum, GLenum, const GLint *);
-GLAPI void APIENTRY glImageTransformParameterfvHP (GLenum, GLenum, const GLfloat *);
-GLAPI void APIENTRY glGetImageTransformParameterivHP (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetImageTransformParameterfvHP (GLenum, GLenum, GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLIMAGETRANSFORMPARAMETERIHPPROC) (GLenum target, GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLIMAGETRANSFORMPARAMETERFHPPROC) (GLenum target, GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLIMAGETRANSFORMPARAMETERIVHPPROC) (GLenum target, GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLIMAGETRANSFORMPARAMETERFVHPPROC) (GLenum target, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLGETIMAGETRANSFORMPARAMETERIVHPPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETIMAGETRANSFORMPARAMETERFVHPPROC) (GLenum target, GLenum pname, GLfloat *params);
-#endif
-
-#ifndef GL_HP_convolution_border_modes
-#define GL_HP_convolution_border_modes 1
-#endif
-
-#ifndef GL_SGIX_texture_add_env
-#define GL_SGIX_texture_add_env 1
-#endif
-
-#ifndef GL_EXT_color_subtable
-#define GL_EXT_color_subtable 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glColorSubTableEXT (GLenum, GLsizei, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glCopyColorSubTableEXT (GLenum, GLsizei, GLint, GLint, GLsizei);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCOLORSUBTABLEEXTPROC) (GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum type, const GLvoid *data);
-typedef void (APIENTRY * PFNGLCOPYCOLORSUBTABLEEXTPROC) (GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
-#endif
-
-#ifndef GL_PGI_vertex_hints
-#define GL_PGI_vertex_hints 1
-#endif
-
-#ifndef GL_PGI_misc_hints
-#define GL_PGI_misc_hints 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glHintPGI (GLenum, GLint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLHINTPGIPROC) (GLenum target, GLint mode);
-#endif
-
-#ifndef GL_EXT_paletted_texture
-#define GL_EXT_paletted_texture 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glColorTableEXT (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *);
-GLAPI void APIENTRY glGetColorTableEXT (GLenum, GLenum, GLenum, GLvoid *);
-GLAPI void APIENTRY glGetColorTableParameterivEXT (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetColorTableParameterfvEXT (GLenum, GLenum, GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCOLORTABLEEXTPROC) (GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum type, const GLvoid *table);
-typedef void (APIENTRY * PFNGLGETCOLORTABLEEXTPROC) (GLenum target, GLenum format, GLenum type, GLvoid *data);
-typedef void (APIENTRY * PFNGLGETCOLORTABLEPARAMETERIVEXTPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETCOLORTABLEPARAMETERFVEXTPROC) (GLenum target, GLenum pname, GLfloat *params);
-#endif
-
-#ifndef GL_EXT_clip_volume_hint
-#define GL_EXT_clip_volume_hint 1
-#endif
-
-#ifndef GL_SGIX_list_priority
-#define GL_SGIX_list_priority 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glGetListParameterfvSGIX (GLuint, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetListParameterivSGIX (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glListParameterfSGIX (GLuint, GLenum, GLfloat);
-GLAPI void APIENTRY glListParameterfvSGIX (GLuint, GLenum, const GLfloat *);
-GLAPI void APIENTRY glListParameteriSGIX (GLuint, GLenum, GLint);
-GLAPI void APIENTRY glListParameterivSGIX (GLuint, GLenum, const GLint *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLGETLISTPARAMETERFVSGIXPROC) (GLuint list, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETLISTPARAMETERIVSGIXPROC) (GLuint list, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLLISTPARAMETERFSGIXPROC) (GLuint list, GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLLISTPARAMETERFVSGIXPROC) (GLuint list, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLLISTPARAMETERISGIXPROC) (GLuint list, GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLLISTPARAMETERIVSGIXPROC) (GLuint list, GLenum pname, const GLint *params);
-#endif
-
-#ifndef GL_SGIX_ir_instrument1
-#define GL_SGIX_ir_instrument1 1
-#endif
-
-#ifndef GL_SGIX_calligraphic_fragment
-#define GL_SGIX_calligraphic_fragment 1
-#endif
-
-#ifndef GL_SGIX_texture_lod_bias
-#define GL_SGIX_texture_lod_bias 1
-#endif
-
-#ifndef GL_SGIX_shadow_ambient
-#define GL_SGIX_shadow_ambient 1
-#endif
-
-#ifndef GL_EXT_index_texture
-#define GL_EXT_index_texture 1
-#endif
-
-#ifndef GL_EXT_index_material
-#define GL_EXT_index_material 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glIndexMaterialEXT (GLenum, GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLINDEXMATERIALEXTPROC) (GLenum face, GLenum mode);
-#endif
-
-#ifndef GL_EXT_index_func
-#define GL_EXT_index_func 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glIndexFuncEXT (GLenum, GLclampf);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLINDEXFUNCEXTPROC) (GLenum func, GLclampf ref);
-#endif
-
-#ifndef GL_EXT_index_array_formats
-#define GL_EXT_index_array_formats 1
-#endif
-
-#ifndef GL_EXT_compiled_vertex_array
-#define GL_EXT_compiled_vertex_array 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glLockArraysEXT (GLint, GLsizei);
-GLAPI void APIENTRY glUnlockArraysEXT (void);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLLOCKARRAYSEXTPROC) (GLint first, GLsizei count);
-typedef void (APIENTRY * PFNGLUNLOCKARRAYSEXTPROC) (void);
-#endif
-
-#ifndef GL_EXT_cull_vertex
-#define GL_EXT_cull_vertex 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glCullParameterdvEXT (GLenum, GLdouble *);
-GLAPI void APIENTRY glCullParameterfvEXT (GLenum, GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCULLPARAMETERDVEXTPROC) (GLenum pname, GLdouble *params);
-typedef void (APIENTRY * PFNGLCULLPARAMETERFVEXTPROC) (GLenum pname, GLfloat *params);
-#endif
-
-#ifndef GL_SGIX_ycrcb
-#define GL_SGIX_ycrcb 1
-#endif
-
-#ifndef GL_SGIX_fragment_lighting
-#define GL_SGIX_fragment_lighting 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glFragmentColorMaterialSGIX (GLenum, GLenum);
-GLAPI void APIENTRY glFragmentLightfSGIX (GLenum, GLenum, GLfloat);
-GLAPI void APIENTRY glFragmentLightfvSGIX (GLenum, GLenum, const GLfloat *);
-GLAPI void APIENTRY glFragmentLightiSGIX (GLenum, GLenum, GLint);
-GLAPI void APIENTRY glFragmentLightivSGIX (GLenum, GLenum, const GLint *);
-GLAPI void APIENTRY glFragmentLightModelfSGIX (GLenum, GLfloat);
-GLAPI void APIENTRY glFragmentLightModelfvSGIX (GLenum, const GLfloat *);
-GLAPI void APIENTRY glFragmentLightModeliSGIX (GLenum, GLint);
-GLAPI void APIENTRY glFragmentLightModelivSGIX (GLenum, const GLint *);
-GLAPI void APIENTRY glFragmentMaterialfSGIX (GLenum, GLenum, GLfloat);
-GLAPI void APIENTRY glFragmentMaterialfvSGIX (GLenum, GLenum, const GLfloat *);
-GLAPI void APIENTRY glFragmentMaterialiSGIX (GLenum, GLenum, GLint);
-GLAPI void APIENTRY glFragmentMaterialivSGIX (GLenum, GLenum, const GLint *);
-GLAPI void APIENTRY glGetFragmentLightfvSGIX (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetFragmentLightivSGIX (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetFragmentMaterialfvSGIX (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetFragmentMaterialivSGIX (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glLightEnviSGIX (GLenum, GLint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLFRAGMENTCOLORMATERIALSGIXPROC) (GLenum face, GLenum mode);
-typedef void (APIENTRY * PFNGLFRAGMENTLIGHTFSGIXPROC) (GLenum light, GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLFRAGMENTLIGHTFVSGIXPROC) (GLenum light, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLFRAGMENTLIGHTISGIXPROC) (GLenum light, GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLFRAGMENTLIGHTIVSGIXPROC) (GLenum light, GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLFRAGMENTLIGHTMODELFSGIXPROC) (GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLFRAGMENTLIGHTMODELFVSGIXPROC) (GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLFRAGMENTLIGHTMODELISGIXPROC) (GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLFRAGMENTLIGHTMODELIVSGIXPROC) (GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLFRAGMENTMATERIALFSGIXPROC) (GLenum face, GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLFRAGMENTMATERIALFVSGIXPROC) (GLenum face, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLFRAGMENTMATERIALISGIXPROC) (GLenum face, GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLFRAGMENTMATERIALIVSGIXPROC) (GLenum face, GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLGETFRAGMENTLIGHTFVSGIXPROC) (GLenum light, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETFRAGMENTLIGHTIVSGIXPROC) (GLenum light, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETFRAGMENTMATERIALFVSGIXPROC) (GLenum face, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETFRAGMENTMATERIALIVSGIXPROC) (GLenum face, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLLIGHTENVISGIXPROC) (GLenum pname, GLint param);
-#endif
-
-#ifndef GL_IBM_rasterpos_clip
-#define GL_IBM_rasterpos_clip 1
-#endif
-
-#ifndef GL_HP_texture_lighting
-#define GL_HP_texture_lighting 1
-#endif
-
-#ifndef GL_EXT_draw_range_elements
-#define GL_EXT_draw_range_elements 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glDrawRangeElementsEXT (GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLDRAWRANGEELEMENTSEXTPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum type, const GLvoid *indices);
-#endif
-
-#ifndef GL_WIN_phong_shading
-#define GL_WIN_phong_shading 1
-#endif
-
-#ifndef GL_WIN_specular_fog
-#define GL_WIN_specular_fog 1
-#endif
-
-#ifndef GL_EXT_light_texture
-#define GL_EXT_light_texture 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glApplyTextureEXT (GLenum);
-GLAPI void APIENTRY glTextureLightEXT (GLenum);
-GLAPI void APIENTRY glTextureMaterialEXT (GLenum, GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLAPPLYTEXTUREEXTPROC) (GLenum mode);
-typedef void (APIENTRY * PFNGLTEXTURELIGHTEXTPROC) (GLenum pname);
-typedef void (APIENTRY * PFNGLTEXTUREMATERIALEXTPROC) (GLenum face, GLenum mode);
-#endif
-
-#ifndef GL_SGIX_blend_alpha_minmax
-#define GL_SGIX_blend_alpha_minmax 1
-#endif
-
-#ifndef GL_EXT_bgra
-#define GL_EXT_bgra 1
-#endif
-
-#ifndef GL_SGIX_async
-#define GL_SGIX_async 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glAsyncMarkerSGIX (GLuint);
-GLAPI GLint APIENTRY glFinishAsyncSGIX (GLuint *);
-GLAPI GLint APIENTRY glPollAsyncSGIX (GLuint *);
-GLAPI GLuint APIENTRY glGenAsyncMarkersSGIX (GLsizei);
-GLAPI void APIENTRY glDeleteAsyncMarkersSGIX (GLuint, GLsizei);
-GLAPI GLboolean APIENTRY glIsAsyncMarkerSGIX (GLuint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLASYNCMARKERSGIXPROC) (GLuint marker);
-typedef GLint (APIENTRY * PFNGLFINISHASYNCSGIXPROC) (GLuint *markerp);
-typedef GLint (APIENTRY * PFNGLPOLLASYNCSGIXPROC) (GLuint *markerp);
-typedef GLuint (APIENTRY * PFNGLGENASYNCMARKERSSGIXPROC) (GLsizei range);
-typedef void (APIENTRY * PFNGLDELETEASYNCMARKERSSGIXPROC) (GLuint marker, GLsizei range);
-typedef GLboolean (APIENTRY * PFNGLISASYNCMARKERSGIXPROC) (GLuint marker);
-#endif
-
-#ifndef GL_SGIX_async_pixel
-#define GL_SGIX_async_pixel 1
-#endif
-
-#ifndef GL_SGIX_async_histogram
-#define GL_SGIX_async_histogram 1
-#endif
-
-#ifndef GL_INTEL_parallel_arrays
-#define GL_INTEL_parallel_arrays 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glVertexPointervINTEL (GLint, GLenum, const GLvoid* *);
-GLAPI void APIENTRY glNormalPointervINTEL (GLenum, const GLvoid* *);
-GLAPI void APIENTRY glColorPointervINTEL (GLint, GLenum, const GLvoid* *);
-GLAPI void APIENTRY glTexCoordPointervINTEL (GLint, GLenum, const GLvoid* *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLVERTEXPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer);
-typedef void (APIENTRY * PFNGLNORMALPOINTERVINTELPROC) (GLenum type, const GLvoid* *pointer);
-typedef void (APIENTRY * PFNGLCOLORPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer);
-typedef void (APIENTRY * PFNGLTEXCOORDPOINTERVINTELPROC) (GLint size, GLenum type, const GLvoid* *pointer);
-#endif
-
-#ifndef GL_HP_occlusion_test
-#define GL_HP_occlusion_test 1
-#endif
-
-#ifndef GL_EXT_pixel_transform
-#define GL_EXT_pixel_transform 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPixelTransformParameteriEXT (GLenum, GLenum, GLint);
-GLAPI void APIENTRY glPixelTransformParameterfEXT (GLenum, GLenum, GLfloat);
-GLAPI void APIENTRY glPixelTransformParameterivEXT (GLenum, GLenum, const GLint *);
-GLAPI void APIENTRY glPixelTransformParameterfvEXT (GLenum, GLenum, const GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLPIXELTRANSFORMPARAMETERIEXTPROC) (GLenum target, GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLPIXELTRANSFORMPARAMETERFEXTPROC) (GLenum target, GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLPIXELTRANSFORMPARAMETERIVEXTPROC) (GLenum target, GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLPIXELTRANSFORMPARAMETERFVEXTPROC) (GLenum target, GLenum pname, const GLfloat *params);
-#endif
-
-#ifndef GL_EXT_pixel_transform_color_table
-#define GL_EXT_pixel_transform_color_table 1
-#endif
-
-#ifndef GL_EXT_shared_texture_palette
-#define GL_EXT_shared_texture_palette 1
-#endif
-
-#ifndef GL_EXT_separate_specular_color
-#define GL_EXT_separate_specular_color 1
-#endif
-
-#ifndef GL_EXT_secondary_color
-#define GL_EXT_secondary_color 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glSecondaryColor3bEXT (GLbyte, GLbyte, GLbyte);
-GLAPI void APIENTRY glSecondaryColor3bvEXT (const GLbyte *);
-GLAPI void APIENTRY glSecondaryColor3dEXT (GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glSecondaryColor3dvEXT (const GLdouble *);
-GLAPI void APIENTRY glSecondaryColor3fEXT (GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glSecondaryColor3fvEXT (const GLfloat *);
-GLAPI void APIENTRY glSecondaryColor3iEXT (GLint, GLint, GLint);
-GLAPI void APIENTRY glSecondaryColor3ivEXT (const GLint *);
-GLAPI void APIENTRY glSecondaryColor3sEXT (GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glSecondaryColor3svEXT (const GLshort *);
-GLAPI void APIENTRY glSecondaryColor3ubEXT (GLubyte, GLubyte, GLubyte);
-GLAPI void APIENTRY glSecondaryColor3ubvEXT (const GLubyte *);
-GLAPI void APIENTRY glSecondaryColor3uiEXT (GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glSecondaryColor3uivEXT (const GLuint *);
-GLAPI void APIENTRY glSecondaryColor3usEXT (GLushort, GLushort, GLushort);
-GLAPI void APIENTRY glSecondaryColor3usvEXT (const GLushort *);
-GLAPI void APIENTRY glSecondaryColorPointerEXT (GLint, GLenum, GLsizei, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3BEXTPROC) (GLbyte red, GLbyte green, GLbyte blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3BVEXTPROC) (const GLbyte *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3DEXTPROC) (GLdouble red, GLdouble green, GLdouble blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3DVEXTPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3FEXTPROC) (GLfloat red, GLfloat green, GLfloat blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3FVEXTPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3IEXTPROC) (GLint red, GLint green, GLint blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3IVEXTPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3SEXTPROC) (GLshort red, GLshort green, GLshort blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3SVEXTPROC) (const GLshort *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3UBEXTPROC) (GLubyte red, GLubyte green, GLubyte blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3UBVEXTPROC) (const GLubyte *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3UIEXTPROC) (GLuint red, GLuint green, GLuint blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3UIVEXTPROC) (const GLuint *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3USEXTPROC) (GLushort red, GLushort green, GLushort blue);
-typedef void (APIENTRY * PFNGLSECONDARYCOLOR3USVEXTPROC) (const GLushort *v);
-typedef void (APIENTRY * PFNGLSECONDARYCOLORPOINTEREXTPROC) (GLint size, GLenum type, GLsizei stride, const GLvoid *pointer);
-#endif
-
-#ifndef GL_EXT_texture_perturb_normal
-#define GL_EXT_texture_perturb_normal 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glTextureNormalEXT (GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLTEXTURENORMALEXTPROC) (GLenum mode);
-#endif
-
-#ifndef GL_EXT_multi_draw_arrays
-#define GL_EXT_multi_draw_arrays 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glMultiDrawArraysEXT (GLenum, GLint *, GLsizei *, GLsizei);
-GLAPI void APIENTRY glMultiDrawElementsEXT (GLenum, const GLsizei *, GLenum, const GLvoid* *, GLsizei);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLMULTIDRAWARRAYSEXTPROC) (GLenum mode, GLint *first, GLsizei *count, GLsizei primcount);
-typedef void (APIENTRY * PFNGLMULTIDRAWELEMENTSEXTPROC) (GLenum mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount);
-#endif
-
-#ifndef GL_EXT_fog_coord
-#define GL_EXT_fog_coord 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glFogCoordfEXT (GLfloat);
-GLAPI void APIENTRY glFogCoordfvEXT (const GLfloat *);
-GLAPI void APIENTRY glFogCoorddEXT (GLdouble);
-GLAPI void APIENTRY glFogCoorddvEXT (const GLdouble *);
-GLAPI void APIENTRY glFogCoordPointerEXT (GLenum, GLsizei, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLFOGCOORDFEXTPROC) (GLfloat coord);
-typedef void (APIENTRY * PFNGLFOGCOORDFVEXTPROC) (const GLfloat *coord);
-typedef void (APIENTRY * PFNGLFOGCOORDDEXTPROC) (GLdouble coord);
-typedef void (APIENTRY * PFNGLFOGCOORDDVEXTPROC) (const GLdouble *coord);
-typedef void (APIENTRY * PFNGLFOGCOORDPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer);
-#endif
-
-#ifndef GL_REND_screen_coordinates
-#define GL_REND_screen_coordinates 1
-#endif
-
-#ifndef GL_EXT_coordinate_frame
-#define GL_EXT_coordinate_frame 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glTangent3bEXT (GLbyte, GLbyte, GLbyte);
-GLAPI void APIENTRY glTangent3bvEXT (const GLbyte *);
-GLAPI void APIENTRY glTangent3dEXT (GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glTangent3dvEXT (const GLdouble *);
-GLAPI void APIENTRY glTangent3fEXT (GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glTangent3fvEXT (const GLfloat *);
-GLAPI void APIENTRY glTangent3iEXT (GLint, GLint, GLint);
-GLAPI void APIENTRY glTangent3ivEXT (const GLint *);
-GLAPI void APIENTRY glTangent3sEXT (GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glTangent3svEXT (const GLshort *);
-GLAPI void APIENTRY glBinormal3bEXT (GLbyte, GLbyte, GLbyte);
-GLAPI void APIENTRY glBinormal3bvEXT (const GLbyte *);
-GLAPI void APIENTRY glBinormal3dEXT (GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glBinormal3dvEXT (const GLdouble *);
-GLAPI void APIENTRY glBinormal3fEXT (GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glBinormal3fvEXT (const GLfloat *);
-GLAPI void APIENTRY glBinormal3iEXT (GLint, GLint, GLint);
-GLAPI void APIENTRY glBinormal3ivEXT (const GLint *);
-GLAPI void APIENTRY glBinormal3sEXT (GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glBinormal3svEXT (const GLshort *);
-GLAPI void APIENTRY glTangentPointerEXT (GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glBinormalPointerEXT (GLenum, GLsizei, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLTANGENT3BEXTPROC) (GLbyte tx, GLbyte ty, GLbyte tz);
-typedef void (APIENTRY * PFNGLTANGENT3BVEXTPROC) (const GLbyte *v);
-typedef void (APIENTRY * PFNGLTANGENT3DEXTPROC) (GLdouble tx, GLdouble ty, GLdouble tz);
-typedef void (APIENTRY * PFNGLTANGENT3DVEXTPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLTANGENT3FEXTPROC) (GLfloat tx, GLfloat ty, GLfloat tz);
-typedef void (APIENTRY * PFNGLTANGENT3FVEXTPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLTANGENT3IEXTPROC) (GLint tx, GLint ty, GLint tz);
-typedef void (APIENTRY * PFNGLTANGENT3IVEXTPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLTANGENT3SEXTPROC) (GLshort tx, GLshort ty, GLshort tz);
-typedef void (APIENTRY * PFNGLTANGENT3SVEXTPROC) (const GLshort *v);
-typedef void (APIENTRY * PFNGLBINORMAL3BEXTPROC) (GLbyte bx, GLbyte by, GLbyte bz);
-typedef void (APIENTRY * PFNGLBINORMAL3BVEXTPROC) (const GLbyte *v);
-typedef void (APIENTRY * PFNGLBINORMAL3DEXTPROC) (GLdouble bx, GLdouble by, GLdouble bz);
-typedef void (APIENTRY * PFNGLBINORMAL3DVEXTPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLBINORMAL3FEXTPROC) (GLfloat bx, GLfloat by, GLfloat bz);
-typedef void (APIENTRY * PFNGLBINORMAL3FVEXTPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLBINORMAL3IEXTPROC) (GLint bx, GLint by, GLint bz);
-typedef void (APIENTRY * PFNGLBINORMAL3IVEXTPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLBINORMAL3SEXTPROC) (GLshort bx, GLshort by, GLshort bz);
-typedef void (APIENTRY * PFNGLBINORMAL3SVEXTPROC) (const GLshort *v);
-typedef void (APIENTRY * PFNGLTANGENTPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLBINORMALPOINTEREXTPROC) (GLenum type, GLsizei stride, const GLvoid *pointer);
-#endif
-
-#ifndef GL_EXT_texture_env_combine
-#define GL_EXT_texture_env_combine 1
-#endif
-
-#ifndef GL_APPLE_specular_vector
-#define GL_APPLE_specular_vector 1
-#endif
-
-#ifndef GL_APPLE_transform_hint
-#define GL_APPLE_transform_hint 1
-#endif
-
-#ifndef GL_SGIX_fog_scale
-#define GL_SGIX_fog_scale 1
-#endif
-
-#ifndef GL_SUNX_constant_data
-#define GL_SUNX_constant_data 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glFinishTextureSUNX (void);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLFINISHTEXTURESUNXPROC) (void);
-#endif
-
-#ifndef GL_SUN_global_alpha
-#define GL_SUN_global_alpha 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glGlobalAlphaFactorbSUN (GLbyte);
-GLAPI void APIENTRY glGlobalAlphaFactorsSUN (GLshort);
-GLAPI void APIENTRY glGlobalAlphaFactoriSUN (GLint);
-GLAPI void APIENTRY glGlobalAlphaFactorfSUN (GLfloat);
-GLAPI void APIENTRY glGlobalAlphaFactordSUN (GLdouble);
-GLAPI void APIENTRY glGlobalAlphaFactorubSUN (GLubyte);
-GLAPI void APIENTRY glGlobalAlphaFactorusSUN (GLushort);
-GLAPI void APIENTRY glGlobalAlphaFactoruiSUN (GLuint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLGLOBALALPHAFACTORBSUNPROC) (GLbyte factor);
-typedef void (APIENTRY * PFNGLGLOBALALPHAFACTORSSUNPROC) (GLshort factor);
-typedef void (APIENTRY * PFNGLGLOBALALPHAFACTORISUNPROC) (GLint factor);
-typedef void (APIENTRY * PFNGLGLOBALALPHAFACTORFSUNPROC) (GLfloat factor);
-typedef void (APIENTRY * PFNGLGLOBALALPHAFACTORDSUNPROC) (GLdouble factor);
-typedef void (APIENTRY * PFNGLGLOBALALPHAFACTORUBSUNPROC) (GLubyte factor);
-typedef void (APIENTRY * PFNGLGLOBALALPHAFACTORUSSUNPROC) (GLushort factor);
-typedef void (APIENTRY * PFNGLGLOBALALPHAFACTORUISUNPROC) (GLuint factor);
-#endif
-
-#ifndef GL_SUN_triangle_list
-#define GL_SUN_triangle_list 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glReplacementCodeuiSUN (GLuint);
-GLAPI void APIENTRY glReplacementCodeusSUN (GLushort);
-GLAPI void APIENTRY glReplacementCodeubSUN (GLubyte);
-GLAPI void APIENTRY glReplacementCodeuivSUN (const GLuint *);
-GLAPI void APIENTRY glReplacementCodeusvSUN (const GLushort *);
-GLAPI void APIENTRY glReplacementCodeubvSUN (const GLubyte *);
-GLAPI void APIENTRY glReplacementCodePointerSUN (GLenum, GLsizei, const GLvoid* *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUISUNPROC) (GLuint code);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUSSUNPROC) (GLushort code);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUBSUNPROC) (GLubyte code);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUIVSUNPROC) (const GLuint *code);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUSVSUNPROC) (const GLushort *code);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUBVSUNPROC) (const GLubyte *code);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEPOINTERSUNPROC) (GLenum type, GLsizei stride, const GLvoid* *pointer);
-#endif
-
-#ifndef GL_SUN_vertex
-#define GL_SUN_vertex 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glColor4ubVertex2fSUN (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat);
-GLAPI void APIENTRY glColor4ubVertex2fvSUN (const GLubyte *, const GLfloat *);
-GLAPI void APIENTRY glColor4ubVertex3fSUN (GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glColor4ubVertex3fvSUN (const GLubyte *, const GLfloat *);
-GLAPI void APIENTRY glColor3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glColor3fVertex3fvSUN (const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glColor4fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glColor4fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glTexCoord2fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glTexCoord2fVertex3fvSUN (const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glTexCoord4fVertex4fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glTexCoord4fVertex4fvSUN (const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glTexCoord2fColor4ubVertex3fSUN (GLfloat, GLfloat, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glTexCoord2fColor4ubVertex3fvSUN (const GLfloat *, const GLubyte *, const GLfloat *);
-GLAPI void APIENTRY glTexCoord2fColor3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glTexCoord2fColor3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glTexCoord2fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glTexCoord2fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glTexCoord2fColor4fNormal3fVertex3fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glTexCoord2fColor4fNormal3fVertex3fvSUN (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glTexCoord4fColor4fNormal3fVertex4fSUN (GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glTexCoord4fColor4fNormal3fVertex4fvSUN (const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glReplacementCodeuiVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glReplacementCodeuiVertex3fvSUN (const GLuint *, const GLfloat *);
-GLAPI void APIENTRY glReplacementCodeuiColor4ubVertex3fSUN (GLuint, GLubyte, GLubyte, GLubyte, GLubyte, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glReplacementCodeuiColor4ubVertex3fvSUN (const GLuint *, const GLubyte *, const GLfloat *);
-GLAPI void APIENTRY glReplacementCodeuiColor3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glReplacementCodeuiColor3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glReplacementCodeuiNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glReplacementCodeuiNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glReplacementCodeuiColor4fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glReplacementCodeuiColor4fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glReplacementCodeuiTexCoord2fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glReplacementCodeuiTexCoord2fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *);
-GLAPI void APIENTRY glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN (GLuint, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN (const GLuint *, const GLfloat *, const GLfloat *, const GLfloat *, const GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCOLOR4UBVERTEX2FSUNPROC) (GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y);
-typedef void (APIENTRY * PFNGLCOLOR4UBVERTEX2FVSUNPROC) (const GLubyte *c, const GLfloat *v);
-typedef void (APIENTRY * PFNGLCOLOR4UBVERTEX3FSUNPROC) (GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLCOLOR4UBVERTEX3FVSUNPROC) (const GLubyte *c, const GLfloat *v);
-typedef void (APIENTRY * PFNGLCOLOR3FVERTEX3FSUNPROC) (GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLCOLOR3FVERTEX3FVSUNPROC) (const GLfloat *c, const GLfloat *v);
-typedef void (APIENTRY * PFNGLNORMAL3FVERTEX3FSUNPROC) (GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *n, const GLfloat *v);
-typedef void (APIENTRY * PFNGLCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *c, const GLfloat *n, const GLfloat *v);
-typedef void (APIENTRY * PFNGLTEXCOORD2FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLTEXCOORD2FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *v);
-typedef void (APIENTRY * PFNGLTEXCOORD4FVERTEX4FSUNPROC) (GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRY * PFNGLTEXCOORD4FVERTEX4FVSUNPROC) (const GLfloat *tc, const GLfloat *v);
-typedef void (APIENTRY * PFNGLTEXCOORD2FCOLOR4UBVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLTEXCOORD2FCOLOR4UBVERTEX3FVSUNPROC) (const GLfloat *tc, const GLubyte *c, const GLfloat *v);
-typedef void (APIENTRY * PFNGLTEXCOORD2FCOLOR3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLTEXCOORD2FCOLOR3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *v);
-typedef void (APIENTRY * PFNGLTEXCOORD2FNORMAL3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLTEXCOORD2FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *n, const GLfloat *v);
-typedef void (APIENTRY * PFNGLTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLTEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
-typedef void (APIENTRY * PFNGLTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FSUNPROC) (GLfloat s, GLfloat t, GLfloat p, GLfloat q, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRY * PFNGLTEXCOORD4FCOLOR4FNORMAL3FVERTEX4FVSUNPROC) (const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUIVERTEX3FSUNPROC) (GLuint rc, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUIVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *v);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUICOLOR4UBVERTEX3FSUNPROC) (GLuint rc, GLubyte r, GLubyte g, GLubyte b, GLubyte a, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUICOLOR4UBVERTEX3FVSUNPROC) (const GLuint *rc, const GLubyte *c, const GLfloat *v);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUICOLOR3FVERTEX3FSUNPROC) (GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUICOLOR3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *c, const GLfloat *v);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUINORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUINORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *n, const GLfloat *v);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUICOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUITEXCOORD2FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUITEXCOORD2FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *v);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUITEXCOORD2FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *n, const GLfloat *v);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FSUNPROC) (GLuint rc, GLfloat s, GLfloat t, GLfloat r, GLfloat g, GLfloat b, GLfloat a, GLfloat nx, GLfloat ny, GLfloat nz, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLREPLACEMENTCODEUITEXCOORD2FCOLOR4FNORMAL3FVERTEX3FVSUNPROC) (const GLuint *rc, const GLfloat *tc, const GLfloat *c, const GLfloat *n, const GLfloat *v);
-#endif
-
-#ifndef GL_EXT_blend_func_separate
-#define GL_EXT_blend_func_separate 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glBlendFuncSeparateEXT (GLenum, GLenum, GLenum, GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLBLENDFUNCSEPARATEEXTPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
-#endif
-
-#ifndef GL_INGR_blend_func_separate
-#define GL_INGR_blend_func_separate 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glBlendFuncSeparateINGR (GLenum, GLenum, GLenum, GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLBLENDFUNCSEPARATEINGRPROC) (GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
-#endif
-
-#ifndef GL_INGR_color_clamp
-#define GL_INGR_color_clamp 1
-#endif
-
-#ifndef GL_INGR_interlace_read
-#define GL_INGR_interlace_read 1
-#endif
-
-#ifndef GL_EXT_stencil_wrap
-#define GL_EXT_stencil_wrap 1
-#endif
-
-#ifndef GL_EXT_422_pixels
-#define GL_EXT_422_pixels 1
-#endif
-
-#ifndef GL_NV_texgen_reflection
-#define GL_NV_texgen_reflection 1
-#endif
-
-#ifndef GL_SUN_convolution_border_modes
-#define GL_SUN_convolution_border_modes 1
-#endif
-
-#ifndef GL_EXT_texture_env_add
-#define GL_EXT_texture_env_add 1
-#endif
-
-#ifndef GL_EXT_texture_lod_bias
-#define GL_EXT_texture_lod_bias 1
-#endif
-
-#ifndef GL_EXT_texture_filter_anisotropic
-#define GL_EXT_texture_filter_anisotropic 1
-#endif
-
-#ifndef GL_EXT_vertex_weighting
-#define GL_EXT_vertex_weighting 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glVertexWeightfEXT (GLfloat);
-GLAPI void APIENTRY glVertexWeightfvEXT (const GLfloat *);
-GLAPI void APIENTRY glVertexWeightPointerEXT (GLsizei, GLenum, GLsizei, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLVERTEXWEIGHTFEXTPROC) (GLfloat weight);
-typedef void (APIENTRY * PFNGLVERTEXWEIGHTFVEXTPROC) (const GLfloat *weight);
-typedef void (APIENTRY * PFNGLVERTEXWEIGHTPOINTEREXTPROC) (GLsizei size, GLenum type, GLsizei stride, const GLvoid *pointer);
-#endif
-
-#ifndef GL_NV_light_max_exponent
-#define GL_NV_light_max_exponent 1
-#endif
-
-#ifndef GL_NV_vertex_array_range
-#define GL_NV_vertex_array_range 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glFlushVertexArrayRangeNV (void);
-GLAPI void APIENTRY glVertexArrayRangeNV (GLsizei, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLFLUSHVERTEXARRAYRANGENVPROC) (void);
-typedef void (APIENTRY * PFNGLVERTEXARRAYRANGENVPROC) (GLsizei length, const GLvoid *pointer);
-#endif
-
-#ifndef GL_NV_register_combiners
-#define GL_NV_register_combiners 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glCombinerParameterfvNV (GLenum, const GLfloat *);
-GLAPI void APIENTRY glCombinerParameterfNV (GLenum, GLfloat);
-GLAPI void APIENTRY glCombinerParameterivNV (GLenum, const GLint *);
-GLAPI void APIENTRY glCombinerParameteriNV (GLenum, GLint);
-GLAPI void APIENTRY glCombinerInputNV (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum);
-GLAPI void APIENTRY glCombinerOutputNV (GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLenum, GLboolean, GLboolean, GLboolean);
-GLAPI void APIENTRY glFinalCombinerInputNV (GLenum, GLenum, GLenum, GLenum);
-GLAPI void APIENTRY glGetCombinerInputParameterfvNV (GLenum, GLenum, GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetCombinerInputParameterivNV (GLenum, GLenum, GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetCombinerOutputParameterfvNV (GLenum, GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetCombinerOutputParameterivNV (GLenum, GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetFinalCombinerInputParameterfvNV (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetFinalCombinerInputParameterivNV (GLenum, GLenum, GLint *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCOMBINERPARAMETERFVNVPROC) (GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLCOMBINERPARAMETERFNVPROC) (GLenum pname, GLfloat param);
-typedef void (APIENTRY * PFNGLCOMBINERPARAMETERIVNVPROC) (GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLCOMBINERPARAMETERINVPROC) (GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLCOMBINERINPUTNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage);
-typedef void (APIENTRY * PFNGLCOMBINEROUTPUTNVPROC) (GLenum stage, GLenum portion, GLenum abOutput, GLenum cdOutput, GLenum sumOutput, GLenum scale, GLenum bias, GLboolean abDotProduct, GLboolean cdDotProduct, GLboolean muxSum);
-typedef void (APIENTRY * PFNGLFINALCOMBINERINPUTNVPROC) (GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage);
-typedef void (APIENTRY * PFNGLGETCOMBINERINPUTPARAMETERFVNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETCOMBINERINPUTPARAMETERIVNVPROC) (GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETCOMBINEROUTPUTPARAMETERFVNVPROC) (GLenum stage, GLenum portion, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETCOMBINEROUTPUTPARAMETERIVNVPROC) (GLenum stage, GLenum portion, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETFINALCOMBINERINPUTPARAMETERFVNVPROC) (GLenum variable, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETFINALCOMBINERINPUTPARAMETERIVNVPROC) (GLenum variable, GLenum pname, GLint *params);
-#endif
-
-#ifndef GL_NV_fog_distance
-#define GL_NV_fog_distance 1
-#endif
-
-#ifndef GL_NV_texgen_emboss
-#define GL_NV_texgen_emboss 1
-#endif
-
-#ifndef GL_NV_blend_square
-#define GL_NV_blend_square 1
-#endif
-
-#ifndef GL_NV_texture_env_combine4
-#define GL_NV_texture_env_combine4 1
-#endif
-
-#ifndef GL_MESA_resize_buffers
-#define GL_MESA_resize_buffers 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glResizeBuffersMESA (void);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLRESIZEBUFFERSMESAPROC) (void);
-#endif
-
-#ifndef GL_MESA_window_pos
-#define GL_MESA_window_pos 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glWindowPos2dMESA (GLdouble, GLdouble);
-GLAPI void APIENTRY glWindowPos2dvMESA (const GLdouble *);
-GLAPI void APIENTRY glWindowPos2fMESA (GLfloat, GLfloat);
-GLAPI void APIENTRY glWindowPos2fvMESA (const GLfloat *);
-GLAPI void APIENTRY glWindowPos2iMESA (GLint, GLint);
-GLAPI void APIENTRY glWindowPos2ivMESA (const GLint *);
-GLAPI void APIENTRY glWindowPos2sMESA (GLshort, GLshort);
-GLAPI void APIENTRY glWindowPos2svMESA (const GLshort *);
-GLAPI void APIENTRY glWindowPos3dMESA (GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glWindowPos3dvMESA (const GLdouble *);
-GLAPI void APIENTRY glWindowPos3fMESA (GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glWindowPos3fvMESA (const GLfloat *);
-GLAPI void APIENTRY glWindowPos3iMESA (GLint, GLint, GLint);
-GLAPI void APIENTRY glWindowPos3ivMESA (const GLint *);
-GLAPI void APIENTRY glWindowPos3sMESA (GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glWindowPos3svMESA (const GLshort *);
-GLAPI void APIENTRY glWindowPos4dMESA (GLdouble, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glWindowPos4dvMESA (const GLdouble *);
-GLAPI void APIENTRY glWindowPos4fMESA (GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glWindowPos4fvMESA (const GLfloat *);
-GLAPI void APIENTRY glWindowPos4iMESA (GLint, GLint, GLint, GLint);
-GLAPI void APIENTRY glWindowPos4ivMESA (const GLint *);
-GLAPI void APIENTRY glWindowPos4sMESA (GLshort, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glWindowPos4svMESA (const GLshort *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLWINDOWPOS2DMESAPROC) (GLdouble x, GLdouble y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2DVMESAPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS2FMESAPROC) (GLfloat x, GLfloat y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2FVMESAPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS2IMESAPROC) (GLint x, GLint y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2IVMESAPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS2SMESAPROC) (GLshort x, GLshort y);
-typedef void (APIENTRY * PFNGLWINDOWPOS2SVMESAPROC) (const GLshort *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3DMESAPROC) (GLdouble x, GLdouble y, GLdouble z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3DVMESAPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3FMESAPROC) (GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3FVMESAPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3IMESAPROC) (GLint x, GLint y, GLint z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3IVMESAPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS3SMESAPROC) (GLshort x, GLshort y, GLshort z);
-typedef void (APIENTRY * PFNGLWINDOWPOS3SVMESAPROC) (const GLshort *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS4DMESAPROC) (GLdouble x, GLdouble y, GLdouble z, GLdouble w);
-typedef void (APIENTRY * PFNGLWINDOWPOS4DVMESAPROC) (const GLdouble *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS4FMESAPROC) (GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRY * PFNGLWINDOWPOS4FVMESAPROC) (const GLfloat *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS4IMESAPROC) (GLint x, GLint y, GLint z, GLint w);
-typedef void (APIENTRY * PFNGLWINDOWPOS4IVMESAPROC) (const GLint *v);
-typedef void (APIENTRY * PFNGLWINDOWPOS4SMESAPROC) (GLshort x, GLshort y, GLshort z, GLshort w);
-typedef void (APIENTRY * PFNGLWINDOWPOS4SVMESAPROC) (const GLshort *v);
-#endif
-
-#ifndef GL_IBM_cull_vertex
-#define GL_IBM_cull_vertex 1
-#endif
-
-#ifndef GL_IBM_multimode_draw_arrays
-#define GL_IBM_multimode_draw_arrays 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glMultiModeDrawArraysIBM (GLenum, const GLint *, const GLsizei *, GLsizei, GLint);
-GLAPI void APIENTRY glMultiModeDrawElementsIBM (const GLenum *, const GLsizei *, GLenum, const GLvoid* *, GLsizei, GLint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLMULTIMODEDRAWARRAYSIBMPROC) (GLenum mode, const GLint *first, const GLsizei *count, GLsizei primcount, GLint modestride);
-typedef void (APIENTRY * PFNGLMULTIMODEDRAWELEMENTSIBMPROC) (const GLenum *mode, const GLsizei *count, GLenum type, const GLvoid* *indices, GLsizei primcount, GLint modestride);
-#endif
-
-#ifndef GL_IBM_vertex_array_lists
-#define GL_IBM_vertex_array_lists 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glColorPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint);
-GLAPI void APIENTRY glSecondaryColorPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint);
-GLAPI void APIENTRY glEdgeFlagPointerListIBM (GLint, const GLboolean* *, GLint);
-GLAPI void APIENTRY glFogCoordPointerListIBM (GLenum, GLint, const GLvoid* *, GLint);
-GLAPI void APIENTRY glIndexPointerListIBM (GLenum, GLint, const GLvoid* *, GLint);
-GLAPI void APIENTRY glNormalPointerListIBM (GLenum, GLint, const GLvoid* *, GLint);
-GLAPI void APIENTRY glTexCoordPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint);
-GLAPI void APIENTRY glVertexPointerListIBM (GLint, GLenum, GLint, const GLvoid* *, GLint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCOLORPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
-typedef void (APIENTRY * PFNGLSECONDARYCOLORPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
-typedef void (APIENTRY * PFNGLEDGEFLAGPOINTERLISTIBMPROC) (GLint stride, const GLboolean* *pointer, GLint ptrstride);
-typedef void (APIENTRY * PFNGLFOGCOORDPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
-typedef void (APIENTRY * PFNGLINDEXPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
-typedef void (APIENTRY * PFNGLNORMALPOINTERLISTIBMPROC) (GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
-typedef void (APIENTRY * PFNGLTEXCOORDPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
-typedef void (APIENTRY * PFNGLVERTEXPOINTERLISTIBMPROC) (GLint size, GLenum type, GLint stride, const GLvoid* *pointer, GLint ptrstride);
-#endif
-
-#ifndef GL_SGIX_subsample
-#define GL_SGIX_subsample 1
-#endif
-
-#ifndef GL_SGIX_ycrcba
-#define GL_SGIX_ycrcba 1
-#endif
-
-#ifndef GL_SGIX_ycrcb_subsample
-#define GL_SGIX_ycrcb_subsample 1
-#endif
-
-#ifndef GL_SGIX_depth_pass_instrument
-#define GL_SGIX_depth_pass_instrument 1
-#endif
-
-#ifndef GL_3DFX_texture_compression_FXT1
-#define GL_3DFX_texture_compression_FXT1 1
-#endif
-
-#ifndef GL_3DFX_multisample
-#define GL_3DFX_multisample 1
-#endif
-
-#ifndef GL_3DFX_tbuffer
-#define GL_3DFX_tbuffer 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glTbufferMask3DFX (GLuint);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLTBUFFERMASK3DFXPROC) (GLuint mask);
-#endif
-
-#ifndef GL_EXT_multisample
-#define GL_EXT_multisample 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glSampleMaskEXT (GLclampf, GLboolean);
-GLAPI void APIENTRY glSamplePatternEXT (GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLSAMPLEMASKEXTPROC) (GLclampf value, GLboolean invert);
-typedef void (APIENTRY * PFNGLSAMPLEPATTERNEXTPROC) (GLenum pattern);
-#endif
-
-#ifndef GL_SGIX_vertex_preclip
-#define GL_SGIX_vertex_preclip 1
-#endif
-
-#ifndef GL_SGIX_convolution_accuracy
-#define GL_SGIX_convolution_accuracy 1
-#endif
-
-#ifndef GL_SGIX_resample
-#define GL_SGIX_resample 1
-#endif
-
-#ifndef GL_SGIS_point_line_texgen
-#define GL_SGIS_point_line_texgen 1
-#endif
-
-#ifndef GL_SGIS_texture_color_mask
-#define GL_SGIS_texture_color_mask 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glTextureColorMaskSGIS (GLboolean, GLboolean, GLboolean, GLboolean);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLTEXTURECOLORMASKSGISPROC) (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
-#endif
-
-#ifndef GL_SGIX_igloo_interface
-#define GL_SGIX_igloo_interface 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glIglooInterfaceSGIX (GLenum, const GLvoid *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLIGLOOINTERFACESGIXPROC) (GLenum pname, const GLvoid *params);
-#endif
-
-#ifndef GL_EXT_texture_env_dot3
-#define GL_EXT_texture_env_dot3 1
-#endif
-
-#ifndef GL_ATI_texture_mirror_once
-#define GL_ATI_texture_mirror_once 1
-#endif
-
-#ifndef GL_NV_fence
-#define GL_NV_fence 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glDeleteFencesNV (GLsizei, const GLuint *);
-GLAPI void APIENTRY glGenFencesNV (GLsizei, GLuint *);
-GLAPI GLboolean APIENTRY glIsFenceNV (GLuint);
-GLAPI GLboolean APIENTRY glTestFenceNV (GLuint);
-GLAPI void APIENTRY glGetFenceivNV (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glFinishFenceNV (GLuint);
-GLAPI void APIENTRY glSetFenceNV (GLuint, GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLDELETEFENCESNVPROC) (GLsizei n, const GLuint *fences);
-typedef void (APIENTRY * PFNGLGENFENCESNVPROC) (GLsizei n, GLuint *fences);
-typedef GLboolean (APIENTRY * PFNGLISFENCENVPROC) (GLuint fence);
-typedef GLboolean (APIENTRY * PFNGLTESTFENCENVPROC) (GLuint fence);
-typedef void (APIENTRY * PFNGLGETFENCEIVNVPROC) (GLuint fence, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLFINISHFENCENVPROC) (GLuint fence);
-typedef void (APIENTRY * PFNGLSETFENCENVPROC) (GLuint fence, GLenum condition);
-#endif
-
-#ifndef GL_NV_evaluators
-#define GL_NV_evaluators 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glMapControlPointsNV (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLint, GLint, GLboolean, const GLvoid *);
-GLAPI void APIENTRY glMapParameterivNV (GLenum, GLenum, const GLint *);
-GLAPI void APIENTRY glMapParameterfvNV (GLenum, GLenum, const GLfloat *);
-GLAPI void APIENTRY glGetMapControlPointsNV (GLenum, GLuint, GLenum, GLsizei, GLsizei, GLboolean, GLvoid *);
-GLAPI void APIENTRY glGetMapParameterivNV (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glGetMapParameterfvNV (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetMapAttribParameterivNV (GLenum, GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glGetMapAttribParameterfvNV (GLenum, GLuint, GLenum, GLfloat *);
-GLAPI void APIENTRY glEvalMapsNV (GLenum, GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLMAPCONTROLPOINTSNVPROC) (GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLint uorder, GLint vorder, GLboolean packed, const GLvoid *points);
-typedef void (APIENTRY * PFNGLMAPPARAMETERIVNVPROC) (GLenum target, GLenum pname, const GLint *params);
-typedef void (APIENTRY * PFNGLMAPPARAMETERFVNVPROC) (GLenum target, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLGETMAPCONTROLPOINTSNVPROC) (GLenum target, GLuint index, GLenum type, GLsizei ustride, GLsizei vstride, GLboolean packed, GLvoid *points);
-typedef void (APIENTRY * PFNGLGETMAPPARAMETERIVNVPROC) (GLenum target, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETMAPPARAMETERFVNVPROC) (GLenum target, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETMAPATTRIBPARAMETERIVNVPROC) (GLenum target, GLuint index, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETMAPATTRIBPARAMETERFVNVPROC) (GLenum target, GLuint index, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLEVALMAPSNVPROC) (GLenum target, GLenum mode);
-#endif
-
-#ifndef GL_NV_packed_depth_stencil
-#define GL_NV_packed_depth_stencil 1
-#endif
-
-#ifndef GL_NV_register_combiners2
-#define GL_NV_register_combiners2 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glCombinerStageParameterfvNV (GLenum, GLenum, const GLfloat *);
-GLAPI void APIENTRY glGetCombinerStageParameterfvNV (GLenum, GLenum, GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLCOMBINERSTAGEPARAMETERFVNVPROC) (GLenum stage, GLenum pname, const GLfloat *params);
-typedef void (APIENTRY * PFNGLGETCOMBINERSTAGEPARAMETERFVNVPROC) (GLenum stage, GLenum pname, GLfloat *params);
-#endif
-
-#ifndef GL_NV_texture_compression_vtc
-#define GL_NV_texture_compression_vtc 1
-#endif
-
-#ifndef GL_NV_texture_rectangle
-#define GL_NV_texture_rectangle 1
-#endif
-
-#ifndef GL_NV_texture_shader
-#define GL_NV_texture_shader 1
-#endif
-
-#ifndef GL_NV_texture_shader2
-#define GL_NV_texture_shader2 1
-#endif
-
-#ifndef GL_NV_vertex_array_range2
-#define GL_NV_vertex_array_range2 1
-#endif
-
-#ifndef GL_NV_vertex_program
-#define GL_NV_vertex_program 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI GLboolean APIENTRY glAreProgramsResidentNV (GLsizei, const GLuint *, GLboolean *);
-GLAPI void APIENTRY glBindProgramNV (GLenum, GLuint);
-GLAPI void APIENTRY glDeleteProgramsNV (GLsizei, const GLuint *);
-GLAPI void APIENTRY glExecuteProgramNV (GLenum, GLuint, const GLfloat *);
-GLAPI void APIENTRY glGenProgramsNV (GLsizei, GLuint *);
-GLAPI void APIENTRY glGetProgramParameterdvNV (GLenum, GLuint, GLenum, GLdouble *);
-GLAPI void APIENTRY glGetProgramParameterfvNV (GLenum, GLuint, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetProgramivNV (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glGetProgramStringNV (GLuint, GLenum, GLubyte *);
-GLAPI void APIENTRY glGetTrackMatrixivNV (GLenum, GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glGetVertexAttribdvNV (GLuint, GLenum, GLdouble *);
-GLAPI void APIENTRY glGetVertexAttribfvNV (GLuint, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetVertexAttribivNV (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glGetVertexAttribPointervNV (GLuint, GLenum, GLvoid* *);
-GLAPI GLboolean APIENTRY glIsProgramNV (GLuint);
-GLAPI void APIENTRY glLoadProgramNV (GLenum, GLuint, GLsizei, const GLubyte *);
-GLAPI void APIENTRY glProgramParameter4dNV (GLenum, GLuint, GLdouble, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glProgramParameter4dvNV (GLenum, GLuint, const GLdouble *);
-GLAPI void APIENTRY glProgramParameter4fNV (GLenum, GLuint, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glProgramParameter4fvNV (GLenum, GLuint, const GLfloat *);
-GLAPI void APIENTRY glProgramParameters4dvNV (GLenum, GLuint, GLuint, const GLdouble *);
-GLAPI void APIENTRY glProgramParameters4fvNV (GLenum, GLuint, GLuint, const GLfloat *);
-GLAPI void APIENTRY glRequestResidentProgramsNV (GLsizei, const GLuint *);
-GLAPI void APIENTRY glTrackMatrixNV (GLenum, GLuint, GLenum, GLenum);
-GLAPI void APIENTRY glVertexAttribPointerNV (GLuint, GLint, GLenum, GLsizei, const GLvoid *);
-GLAPI void APIENTRY glVertexAttrib1dNV (GLuint, GLdouble);
-GLAPI void APIENTRY glVertexAttrib1dvNV (GLuint, const GLdouble *);
-GLAPI void APIENTRY glVertexAttrib1fNV (GLuint, GLfloat);
-GLAPI void APIENTRY glVertexAttrib1fvNV (GLuint, const GLfloat *);
-GLAPI void APIENTRY glVertexAttrib1sNV (GLuint, GLshort);
-GLAPI void APIENTRY glVertexAttrib1svNV (GLuint, const GLshort *);
-GLAPI void APIENTRY glVertexAttrib2dNV (GLuint, GLdouble, GLdouble);
-GLAPI void APIENTRY glVertexAttrib2dvNV (GLuint, const GLdouble *);
-GLAPI void APIENTRY glVertexAttrib2fNV (GLuint, GLfloat, GLfloat);
-GLAPI void APIENTRY glVertexAttrib2fvNV (GLuint, const GLfloat *);
-GLAPI void APIENTRY glVertexAttrib2sNV (GLuint, GLshort, GLshort);
-GLAPI void APIENTRY glVertexAttrib2svNV (GLuint, const GLshort *);
-GLAPI void APIENTRY glVertexAttrib3dNV (GLuint, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glVertexAttrib3dvNV (GLuint, const GLdouble *);
-GLAPI void APIENTRY glVertexAttrib3fNV (GLuint, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glVertexAttrib3fvNV (GLuint, const GLfloat *);
-GLAPI void APIENTRY glVertexAttrib3sNV (GLuint, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glVertexAttrib3svNV (GLuint, const GLshort *);
-GLAPI void APIENTRY glVertexAttrib4dNV (GLuint, GLdouble, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glVertexAttrib4dvNV (GLuint, const GLdouble *);
-GLAPI void APIENTRY glVertexAttrib4fNV (GLuint, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glVertexAttrib4fvNV (GLuint, const GLfloat *);
-GLAPI void APIENTRY glVertexAttrib4sNV (GLuint, GLshort, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glVertexAttrib4svNV (GLuint, const GLshort *);
-GLAPI void APIENTRY glVertexAttrib4ubNV (GLuint, GLubyte, GLubyte, GLubyte, GLubyte);
-GLAPI void APIENTRY glVertexAttrib4ubvNV (GLuint, const GLubyte *);
-GLAPI void APIENTRY glVertexAttribs1dvNV (GLuint, GLsizei, const GLdouble *);
-GLAPI void APIENTRY glVertexAttribs1fvNV (GLuint, GLsizei, const GLfloat *);
-GLAPI void APIENTRY glVertexAttribs1svNV (GLuint, GLsizei, const GLshort *);
-GLAPI void APIENTRY glVertexAttribs2dvNV (GLuint, GLsizei, const GLdouble *);
-GLAPI void APIENTRY glVertexAttribs2fvNV (GLuint, GLsizei, const GLfloat *);
-GLAPI void APIENTRY glVertexAttribs2svNV (GLuint, GLsizei, const GLshort *);
-GLAPI void APIENTRY glVertexAttribs3dvNV (GLuint, GLsizei, const GLdouble *);
-GLAPI void APIENTRY glVertexAttribs3fvNV (GLuint, GLsizei, const GLfloat *);
-GLAPI void APIENTRY glVertexAttribs3svNV (GLuint, GLsizei, const GLshort *);
-GLAPI void APIENTRY glVertexAttribs4dvNV (GLuint, GLsizei, const GLdouble *);
-GLAPI void APIENTRY glVertexAttribs4fvNV (GLuint, GLsizei, const GLfloat *);
-GLAPI void APIENTRY glVertexAttribs4svNV (GLuint, GLsizei, const GLshort *);
-GLAPI void APIENTRY glVertexAttribs4ubvNV (GLuint, GLsizei, const GLubyte *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef GLboolean (APIENTRY * PFNGLAREPROGRAMSRESIDENTNVPROC) (GLsizei n, const GLuint *programs, GLboolean *residences);
-typedef void (APIENTRY * PFNGLBINDPROGRAMNVPROC) (GLenum target, GLuint id);
-typedef void (APIENTRY * PFNGLDELETEPROGRAMSNVPROC) (GLsizei n, const GLuint *programs);
-typedef void (APIENTRY * PFNGLEXECUTEPROGRAMNVPROC) (GLenum target, GLuint id, const GLfloat *params);
-typedef void (APIENTRY * PFNGLGENPROGRAMSNVPROC) (GLsizei n, GLuint *programs);
-typedef void (APIENTRY * PFNGLGETPROGRAMPARAMETERDVNVPROC) (GLenum target, GLuint index, GLenum pname, GLdouble *params);
-typedef void (APIENTRY * PFNGLGETPROGRAMPARAMETERFVNVPROC) (GLenum target, GLuint index, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETPROGRAMIVNVPROC) (GLuint id, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETPROGRAMSTRINGNVPROC) (GLuint id, GLenum pname, GLubyte *program);
-typedef void (APIENTRY * PFNGLGETTRACKMATRIXIVNVPROC) (GLenum target, GLuint address, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETVERTEXATTRIBDVNVPROC) (GLuint index, GLenum pname, GLdouble *params);
-typedef void (APIENTRY * PFNGLGETVERTEXATTRIBFVNVPROC) (GLuint index, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETVERTEXATTRIBIVNVPROC) (GLuint index, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETVERTEXATTRIBPOINTERVNVPROC) (GLuint index, GLenum pname, GLvoid* *pointer);
-typedef GLboolean (APIENTRY * PFNGLISPROGRAMNVPROC) (GLuint id);
-typedef void (APIENTRY * PFNGLLOADPROGRAMNVPROC) (GLenum target, GLuint id, GLsizei len, const GLubyte *program);
-typedef void (APIENTRY * PFNGLPROGRAMPARAMETER4DNVPROC) (GLenum target, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
-typedef void (APIENTRY * PFNGLPROGRAMPARAMETER4DVNVPROC) (GLenum target, GLuint index, const GLdouble *v);
-typedef void (APIENTRY * PFNGLPROGRAMPARAMETER4FNVPROC) (GLenum target, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRY * PFNGLPROGRAMPARAMETER4FVNVPROC) (GLenum target, GLuint index, const GLfloat *v);
-typedef void (APIENTRY * PFNGLPROGRAMPARAMETERS4DVNVPROC) (GLenum target, GLuint index, GLuint count, const GLdouble *v);
-typedef void (APIENTRY * PFNGLPROGRAMPARAMETERS4FVNVPROC) (GLenum target, GLuint index, GLuint count, const GLfloat *v);
-typedef void (APIENTRY * PFNGLREQUESTRESIDENTPROGRAMSNVPROC) (GLsizei n, const GLuint *programs);
-typedef void (APIENTRY * PFNGLTRACKMATRIXNVPROC) (GLenum target, GLuint address, GLenum matrix, GLenum transform);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBPOINTERNVPROC) (GLuint index, GLint fsize, GLenum type, GLsizei stride, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1DNVPROC) (GLuint index, GLdouble x);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1DVNVPROC) (GLuint index, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1FNVPROC) (GLuint index, GLfloat x);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1FVNVPROC) (GLuint index, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1SNVPROC) (GLuint index, GLshort x);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB1SVNVPROC) (GLuint index, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2DNVPROC) (GLuint index, GLdouble x, GLdouble y);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2DVNVPROC) (GLuint index, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2FNVPROC) (GLuint index, GLfloat x, GLfloat y);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2FVNVPROC) (GLuint index, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2SNVPROC) (GLuint index, GLshort x, GLshort y);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB2SVNVPROC) (GLuint index, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3DNVPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3DVNVPROC) (GLuint index, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3FNVPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3FVNVPROC) (GLuint index, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3SNVPROC) (GLuint index, GLshort x, GLshort y, GLshort z);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB3SVNVPROC) (GLuint index, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4DNVPROC) (GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4DVNVPROC) (GLuint index, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4FNVPROC) (GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4FVNVPROC) (GLuint index, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4SNVPROC) (GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4SVNVPROC) (GLuint index, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4UBNVPROC) (GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
-typedef void (APIENTRY * PFNGLVERTEXATTRIB4UBVNVPROC) (GLuint index, const GLubyte *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS1DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS1FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS1SVNVPROC) (GLuint index, GLsizei count, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS2DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS2FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS2SVNVPROC) (GLuint index, GLsizei count, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS3DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS3FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS3SVNVPROC) (GLuint index, GLsizei count, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS4DVNVPROC) (GLuint index, GLsizei count, const GLdouble *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS4FVNVPROC) (GLuint index, GLsizei count, const GLfloat *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS4SVNVPROC) (GLuint index, GLsizei count, const GLshort *v);
-typedef void (APIENTRY * PFNGLVERTEXATTRIBS4UBVNVPROC) (GLuint index, GLsizei count, const GLubyte *v);
-#endif
-
-#ifndef GL_SGIX_texture_coordinate_clamp
-#define GL_SGIX_texture_coordinate_clamp 1
-#endif
-
-#ifndef GL_SGIX_scalebias_hint
-#define GL_SGIX_scalebias_hint 1
-#endif
-
-#ifndef GL_OML_interlace
-#define GL_OML_interlace 1
-#endif
-
-#ifndef GL_OML_subsample
-#define GL_OML_subsample 1
-#endif
-
-#ifndef GL_OML_resample
-#define GL_OML_resample 1
-#endif
-
-#ifndef GL_NV_copy_depth_to_color
-#define GL_NV_copy_depth_to_color 1
-#endif
-
-#ifndef GL_ATI_envmap_bumpmap
-#define GL_ATI_envmap_bumpmap 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glTexBumpParameterivATI (GLenum, const GLint *);
-GLAPI void APIENTRY glTexBumpParameterfvATI (GLenum, const GLfloat *);
-GLAPI void APIENTRY glGetTexBumpParameterivATI (GLenum, GLint *);
-GLAPI void APIENTRY glGetTexBumpParameterfvATI (GLenum, GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLTEXBUMPPARAMETERIVATIPROC) (GLenum pname, const GLint *param);
-typedef void (APIENTRY * PFNGLTEXBUMPPARAMETERFVATIPROC) (GLenum pname, const GLfloat *param);
-typedef void (APIENTRY * PFNGLGETTEXBUMPPARAMETERIVATIPROC) (GLenum pname, GLint *param);
-typedef void (APIENTRY * PFNGLGETTEXBUMPPARAMETERFVATIPROC) (GLenum pname, GLfloat *param);
-#endif
-
-#ifndef GL_ATI_fragment_shader
-#define GL_ATI_fragment_shader 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI GLuint APIENTRY glGenFragmentShadersATI (GLuint);
-GLAPI void APIENTRY glBindFragmentShaderATI (GLuint);
-GLAPI void APIENTRY glDeleteFragmentShaderATI (GLuint);
-GLAPI void APIENTRY glBeginFragmentShaderATI (void);
-GLAPI void APIENTRY glEndFragmentShaderATI (void);
-GLAPI void APIENTRY glPassTexCoordATI (GLuint, GLuint, GLenum);
-GLAPI void APIENTRY glSampleMapATI (GLuint, GLuint, GLenum);
-GLAPI void APIENTRY glColorFragmentOp1ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glColorFragmentOp2ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glColorFragmentOp3ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glAlphaFragmentOp1ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glAlphaFragmentOp2ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glAlphaFragmentOp3ATI (GLenum, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glSetFragmentShaderConstantATI (GLuint, const GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef GLuint (APIENTRY * PFNGLGENFRAGMENTSHADERSATIPROC) (GLuint range);
-typedef void (APIENTRY * PFNGLBINDFRAGMENTSHADERATIPROC) (GLuint id);
-typedef void (APIENTRY * PFNGLDELETEFRAGMENTSHADERATIPROC) (GLuint id);
-typedef void (APIENTRY * PFNGLBEGINFRAGMENTSHADERATIPROC) (void);
-typedef void (APIENTRY * PFNGLENDFRAGMENTSHADERATIPROC) (void);
-typedef void (APIENTRY * PFNGLPASSTEXCOORDATIPROC) (GLuint dst, GLuint coord, GLenum swizzle);
-typedef void (APIENTRY * PFNGLSAMPLEMAPATIPROC) (GLuint dst, GLuint interp, GLenum swizzle);
-typedef void (APIENTRY * PFNGLCOLORFRAGMENTOP1ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod);
-typedef void (APIENTRY * PFNGLCOLORFRAGMENTOP2ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod);
-typedef void (APIENTRY * PFNGLCOLORFRAGMENTOP3ATIPROC) (GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod);
-typedef void (APIENTRY * PFNGLALPHAFRAGMENTOP1ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod);
-typedef void (APIENTRY * PFNGLALPHAFRAGMENTOP2ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod);
-typedef void (APIENTRY * PFNGLALPHAFRAGMENTOP3ATIPROC) (GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod);
-typedef void (APIENTRY * PFNGLSETFRAGMENTSHADERCONSTANTATIPROC) (GLuint dst, const GLfloat *value);
-#endif
-
-#ifndef GL_ATI_pn_triangles
-#define GL_ATI_pn_triangles 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPNTrianglesiATI (GLenum, GLint);
-GLAPI void APIENTRY glPNTrianglesfATI (GLenum, GLfloat);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLPNTRIANGLESIATIPROC) (GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLPNTRIANGLESFATIPROC) (GLenum pname, GLfloat param);
-#endif
-
-#ifndef GL_ATI_vertex_array_object
-#define GL_ATI_vertex_array_object 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI GLuint APIENTRY glNewObjectBufferATI (GLsizei, const GLvoid *, GLenum);
-GLAPI GLboolean APIENTRY glIsObjectBufferATI (GLuint);
-GLAPI void APIENTRY glUpdateObjectBufferATI (GLuint, GLuint, GLsizei, const GLvoid *, GLenum);
-GLAPI void APIENTRY glGetObjectBufferfvATI (GLuint, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetObjectBufferivATI (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glDeleteObjectBufferATI (GLuint);
-GLAPI void APIENTRY glArrayObjectATI (GLenum, GLint, GLenum, GLsizei, GLuint, GLuint);
-GLAPI void APIENTRY glGetArrayObjectfvATI (GLenum, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetArrayObjectivATI (GLenum, GLenum, GLint *);
-GLAPI void APIENTRY glVariantArrayObjectATI (GLuint, GLenum, GLsizei, GLuint, GLuint);
-GLAPI void APIENTRY glGetVariantArrayObjectfvATI (GLuint, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetVariantArrayObjectivATI (GLuint, GLenum, GLint *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef GLuint (APIENTRY * PFNGLNEWOBJECTBUFFERATIPROC) (GLsizei size, const GLvoid *pointer, GLenum usage);
-typedef GLboolean (APIENTRY * PFNGLISOBJECTBUFFERATIPROC) (GLuint buffer);
-typedef void (APIENTRY * PFNGLUPDATEOBJECTBUFFERATIPROC) (GLuint buffer, GLuint offset, GLsizei size, const GLvoid *pointer, GLenum preserve);
-typedef void (APIENTRY * PFNGLGETOBJECTBUFFERFVATIPROC) (GLuint buffer, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETOBJECTBUFFERIVATIPROC) (GLuint buffer, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLDELETEOBJECTBUFFERATIPROC) (GLuint buffer);
-typedef void (APIENTRY * PFNGLARRAYOBJECTATIPROC) (GLenum array, GLint size, GLenum type, GLsizei stride, GLuint buffer, GLuint offset);
-typedef void (APIENTRY * PFNGLGETARRAYOBJECTFVATIPROC) (GLenum array, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETARRAYOBJECTIVATIPROC) (GLenum array, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLVARIANTARRAYOBJECTATIPROC) (GLuint id, GLenum type, GLsizei stride, GLuint buffer, GLuint offset);
-typedef void (APIENTRY * PFNGLGETVARIANTARRAYOBJECTFVATIPROC) (GLuint id, GLenum pname, GLfloat *params);
-typedef void (APIENTRY * PFNGLGETVARIANTARRAYOBJECTIVATIPROC) (GLuint id, GLenum pname, GLint *params);
-#endif
-
-#ifndef GL_EXT_vertex_shader
-#define GL_EXT_vertex_shader 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glBeginVertexShaderEXT (void);
-GLAPI void APIENTRY glEndVertexShaderEXT (void);
-GLAPI void APIENTRY glBindVertexShaderEXT (GLuint);
-GLAPI GLuint APIENTRY glGenVertexShadersEXT (GLuint);
-GLAPI void APIENTRY glDeleteVertexShaderEXT (GLuint);
-GLAPI void APIENTRY glShaderOp1EXT (GLenum, GLuint, GLuint);
-GLAPI void APIENTRY glShaderOp2EXT (GLenum, GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glShaderOp3EXT (GLenum, GLuint, GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glSwizzleEXT (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum);
-GLAPI void APIENTRY glWriteMaskEXT (GLuint, GLuint, GLenum, GLenum, GLenum, GLenum);
-GLAPI void APIENTRY glInsertComponentEXT (GLuint, GLuint, GLuint);
-GLAPI void APIENTRY glExtractComponentEXT (GLuint, GLuint, GLuint);
-GLAPI GLuint APIENTRY glGenSymbolsEXT (GLenum, GLenum, GLenum, GLuint);
-GLAPI void APIENTRY glSetInvariantEXT (GLuint, GLenum, const void *);
-GLAPI void APIENTRY glSetLocalConstantEXT (GLuint, GLenum, const void *);
-GLAPI void APIENTRY glVariantbvEXT (GLuint, const GLbyte *);
-GLAPI void APIENTRY glVariantsvEXT (GLuint, const GLshort *);
-GLAPI void APIENTRY glVariantivEXT (GLuint, const GLint *);
-GLAPI void APIENTRY glVariantfvEXT (GLuint, const GLfloat *);
-GLAPI void APIENTRY glVariantdvEXT (GLuint, const GLdouble *);
-GLAPI void APIENTRY glVariantubvEXT (GLuint, const GLubyte *);
-GLAPI void APIENTRY glVariantusvEXT (GLuint, const GLushort *);
-GLAPI void APIENTRY glVariantuivEXT (GLuint, const GLuint *);
-GLAPI void APIENTRY glVariantPointerEXT (GLuint, GLenum, GLuint, const void *);
-GLAPI void APIENTRY glEnableVariantClientStateEXT (GLuint);
-GLAPI void APIENTRY glDisableVariantClientStateEXT (GLuint);
-GLAPI GLuint APIENTRY glBindLightParameterEXT (GLenum, GLenum);
-GLAPI GLuint APIENTRY glBindMaterialParameterEXT (GLenum, GLenum);
-GLAPI GLuint APIENTRY glBindTexGenParameterEXT (GLenum, GLenum, GLenum);
-GLAPI GLuint APIENTRY glBindTextureUnitParameterEXT (GLenum, GLenum);
-GLAPI GLuint APIENTRY glBindParameterEXT (GLenum);
-GLAPI GLboolean APIENTRY glIsVariantEnabledEXT (GLuint, GLenum);
-GLAPI void APIENTRY glGetVariantBooleanvEXT (GLuint, GLenum, GLboolean *);
-GLAPI void APIENTRY glGetVariantIntegervEXT (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glGetVariantFloatvEXT (GLuint, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetVariantPointervEXT (GLuint, GLenum, GLvoid* *);
-GLAPI void APIENTRY glGetInvariantBooleanvEXT (GLuint, GLenum, GLboolean *);
-GLAPI void APIENTRY glGetInvariantIntegervEXT (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glGetInvariantFloatvEXT (GLuint, GLenum, GLfloat *);
-GLAPI void APIENTRY glGetLocalConstantBooleanvEXT (GLuint, GLenum, GLboolean *);
-GLAPI void APIENTRY glGetLocalConstantIntegervEXT (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glGetLocalConstantFloatvEXT (GLuint, GLenum, GLfloat *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLBEGINVERTEXSHADEREXTPROC) (void);
-typedef void (APIENTRY * PFNGLENDVERTEXSHADEREXTPROC) (void);
-typedef void (APIENTRY * PFNGLBINDVERTEXSHADEREXTPROC) (GLuint id);
-typedef GLuint (APIENTRY * PFNGLGENVERTEXSHADERSEXTPROC) (GLuint range);
-typedef void (APIENTRY * PFNGLDELETEVERTEXSHADEREXTPROC) (GLuint id);
-typedef void (APIENTRY * PFNGLSHADEROP1EXTPROC) (GLenum op, GLuint res, GLuint arg1);
-typedef void (APIENTRY * PFNGLSHADEROP2EXTPROC) (GLenum op, GLuint res, GLuint arg1, GLuint arg2);
-typedef void (APIENTRY * PFNGLSHADEROP3EXTPROC) (GLenum op, GLuint res, GLuint arg1, GLuint arg2, GLuint arg3);
-typedef void (APIENTRY * PFNGLSWIZZLEEXTPROC) (GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW);
-typedef void (APIENTRY * PFNGLWRITEMASKEXTPROC) (GLuint res, GLuint in, GLenum outX, GLenum outY, GLenum outZ, GLenum outW);
-typedef void (APIENTRY * PFNGLINSERTCOMPONENTEXTPROC) (GLuint res, GLuint src, GLuint num);
-typedef void (APIENTRY * PFNGLEXTRACTCOMPONENTEXTPROC) (GLuint res, GLuint src, GLuint num);
-typedef GLuint (APIENTRY * PFNGLGENSYMBOLSEXTPROC) (GLenum datatype, GLenum storagetype, GLenum range, GLuint components);
-typedef void (APIENTRY * PFNGLSETINVARIANTEXTPROC) (GLuint id, GLenum type, const void *addr);
-typedef void (APIENTRY * PFNGLSETLOCALCONSTANTEXTPROC) (GLuint id, GLenum type, const void *addr);
-typedef void (APIENTRY * PFNGLVARIANTBVEXTPROC) (GLuint id, const GLbyte *addr);
-typedef void (APIENTRY * PFNGLVARIANTSVEXTPROC) (GLuint id, const GLshort *addr);
-typedef void (APIENTRY * PFNGLVARIANTIVEXTPROC) (GLuint id, const GLint *addr);
-typedef void (APIENTRY * PFNGLVARIANTFVEXTPROC) (GLuint id, const GLfloat *addr);
-typedef void (APIENTRY * PFNGLVARIANTDVEXTPROC) (GLuint id, const GLdouble *addr);
-typedef void (APIENTRY * PFNGLVARIANTUBVEXTPROC) (GLuint id, const GLubyte *addr);
-typedef void (APIENTRY * PFNGLVARIANTUSVEXTPROC) (GLuint id, const GLushort *addr);
-typedef void (APIENTRY * PFNGLVARIANTUIVEXTPROC) (GLuint id, const GLuint *addr);
-typedef void (APIENTRY * PFNGLVARIANTPOINTEREXTPROC) (GLuint id, GLenum type, GLuint stride, const void *addr);
-typedef void (APIENTRY * PFNGLENABLEVARIANTCLIENTSTATEEXTPROC) (GLuint id);
-typedef void (APIENTRY * PFNGLDISABLEVARIANTCLIENTSTATEEXTPROC) (GLuint id);
-typedef GLuint (APIENTRY * PFNGLBINDLIGHTPARAMETEREXTPROC) (GLenum light, GLenum value);
-typedef GLuint (APIENTRY * PFNGLBINDMATERIALPARAMETEREXTPROC) (GLenum face, GLenum value);
-typedef GLuint (APIENTRY * PFNGLBINDTEXGENPARAMETEREXTPROC) (GLenum unit, GLenum coord, GLenum value);
-typedef GLuint (APIENTRY * PFNGLBINDTEXTUREUNITPARAMETEREXTPROC) (GLenum unit, GLenum value);
-typedef GLuint (APIENTRY * PFNGLBINDPARAMETEREXTPROC) (GLenum value);
-typedef GLboolean (APIENTRY * PFNGLISVARIANTENABLEDEXTPROC) (GLuint id, GLenum cap);
-typedef void (APIENTRY * PFNGLGETVARIANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data);
-typedef void (APIENTRY * PFNGLGETVARIANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data);
-typedef void (APIENTRY * PFNGLGETVARIANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data);
-typedef void (APIENTRY * PFNGLGETVARIANTPOINTERVEXTPROC) (GLuint id, GLenum value, GLvoid* *data);
-typedef void (APIENTRY * PFNGLGETINVARIANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data);
-typedef void (APIENTRY * PFNGLGETINVARIANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data);
-typedef void (APIENTRY * PFNGLGETINVARIANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data);
-typedef void (APIENTRY * PFNGLGETLOCALCONSTANTBOOLEANVEXTPROC) (GLuint id, GLenum value, GLboolean *data);
-typedef void (APIENTRY * PFNGLGETLOCALCONSTANTINTEGERVEXTPROC) (GLuint id, GLenum value, GLint *data);
-typedef void (APIENTRY * PFNGLGETLOCALCONSTANTFLOATVEXTPROC) (GLuint id, GLenum value, GLfloat *data);
-#endif
-
-#ifndef GL_ATI_vertex_streams
-#define GL_ATI_vertex_streams 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glVertexStream1sATI (GLenum, GLshort);
-GLAPI void APIENTRY glVertexStream1svATI (GLenum, const GLshort *);
-GLAPI void APIENTRY glVertexStream1iATI (GLenum, GLint);
-GLAPI void APIENTRY glVertexStream1ivATI (GLenum, const GLint *);
-GLAPI void APIENTRY glVertexStream1fATI (GLenum, GLfloat);
-GLAPI void APIENTRY glVertexStream1fvATI (GLenum, const GLfloat *);
-GLAPI void APIENTRY glVertexStream1dATI (GLenum, GLdouble);
-GLAPI void APIENTRY glVertexStream1dvATI (GLenum, const GLdouble *);
-GLAPI void APIENTRY glVertexStream2sATI (GLenum, GLshort, GLshort);
-GLAPI void APIENTRY glVertexStream2svATI (GLenum, const GLshort *);
-GLAPI void APIENTRY glVertexStream2iATI (GLenum, GLint, GLint);
-GLAPI void APIENTRY glVertexStream2ivATI (GLenum, const GLint *);
-GLAPI void APIENTRY glVertexStream2fATI (GLenum, GLfloat, GLfloat);
-GLAPI void APIENTRY glVertexStream2fvATI (GLenum, const GLfloat *);
-GLAPI void APIENTRY glVertexStream2dATI (GLenum, GLdouble, GLdouble);
-GLAPI void APIENTRY glVertexStream2dvATI (GLenum, const GLdouble *);
-GLAPI void APIENTRY glVertexStream3sATI (GLenum, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glVertexStream3svATI (GLenum, const GLshort *);
-GLAPI void APIENTRY glVertexStream3iATI (GLenum, GLint, GLint, GLint);
-GLAPI void APIENTRY glVertexStream3ivATI (GLenum, const GLint *);
-GLAPI void APIENTRY glVertexStream3fATI (GLenum, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glVertexStream3fvATI (GLenum, const GLfloat *);
-GLAPI void APIENTRY glVertexStream3dATI (GLenum, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glVertexStream3dvATI (GLenum, const GLdouble *);
-GLAPI void APIENTRY glVertexStream4sATI (GLenum, GLshort, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glVertexStream4svATI (GLenum, const GLshort *);
-GLAPI void APIENTRY glVertexStream4iATI (GLenum, GLint, GLint, GLint, GLint);
-GLAPI void APIENTRY glVertexStream4ivATI (GLenum, const GLint *);
-GLAPI void APIENTRY glVertexStream4fATI (GLenum, GLfloat, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glVertexStream4fvATI (GLenum, const GLfloat *);
-GLAPI void APIENTRY glVertexStream4dATI (GLenum, GLdouble, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glVertexStream4dvATI (GLenum, const GLdouble *);
-GLAPI void APIENTRY glNormalStream3bATI (GLenum, GLbyte, GLbyte, GLbyte);
-GLAPI void APIENTRY glNormalStream3bvATI (GLenum, const GLbyte *);
-GLAPI void APIENTRY glNormalStream3sATI (GLenum, GLshort, GLshort, GLshort);
-GLAPI void APIENTRY glNormalStream3svATI (GLenum, const GLshort *);
-GLAPI void APIENTRY glNormalStream3iATI (GLenum, GLint, GLint, GLint);
-GLAPI void APIENTRY glNormalStream3ivATI (GLenum, const GLint *);
-GLAPI void APIENTRY glNormalStream3fATI (GLenum, GLfloat, GLfloat, GLfloat);
-GLAPI void APIENTRY glNormalStream3fvATI (GLenum, const GLfloat *);
-GLAPI void APIENTRY glNormalStream3dATI (GLenum, GLdouble, GLdouble, GLdouble);
-GLAPI void APIENTRY glNormalStream3dvATI (GLenum, const GLdouble *);
-GLAPI void APIENTRY glClientActiveVertexStreamATI (GLenum);
-GLAPI void APIENTRY glVertexBlendEnviATI (GLenum, GLint);
-GLAPI void APIENTRY glVertexBlendEnvfATI (GLenum, GLfloat);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLVERTEXSTREAM1SATIPROC) (GLenum stream, GLshort x);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM1SVATIPROC) (GLenum stream, const GLshort *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM1IATIPROC) (GLenum stream, GLint x);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM1IVATIPROC) (GLenum stream, const GLint *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM1FATIPROC) (GLenum stream, GLfloat x);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM1FVATIPROC) (GLenum stream, const GLfloat *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM1DATIPROC) (GLenum stream, GLdouble x);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM1DVATIPROC) (GLenum stream, const GLdouble *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM2SATIPROC) (GLenum stream, GLshort x, GLshort y);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM2SVATIPROC) (GLenum stream, const GLshort *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM2IATIPROC) (GLenum stream, GLint x, GLint y);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM2IVATIPROC) (GLenum stream, const GLint *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM2FATIPROC) (GLenum stream, GLfloat x, GLfloat y);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM2FVATIPROC) (GLenum stream, const GLfloat *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM2DATIPROC) (GLenum stream, GLdouble x, GLdouble y);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM2DVATIPROC) (GLenum stream, const GLdouble *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM3SATIPROC) (GLenum stream, GLshort x, GLshort y, GLshort z);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM3SVATIPROC) (GLenum stream, const GLshort *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM3IATIPROC) (GLenum stream, GLint x, GLint y, GLint z);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM3IVATIPROC) (GLenum stream, const GLint *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM3FATIPROC) (GLenum stream, GLfloat x, GLfloat y, GLfloat z);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM3FVATIPROC) (GLenum stream, const GLfloat *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM3DATIPROC) (GLenum stream, GLdouble x, GLdouble y, GLdouble z);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM3DVATIPROC) (GLenum stream, const GLdouble *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM4SATIPROC) (GLenum stream, GLshort x, GLshort y, GLshort z, GLshort w);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM4SVATIPROC) (GLenum stream, const GLshort *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM4IATIPROC) (GLenum stream, GLint x, GLint y, GLint z, GLint w);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM4IVATIPROC) (GLenum stream, const GLint *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM4FATIPROC) (GLenum stream, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM4FVATIPROC) (GLenum stream, const GLfloat *coords);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM4DATIPROC) (GLenum stream, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
-typedef void (APIENTRY * PFNGLVERTEXSTREAM4DVATIPROC) (GLenum stream, const GLdouble *coords);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3BATIPROC) (GLenum stream, GLbyte nx, GLbyte ny, GLbyte nz);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3BVATIPROC) (GLenum stream, const GLbyte *coords);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3SATIPROC) (GLenum stream, GLshort nx, GLshort ny, GLshort nz);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3SVATIPROC) (GLenum stream, const GLshort *coords);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3IATIPROC) (GLenum stream, GLint nx, GLint ny, GLint nz);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3IVATIPROC) (GLenum stream, const GLint *coords);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3FATIPROC) (GLenum stream, GLfloat nx, GLfloat ny, GLfloat nz);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3FVATIPROC) (GLenum stream, const GLfloat *coords);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3DATIPROC) (GLenum stream, GLdouble nx, GLdouble ny, GLdouble nz);
-typedef void (APIENTRY * PFNGLNORMALSTREAM3DVATIPROC) (GLenum stream, const GLdouble *coords);
-typedef void (APIENTRY * PFNGLCLIENTACTIVEVERTEXSTREAMATIPROC) (GLenum stream);
-typedef void (APIENTRY * PFNGLVERTEXBLENDENVIATIPROC) (GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLVERTEXBLENDENVFATIPROC) (GLenum pname, GLfloat param);
-#endif
-
-#ifndef GL_ATI_element_array
-#define GL_ATI_element_array 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glElementPointerATI (GLenum, const GLvoid *);
-GLAPI void APIENTRY glDrawElementArrayATI (GLenum, GLsizei);
-GLAPI void APIENTRY glDrawRangeElementArrayATI (GLenum, GLuint, GLuint, GLsizei);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLELEMENTPOINTERATIPROC) (GLenum type, const GLvoid *pointer);
-typedef void (APIENTRY * PFNGLDRAWELEMENTARRAYATIPROC) (GLenum mode, GLsizei count);
-typedef void (APIENTRY * PFNGLDRAWRANGEELEMENTARRAYATIPROC) (GLenum mode, GLuint start, GLuint end, GLsizei count);
-#endif
-
-#ifndef GL_SUN_mesh_array
-#define GL_SUN_mesh_array 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glDrawMeshArraysSUN (GLenum, GLint, GLsizei, GLsizei);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLDRAWMESHARRAYSSUNPROC) (GLenum mode, GLint first, GLsizei count, GLsizei width);
-#endif
-
-#ifndef GL_SUN_slice_accum
-#define GL_SUN_slice_accum 1
-#endif
-
-#ifndef GL_NV_multisample_filter_hint
-#define GL_NV_multisample_filter_hint 1
-#endif
-
-#ifndef GL_NV_depth_clamp
-#define GL_NV_depth_clamp 1
-#endif
-
-#ifndef GL_NV_occlusion_query
-#define GL_NV_occlusion_query 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glGenOcclusionQueriesNV (GLsizei, GLuint *);
-GLAPI void APIENTRY glDeleteOcclusionQueriesNV (GLsizei, const GLuint *);
-GLAPI GLboolean APIENTRY glIsOcclusionQueryNV (GLuint);
-GLAPI void APIENTRY glBeginOcclusionQueryNV (GLuint);
-GLAPI void APIENTRY glEndOcclusionQueryNV (void);
-GLAPI void APIENTRY glGetOcclusionQueryivNV (GLuint, GLenum, GLint *);
-GLAPI void APIENTRY glGetOcclusionQueryuivNV (GLuint, GLenum, GLuint *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLGENOCCLUSIONQUERIESNVPROC) (GLsizei n, GLuint *ids);
-typedef void (APIENTRY * PFNGLDELETEOCCLUSIONQUERIESNVPROC) (GLsizei n, const GLuint *ids);
-typedef GLboolean (APIENTRY * PFNGLISOCCLUSIONQUERYNVPROC) (GLuint id);
-typedef void (APIENTRY * PFNGLBEGINOCCLUSIONQUERYNVPROC) (GLuint id);
-typedef void (APIENTRY * PFNGLENDOCCLUSIONQUERYNVPROC) (void);
-typedef void (APIENTRY * PFNGLGETOCCLUSIONQUERYIVNVPROC) (GLuint id, GLenum pname, GLint *params);
-typedef void (APIENTRY * PFNGLGETOCCLUSIONQUERYUIVNVPROC) (GLuint id, GLenum pname, GLuint *params);
-#endif
-
-#ifndef GL_NV_point_sprite
-#define GL_NV_point_sprite 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glPointParameteriNV (GLenum, GLint);
-GLAPI void APIENTRY glPointParameterivNV (GLenum, const GLint *);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLPOINTPARAMETERINVPROC) (GLenum pname, GLint param);
-typedef void (APIENTRY * PFNGLPOINTPARAMETERIVNVPROC) (GLenum pname, const GLint *params);
-#endif
-
-#ifndef GL_NV_texture_shader3
-#define GL_NV_texture_shader3 1
-#endif
-
-#ifndef GL_NV_vertex_program1_1
-#define GL_NV_vertex_program1_1 1
-#endif
-
-#ifndef GL_EXT_shadow_funcs
-#define GL_EXT_shadow_funcs 1
-#endif
-
-#ifndef GL_EXT_stencil_two_side
-#define GL_EXT_stencil_two_side 1
-#ifdef GL_GLEXT_PROTOTYPES
-GLAPI void APIENTRY glActiveStencilFaceEXT (GLenum);
-#endif /* GL_GLEXT_PROTOTYPES */
-typedef void (APIENTRY * PFNGLACTIVESTENCILFACEEXTPROC) (GLenum face);
-#endif
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/libtess/Imakefile b/libtess/Imakefile
deleted file mode 100644
index 1cdedf2..0000000
--- a/libtess/Imakefile
+++ /dev/null
@@ -1,60 +0,0 @@
-XCOMM made subject to an alternative license as permitted in the SGI Free
-XCOMM Software License B, Version 1.1 (the "License"), the contents of this
-XCOMM file are subject only to the provisions of the License. You may not use
-XCOMM this file except in compliance with the License. You may obtain a copy
-XCOMM of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-XCOMM Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-XCOMM
-XCOMM http://oss.sgi.com/projects/FreeB
-XCOMM
-XCOMM Note that, as provided in the License, the Software is distributed on an
-XCOMM "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-XCOMM DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-XCOMM CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-XCOMM PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-XCOMM
-XCOMM Original Code. The Original Code is: OpenGL Sample Implementation,
-XCOMM Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-XCOMM Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-XCOMM Copyright in any portions created by third parties is as indicated
-XCOMM elsewhere herein. All Rights Reserved.
-XCOMM
-XCOMM Additional Notice Provisions: The application programming interfaces
-XCOMM established by SGI in conjunction with the Original Code are The
-XCOMM OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-XCOMM April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-XCOMM 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-XCOMM Window System(R) (Version 1.3), released October 19, 1998. This software
-XCOMM was created using the OpenGL(R) version 1.2.1 Sample Implementation
-XCOMM published by SGI, but has not been independently verified as being
-XCOMM compliant with the OpenGL(R) version 1.2.1 Specification.
-XCOMM
-
-#include <Library.tmpl>
-
-OBJS = \
- dict.o \
- geom.o \
- memalloc.o \
- mesh.o \
- normal.o \
- priorityq.o \
- render.o \
- sweep.o \
- tess.o \
- tessmono.o
-
-INCLUDES = \
- -I../include \
- -I$(TOP)/include \
- -I$(TOP)/include/GL
-
-DEFINES = \
- -DNDEBUG
-
-NormalLibraryObjectRule()
-
-NormalLibraryTarget(tess, $(OBJS))
-
-DependTarget()
-CleanTarget()
diff --git a/libtess/README b/libtess/README
deleted file mode 100644
index 6396f5b..0000000
--- a/libtess/README
+++ /dev/null
@@ -1,447 +0,0 @@
-/*
-** $Header$
-*/
-
-General Polygon Tesselation
----------------------------
-
- This note describes a tesselator for polygons consisting of one or
- more closed contours. It is backward-compatible with the current
- OpenGL Utilities tesselator, and is intended to replace it. Here is
- a summary of the major differences:
-
- - input contours can be intersecting, self-intersecting, or degenerate.
-
- - supports a choice of several winding rules for determining which parts
- of the polygon are on the "interior". This makes it possible to do
- CSG operations on polygons.
-
- - boundary extraction: instead of tesselating the polygon, returns a
- set of closed contours which separate the interior from the exterior.
-
- - returns the output as a small number of triangle fans and strips,
- rather than a list of independent triangles (when possible).
-
- - output is available as an explicit mesh (a quad-edge structure),
- in addition to the normal callback interface.
-
- - the algorithm used is extremely robust.
-
-
-The interface
--------------
-
- The tesselator state is maintained in a "tesselator object".
- These are allocated and destroyed using
-
- GLUtesselator *gluNewTess( void );
- void gluDeleteTess( GLUtesselator *tess );
-
- Several tesselator objects may be used simultaneously.
-
- Inputs
- ------
-
- The input contours are specified with the following routines:
-
- void gluTessBeginPolygon( GLUtesselator *tess );
- void gluTessBeginContour( GLUtesselator *tess );
- void gluTessVertex( GLUtesselator *tess, GLUcoord coords[3], void *data );
- void gluTessEndContour( GLUtesselator *tess );
- void gluTessEndPolygon( GLUtesselator *tess );
-
- Within each BeginPolygon/EndPolygon pair, there can be zero or more
- calls to BeginContour/EndContour. Within each contour, there are zero
- or more calls to gluTessVertex(). The vertices specify a closed
- contour (the last vertex of each contour is automatically linked to
- the first).
-
- "coords" give the coordinates of the vertex in 3-space. For useful
- results, all vertices should lie in some plane, since the vertices
- are projected onto a plane before tesselation. "data" is a pointer
- to a user-defined vertex structure, which typically contains other
- information such as color, texture coordinates, normal, etc. It is
- used to refer to the vertex during rendering.
-
- The library can be compiled in single- or double-precision; the type
- GLUcoord represents either "float" or "double" accordingly. The GLU
- version will be available in double-precision only. Compile with
- GLU_TESS_API_FLOAT defined to get the single-precision version.
-
- When EndPolygon is called, the tesselation algorithm determines
- which regions are interior to the given contours, according to one
- of several "winding rules" described below. The interior regions
- are then tesselated, and the output is provided as callbacks.
-
-
- Rendering Callbacks
- -------------------
-
- Callbacks are specified by the client using
-
- void gluTessCallback( GLUtesselator *tess, GLenum which, void (*fn)());
-
- If "fn" is NULL, any previously defined callback is discarded.
-
- The callbacks used to provide output are: /* which == */
-
- void begin( GLenum type ); /* GLU_TESS_BEGIN */
- void edgeFlag( GLboolean flag ); /* GLU_TESS_EDGE_FLAG */
- void vertex( void *data ); /* GLU_TESS_VERTEX */
- void end( void ); /* GLU_TESS_END */
-
- Any of the callbacks may be left undefined; if so, the corresponding
- information will not be supplied during rendering.
-
- The "begin" callback indicates the start of a primitive; type is one
- of GL_TRIANGLE_STRIP, GL_TRIANGLE_FAN, or GL_TRIANGLES (but see the
- notes on "boundary extraction" below).
-
- It is followed by any number of "vertex" callbacks, which supply the
- vertices in the same order as expected by the corresponding glBegin()
- call. After the last vertex of a given primitive, there is a callback
- to "end".
-
- If the "edgeFlag" callback is provided, no triangle fans or strips
- will be used. When edgeFlag is called, if "flag" is GL_TRUE then each
- vertex which follows begins an edge which lies on the polygon boundary
- (ie. an edge which separates an interior region from an exterior one).
- If "flag" is GL_FALSE, each vertex which follows begins an edge which lies
- in the polygon interior. "edgeFlag" will be called before the first
- call to "vertex".
-
- Other Callbacks
- ---------------
-
- void mesh( GLUmesh *mesh ); /* GLU_TESS_MESH */
-
- - Returns an explicit mesh, represented using the quad-edge structure
- (Guibas/Stolfi '85). Other implementations of this interface might
- use a different mesh structure, so this is available only only as an
- SGI extension. When the mesh is no longer needed, it should be freed
- using
-
- void gluDeleteMesh( GLUmesh *mesh );
-
- There is a brief description of this data structure in the include
- file "mesh.h". For the full details, see L. Guibas and J. Stolfi,
- Primitives for the manipulation of general subdivisions and the
- computation of Voronoi diagrams, ACM Transactions on Graphics,
- 4(2):74-123, April 1985. For an introduction, see the course notes
- for CS348a, "Mathematical Foundations of Computer Graphics",
- available at the Stanford bookstore (and taught during the fall
- quarter).
-
- void error( GLenum errno ); /* GLU_TESS_ERROR */
-
- - errno is one of GLU_TESS_MISSING_BEGIN_POLYGON,
- GLU_TESS_MISSING_END_POLYGON,
- GLU_TESS_MISSING_BEGIN_CONTOUR,
- GLU_TESS_MISSING_END_CONTOUR,
- GLU_TESS_COORD_TOO_LARGE,
- GLU_TESS_NEED_COMBINE_CALLBACK
-
- The first four are obvious. The interface recovers from these
- errors by inserting the missing call(s).
-
- GLU_TESS_COORD_TOO_LARGE says that some vertex coordinate exceeded
- the predefined constant GLU_TESS_MAX_COORD in absolute value, and
- that the value has been clamped. (Coordinate values must be small
- enough so that two can be multiplied together without overflow.)
-
- GLU_TESS_NEED_COMBINE_CALLBACK says that the algorithm detected an
- intersection between two edges in the input data, and the "combine"
- callback (below) was not provided. No output will be generated.
-
-
- void combine( GLUcoord coords[3], void *data[4], /* GLU_TESS_COMBINE */
- GLUcoord weight[4], void **outData );
-
- - When the algorithm detects an intersection, or wishes to merge
- features, it needs to create a new vertex. The vertex is defined
- as a linear combination of up to 4 existing vertices, referenced
- by data[0..3]. The coefficients of the linear combination are
- given by weight[0..3]; these weights always sum to 1.0. All vertex
- pointers are valid even when some of the weights are zero.
- "coords" gives the location of the new vertex.
-
- The user must allocate another vertex, interpolate parameters
- using "data" and "weights", and return the new vertex pointer in
- "outData". This handle is supplied during rendering callbacks.
- For example, if the polygon lies in an arbitrary plane in 3-space,
- and we associate a color with each vertex, the combine callback might
- look like this:
-
- void myCombine( GLUcoord coords[3], VERTEX *d[4],
- GLUcoord w[4], VERTEX **dataOut )
- {
- VERTEX *new = new_vertex();
-
- new->x = coords[0];
- new->y = coords[1];
- new->z = coords[2];
- new->r = w[0]*d[0]->r + w[1]*d[1]->r + w[2]*d[2]->r + w[3]*d[3]->r;
- new->g = w[0]*d[0]->g + w[1]*d[1]->g + w[2]*d[2]->g + w[3]*d[3]->g;
- new->b = w[0]*d[0]->b + w[1]*d[1]->b + w[2]*d[2]->b + w[3]*d[3]->b;
- new->a = w[0]*d[0]->a + w[1]*d[1]->a + w[2]*d[2]->a + w[3]*d[3]->a;
- *dataOut = new;
- }
-
- If the algorithm detects an intersection, then the "combine" callback
- must be defined, and must write a non-NULL pointer into "dataOut".
- Otherwise the GLU_TESS_NEED_COMBINE_CALLBACK error occurs, and no
- output is generated. This is the only error that can occur during
- tesselation and rendering.
-
-
- Control over Tesselation
- ------------------------
-
- void gluTessProperty( GLUtesselator *tess, GLenum which, GLUcoord value );
-
- Properties defined:
-
- - GLU_TESS_WINDING_RULE. Possible values:
-
- GLU_TESS_WINDING_ODD
- GLU_TESS_WINDING_NONZERO
- GLU_TESS_WINDING_POSITIVE
- GLU_TESS_WINDING_NEGATIVE
- GLU_TESS_WINDING_ABS_GEQ_TWO
-
- The input contours parition the plane into regions. A winding
- rule determines which of these regions are inside the polygon.
-
- For a single contour C, the winding number of a point x is simply
- the signed number of revolutions we make around x as we travel
- once around C (where CCW is positive). When there are several
- contours, the individual winding numbers are summed. This
- procedure associates a signed integer value with each point x in
- the plane. Note that the winding number is the same for all
- points in a single region.
-
- The winding rule classifies a region as "inside" if its winding
- number belongs to the chosen category (odd, nonzero, positive,
- negative, or absolute value of at least two). The current GLU
- tesselator implements the "odd" rule. The "nonzero" rule is another
- common way to define the interior. The other three rules are
- useful for polygon CSG operations (see below).
-
- - GLU_TESS_BOUNDARY_ONLY. Values: TRUE (non-zero) or FALSE (zero).
-
- If TRUE, returns a set of closed contours which separate the
- polygon interior and exterior (rather than a tesselation).
- Exterior contours are oriented CCW with respect to the normal,
- interior contours are oriented CW. The GLU_TESS_BEGIN callback
- uses the type GL_LINE_LOOP for each contour.
-
- - GLU_TESS_TOLERANCE. Value: a real number between 0.0 and 1.0.
-
- This specifies a tolerance for merging features to reduce the size
- of the output. For example, two vertices which are very close to
- each other might be replaced by a single vertex. The tolerance
- is multiplied by the largest coordinate magnitude of any input vertex;
- this specifies the maximum distance that any feature can move as the
- result of a single merge operation. If a single feature takes part
- in several merge operations, the total distance moved could be larger.
-
- Feature merging is completely optional; the tolerance is only a hint.
- The implementation is free to merge in some cases and not in others,
- or to never merge features at all. The default tolerance is zero.
-
- The current implementation merges vertices only if they are exactly
- coincident, regardless of the current tolerance. A vertex is
- spliced into an edge only if the implementation is unable to
- distinguish which side of the edge the vertex lies on.
- Two edges are merged only when both endpoints are identical.
-
-
- void gluTessNormal( GLUtesselator *tess,
- GLUcoord x, GLUcoord y, GLUcoord z )
-
- - Lets the user supply the polygon normal, if known. All input data
- is projected into a plane perpendicular to the normal before
- tesselation. All output triangles are oriented CCW with
- respect to the normal (CW orientation can be obtained by
- reversing the sign of the supplied normal). For example, if
- you know that all polygons lie in the x-y plane, call
- "gluTessNormal(tess, 0.0, 0.0, 1.0)" before rendering any polygons.
-
- - If the supplied normal is (0,0,0) (the default value), the
- normal is determined as follows. The direction of the normal,
- up to its sign, is found by fitting a plane to the vertices,
- without regard to how the vertices are connected. It is
- expected that the input data lies approximately in plane;
- otherwise projection perpendicular to the computed normal may
- substantially change the geometry. The sign of the normal is
- chosen so that the sum of the signed areas of all input contours
- is non-negative (where a CCW contour has positive area).
-
- - The supplied normal persists until it is changed by another
- call to gluTessNormal.
-
-
- Backward compatibility with the GLU tesselator
- ----------------------------------------------
-
- The preferred interface is the one described above. The following
- routines are obsolete, and are provided only for backward compatibility:
-
- typedef GLUtesselator GLUtriangulatorObj; /* obsolete name */
-
- void gluBeginPolygon( GLUtesselator *tess );
- void gluNextContour( GLUtesselator *tess, GLenum type );
- void gluEndPolygon( GLUtesselator *tess );
-
- "type" is one of GLU_EXTERIOR, GLU_INTERIOR, GLU_CCW, GLU_CW, or
- GLU_UNKNOWN. It is ignored by the current GLU tesselator.
-
- GLU_BEGIN, GLU_VERTEX, GLU_END, GLU_ERROR, and GLU_EDGE_FLAG are defined
- as synonyms for GLU_TESS_BEGIN, GLU_TESS_VERTEX, GLU_TESS_END,
- GLU_TESS_ERROR, and GLU_TESS_EDGE_FLAG.
-
-
-Polygon CSG operations
-----------------------
-
- The features of the tesselator make it easy to find the union, difference,
- or intersection of several polygons.
-
- First, assume that each polygon is defined so that the winding number
- is 0 for each exterior region, and 1 for each interior region. Under
- this model, CCW contours define the outer boundary of the polygon, and
- CW contours define holes. Contours may be nested, but a nested
- contour must be oriented oppositely from the contour that contains it.
-
- If the original polygons do not satisfy this description, they can be
- converted to this form by first running the tesselator with the
- GLU_TESS_BOUNDARY_ONLY property turned on. This returns a list of
- contours satisfying the restriction above. By allocating two
- tesselator objects, the callbacks from one tesselator can be fed
- directly to the input of another.
-
- Given two or more polygons of the form above, CSG operations can be
- implemented as follows:
-
- Union
- Draw all the input contours as a single polygon. The winding number
- of each resulting region is the number of original polygons
- which cover it. The union can be extracted using the
- GLU_TESS_WINDING_NONZERO or GLU_TESS_WINDING_POSITIVE winding rules.
- Note that with the nonzero rule, we would get the same result if
- all contour orientations were reversed.
-
- Intersection (two polygons at a time only)
- Draw a single polygon using the contours from both input polygons.
- Extract the result using GLU_TESS_WINDING_ABS_GEQ_TWO. (Since this
- winding rule looks at the absolute value, reversing all contour
- orientations does not change the result.)
-
- Difference
-
- Suppose we want to compute A \ (B union C union D). Draw a single
- polygon consisting of the unmodified contours from A, followed by
- the contours of B,C,D with the vertex order reversed (this changes
- the winding number of the interior regions to -1). To extract the
- result, use the GLU_TESS_WINDING_POSITIVE rule.
-
- If B,C,D are the result of a GLU_TESS_BOUNDARY_ONLY call, an
- alternative to reversing the vertex order is to reverse the sign of
- the supplied normal. For example in the x-y plane, call
- gluTessNormal( tess, 0.0, 0.0, -1.0 ).
-
-
-Performance
------------
-
- The tesselator is not intended for immediate-mode rendering; when
- possible the output should be cached in a user structure or display
- list. General polygon tesselation is an inherently difficult problem,
- especially given the goal of extreme robustness.
-
- The implementation makes an effort to output a small number of fans
- and strips; this should improve the rendering performance when the
- output is used in a display list.
-
- Single-contour input polygons are first tested to see whether they can
- be rendered as a triangle fan with respect to the first vertex (to
- avoid running the full decomposition algorithm on convex polygons).
- Non-convex polygons may be rendered by this "fast path" as well, if
- the algorithm gets lucky in its choice of a starting vertex.
-
- For best performance follow these guidelines:
-
- - supply the polygon normal, if available, using gluTessNormal().
- This represents about 10% of the computation time. For example,
- if all polygons lie in the x-y plane, use gluTessNormal(tess,0,0,1).
-
- - render many polygons using the same tesselator object, rather than
- allocating a new tesselator for each one. (In a multi-threaded,
- multi-processor environment you may get better performance using
- several tesselators.)
-
-
-Comparison with the GLU tesselator
-----------------------------------
-
- On polygons which make it through the "fast path", the tesselator is
- 3 to 5 times faster than the GLU tesselator.
-
- On polygons which don't make it through the fast path (but which don't
- have self-intersections or degeneracies), it is about 2 times slower.
-
- On polygons with self-intersections or degeneraces, there is nothing
- to compare against.
-
- The new tesselator generates many more fans and strips, reducing the
- number of vertices that need to be sent to the hardware.
-
- Key to the statistics:
-
- vert number of input vertices on all contours
- cntr number of input contours
- tri number of triangles in all output primitives
- strip number of triangle strips
- fan number of triangle fans
- ind number of independent triangles
- ms number of milliseconds for tesselation
- (on a 150MHz R4400 Indy)
-
- Convex polygon examples:
-
-New: 3 vert, 1 cntr, 1 tri, 0 strip, 0 fan, 1 ind, 0.0459 ms
-Old: 3 vert, 1 cntr, 1 tri, 0 strip, 0 fan, 1 ind, 0.149 ms
-New: 4 vert, 1 cntr, 2 tri, 0 strip, 1 fan, 0 ind, 0.0459 ms
-Old: 4 vert, 1 cntr, 2 tri, 0 strip, 0 fan, 2 ind, 0.161 ms
-New: 36 vert, 1 cntr, 34 tri, 0 strip, 1 fan, 0 ind, 0.153 ms
-Old: 36 vert, 1 cntr, 34 tri, 0 strip, 0 fan, 34 ind, 0.621 ms
-
- Concave single-contour polygons:
-
-New: 5 vert, 1 cntr, 3 tri, 0 strip, 1 fan, 0 ind, 0.052 ms
-Old: 5 vert, 1 cntr, 3 tri, 0 strip, 0 fan, 3 ind, 0.252 ms
-New: 19 vert, 1 cntr, 17 tri, 2 strip, 2 fan, 1 ind, 0.911 ms
-Old: 19 vert, 1 cntr, 17 tri, 0 strip, 0 fan, 17 ind, 0.529 ms
-New: 151 vert, 1 cntr, 149 tri, 13 strip, 18 fan, 3 ind, 6.82 ms
-Old: 151 vert, 1 cntr, 149 tri, 0 strip, 3 fan, 143 ind, 2.7 ms
-New: 574 vert, 1 cntr, 572 tri, 59 strip, 54 fan, 11 ind, 26.6 ms
-Old: 574 vert, 1 cntr, 572 tri, 0 strip, 31 fan, 499 ind, 12.4 ms
-
- Multiple contours, but no intersections:
-
-New: 7 vert, 2 cntr, 7 tri, 1 strip, 0 fan, 0 ind, 0.527 ms
-Old: 7 vert, 2 cntr, 7 tri, 0 strip, 0 fan, 7 ind, 0.274 ms
-New: 81 vert, 6 cntr, 89 tri, 9 strip, 7 fan, 6 ind, 3.88 ms
-Old: 81 vert, 6 cntr, 89 tri, 0 strip, 13 fan, 61 ind, 2.2 ms
-New: 391 vert, 19 cntr, 413 tri, 37 strip, 32 fan, 26 ind, 20.2 ms
-Old: 391 vert, 19 cntr, 413 tri, 0 strip, 25 fan, 363 ind, 8.68 ms
-
- Self-intersecting and degenerate examples:
-
-Bowtie: 4 vert, 1 cntr, 2 tri, 0 strip, 0 fan, 2 ind, 0.483 ms
-Star: 5 vert, 1 cntr, 5 tri, 0 strip, 0 fan, 5 ind, 0.91 ms
-Random: 24 vert, 7 cntr, 46 tri, 2 strip, 12 fan, 7 ind, 5.32 ms
-Font: 333 vert, 2 cntr, 331 tri, 32 strip, 16 fan, 3 ind, 14.1 ms
-: 167 vert, 35 cntr, 254 tri, 8 strip, 56 fan, 52 ind, 46.3 ms
-: 78 vert, 1 cntr, 2675 tri, 148 strip, 207 fan, 180 ind, 243 ms
-: 12480 vert, 2 cntr, 12478 tri, 736 strip,1275 fan, 5 ind, 1010 ms
diff --git a/libtess/alg-outline b/libtess/alg-outline
deleted file mode 100644
index fd0a8bf..0000000
--- a/libtess/alg-outline
+++ /dev/null
@@ -1,229 +0,0 @@
-/*
-** $Header$
-*/
-
-This is only a very brief overview. There is quite a bit of
-additional documentation in the source code itself.
-
-
-Goals of robust tesselation
----------------------------
-
-The tesselation algorithm is fundamentally a 2D algorithm. We
-initially project all data into a plane; our goal is to robustly
-tesselate the projected data. The same topological tesselation is
-then applied to the input data.
-
-Topologically, the output should always be a tesselation. If the
-input is even slightly non-planar, then some triangles will
-necessarily be back-facing when viewed from some angles, but the goal
-is to minimize this effect.
-
-The algorithm needs some capability of cleaning up the input data as
-well as the numerical errors in its own calculations. One way to do
-this is to specify a tolerance as defined above, and clean up the
-input and output during the line sweep process. At the very least,
-the algorithm must handle coincident vertices, vertices incident to an
-edge, and coincident edges.
-
-
-Phases of the algorithm
------------------------
-
-1. Find the polygon normal N.
-2. Project the vertex data onto a plane. It does not need to be
- perpendicular to the normal, eg. we can project onto the plane
- perpendicular to the coordinate axis whose dot product with N
- is largest.
-3. Using a line-sweep algorithm, partition the plane into x-monotone
- regions. Any vertical line intersects an x-monotone region in
- at most one interval.
-4. Triangulate the x-monotone regions.
-5. Group the triangles into strips and fans.
-
-
-Finding the normal vector
--------------------------
-
-A common way to find a polygon normal is to compute the signed area
-when the polygon is projected along the three coordinate axes. We
-can't do this, since contours can have zero area without being
-degenerate (eg. a bowtie).
-
-We fit a plane to the vertex data, ignoring how they are connected
-into contours. Ideally this would be a least-squares fit; however for
-our purpose the accuracy of the normal is not important. Instead we
-find three vertices which are widely separated, and compute the normal
-to the triangle they form. The vertices are chosen so that the
-triangle has an area at least 1/sqrt(3) times the largest area of any
-triangle formed using the input vertices.
-
-The contours do affect the orientation of the normal; after computing
-the normal, we check that the sum of the signed contour areas is
-non-negative, and reverse the normal if necessary.
-
-
-Projecting the vertices
------------------------
-
-We project the vertices onto a plane perpendicular to one of the three
-coordinate axes. This helps numerical accuracy by removing a
-transformation step between the original input data and the data
-processed by the algorithm. The projection also compresses the input
-data; the 2D distance between vertices after projection may be smaller
-than the original 2D distance. However by choosing the coordinate
-axis whose dot product with the normal is greatest, the compression
-factor is at most 1/sqrt(3).
-
-Even though the *accuracy* of the normal is not that important (since
-we are projecting perpendicular to a coordinate axis anyway), the
-*robustness* of the computation is important. For example, if there
-are many vertices which lie almost along a line, and one vertex V
-which is well-separated from the line, then our normal computation
-should involve V otherwise the results will be garbage.
-
-The advantage of projecting perpendicular to the polygon normal is
-that computed intersection points will be as close as possible to
-their ideal locations. To get this behavior, define TRUE_PROJECT.
-
-
-The Line Sweep
---------------
-
-There are three data structures: the mesh, the event queue, and the
-edge dictionary.
-
-The mesh is a "quad-edge" data structure which records the topology of
-the current decomposition; for details see the include file "mesh.h".
-
-The event queue simply holds all vertices (both original and computed
-ones), organized so that we can quickly extract the vertex with the
-minimum x-coord (and among those, the one with the minimum y-coord).
-
-The edge dictionary describes the current intersection of the sweep
-line with the regions of the polygon. This is just an ordering of the
-edges which intersect the sweep line, sorted by their current order of
-intersection. For each pair of edges, we store some information about
-the monotone region between them -- these are call "active regions"
-(since they are crossed by the current sweep line).
-
-The basic algorithm is to sweep from left to right, processing each
-vertex. The processed portion of the mesh (left of the sweep line) is
-a planar decomposition. As we cross each vertex, we update the mesh
-and the edge dictionary, then we check any newly adjacent pairs of
-edges to see if they intersect.
-
-A vertex can have any number of edges. Vertices with many edges can
-be created as vertices are merged and intersection points are
-computed. For unprocessed vertices (right of the sweep line), these
-edges are in no particular order around the vertex; for processed
-vertices, the topological ordering should match the geometric ordering.
-
-The vertex processing happens in two phases: first we process are the
-left-going edges (all these edges are currently in the edge
-dictionary). This involves:
-
- - deleting the left-going edges from the dictionary;
- - relinking the mesh if necessary, so that the order of these edges around
- the event vertex matches the order in the dictionary;
- - marking any terminated regions (regions which lie between two left-going
- edges) as either "inside" or "outside" according to their winding number.
-
-When there are no left-going edges, and the event vertex is in an
-"interior" region, we need to add an edge (to split the region into
-monotone pieces). To do this we simply join the event vertex to the
-rightmost left endpoint of the upper or lower edge of the containing
-region.
-
-Then we process the right-going edges. This involves:
-
- - inserting the edges in the edge dictionary;
- - computing the winding number of any newly created active regions.
- We can compute this incrementally using the winding of each edge
- that we cross as we walk through the dictionary.
- - relinking the mesh if necessary, so that the order of these edges around
- the event vertex matches the order in the dictionary;
- - checking any newly adjacent edges for intersection and/or merging.
-
-If there are no right-going edges, again we need to add one to split
-the containing region into monotone pieces. In our case it is most
-convenient to add an edge to the leftmost right endpoint of either
-containing edge; however we may need to change this later (see the
-code for details).
-
-
-Invariants
-----------
-
-These are the most important invariants maintained during the sweep.
-We define a function VertLeq(v1,v2) which defines the order in which
-vertices cross the sweep line, and a function EdgeLeq(e1,e2; loc)
-which says whether e1 is below e2 at the sweep event location "loc".
-This function is defined only at sweep event locations which lie
-between the rightmost left endpoint of {e1,e2}, and the leftmost right
-endpoint of {e1,e2}.
-
-Invariants for the Edge Dictionary.
-
- - Each pair of adjacent edges e2=Succ(e1) satisfies EdgeLeq(e1,e2)
- at any valid location of the sweep event.
- - If EdgeLeq(e2,e1) as well (at any valid sweep event), then e1 and e2
- share a common endpoint.
- - For each e in the dictionary, e->Dst has been processed but not e->Org.
- - Each edge e satisfies VertLeq(e->Dst,event) && VertLeq(event,e->Org)
- where "event" is the current sweep line event.
- - No edge e has zero length.
- - No two edges have identical left and right endpoints.
-
-Invariants for the Mesh (the processed portion).
-
- - The portion of the mesh left of the sweep line is a planar graph,
- ie. there is *some* way to embed it in the plane.
- - No processed edge has zero length.
- - No two processed vertices have identical coordinates.
- - Each "inside" region is monotone, ie. can be broken into two chains
- of monotonically increasing vertices according to VertLeq(v1,v2)
- - a non-invariant: these chains may intersect (slightly) due to
- numerical errors, but this does not affect the algorithm's operation.
-
-Invariants for the Sweep.
-
- - If a vertex has any left-going edges, then these must be in the edge
- dictionary at the time the vertex is processed.
- - If an edge is marked "fixUpperEdge" (it is a temporary edge introduced
- by ConnectRightVertex), then it is the only right-going edge from
- its associated vertex. (This says that these edges exist only
- when it is necessary.)
-
-
-Robustness
-----------
-
-The key to the robustness of the algorithm is maintaining the
-invariants above, especially the correct ordering of the edge
-dictionary. We achieve this by:
-
- 1. Writing the numerical computations for maximum precision rather
- than maximum speed.
-
- 2. Making no assumptions at all about the results of the edge
- intersection calculations -- for sufficiently degenerate inputs,
- the computed location is not much better than a random number.
-
- 3. When numerical errors violate the invariants, restore them
- by making *topological* changes when necessary (ie. relinking
- the mesh structure).
-
-
-Triangulation and Grouping
---------------------------
-
-We finish the line sweep before doing any triangulation. This is
-because even after a monotone region is complete, there can be further
-changes to its vertex data because of further vertex merging.
-
-After triangulating all monotone regions, we want to group the
-triangles into fans and strips. We do this using a greedy approach.
-The triangulation itself is not optimized to reduce the number of
-primitives; we just try to get a reasonable decomposition of the
-computed triangulation.
diff --git a/libtess/dict-list.h b/libtess/dict-list.h
deleted file mode 100644
index 4ae1f7b..0000000
--- a/libtess/dict-list.h
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __dict_list_h_
-#define __dict_list_h_
-
-/* Use #define's so that another heap implementation can use this one */
-
-#define DictKey DictListKey
-#define Dict DictList
-#define DictNode DictListNode
-
-#define dictNewDict(frame,leq) __gl_dictListNewDict(frame,leq)
-#define dictDeleteDict(dict) __gl_dictListDeleteDict(dict)
-
-#define dictSearch(dict,key) __gl_dictListSearch(dict,key)
-#define dictInsert(dict,key) __gl_dictListInsert(dict,key)
-#define dictInsertBefore(dict,node,key) __gl_dictListInsertBefore(dict,node,key)
-#define dictDelete(dict,node) __gl_dictListDelete(dict,node)
-
-#define dictKey(n) __gl_dictListKey(n)
-#define dictSucc(n) __gl_dictListSucc(n)
-#define dictPred(n) __gl_dictListPred(n)
-#define dictMin(d) __gl_dictListMin(d)
-#define dictMax(d) __gl_dictListMax(d)
-
-
-
-typedef void *DictKey;
-typedef struct Dict Dict;
-typedef struct DictNode DictNode;
-
-Dict *dictNewDict(
- void *frame,
- int (*leq)(void *frame, DictKey key1, DictKey key2) );
-
-void dictDeleteDict( Dict *dict );
-
-/* Search returns the node with the smallest key greater than or equal
- * to the given key. If there is no such key, returns a node whose
- * key is NULL. Similarly, Succ(Max(d)) has a NULL key, etc.
- */
-DictNode *dictSearch( Dict *dict, DictKey key );
-DictNode *dictInsertBefore( Dict *dict, DictNode *node, DictKey key );
-void dictDelete( Dict *dict, DictNode *node );
-
-#define __gl_dictListKey(n) ((n)->key)
-#define __gl_dictListSucc(n) ((n)->next)
-#define __gl_dictListPred(n) ((n)->prev)
-#define __gl_dictListMin(d) ((d)->head.next)
-#define __gl_dictListMax(d) ((d)->head.prev)
-#define __gl_dictListInsert(d,k) (dictInsertBefore((d),&(d)->head,(k)))
-
-
-/*** Private data structures ***/
-
-struct DictNode {
- DictKey key;
- DictNode *next;
- DictNode *prev;
-};
-
-struct Dict {
- DictNode head;
- void *frame;
- int (*leq)(void *frame, DictKey key1, DictKey key2);
-};
-
-#endif
diff --git a/libtess/dict.c b/libtess/dict.c
deleted file mode 100644
index ad5604b..0000000
--- a/libtess/dict.c
+++ /dev/null
@@ -1,117 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include <stddef.h>
-#include "dict-list.h"
-#include "memalloc.h"
-
-/* really __gl_dictListNewDict */
-Dict *dictNewDict( void *frame,
- int (*leq)(void *frame, DictKey key1, DictKey key2) )
-{
- Dict *dict = (Dict *) memAlloc( sizeof( Dict ));
- DictNode *head;
-
- if (dict == NULL) return NULL;
-
- head = &dict->head;
-
- head->key = NULL;
- head->next = head;
- head->prev = head;
-
- dict->frame = frame;
- dict->leq = leq;
-
- return dict;
-}
-
-/* really __gl_dictListDeleteDict */
-void dictDeleteDict( Dict *dict )
-{
- DictNode *node;
-
- for( node = dict->head.next; node != &dict->head; node = node->next ) {
- memFree( node );
- }
- memFree( dict );
-}
-
-/* really __gl_dictListInsertBefore */
-DictNode *dictInsertBefore( Dict *dict, DictNode *node, DictKey key )
-{
- DictNode *newNode;
-
- do {
- node = node->prev;
- } while( node->key != NULL && ! (*dict->leq)(dict->frame, node->key, key));
-
- newNode = (DictNode *) memAlloc( sizeof( DictNode ));
- if (newNode == NULL) return NULL;
-
- newNode->key = key;
- newNode->next = node->next;
- node->next->prev = newNode;
- newNode->prev = node;
- node->next = newNode;
-
- return newNode;
-}
-
-/* really __gl_dictListDelete */
-void dictDelete( Dict *dict, DictNode *node ) /*ARGSUSED*/
-{
- node->next->prev = node->prev;
- node->prev->next = node->next;
- memFree( node );
-}
-
-/* really __gl_dictListSearch */
-DictNode *dictSearch( Dict *dict, DictKey key )
-{
- DictNode *node = &dict->head;
-
- do {
- node = node->next;
- } while( node->key != NULL && ! (*dict->leq)(dict->frame, key, node->key));
-
- return node;
-}
diff --git a/libtess/dict.h b/libtess/dict.h
deleted file mode 100644
index 4ae1f7b..0000000
--- a/libtess/dict.h
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __dict_list_h_
-#define __dict_list_h_
-
-/* Use #define's so that another heap implementation can use this one */
-
-#define DictKey DictListKey
-#define Dict DictList
-#define DictNode DictListNode
-
-#define dictNewDict(frame,leq) __gl_dictListNewDict(frame,leq)
-#define dictDeleteDict(dict) __gl_dictListDeleteDict(dict)
-
-#define dictSearch(dict,key) __gl_dictListSearch(dict,key)
-#define dictInsert(dict,key) __gl_dictListInsert(dict,key)
-#define dictInsertBefore(dict,node,key) __gl_dictListInsertBefore(dict,node,key)
-#define dictDelete(dict,node) __gl_dictListDelete(dict,node)
-
-#define dictKey(n) __gl_dictListKey(n)
-#define dictSucc(n) __gl_dictListSucc(n)
-#define dictPred(n) __gl_dictListPred(n)
-#define dictMin(d) __gl_dictListMin(d)
-#define dictMax(d) __gl_dictListMax(d)
-
-
-
-typedef void *DictKey;
-typedef struct Dict Dict;
-typedef struct DictNode DictNode;
-
-Dict *dictNewDict(
- void *frame,
- int (*leq)(void *frame, DictKey key1, DictKey key2) );
-
-void dictDeleteDict( Dict *dict );
-
-/* Search returns the node with the smallest key greater than or equal
- * to the given key. If there is no such key, returns a node whose
- * key is NULL. Similarly, Succ(Max(d)) has a NULL key, etc.
- */
-DictNode *dictSearch( Dict *dict, DictKey key );
-DictNode *dictInsertBefore( Dict *dict, DictNode *node, DictKey key );
-void dictDelete( Dict *dict, DictNode *node );
-
-#define __gl_dictListKey(n) ((n)->key)
-#define __gl_dictListSucc(n) ((n)->next)
-#define __gl_dictListPred(n) ((n)->prev)
-#define __gl_dictListMin(d) ((d)->head.next)
-#define __gl_dictListMax(d) ((d)->head.prev)
-#define __gl_dictListInsert(d,k) (dictInsertBefore((d),&(d)->head,(k)))
-
-
-/*** Private data structures ***/
-
-struct DictNode {
- DictKey key;
- DictNode *next;
- DictNode *prev;
-};
-
-struct Dict {
- DictNode head;
- void *frame;
- int (*leq)(void *frame, DictKey key1, DictKey key2);
-};
-
-#endif
diff --git a/libtess/geom.c b/libtess/geom.c
deleted file mode 100644
index 19fedc6..0000000
--- a/libtess/geom.c
+++ /dev/null
@@ -1,271 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include "gluos.h"
-#include <assert.h>
-#include "mesh.h"
-#include "geom.h"
-
-int __gl_vertLeq( GLUvertex *u, GLUvertex *v )
-{
- /* Returns TRUE if u is lexicographically <= v. */
-
- return VertLeq( u, v );
-}
-
-GLdouble __gl_edgeEval( GLUvertex *u, GLUvertex *v, GLUvertex *w )
-{
- /* Given three vertices u,v,w such that VertLeq(u,v) && VertLeq(v,w),
- * evaluates the t-coord of the edge uw at the s-coord of the vertex v.
- * Returns v->t - (uw)(v->s), ie. the signed distance from uw to v.
- * If uw is vertical (and thus passes thru v), the result is zero.
- *
- * The calculation is extremely accurate and stable, even when v
- * is very close to u or w. In particular if we set v->t = 0 and
- * let r be the negated result (this evaluates (uw)(v->s)), then
- * r is guaranteed to satisfy MIN(u->t,w->t) <= r <= MAX(u->t,w->t).
- */
- GLdouble gapL, gapR;
-
- assert( VertLeq( u, v ) && VertLeq( v, w ));
-
- gapL = v->s - u->s;
- gapR = w->s - v->s;
-
- if( gapL + gapR > 0 ) {
- if( gapL < gapR ) {
- return (v->t - u->t) + (u->t - w->t) * (gapL / (gapL + gapR));
- } else {
- return (v->t - w->t) + (w->t - u->t) * (gapR / (gapL + gapR));
- }
- }
- /* vertical line */
- return 0;
-}
-
-GLdouble __gl_edgeSign( GLUvertex *u, GLUvertex *v, GLUvertex *w )
-{
- /* Returns a number whose sign matches EdgeEval(u,v,w) but which
- * is cheaper to evaluate. Returns > 0, == 0 , or < 0
- * as v is above, on, or below the edge uw.
- */
- GLdouble gapL, gapR;
-
- assert( VertLeq( u, v ) && VertLeq( v, w ));
-
- gapL = v->s - u->s;
- gapR = w->s - v->s;
-
- if( gapL + gapR > 0 ) {
- return (v->t - w->t) * gapL + (v->t - u->t) * gapR;
- }
- /* vertical line */
- return 0;
-}
-
-
-/***********************************************************************
- * Define versions of EdgeSign, EdgeEval with s and t transposed.
- */
-
-GLdouble __gl_transEval( GLUvertex *u, GLUvertex *v, GLUvertex *w )
-{
- /* Given three vertices u,v,w such that TransLeq(u,v) && TransLeq(v,w),
- * evaluates the t-coord of the edge uw at the s-coord of the vertex v.
- * Returns v->s - (uw)(v->t), ie. the signed distance from uw to v.
- * If uw is vertical (and thus passes thru v), the result is zero.
- *
- * The calculation is extremely accurate and stable, even when v
- * is very close to u or w. In particular if we set v->s = 0 and
- * let r be the negated result (this evaluates (uw)(v->t)), then
- * r is guaranteed to satisfy MIN(u->s,w->s) <= r <= MAX(u->s,w->s).
- */
- GLdouble gapL, gapR;
-
- assert( TransLeq( u, v ) && TransLeq( v, w ));
-
- gapL = v->t - u->t;
- gapR = w->t - v->t;
-
- if( gapL + gapR > 0 ) {
- if( gapL < gapR ) {
- return (v->s - u->s) + (u->s - w->s) * (gapL / (gapL + gapR));
- } else {
- return (v->s - w->s) + (w->s - u->s) * (gapR / (gapL + gapR));
- }
- }
- /* vertical line */
- return 0;
-}
-
-GLdouble __gl_transSign( GLUvertex *u, GLUvertex *v, GLUvertex *w )
-{
- /* Returns a number whose sign matches TransEval(u,v,w) but which
- * is cheaper to evaluate. Returns > 0, == 0 , or < 0
- * as v is above, on, or below the edge uw.
- */
- GLdouble gapL, gapR;
-
- assert( TransLeq( u, v ) && TransLeq( v, w ));
-
- gapL = v->t - u->t;
- gapR = w->t - v->t;
-
- if( gapL + gapR > 0 ) {
- return (v->s - w->s) * gapL + (v->s - u->s) * gapR;
- }
- /* vertical line */
- return 0;
-}
-
-
-int __gl_vertCCW( GLUvertex *u, GLUvertex *v, GLUvertex *w )
-{
- /* For almost-degenerate situations, the results are not reliable.
- * Unless the floating-point arithmetic can be performed without
- * rounding errors, *any* implementation will give incorrect results
- * on some degenerate inputs, so the client must have some way to
- * handle this situation.
- */
- return (u->s*(v->t - w->t) + v->s*(w->t - u->t) + w->s*(u->t - v->t)) >= 0;
-}
-
-/* Given parameters a,x,b,y returns the value (b*x+a*y)/(a+b),
- * or (x+y)/2 if a==b==0. It requires that a,b >= 0, and enforces
- * this in the rare case that one argument is slightly negative.
- * The implementation is extremely stable numerically.
- * In particular it guarantees that the result r satisfies
- * MIN(x,y) <= r <= MAX(x,y), and the results are very accurate
- * even when a and b differ greatly in magnitude.
- */
-#define RealInterpolate(a,x,b,y) \
- (a = (a < 0) ? 0 : a, b = (b < 0) ? 0 : b, \
- ((a <= b) ? ((b == 0) ? ((x+y) / 2) \
- : (x + (y-x) * (a/(a+b)))) \
- : (y + (x-y) * (b/(a+b)))))
-
-#ifndef FOR_TRITE_TEST_PROGRAM
-#define Interpolate(a,x,b,y) RealInterpolate(a,x,b,y)
-#else
-
-/* Claim: the ONLY property the sweep algorithm relies on is that
- * MIN(x,y) <= r <= MAX(x,y). This is a nasty way to test that.
- */
-#include <stdlib.h>
-extern int RandomInterpolate;
-
-GLdouble Interpolate( GLdouble a, GLdouble x, GLdouble b, GLdouble y)
-{
-printf("*********************%d\n",RandomInterpolate);
- if( RandomInterpolate ) {
- a = 1.2 * drand48() - 0.1;
- a = (a < 0) ? 0 : ((a > 1) ? 1 : a);
- b = 1.0 - a;
- }
- return RealInterpolate(a,x,b,y);
-}
-
-#endif
-
-#define Swap(a,b) if (1) { GLUvertex *t = a; a = b; b = t; } else
-
-void __gl_edgeIntersect( GLUvertex *o1, GLUvertex *d1,
- GLUvertex *o2, GLUvertex *d2,
- GLUvertex *v )
-/* Given edges (o1,d1) and (o2,d2), compute their point of intersection.
- * The computed point is guaranteed to lie in the intersection of the
- * bounding rectangles defined by each edge.
- */
-{
- GLdouble z1, z2;
-
- /* This is certainly not the most efficient way to find the intersection
- * of two line segments, but it is very numerically stable.
- *
- * Strategy: find the two middle vertices in the VertLeq ordering,
- * and interpolate the intersection s-value from these. Then repeat
- * using the TransLeq ordering to find the intersection t-value.
- */
-
- if( ! VertLeq( o1, d1 )) { Swap( o1, d1 ); }
- if( ! VertLeq( o2, d2 )) { Swap( o2, d2 ); }
- if( ! VertLeq( o1, o2 )) { Swap( o1, o2 ); Swap( d1, d2 ); }
-
- if( ! VertLeq( o2, d1 )) {
- /* Technically, no intersection -- do our best */
- v->s = (o2->s + d1->s) / 2;
- } else if( VertLeq( d1, d2 )) {
- /* Interpolate between o2 and d1 */
- z1 = EdgeEval( o1, o2, d1 );
- z2 = EdgeEval( o2, d1, d2 );
- if( z1+z2 < 0 ) { z1 = -z1; z2 = -z2; }
- v->s = Interpolate( z1, o2->s, z2, d1->s );
- } else {
- /* Interpolate between o2 and d2 */
- z1 = EdgeSign( o1, o2, d1 );
- z2 = -EdgeSign( o1, d2, d1 );
- if( z1+z2 < 0 ) { z1 = -z1; z2 = -z2; }
- v->s = Interpolate( z1, o2->s, z2, d2->s );
- }
-
- /* Now repeat the process for t */
-
- if( ! TransLeq( o1, d1 )) { Swap( o1, d1 ); }
- if( ! TransLeq( o2, d2 )) { Swap( o2, d2 ); }
- if( ! TransLeq( o1, o2 )) { Swap( o1, o2 ); Swap( d1, d2 ); }
-
- if( ! TransLeq( o2, d1 )) {
- /* Technically, no intersection -- do our best */
- v->t = (o2->t + d1->t) / 2;
- } else if( TransLeq( d1, d2 )) {
- /* Interpolate between o2 and d1 */
- z1 = TransEval( o1, o2, d1 );
- z2 = TransEval( o2, d1, d2 );
- if( z1+z2 < 0 ) { z1 = -z1; z2 = -z2; }
- v->t = Interpolate( z1, o2->t, z2, d1->t );
- } else {
- /* Interpolate between o2 and d2 */
- z1 = TransSign( o1, o2, d1 );
- z2 = -TransSign( o1, d2, d1 );
- if( z1+z2 < 0 ) { z1 = -z1; z2 = -z2; }
- v->t = Interpolate( z1, o2->t, z2, d2->t );
- }
-}
diff --git a/libtess/geom.h b/libtess/geom.h
deleted file mode 100644
index a122d79..0000000
--- a/libtess/geom.h
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __geom_h_
-#define __geom_h_
-
-#include "mesh.h"
-
-#ifdef NO_BRANCH_CONDITIONS
-/* MIPS architecture has special instructions to evaluate boolean
- * conditions -- more efficient than branching, IF you can get the
- * compiler to generate the right instructions (SGI compiler doesn't)
- */
-#define VertEq(u,v) (((u)->s == (v)->s) & ((u)->t == (v)->t))
-#define VertLeq(u,v) (((u)->s < (v)->s) | \
- ((u)->s == (v)->s & (u)->t <= (v)->t))
-#else
-#define VertEq(u,v) ((u)->s == (v)->s && (u)->t == (v)->t)
-#define VertLeq(u,v) (((u)->s < (v)->s) || \
- ((u)->s == (v)->s && (u)->t <= (v)->t))
-#endif
-
-#define EdgeEval(u,v,w) __gl_edgeEval(u,v,w)
-#define EdgeSign(u,v,w) __gl_edgeSign(u,v,w)
-
-/* Versions of VertLeq, EdgeSign, EdgeEval with s and t transposed. */
-
-#define TransLeq(u,v) (((u)->t < (v)->t) || \
- ((u)->t == (v)->t && (u)->s <= (v)->s))
-#define TransEval(u,v,w) __gl_transEval(u,v,w)
-#define TransSign(u,v,w) __gl_transSign(u,v,w)
-
-
-#define EdgeGoesLeft(e) VertLeq( (e)->Dst, (e)->Org )
-#define EdgeGoesRight(e) VertLeq( (e)->Org, (e)->Dst )
-
-#define ABS(x) ((x) < 0 ? -(x) : (x))
-#define VertL1dist(u,v) (ABS(u->s - v->s) + ABS(u->t - v->t))
-
-#define VertCCW(u,v,w) __gl_vertCCW(u,v,w)
-
-int __gl_vertLeq( GLUvertex *u, GLUvertex *v );
-GLdouble __gl_edgeEval( GLUvertex *u, GLUvertex *v, GLUvertex *w );
-GLdouble __gl_edgeSign( GLUvertex *u, GLUvertex *v, GLUvertex *w );
-GLdouble __gl_transEval( GLUvertex *u, GLUvertex *v, GLUvertex *w );
-GLdouble __gl_transSign( GLUvertex *u, GLUvertex *v, GLUvertex *w );
-int __gl_vertCCW( GLUvertex *u, GLUvertex *v, GLUvertex *w );
-void __gl_edgeIntersect( GLUvertex *o1, GLUvertex *d1,
- GLUvertex *o2, GLUvertex *d2,
- GLUvertex *v );
-
-#endif
diff --git a/libtess/glu.h b/libtess/glu.h
deleted file mode 100644
index 391583a..0000000
--- a/libtess/glu.h
+++ /dev/null
@@ -1,325 +0,0 @@
-/* $XFree86: xc/include/GL/glu.h,v 1.1 2001/01/15 22:17:50 dawes Exp $ */
-
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: This software was created using the
-** OpenGL(R) version 1.2.1 Sample Implementation published by SGI, but has
-** not been independently verified as being compliant with the OpenGL(R)
-** version 1.2.1 Specification.
-*/
-
-#ifndef __glu_h__
-#define __glu_h__
-
-#include <GL/gl.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*************************************************************/
-
-/* Extensions */
-#define GLU_EXT_object_space_tess 1
-#define GLU_EXT_nurbs_tessellator 1
-
-/* Boolean */
-#define GLU_FALSE 0
-#define GLU_TRUE 1
-
-/* Version */
-#define GLU_VERSION_1_1 1
-#define GLU_VERSION_1_2 1
-#define GLU_VERSION_1_3 1
-
-/* StringName */
-#define GLU_VERSION 100800
-#define GLU_EXTENSIONS 100801
-
-/* ErrorCode */
-#define GLU_INVALID_ENUM 100900
-#define GLU_INVALID_VALUE 100901
-#define GLU_OUT_OF_MEMORY 100902
-#define GLU_INVALID_OPERATION 100904
-
-/* NurbsDisplay */
-/* GLU_FILL */
-#define GLU_OUTLINE_POLYGON 100240
-#define GLU_OUTLINE_PATCH 100241
-
-/* NurbsCallback */
-#define GLU_NURBS_ERROR 100103
-#define GLU_ERROR 100103
-#define GLU_NURBS_BEGIN 100164
-#define GLU_NURBS_BEGIN_EXT 100164
-#define GLU_NURBS_VERTEX 100165
-#define GLU_NURBS_VERTEX_EXT 100165
-#define GLU_NURBS_NORMAL 100166
-#define GLU_NURBS_NORMAL_EXT 100166
-#define GLU_NURBS_COLOR 100167
-#define GLU_NURBS_COLOR_EXT 100167
-#define GLU_NURBS_TEXTURE_COORD 100168
-#define GLU_NURBS_TEX_COORD_EXT 100168
-#define GLU_NURBS_END 100169
-#define GLU_NURBS_END_EXT 100169
-#define GLU_NURBS_BEGIN_DATA 100170
-#define GLU_NURBS_BEGIN_DATA_EXT 100170
-#define GLU_NURBS_VERTEX_DATA 100171
-#define GLU_NURBS_VERTEX_DATA_EXT 100171
-#define GLU_NURBS_NORMAL_DATA 100172
-#define GLU_NURBS_NORMAL_DATA_EXT 100172
-#define GLU_NURBS_COLOR_DATA 100173
-#define GLU_NURBS_COLOR_DATA_EXT 100173
-#define GLU_NURBS_TEXTURE_COORD_DATA 100174
-#define GLU_NURBS_TEX_COORD_DATA_EXT 100174
-#define GLU_NURBS_END_DATA 100175
-#define GLU_NURBS_END_DATA_EXT 100175
-
-/* NurbsError */
-#define GLU_NURBS_ERROR1 100251
-#define GLU_NURBS_ERROR2 100252
-#define GLU_NURBS_ERROR3 100253
-#define GLU_NURBS_ERROR4 100254
-#define GLU_NURBS_ERROR5 100255
-#define GLU_NURBS_ERROR6 100256
-#define GLU_NURBS_ERROR7 100257
-#define GLU_NURBS_ERROR8 100258
-#define GLU_NURBS_ERROR9 100259
-#define GLU_NURBS_ERROR10 100260
-#define GLU_NURBS_ERROR11 100261
-#define GLU_NURBS_ERROR12 100262
-#define GLU_NURBS_ERROR13 100263
-#define GLU_NURBS_ERROR14 100264
-#define GLU_NURBS_ERROR15 100265
-#define GLU_NURBS_ERROR16 100266
-#define GLU_NURBS_ERROR17 100267
-#define GLU_NURBS_ERROR18 100268
-#define GLU_NURBS_ERROR19 100269
-#define GLU_NURBS_ERROR20 100270
-#define GLU_NURBS_ERROR21 100271
-#define GLU_NURBS_ERROR22 100272
-#define GLU_NURBS_ERROR23 100273
-#define GLU_NURBS_ERROR24 100274
-#define GLU_NURBS_ERROR25 100275
-#define GLU_NURBS_ERROR26 100276
-#define GLU_NURBS_ERROR27 100277
-#define GLU_NURBS_ERROR28 100278
-#define GLU_NURBS_ERROR29 100279
-#define GLU_NURBS_ERROR30 100280
-#define GLU_NURBS_ERROR31 100281
-#define GLU_NURBS_ERROR32 100282
-#define GLU_NURBS_ERROR33 100283
-#define GLU_NURBS_ERROR34 100284
-#define GLU_NURBS_ERROR35 100285
-#define GLU_NURBS_ERROR36 100286
-#define GLU_NURBS_ERROR37 100287
-
-/* NurbsProperty */
-#define GLU_AUTO_LOAD_MATRIX 100200
-#define GLU_CULLING 100201
-#define GLU_SAMPLING_TOLERANCE 100203
-#define GLU_DISPLAY_MODE 100204
-#define GLU_PARAMETRIC_TOLERANCE 100202
-#define GLU_SAMPLING_METHOD 100205
-#define GLU_U_STEP 100206
-#define GLU_V_STEP 100207
-#define GLU_NURBS_MODE 100160
-#define GLU_NURBS_MODE_EXT 100160
-#define GLU_NURBS_TESSELLATOR 100161
-#define GLU_NURBS_TESSELLATOR_EXT 100161
-#define GLU_NURBS_RENDERER 100162
-#define GLU_NURBS_RENDERER_EXT 100162
-
-/* NurbsSampling */
-#define GLU_OBJECT_PARAMETRIC_ERROR 100208
-#define GLU_OBJECT_PARAMETRIC_ERROR_EXT 100208
-#define GLU_OBJECT_PATH_LENGTH 100209
-#define GLU_OBJECT_PATH_LENGTH_EXT 100209
-#define GLU_PATH_LENGTH 100215
-#define GLU_PARAMETRIC_ERROR 100216
-#define GLU_DOMAIN_DISTANCE 100217
-
-/* NurbsTrim */
-#define GLU_MAP1_TRIM_2 100210
-#define GLU_MAP1_TRIM_3 100211
-
-/* QuadricDrawStyle */
-#define GLU_POINT 100010
-#define GLU_LINE 100011
-#define GLU_FILL 100012
-#define GLU_SILHOUETTE 100013
-
-/* QuadricCallback */
-/* GLU_ERROR */
-
-/* QuadricNormal */
-#define GLU_SMOOTH 100000
-#define GLU_FLAT 100001
-#define GLU_NONE 100002
-
-/* QuadricOrientation */
-#define GLU_OUTSIDE 100020
-#define GLU_INSIDE 100021
-
-/* TessCallback */
-#define GLU_TESS_BEGIN 100100
-#define GLU_BEGIN 100100
-#define GLU_TESS_VERTEX 100101
-#define GLU_VERTEX 100101
-#define GLU_TESS_END 100102
-#define GLU_END 100102
-#define GLU_TESS_ERROR 100103
-#define GLU_TESS_EDGE_FLAG 100104
-#define GLU_EDGE_FLAG 100104
-#define GLU_TESS_COMBINE 100105
-#define GLU_TESS_BEGIN_DATA 100106
-#define GLU_TESS_VERTEX_DATA 100107
-#define GLU_TESS_END_DATA 100108
-#define GLU_TESS_ERROR_DATA 100109
-#define GLU_TESS_EDGE_FLAG_DATA 100110
-#define GLU_TESS_COMBINE_DATA 100111
-
-/* TessContour */
-#define GLU_CW 100120
-#define GLU_CCW 100121
-#define GLU_INTERIOR 100122
-#define GLU_EXTERIOR 100123
-#define GLU_UNKNOWN 100124
-
-/* TessProperty */
-#define GLU_TESS_WINDING_RULE 100140
-#define GLU_TESS_BOUNDARY_ONLY 100141
-#define GLU_TESS_TOLERANCE 100142
-
-/* TessError */
-#define GLU_TESS_ERROR1 100151
-#define GLU_TESS_ERROR2 100152
-#define GLU_TESS_ERROR3 100153
-#define GLU_TESS_ERROR4 100154
-#define GLU_TESS_ERROR5 100155
-#define GLU_TESS_ERROR6 100156
-#define GLU_TESS_ERROR7 100157
-#define GLU_TESS_ERROR8 100158
-#define GLU_TESS_MISSING_BEGIN_POLYGON 100151
-#define GLU_TESS_MISSING_BEGIN_CONTOUR 100152
-#define GLU_TESS_MISSING_END_POLYGON 100153
-#define GLU_TESS_MISSING_END_CONTOUR 100154
-#define GLU_TESS_COORD_TOO_LARGE 100155
-#define GLU_TESS_NEED_COMBINE_CALLBACK 100156
-
-/* TessWinding */
-#define GLU_TESS_WINDING_ODD 100130
-#define GLU_TESS_WINDING_NONZERO 100131
-#define GLU_TESS_WINDING_POSITIVE 100132
-#define GLU_TESS_WINDING_NEGATIVE 100133
-#define GLU_TESS_WINDING_ABS_GEQ_TWO 100134
-
-/*************************************************************/
-
-
-#ifdef __cplusplus
-class GLUnurbs;
-class GLUquadric;
-class GLUtesselator;
-#else
-typedef struct GLUnurbs GLUnurbs;
-typedef struct GLUquadric GLUquadric;
-typedef struct GLUtesselator GLUtesselator;
-#endif
-
-typedef struct GLUnurbs GLUnurbsObj;
-typedef struct GLUquadric GLUquadricObj;
-typedef struct GLUtesselator GLUtesselatorObj;
-typedef struct GLUtesselator GLUtriangulatorObj;
-
-#define GLU_TESS_MAX_COORD 1.0e150
-
-/* Internal convenience typedefs */
-typedef GLvoid (*_GLUfuncptr)(GLvoid);
-
-extern void gluBeginCurve (GLUnurbs* nurb);
-extern void gluBeginPolygon (GLUtesselator* tess);
-extern void gluBeginSurface (GLUnurbs* nurb);
-extern void gluBeginTrim (GLUnurbs* nurb);
-extern GLint gluBuild1DMipmapLevels (GLenum target, GLint internalFormat, GLsizei width, GLenum format, GLenum type, GLint level, GLint base, GLint max, const void *data);
-extern GLint gluBuild1DMipmaps (GLenum target, GLint internalFormat, GLsizei width, GLenum format, GLenum type, const void *data);
-extern GLint gluBuild2DMipmapLevels (GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint level, GLint base, GLint max, const void *data);
-extern GLint gluBuild2DMipmaps (GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *data);
-extern GLint gluBuild3DMipmapLevels (GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLint level, GLint base, GLint max, const void *data);
-extern GLint gluBuild3DMipmaps (GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *data);
-extern GLboolean gluCheckExtension (const GLubyte *extName, const GLubyte *extString);
-extern void gluCylinder (GLUquadric* quad, GLdouble base, GLdouble top, GLdouble height, GLint slices, GLint stacks);
-extern void gluDeleteNurbsRenderer (GLUnurbs* nurb);
-extern void gluDeleteQuadric (GLUquadric* quad);
-extern void gluDeleteTess (GLUtesselator* tess);
-extern void gluDisk (GLUquadric* quad, GLdouble inner, GLdouble outer, GLint slices, GLint loops);
-extern void gluEndCurve (GLUnurbs* nurb);
-extern void gluEndPolygon (GLUtesselator* tess);
-extern void gluEndSurface (GLUnurbs* nurb);
-extern void gluEndTrim (GLUnurbs* nurb);
-extern const GLubyte * gluErrorString (GLenum error);
-extern void gluGetNurbsProperty (GLUnurbs* nurb, GLenum property, GLfloat* data);
-extern const GLubyte * gluGetString (GLenum name);
-extern void gluGetTessProperty (GLUtesselator* tess, GLenum which, GLdouble* data);
-extern void gluLoadSamplingMatrices (GLUnurbs* nurb, const GLfloat *model, const GLfloat *perspective, const GLint *view);
-extern void gluLookAt (GLdouble eyeX, GLdouble eyeY, GLdouble eyeZ, GLdouble centerX, GLdouble centerY, GLdouble centerZ, GLdouble upX, GLdouble upY, GLdouble upZ);
-extern GLUnurbs* gluNewNurbsRenderer (void);
-extern GLUquadric* gluNewQuadric (void);
-extern GLUtesselator* gluNewTess (void);
-extern void gluNextContour (GLUtesselator* tess, GLenum type);
-extern void gluNurbsCallback (GLUnurbs* nurb, GLenum which, _GLUfuncptr CallBackFunc);
-extern void gluNurbsCallbackData (GLUnurbs* nurb, GLvoid* userData);
-extern void gluNurbsCallbackDataEXT (GLUnurbs* nurb, GLvoid* userData);
-extern void gluNurbsCurve (GLUnurbs* nurb, GLint knotCount, GLfloat *knots, GLint stride, GLfloat *control, GLint order, GLenum type);
-extern void gluNurbsProperty (GLUnurbs* nurb, GLenum property, GLfloat value);
-extern void gluNurbsSurface (GLUnurbs* nurb, GLint sKnotCount, GLfloat* sKnots, GLint tKnotCount, GLfloat* tKnots, GLint sStride, GLint tStride, GLfloat* control, GLint sOrder, GLint tOrder, GLenum type);
-extern void gluOrtho2D (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top);
-extern void gluPartialDisk (GLUquadric* quad, GLdouble inner, GLdouble outer, GLint slices, GLint loops, GLdouble start, GLdouble sweep);
-extern void gluPerspective (GLdouble fovy, GLdouble aspect, GLdouble zNear, GLdouble zFar);
-extern void gluPickMatrix (GLdouble x, GLdouble y, GLdouble delX, GLdouble delY, GLint *viewport);
-extern GLint gluProject (GLdouble objX, GLdouble objY, GLdouble objZ, const GLdouble *model, const GLdouble *proj, const GLint *view, GLdouble* winX, GLdouble* winY, GLdouble* winZ);
-extern void gluPwlCurve (GLUnurbs* nurb, GLint count, GLfloat* data, GLint stride, GLenum type);
-extern void gluQuadricCallback (GLUquadric* quad, GLenum which, _GLUfuncptr CallBackFunc);
-extern void gluQuadricDrawStyle (GLUquadric* quad, GLenum draw);
-extern void gluQuadricNormals (GLUquadric* quad, GLenum normal);
-extern void gluQuadricOrientation (GLUquadric* quad, GLenum orientation);
-extern void gluQuadricTexture (GLUquadric* quad, GLboolean texture);
-extern GLint gluScaleImage (GLenum format, GLsizei wIn, GLsizei hIn, GLenum typeIn, const void *dataIn, GLsizei wOut, GLsizei hOut, GLenum typeOut, GLvoid* dataOut);
-extern void gluSphere (GLUquadric* quad, GLdouble radius, GLint slices, GLint stacks);
-extern void gluTessBeginContour (GLUtesselator* tess);
-extern void gluTessBeginPolygon (GLUtesselator* tess, GLvoid* data);
-extern void gluTessCallback (GLUtesselator* tess, GLenum which, _GLUfuncptr CallBackFunc);
-extern void gluTessEndContour (GLUtesselator* tess);
-extern void gluTessEndPolygon (GLUtesselator* tess);
-extern void gluTessNormal (GLUtesselator* tess, GLdouble valueX, GLdouble valueY, GLdouble valueZ);
-extern void gluTessProperty (GLUtesselator* tess, GLenum which, GLdouble data);
-extern void gluTessVertex (GLUtesselator* tess, GLdouble *location, GLvoid* data);
-extern GLint gluUnProject (GLdouble winX, GLdouble winY, GLdouble winZ, const GLdouble *model, const GLdouble *proj, const GLint *view, GLdouble* objX, GLdouble* objY, GLdouble* objZ);
-extern GLint gluUnProject4 (GLdouble winX, GLdouble winY, GLdouble winZ, GLdouble clipW, const GLdouble *model, const GLdouble *proj, const GLint *view, GLdouble near, GLdouble far, GLdouble* objX, GLdouble* objY, GLdouble* objZ, GLdouble* objW);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* __glu_h__ */
diff --git a/libtess/gluos.h b/libtess/gluos.h
deleted file mode 100644
index e776503..0000000
--- a/libtess/gluos.h
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
-** gluos.h - operating system dependencies for GLU
-**
-** $Header$
-*/
-#ifdef __VMS
-#ifdef __cplusplus
-#pragma message disable nocordel
-#pragma message disable codeunreachable
-#pragma message disable codcauunr
-#endif
-#endif
-
-#ifdef _WIN32
-#include <stdlib.h> /* For _MAX_PATH definition */
-#include <stdio.h>
-#include <malloc.h>
-
-#define WIN32_LEAN_AND_MEAN
-/*#define NOGDI*/
-#define NOIME
-#define NOMINMAX
-
-#ifndef _WIN32_WINNT
-#define _WIN32_WINNT 0x0400
-#endif
-#ifndef STRICT
- #define STRICT 1
-#endif
-
-#include <windows.h>
-
-/* Disable warnings */
-#ifndef __GNUC__
-#pragma warning(disable : 4101)
-#pragma warning(disable : 4244)
-#pragma warning(disable : 4761)
-#endif
-
-#if defined(_MSC_VER) && _MSC_VER >= 1200
-#pragma comment(linker, "/OPT:NOWIN98")
-#endif
-
-#else
-
-/* Disable Microsoft-specific keywords */
-#define GLAPIENTRY
-#define WINGDIAPI
-
-#endif
diff --git a/libtess/libtess_la_SOURCES b/libtess/libtess_la_SOURCES
deleted file mode 100644
index e215539..0000000
--- a/libtess/libtess_la_SOURCES
+++ /dev/null
@@ -1,27 +0,0 @@
-libtess_la_SOURCES = \
- dict-list.h \
- dict.c \
- dict.h \
- geom.c \
- geom.h \
- memalloc.c \
- memalloc.h \
- mesh.c \
- mesh.h \
- normal.c \
- normal.h \
- priorityq.c \
- priorityq.h \
- render.c \
- render.h \
- sweep.c \
- sweep.h \
- tess.c \
- tess.h \
- tessmono.c \
- tessmono.h
-
-EXTRA_DIST = \
- priorityq-heap.c \
- priorityq-heap.h \
- priorityq-sort.h
diff --git a/libtess/memalloc.c b/libtess/memalloc.c
deleted file mode 100644
index 123d026..0000000
--- a/libtess/memalloc.c
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include "memalloc.h"
-#include "string.h"
-
-int __gl_memInit( size_t maxFast )
-{
-#ifndef NO_MALLOPT
-/* mallopt( M_MXFAST, maxFast );*/
-#ifdef MEMORY_DEBUG
- mallopt( M_DEBUG, 1 );
-#endif
-#endif
- return 1;
-}
-
-#ifdef MEMORY_DEBUG
-void *__gl_memAlloc( size_t n )
-{
- return memset( malloc( n ), 0xa5, n );
-}
-#endif
-
diff --git a/libtess/memalloc.h b/libtess/memalloc.h
deleted file mode 100644
index 0a55694..0000000
--- a/libtess/memalloc.h
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __memalloc_simple_h_
-#define __memalloc_simple_h_
-
-#if defined(__VMS) || defined(darwin) || defined(__APPLE__)
-# include <stdlib.h>
-#else
-# include <malloc.h>
-#endif
-
-#define memRealloc realloc
-#define memFree free
-
-#define memInit __gl_memInit
-/*extern void __gl_memInit( size_t );*/
-extern int __gl_memInit( size_t );
-
-#ifndef MEMORY_DEBUG
-#define memAlloc malloc
-#else
-#define memAlloc __gl_memAlloc
-extern void * __gl_memAlloc( size_t );
-#endif
-
-#endif
diff --git a/libtess/mesh.c b/libtess/mesh.c
deleted file mode 100644
index b0e5393..0000000
--- a/libtess/mesh.c
+++ /dev/null
@@ -1,796 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include "gluos.h"
-#include <stddef.h>
-#include <assert.h>
-#include "mesh.h"
-#include "memalloc.h"
-
-#define TRUE 1
-#define FALSE 0
-
-static GLUvertex *allocVertex()
-{
- return (GLUvertex *)memAlloc( sizeof( GLUvertex ));
-}
-
-static GLUface *allocFace()
-{
- return (GLUface *)memAlloc( sizeof( GLUface ));
-}
-
-/************************ Utility Routines ************************/
-
-/* Allocate and free half-edges in pairs for efficiency.
- * The *only* place that should use this fact is allocation/free.
- */
-typedef struct { GLUhalfEdge e, eSym; } EdgePair;
-
-/* MakeEdge creates a new pair of half-edges which form their own loop.
- * No vertex or face structures are allocated, but these must be assigned
- * before the current edge operation is completed.
- */
-static GLUhalfEdge *MakeEdge( GLUhalfEdge *eNext )
-{
- GLUhalfEdge *e;
- GLUhalfEdge *eSym;
- GLUhalfEdge *ePrev;
- EdgePair *pair = (EdgePair *)memAlloc( sizeof( EdgePair ));
- if (pair == NULL) return NULL;
-
- e = &pair->e;
- eSym = &pair->eSym;
-
- /* Make sure eNext points to the first edge of the edge pair */
- if( eNext->Sym < eNext ) { eNext = eNext->Sym; }
-
- /* Insert in circular doubly-linked list before eNext.
- * Note that the prev pointer is stored in Sym->next.
- */
- ePrev = eNext->Sym->next;
- eSym->next = ePrev;
- ePrev->Sym->next = e;
- e->next = eNext;
- eNext->Sym->next = eSym;
-
- e->Sym = eSym;
- e->Onext = e;
- e->Lnext = eSym;
- e->Org = NULL;
- e->Lface = NULL;
- e->winding = 0;
- e->activeRegion = NULL;
-
- eSym->Sym = e;
- eSym->Onext = eSym;
- eSym->Lnext = e;
- eSym->Org = NULL;
- eSym->Lface = NULL;
- eSym->winding = 0;
- eSym->activeRegion = NULL;
-
- return e;
-}
-
-/* Splice( a, b ) is best described by the Guibas/Stolfi paper or the
- * CS348a notes (see mesh.h). Basically it modifies the mesh so that
- * a->Onext and b->Onext are exchanged. This can have various effects
- * depending on whether a and b belong to different face or vertex rings.
- * For more explanation see __gl_meshSplice() below.
- */
-static void Splice( GLUhalfEdge *a, GLUhalfEdge *b )
-{
- GLUhalfEdge *aOnext = a->Onext;
- GLUhalfEdge *bOnext = b->Onext;
-
- aOnext->Sym->Lnext = b;
- bOnext->Sym->Lnext = a;
- a->Onext = bOnext;
- b->Onext = aOnext;
-}
-
-/* MakeVertex( newVertex, eOrig, vNext ) attaches a new vertex and makes it the
- * origin of all edges in the vertex loop to which eOrig belongs. "vNext" gives
- * a place to insert the new vertex in the global vertex list. We insert
- * the new vertex *before* vNext so that algorithms which walk the vertex
- * list will not see the newly created vertices.
- */
-static void MakeVertex( GLUvertex *newVertex,
- GLUhalfEdge *eOrig, GLUvertex *vNext )
-{
- GLUhalfEdge *e;
- GLUvertex *vPrev;
- GLUvertex *vNew = newVertex;
-
- assert(vNew != NULL);
-
- /* insert in circular doubly-linked list before vNext */
- vPrev = vNext->prev;
- vNew->prev = vPrev;
- vPrev->next = vNew;
- vNew->next = vNext;
- vNext->prev = vNew;
-
- vNew->anEdge = eOrig;
- vNew->data = NULL;
- /* leave coords, s, t undefined */
-
- /* fix other edges on this vertex loop */
- e = eOrig;
- do {
- e->Org = vNew;
- e = e->Onext;
- } while( e != eOrig );
-}
-
-/* MakeFace( newFace, eOrig, fNext ) attaches a new face and makes it the left
- * face of all edges in the face loop to which eOrig belongs. "fNext" gives
- * a place to insert the new face in the global face list. We insert
- * the new face *before* fNext so that algorithms which walk the face
- * list will not see the newly created faces.
- */
-static void MakeFace( GLUface *newFace, GLUhalfEdge *eOrig, GLUface *fNext )
-{
- GLUhalfEdge *e;
- GLUface *fPrev;
- GLUface *fNew = newFace;
-
- assert(fNew != NULL);
-
- /* insert in circular doubly-linked list before fNext */
- fPrev = fNext->prev;
- fNew->prev = fPrev;
- fPrev->next = fNew;
- fNew->next = fNext;
- fNext->prev = fNew;
-
- fNew->anEdge = eOrig;
- fNew->data = NULL;
- fNew->trail = NULL;
- fNew->marked = FALSE;
-
- /* The new face is marked "inside" if the old one was. This is a
- * convenience for the common case where a face has been split in two.
- */
- fNew->inside = fNext->inside;
-
- /* fix other edges on this face loop */
- e = eOrig;
- do {
- e->Lface = fNew;
- e = e->Lnext;
- } while( e != eOrig );
-}
-
-/* KillEdge( eDel ) destroys an edge (the half-edges eDel and eDel->Sym),
- * and removes from the global edge list.
- */
-static void KillEdge( GLUhalfEdge *eDel )
-{
- GLUhalfEdge *ePrev, *eNext;
-
- /* Half-edges are allocated in pairs, see EdgePair above */
- if( eDel->Sym < eDel ) { eDel = eDel->Sym; }
-
- /* delete from circular doubly-linked list */
- eNext = eDel->next;
- ePrev = eDel->Sym->next;
- eNext->Sym->next = ePrev;
- ePrev->Sym->next = eNext;
-
- memFree( eDel );
-}
-
-
-/* KillVertex( vDel ) destroys a vertex and removes it from the global
- * vertex list. It updates the vertex loop to point to a given new vertex.
- */
-static void KillVertex( GLUvertex *vDel, GLUvertex *newOrg )
-{
- GLUhalfEdge *e, *eStart = vDel->anEdge;
- GLUvertex *vPrev, *vNext;
-
- /* change the origin of all affected edges */
- e = eStart;
- do {
- e->Org = newOrg;
- e = e->Onext;
- } while( e != eStart );
-
- /* delete from circular doubly-linked list */
- vPrev = vDel->prev;
- vNext = vDel->next;
- vNext->prev = vPrev;
- vPrev->next = vNext;
-
- memFree( vDel );
-}
-
-/* KillFace( fDel ) destroys a face and removes it from the global face
- * list. It updates the face loop to point to a given new face.
- */
-static void KillFace( GLUface *fDel, GLUface *newLface )
-{
- GLUhalfEdge *e, *eStart = fDel->anEdge;
- GLUface *fPrev, *fNext;
-
- /* change the left face of all affected edges */
- e = eStart;
- do {
- e->Lface = newLface;
- e = e->Lnext;
- } while( e != eStart );
-
- /* delete from circular doubly-linked list */
- fPrev = fDel->prev;
- fNext = fDel->next;
- fNext->prev = fPrev;
- fPrev->next = fNext;
-
- memFree( fDel );
-}
-
-
-/****************** Basic Edge Operations **********************/
-
-/* __gl_meshMakeEdge creates one edge, two vertices, and a loop (face).
- * The loop consists of the two new half-edges.
- */
-GLUhalfEdge *__gl_meshMakeEdge( GLUmesh *mesh )
-{
- GLUvertex *newVertex1= allocVertex();
- GLUvertex *newVertex2= allocVertex();
- GLUface *newFace= allocFace();
- GLUhalfEdge *e;
-
- /* if any one is null then all get freed */
- if (newVertex1 == NULL || newVertex2 == NULL || newFace == NULL) {
- if (newVertex1 != NULL) memFree(newVertex1);
- if (newVertex2 != NULL) memFree(newVertex2);
- if (newFace != NULL) memFree(newFace);
- return NULL;
- }
-
- e = MakeEdge( &mesh->eHead );
- if (e == NULL) return NULL;
-
- MakeVertex( newVertex1, e, &mesh->vHead );
- MakeVertex( newVertex2, e->Sym, &mesh->vHead );
- MakeFace( newFace, e, &mesh->fHead );
- return e;
-}
-
-
-/* __gl_meshSplice( eOrg, eDst ) is the basic operation for changing the
- * mesh connectivity and topology. It changes the mesh so that
- * eOrg->Onext <- OLD( eDst->Onext )
- * eDst->Onext <- OLD( eOrg->Onext )
- * where OLD(...) means the value before the meshSplice operation.
- *
- * This can have two effects on the vertex structure:
- * - if eOrg->Org != eDst->Org, the two vertices are merged together
- * - if eOrg->Org == eDst->Org, the origin is split into two vertices
- * In both cases, eDst->Org is changed and eOrg->Org is untouched.
- *
- * Similarly (and independently) for the face structure,
- * - if eOrg->Lface == eDst->Lface, one loop is split into two
- * - if eOrg->Lface != eDst->Lface, two distinct loops are joined into one
- * In both cases, eDst->Lface is changed and eOrg->Lface is unaffected.
- *
- * Some special cases:
- * If eDst == eOrg, the operation has no effect.
- * If eDst == eOrg->Lnext, the new face will have a single edge.
- * If eDst == eOrg->Lprev, the old face will have a single edge.
- * If eDst == eOrg->Onext, the new vertex will have a single edge.
- * If eDst == eOrg->Oprev, the old vertex will have a single edge.
- */
-int __gl_meshSplice( GLUhalfEdge *eOrg, GLUhalfEdge *eDst )
-{
- int joiningLoops = FALSE;
- int joiningVertices = FALSE;
-
- if( eOrg == eDst ) return 1;
-
- if( eDst->Org != eOrg->Org ) {
- /* We are merging two disjoint vertices -- destroy eDst->Org */
- joiningVertices = TRUE;
- KillVertex( eDst->Org, eOrg->Org );
- }
- if( eDst->Lface != eOrg->Lface ) {
- /* We are connecting two disjoint loops -- destroy eDst->Lface */
- joiningLoops = TRUE;
- KillFace( eDst->Lface, eOrg->Lface );
- }
-
- /* Change the edge structure */
- Splice( eDst, eOrg );
-
- if( ! joiningVertices ) {
- GLUvertex *newVertex= allocVertex();
- if (newVertex == NULL) return 0;
-
- /* We split one vertex into two -- the new vertex is eDst->Org.
- * Make sure the old vertex points to a valid half-edge.
- */
- MakeVertex( newVertex, eDst, eOrg->Org );
- eOrg->Org->anEdge = eOrg;
- }
- if( ! joiningLoops ) {
- GLUface *newFace= allocFace();
- if (newFace == NULL) return 0;
-
- /* We split one loop into two -- the new loop is eDst->Lface.
- * Make sure the old face points to a valid half-edge.
- */
- MakeFace( newFace, eDst, eOrg->Lface );
- eOrg->Lface->anEdge = eOrg;
- }
-
- return 1;
-}
-
-
-/* __gl_meshDelete( eDel ) removes the edge eDel. There are several cases:
- * if (eDel->Lface != eDel->Rface), we join two loops into one; the loop
- * eDel->Lface is deleted. Otherwise, we are splitting one loop into two;
- * the newly created loop will contain eDel->Dst. If the deletion of eDel
- * would create isolated vertices, those are deleted as well.
- *
- * This function could be implemented as two calls to __gl_meshSplice
- * plus a few calls to memFree, but this would allocate and delete
- * unnecessary vertices and faces.
- */
-int __gl_meshDelete( GLUhalfEdge *eDel )
-{
- GLUhalfEdge *eDelSym = eDel->Sym;
- int joiningLoops = FALSE;
-
- /* First step: disconnect the origin vertex eDel->Org. We make all
- * changes to get a consistent mesh in this "intermediate" state.
- */
- if( eDel->Lface != eDel->Rface ) {
- /* We are joining two loops into one -- remove the left face */
- joiningLoops = TRUE;
- KillFace( eDel->Lface, eDel->Rface );
- }
-
- if( eDel->Onext == eDel ) {
- KillVertex( eDel->Org, NULL );
- } else {
- /* Make sure that eDel->Org and eDel->Rface point to valid half-edges */
- eDel->Rface->anEdge = eDel->Oprev;
- eDel->Org->anEdge = eDel->Onext;
-
- Splice( eDel, eDel->Oprev );
- if( ! joiningLoops ) {
- GLUface *newFace= allocFace();
- if (newFace == NULL) return 0;
-
- /* We are splitting one loop into two -- create a new loop for eDel. */
- MakeFace( newFace, eDel, eDel->Lface );
- }
- }
-
- /* Claim: the mesh is now in a consistent state, except that eDel->Org
- * may have been deleted. Now we disconnect eDel->Dst.
- */
- if( eDelSym->Onext == eDelSym ) {
- KillVertex( eDelSym->Org, NULL );
- KillFace( eDelSym->Lface, NULL );
- } else {
- /* Make sure that eDel->Dst and eDel->Lface point to valid half-edges */
- eDel->Lface->anEdge = eDelSym->Oprev;
- eDelSym->Org->anEdge = eDelSym->Onext;
- Splice( eDelSym, eDelSym->Oprev );
- }
-
- /* Any isolated vertices or faces have already been freed. */
- KillEdge( eDel );
-
- return 1;
-}
-
-
-/******************** Other Edge Operations **********************/
-
-/* All these routines can be implemented with the basic edge
- * operations above. They are provided for convenience and efficiency.
- */
-
-
-/* __gl_meshAddEdgeVertex( eOrg ) creates a new edge eNew such that
- * eNew == eOrg->Lnext, and eNew->Dst is a newly created vertex.
- * eOrg and eNew will have the same left face.
- */
-GLUhalfEdge *__gl_meshAddEdgeVertex( GLUhalfEdge *eOrg )
-{
- GLUhalfEdge *eNewSym;
- GLUhalfEdge *eNew = MakeEdge( eOrg );
- if (eNew == NULL) return NULL;
-
- eNewSym = eNew->Sym;
-
- /* Connect the new edge appropriately */
- Splice( eNew, eOrg->Lnext );
-
- /* Set the vertex and face information */
- eNew->Org = eOrg->Dst;
- {
- GLUvertex *newVertex= allocVertex();
- if (newVertex == NULL) return NULL;
-
- MakeVertex( newVertex, eNewSym, eNew->Org );
- }
- eNew->Lface = eNewSym->Lface = eOrg->Lface;
-
- return eNew;
-}
-
-
-/* __gl_meshSplitEdge( eOrg ) splits eOrg into two edges eOrg and eNew,
- * such that eNew == eOrg->Lnext. The new vertex is eOrg->Dst == eNew->Org.
- * eOrg and eNew will have the same left face.
- */
-GLUhalfEdge *__gl_meshSplitEdge( GLUhalfEdge *eOrg )
-{
- GLUhalfEdge *eNew;
- GLUhalfEdge *tempHalfEdge= __gl_meshAddEdgeVertex( eOrg );
- if (tempHalfEdge == NULL) return NULL;
-
- eNew = tempHalfEdge->Sym;
-
- /* Disconnect eOrg from eOrg->Dst and connect it to eNew->Org */
- Splice( eOrg->Sym, eOrg->Sym->Oprev );
- Splice( eOrg->Sym, eNew );
-
- /* Set the vertex and face information */
- eOrg->Dst = eNew->Org;
- eNew->Dst->anEdge = eNew->Sym; /* may have pointed to eOrg->Sym */
- eNew->Rface = eOrg->Rface;
- eNew->winding = eOrg->winding; /* copy old winding information */
- eNew->Sym->winding = eOrg->Sym->winding;
-
- return eNew;
-}
-
-
-/* __gl_meshConnect( eOrg, eDst ) creates a new edge from eOrg->Dst
- * to eDst->Org, and returns the corresponding half-edge eNew.
- * If eOrg->Lface == eDst->Lface, this splits one loop into two,
- * and the newly created loop is eNew->Lface. Otherwise, two disjoint
- * loops are merged into one, and the loop eDst->Lface is destroyed.
- *
- * If (eOrg == eDst), the new face will have only two edges.
- * If (eOrg->Lnext == eDst), the old face is reduced to a single edge.
- * If (eOrg->Lnext->Lnext == eDst), the old face is reduced to two edges.
- */
-GLUhalfEdge *__gl_meshConnect( GLUhalfEdge *eOrg, GLUhalfEdge *eDst )
-{
- GLUhalfEdge *eNewSym;
- int joiningLoops = FALSE;
- GLUhalfEdge *eNew = MakeEdge( eOrg );
- if (eNew == NULL) return NULL;
-
- eNewSym = eNew->Sym;
-
- if( eDst->Lface != eOrg->Lface ) {
- /* We are connecting two disjoint loops -- destroy eDst->Lface */
- joiningLoops = TRUE;
- KillFace( eDst->Lface, eOrg->Lface );
- }
-
- /* Connect the new edge appropriately */
- Splice( eNew, eOrg->Lnext );
- Splice( eNewSym, eDst );
-
- /* Set the vertex and face information */
- eNew->Org = eOrg->Dst;
- eNewSym->Org = eDst->Org;
- eNew->Lface = eNewSym->Lface = eOrg->Lface;
-
- /* Make sure the old face points to a valid half-edge */
- eOrg->Lface->anEdge = eNewSym;
-
- if( ! joiningLoops ) {
- GLUface *newFace= allocFace();
- if (newFace == NULL) return NULL;
-
- /* We split one loop into two -- the new loop is eNew->Lface */
- MakeFace( newFace, eNew, eOrg->Lface );
- }
- return eNew;
-}
-
-
-/******************** Other Operations **********************/
-
-/* __gl_meshZapFace( fZap ) destroys a face and removes it from the
- * global face list. All edges of fZap will have a NULL pointer as their
- * left face. Any edges which also have a NULL pointer as their right face
- * are deleted entirely (along with any isolated vertices this produces).
- * An entire mesh can be deleted by zapping its faces, one at a time,
- * in any order. Zapped faces cannot be used in further mesh operations!
- */
-void __gl_meshZapFace( GLUface *fZap )
-{
- GLUhalfEdge *eStart = fZap->anEdge;
- GLUhalfEdge *e, *eNext, *eSym;
- GLUface *fPrev, *fNext;
-
- /* walk around face, deleting edges whose right face is also NULL */
- eNext = eStart->Lnext;
- do {
- e = eNext;
- eNext = e->Lnext;
-
- e->Lface = NULL;
- if( e->Rface == NULL ) {
- /* delete the edge -- see __gl_MeshDelete above */
-
- if( e->Onext == e ) {
- KillVertex( e->Org, NULL );
- } else {
- /* Make sure that e->Org points to a valid half-edge */
- e->Org->anEdge = e->Onext;
- Splice( e, e->Oprev );
- }
- eSym = e->Sym;
- if( eSym->Onext == eSym ) {
- KillVertex( eSym->Org, NULL );
- } else {
- /* Make sure that eSym->Org points to a valid half-edge */
- eSym->Org->anEdge = eSym->Onext;
- Splice( eSym, eSym->Oprev );
- }
- KillEdge( e );
- }
- } while( e != eStart );
-
- /* delete from circular doubly-linked list */
- fPrev = fZap->prev;
- fNext = fZap->next;
- fNext->prev = fPrev;
- fPrev->next = fNext;
-
- memFree( fZap );
-}
-
-
-/* __gl_meshNewMesh() creates a new mesh with no edges, no vertices,
- * and no loops (what we usually call a "face").
- */
-GLUmesh *__gl_meshNewMesh( void )
-{
- GLUvertex *v;
- GLUface *f;
- GLUhalfEdge *e;
- GLUhalfEdge *eSym;
- GLUmesh *mesh = (GLUmesh *)memAlloc( sizeof( GLUmesh ));
- if (mesh == NULL) {
- return NULL;
- }
-
- v = &mesh->vHead;
- f = &mesh->fHead;
- e = &mesh->eHead;
- eSym = &mesh->eHeadSym;
-
- v->next = v->prev = v;
- v->anEdge = NULL;
- v->data = NULL;
-
- f->next = f->prev = f;
- f->anEdge = NULL;
- f->data = NULL;
- f->trail = NULL;
- f->marked = FALSE;
- f->inside = FALSE;
-
- e->next = e;
- e->Sym = eSym;
- e->Onext = NULL;
- e->Lnext = NULL;
- e->Org = NULL;
- e->Lface = NULL;
- e->winding = 0;
- e->activeRegion = NULL;
-
- eSym->next = eSym;
- eSym->Sym = e;
- eSym->Onext = NULL;
- eSym->Lnext = NULL;
- eSym->Org = NULL;
- eSym->Lface = NULL;
- eSym->winding = 0;
- eSym->activeRegion = NULL;
-
- return mesh;
-}
-
-
-/* __gl_meshUnion( mesh1, mesh2 ) forms the union of all structures in
- * both meshes, and returns the new mesh (the old meshes are destroyed).
- */
-GLUmesh *__gl_meshUnion( GLUmesh *mesh1, GLUmesh *mesh2 )
-{
- GLUface *f1 = &mesh1->fHead;
- GLUvertex *v1 = &mesh1->vHead;
- GLUhalfEdge *e1 = &mesh1->eHead;
- GLUface *f2 = &mesh2->fHead;
- GLUvertex *v2 = &mesh2->vHead;
- GLUhalfEdge *e2 = &mesh2->eHead;
-
- /* Add the faces, vertices, and edges of mesh2 to those of mesh1 */
- if( f2->next != f2 ) {
- f1->prev->next = f2->next;
- f2->next->prev = f1->prev;
- f2->prev->next = f1;
- f1->prev = f2->prev;
- }
-
- if( v2->next != v2 ) {
- v1->prev->next = v2->next;
- v2->next->prev = v1->prev;
- v2->prev->next = v1;
- v1->prev = v2->prev;
- }
-
- if( e2->next != e2 ) {
- e1->Sym->next->Sym->next = e2->next;
- e2->next->Sym->next = e1->Sym->next;
- e2->Sym->next->Sym->next = e1;
- e1->Sym->next = e2->Sym->next;
- }
-
- memFree( mesh2 );
- return mesh1;
-}
-
-
-#ifdef DELETE_BY_ZAPPING
-
-/* __gl_meshDeleteMesh( mesh ) will free all storage for any valid mesh.
- */
-void __gl_meshDeleteMesh( GLUmesh *mesh )
-{
- GLUface *fHead = &mesh->fHead;
-
- while( fHead->next != fHead ) {
- __gl_meshZapFace( fHead->next );
- }
- assert( mesh->vHead.next == &mesh->vHead );
-
- memFree( mesh );
-}
-
-#else
-
-/* __gl_meshDeleteMesh( mesh ) will free all storage for any valid mesh.
- */
-void __gl_meshDeleteMesh( GLUmesh *mesh )
-{
- GLUface *f, *fNext;
- GLUvertex *v, *vNext;
- GLUhalfEdge *e, *eNext;
-
- for( f = mesh->fHead.next; f != &mesh->fHead; f = fNext ) {
- fNext = f->next;
- memFree( f );
- }
-
- for( v = mesh->vHead.next; v != &mesh->vHead; v = vNext ) {
- vNext = v->next;
- memFree( v );
- }
-
- for( e = mesh->eHead.next; e != &mesh->eHead; e = eNext ) {
- /* One call frees both e and e->Sym (see EdgePair above) */
- eNext = e->next;
- memFree( e );
- }
-
- memFree( mesh );
-}
-
-#endif
-
-#ifndef NDEBUG
-
-/* __gl_meshCheckMesh( mesh ) checks a mesh for self-consistency.
- */
-void __gl_meshCheckMesh( GLUmesh *mesh )
-{
- GLUface *fHead = &mesh->fHead;
- GLUvertex *vHead = &mesh->vHead;
- GLUhalfEdge *eHead = &mesh->eHead;
- GLUface *f, *fPrev;
- GLUvertex *v, *vPrev;
- GLUhalfEdge *e, *ePrev;
-
- fPrev = fHead;
- for( fPrev = fHead ; (f = fPrev->next) != fHead; fPrev = f) {
- assert( f->prev == fPrev );
- e = f->anEdge;
- do {
- assert( e->Sym != e );
- assert( e->Sym->Sym == e );
- assert( e->Lnext->Onext->Sym == e );
- assert( e->Onext->Sym->Lnext == e );
- assert( e->Lface == f );
- e = e->Lnext;
- } while( e != f->anEdge );
- }
- assert( f->prev == fPrev && f->anEdge == NULL && f->data == NULL );
-
- vPrev = vHead;
- for( vPrev = vHead ; (v = vPrev->next) != vHead; vPrev = v) {
- assert( v->prev == vPrev );
- e = v->anEdge;
- do {
- assert( e->Sym != e );
- assert( e->Sym->Sym == e );
- assert( e->Lnext->Onext->Sym == e );
- assert( e->Onext->Sym->Lnext == e );
- assert( e->Org == v );
- e = e->Onext;
- } while( e != v->anEdge );
- }
- assert( v->prev == vPrev && v->anEdge == NULL && v->data == NULL );
-
- ePrev = eHead;
- for( ePrev = eHead ; (e = ePrev->next) != eHead; ePrev = e) {
- assert( e->Sym->next == ePrev->Sym );
- assert( e->Sym != e );
- assert( e->Sym->Sym == e );
- assert( e->Org != NULL );
- assert( e->Dst != NULL );
- assert( e->Lnext->Onext->Sym == e );
- assert( e->Onext->Sym->Lnext == e );
- }
- assert( e->Sym->next == ePrev->Sym
- && e->Sym == &mesh->eHeadSym
- && e->Sym->Sym == e
- && e->Org == NULL && e->Dst == NULL
- && e->Lface == NULL && e->Rface == NULL );
-}
-
-#endif
diff --git a/libtess/mesh.h b/libtess/mesh.h
deleted file mode 100644
index 802a3ff..0000000
--- a/libtess/mesh.h
+++ /dev/null
@@ -1,273 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __mesh_h_
-#define __mesh_h_
-
-#include "glu.h"
-
-typedef struct GLUmesh GLUmesh;
-
-typedef struct GLUvertex GLUvertex;
-typedef struct GLUface GLUface;
-typedef struct GLUhalfEdge GLUhalfEdge;
-
-typedef struct ActiveRegion ActiveRegion; /* Internal data */
-
-/* The mesh structure is similar in spirit, notation, and operations
- * to the "quad-edge" structure (see L. Guibas and J. Stolfi, Primitives
- * for the manipulation of general subdivisions and the computation of
- * Voronoi diagrams, ACM Transactions on Graphics, 4(2):74-123, April 1985).
- * For a simplified description, see the course notes for CS348a,
- * "Mathematical Foundations of Computer Graphics", available at the
- * Stanford bookstore (and taught during the fall quarter).
- * The implementation also borrows a tiny subset of the graph-based approach
- * use in Mantyla's Geometric Work Bench (see M. Mantyla, An Introduction
- * to Sold Modeling, Computer Science Press, Rockville, Maryland, 1988).
- *
- * The fundamental data structure is the "half-edge". Two half-edges
- * go together to make an edge, but they point in opposite directions.
- * Each half-edge has a pointer to its mate (the "symmetric" half-edge Sym),
- * its origin vertex (Org), the face on its left side (Lface), and the
- * adjacent half-edges in the CCW direction around the origin vertex
- * (Onext) and around the left face (Lnext). There is also a "next"
- * pointer for the global edge list (see below).
- *
- * The notation used for mesh navigation:
- * Sym = the mate of a half-edge (same edge, but opposite direction)
- * Onext = edge CCW around origin vertex (keep same origin)
- * Dnext = edge CCW around destination vertex (keep same dest)
- * Lnext = edge CCW around left face (dest becomes new origin)
- * Rnext = edge CCW around right face (origin becomes new dest)
- *
- * "prev" means to substitute CW for CCW in the definitions above.
- *
- * The mesh keeps global lists of all vertices, faces, and edges,
- * stored as doubly-linked circular lists with a dummy header node.
- * The mesh stores pointers to these dummy headers (vHead, fHead, eHead).
- *
- * The circular edge list is special; since half-edges always occur
- * in pairs (e and e->Sym), each half-edge stores a pointer in only
- * one direction. Starting at eHead and following the e->next pointers
- * will visit each *edge* once (ie. e or e->Sym, but not both).
- * e->Sym stores a pointer in the opposite direction, thus it is
- * always true that e->Sym->next->Sym->next == e.
- *
- * Each vertex has a pointer to next and previous vertices in the
- * circular list, and a pointer to a half-edge with this vertex as
- * the origin (NULL if this is the dummy header). There is also a
- * field "data" for client data.
- *
- * Each face has a pointer to the next and previous faces in the
- * circular list, and a pointer to a half-edge with this face as
- * the left face (NULL if this is the dummy header). There is also
- * a field "data" for client data.
- *
- * Note that what we call a "face" is really a loop; faces may consist
- * of more than one loop (ie. not simply connected), but there is no
- * record of this in the data structure. The mesh may consist of
- * several disconnected regions, so it may not be possible to visit
- * the entire mesh by starting at a half-edge and traversing the edge
- * structure.
- *
- * The mesh does NOT support isolated vertices; a vertex is deleted along
- * with its last edge. Similarly when two faces are merged, one of the
- * faces is deleted (see __gl_meshDelete below). For mesh operations,
- * all face (loop) and vertex pointers must not be NULL. However, once
- * mesh manipulation is finished, __gl_MeshZapFace can be used to delete
- * faces of the mesh, one at a time. All external faces can be "zapped"
- * before the mesh is returned to the client; then a NULL face indicates
- * a region which is not part of the output polygon.
- */
-
-struct GLUvertex {
- GLUvertex *next; /* next vertex (never NULL) */
- GLUvertex *prev; /* previous vertex (never NULL) */
- GLUhalfEdge *anEdge; /* a half-edge with this origin */
- void *data; /* client's data */
-
- /* Internal data (keep hidden) */
- GLdouble coords[3]; /* vertex location in 3D */
- GLdouble s, t; /* projection onto the sweep plane */
- long pqHandle; /* to allow deletion from priority queue */
-};
-
-struct GLUface {
- GLUface *next; /* next face (never NULL) */
- GLUface *prev; /* previous face (never NULL) */
- GLUhalfEdge *anEdge; /* a half edge with this left face */
- void *data; /* room for client's data */
-
- /* Internal data (keep hidden) */
- GLUface *trail; /* "stack" for conversion to strips */
- GLboolean marked; /* flag for conversion to strips */
- GLboolean inside; /* this face is in the polygon interior */
-};
-
-struct GLUhalfEdge {
- GLUhalfEdge *next; /* doubly-linked list (prev==Sym->next) */
- GLUhalfEdge *Sym; /* same edge, opposite direction */
- GLUhalfEdge *Onext; /* next edge CCW around origin */
- GLUhalfEdge *Lnext; /* next edge CCW around left face */
- GLUvertex *Org; /* origin vertex (Overtex too long) */
- GLUface *Lface; /* left face */
-
- /* Internal data (keep hidden) */
- ActiveRegion *activeRegion; /* a region with this upper edge (sweep.c) */
- int winding; /* change in winding number when crossing
- from the right face to the left face */
-};
-
-#define Rface Sym->Lface
-#define Dst Sym->Org
-
-#define Oprev Sym->Lnext
-#define Lprev Onext->Sym
-#define Dprev Lnext->Sym
-#define Rprev Sym->Onext
-#define Dnext Rprev->Sym /* 3 pointers */
-#define Rnext Oprev->Sym /* 3 pointers */
-
-
-struct GLUmesh {
- GLUvertex vHead; /* dummy header for vertex list */
- GLUface fHead; /* dummy header for face list */
- GLUhalfEdge eHead; /* dummy header for edge list */
- GLUhalfEdge eHeadSym; /* and its symmetric counterpart */
-};
-
-/* The mesh operations below have three motivations: completeness,
- * convenience, and efficiency. The basic mesh operations are MakeEdge,
- * Splice, and Delete. All the other edge operations can be implemented
- * in terms of these. The other operations are provided for convenience
- * and/or efficiency.
- *
- * When a face is split or a vertex is added, they are inserted into the
- * global list *before* the existing vertex or face (ie. e->Org or e->Lface).
- * This makes it easier to process all vertices or faces in the global lists
- * without worrying about processing the same data twice. As a convenience,
- * when a face is split, the "inside" flag is copied from the old face.
- * Other internal data (v->data, v->activeRegion, f->data, f->marked,
- * f->trail, e->winding) is set to zero.
- *
- * ********************** Basic Edge Operations **************************
- *
- * __gl_meshMakeEdge( mesh ) creates one edge, two vertices, and a loop.
- * The loop (face) consists of the two new half-edges.
- *
- * __gl_meshSplice( eOrg, eDst ) is the basic operation for changing the
- * mesh connectivity and topology. It changes the mesh so that
- * eOrg->Onext <- OLD( eDst->Onext )
- * eDst->Onext <- OLD( eOrg->Onext )
- * where OLD(...) means the value before the meshSplice operation.
- *
- * This can have two effects on the vertex structure:
- * - if eOrg->Org != eDst->Org, the two vertices are merged together
- * - if eOrg->Org == eDst->Org, the origin is split into two vertices
- * In both cases, eDst->Org is changed and eOrg->Org is untouched.
- *
- * Similarly (and independently) for the face structure,
- * - if eOrg->Lface == eDst->Lface, one loop is split into two
- * - if eOrg->Lface != eDst->Lface, two distinct loops are joined into one
- * In both cases, eDst->Lface is changed and eOrg->Lface is unaffected.
- *
- * __gl_meshDelete( eDel ) removes the edge eDel. There are several cases:
- * if (eDel->Lface != eDel->Rface), we join two loops into one; the loop
- * eDel->Lface is deleted. Otherwise, we are splitting one loop into two;
- * the newly created loop will contain eDel->Dst. If the deletion of eDel
- * would create isolated vertices, those are deleted as well.
- *
- * ********************** Other Edge Operations **************************
- *
- * __gl_meshAddEdgeVertex( eOrg ) creates a new edge eNew such that
- * eNew == eOrg->Lnext, and eNew->Dst is a newly created vertex.
- * eOrg and eNew will have the same left face.
- *
- * __gl_meshSplitEdge( eOrg ) splits eOrg into two edges eOrg and eNew,
- * such that eNew == eOrg->Lnext. The new vertex is eOrg->Dst == eNew->Org.
- * eOrg and eNew will have the same left face.
- *
- * __gl_meshConnect( eOrg, eDst ) creates a new edge from eOrg->Dst
- * to eDst->Org, and returns the corresponding half-edge eNew.
- * If eOrg->Lface == eDst->Lface, this splits one loop into two,
- * and the newly created loop is eNew->Lface. Otherwise, two disjoint
- * loops are merged into one, and the loop eDst->Lface is destroyed.
- *
- * ************************ Other Operations *****************************
- *
- * __gl_meshNewMesh() creates a new mesh with no edges, no vertices,
- * and no loops (what we usually call a "face").
- *
- * __gl_meshUnion( mesh1, mesh2 ) forms the union of all structures in
- * both meshes, and returns the new mesh (the old meshes are destroyed).
- *
- * __gl_meshDeleteMesh( mesh ) will free all storage for any valid mesh.
- *
- * __gl_meshZapFace( fZap ) destroys a face and removes it from the
- * global face list. All edges of fZap will have a NULL pointer as their
- * left face. Any edges which also have a NULL pointer as their right face
- * are deleted entirely (along with any isolated vertices this produces).
- * An entire mesh can be deleted by zapping its faces, one at a time,
- * in any order. Zapped faces cannot be used in further mesh operations!
- *
- * __gl_meshCheckMesh( mesh ) checks a mesh for self-consistency.
- */
-
-GLUhalfEdge *__gl_meshMakeEdge( GLUmesh *mesh );
-int __gl_meshSplice( GLUhalfEdge *eOrg, GLUhalfEdge *eDst );
-int __gl_meshDelete( GLUhalfEdge *eDel );
-
-GLUhalfEdge *__gl_meshAddEdgeVertex( GLUhalfEdge *eOrg );
-GLUhalfEdge *__gl_meshSplitEdge( GLUhalfEdge *eOrg );
-GLUhalfEdge *__gl_meshConnect( GLUhalfEdge *eOrg, GLUhalfEdge *eDst );
-
-GLUmesh *__gl_meshNewMesh( void );
-GLUmesh *__gl_meshUnion( GLUmesh *mesh1, GLUmesh *mesh2 );
-void __gl_meshDeleteMesh( GLUmesh *mesh );
-void __gl_meshZapFace( GLUface *fZap );
-
-#ifdef NDEBUG
-#define __gl_meshCheckMesh( mesh )
-#else
-void __gl_meshCheckMesh( GLUmesh *mesh );
-#endif
-
-#endif
diff --git a/libtess/normal.c b/libtess/normal.c
deleted file mode 100644
index feae622..0000000
--- a/libtess/normal.c
+++ /dev/null
@@ -1,259 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include "gluos.h"
-#include "mesh.h"
-#include "tess.h"
-#include "normal.h"
-#include <math.h>
-#include <assert.h>
-
-#define TRUE 1
-#define FALSE 0
-
-#define Dot(u,v) (u[0]*v[0] + u[1]*v[1] + u[2]*v[2])
-
-#if 0
-static void Normalize( GLdouble v[3] )
-{
- GLdouble len = v[0]*v[0] + v[1]*v[1] + v[2]*v[2];
-
- assert( len > 0 );
- len = sqrt( len );
- v[0] /= len;
- v[1] /= len;
- v[2] /= len;
-}
-#endif
-
-#define ABS(x) ((x) < 0 ? -(x) : (x))
-
-static int LongAxis( GLdouble v[3] )
-{
- int i = 0;
-
- if( ABS(v[1]) > ABS(v[0]) ) { i = 1; }
- if( ABS(v[2]) > ABS(v[i]) ) { i = 2; }
- return i;
-}
-
-static void ComputeNormal( GLUtesselator *tess, GLdouble norm[3] )
-{
- GLUvertex *v, *v1, *v2;
- GLdouble c, tLen2, maxLen2;
- GLdouble maxVal[3], minVal[3], d1[3], d2[3], tNorm[3];
- GLUvertex *maxVert[3], *minVert[3];
- GLUvertex *vHead = &tess->mesh->vHead;
- int i;
-
- maxVal[0] = maxVal[1] = maxVal[2] = -2 * GLU_TESS_MAX_COORD;
- minVal[0] = minVal[1] = minVal[2] = 2 * GLU_TESS_MAX_COORD;
-
- for( v = vHead->next; v != vHead; v = v->next ) {
- for( i = 0; i < 3; ++i ) {
- c = v->coords[i];
- if( c < minVal[i] ) { minVal[i] = c; minVert[i] = v; }
- if( c > maxVal[i] ) { maxVal[i] = c; maxVert[i] = v; }
- }
- }
-
- /* Find two vertices separated by at least 1/sqrt(3) of the maximum
- * distance between any two vertices
- */
- i = 0;
- if( maxVal[1] - minVal[1] > maxVal[0] - minVal[0] ) { i = 1; }
- if( maxVal[2] - minVal[2] > maxVal[i] - minVal[i] ) { i = 2; }
- if( minVal[i] >= maxVal[i] ) {
- /* All vertices are the same -- normal doesn't matter */
- norm[0] = 0; norm[1] = 0; norm[2] = 1;
- return;
- }
-
- /* Look for a third vertex which forms the triangle with maximum area
- * (Length of normal == twice the triangle area)
- */
- maxLen2 = 0;
- v1 = minVert[i];
- v2 = maxVert[i];
- d1[0] = v1->coords[0] - v2->coords[0];
- d1[1] = v1->coords[1] - v2->coords[1];
- d1[2] = v1->coords[2] - v2->coords[2];
- for( v = vHead->next; v != vHead; v = v->next ) {
- d2[0] = v->coords[0] - v2->coords[0];
- d2[1] = v->coords[1] - v2->coords[1];
- d2[2] = v->coords[2] - v2->coords[2];
- tNorm[0] = d1[1]*d2[2] - d1[2]*d2[1];
- tNorm[1] = d1[2]*d2[0] - d1[0]*d2[2];
- tNorm[2] = d1[0]*d2[1] - d1[1]*d2[0];
- tLen2 = tNorm[0]*tNorm[0] + tNorm[1]*tNorm[1] + tNorm[2]*tNorm[2];
- if( tLen2 > maxLen2 ) {
- maxLen2 = tLen2;
- norm[0] = tNorm[0];
- norm[1] = tNorm[1];
- norm[2] = tNorm[2];
- }
- }
-
- if( maxLen2 <= 0 ) {
- /* All points lie on a single line -- any decent normal will do */
- norm[0] = norm[1] = norm[2] = 0;
- norm[LongAxis(d1)] = 1;
- }
-}
-
-
-static void CheckOrientation( GLUtesselator *tess )
-{
- GLdouble area;
- GLUface *f, *fHead = &tess->mesh->fHead;
- GLUvertex *v, *vHead = &tess->mesh->vHead;
- GLUhalfEdge *e;
-
- /* When we compute the normal automatically, we choose the orientation
- * so that the the sum of the signed areas of all contours is non-negative.
- */
- area = 0;
- for( f = fHead->next; f != fHead; f = f->next ) {
- e = f->anEdge;
- if( e->winding <= 0 ) continue;
- do {
- area += (e->Org->s - e->Dst->s) * (e->Org->t + e->Dst->t);
- e = e->Lnext;
- } while( e != f->anEdge );
- }
- if( area < 0 ) {
- /* Reverse the orientation by flipping all the t-coordinates */
- for( v = vHead->next; v != vHead; v = v->next ) {
- v->t = - v->t;
- }
- tess->tUnit[0] = - tess->tUnit[0];
- tess->tUnit[1] = - tess->tUnit[1];
- tess->tUnit[2] = - tess->tUnit[2];
- }
-}
-
-#ifdef FOR_TRITE_TEST_PROGRAM
-#include <stdlib.h>
-extern int RandomSweep;
-#define S_UNIT_X (RandomSweep ? (2*drand48()-1) : 1.0)
-#define S_UNIT_Y (RandomSweep ? (2*drand48()-1) : 0.0)
-#else
-#if defined(SLANTED_SWEEP)
-/* The "feature merging" is not intended to be complete. There are
- * special cases where edges are nearly parallel to the sweep line
- * which are not implemented. The algorithm should still behave
- * robustly (ie. produce a reasonable tesselation) in the presence
- * of such edges, however it may miss features which could have been
- * merged. We could minimize this effect by choosing the sweep line
- * direction to be something unusual (ie. not parallel to one of the
- * coordinate axes).
- */
-#define S_UNIT_X 0.50941539564955385 /* Pre-normalized */
-#define S_UNIT_Y 0.86052074622010633
-#else
-#define S_UNIT_X 1.0
-#define S_UNIT_Y 0.0
-#endif
-#endif
-
-/* Determine the polygon normal and project vertices onto the plane
- * of the polygon.
- */
-void __gl_projectPolygon( GLUtesselator *tess )
-{
- GLUvertex *v, *vHead = &tess->mesh->vHead;
- GLdouble norm[3];
- GLdouble *sUnit, *tUnit;
- int i, computedNormal = FALSE;
-
- norm[0] = tess->normal[0];
- norm[1] = tess->normal[1];
- norm[2] = tess->normal[2];
- if( norm[0] == 0 && norm[1] == 0 && norm[2] == 0 ) {
- ComputeNormal( tess, norm );
- computedNormal = TRUE;
- }
- sUnit = tess->sUnit;
- tUnit = tess->tUnit;
- i = LongAxis( norm );
-
-#if defined(FOR_TRITE_TEST_PROGRAM) || defined(TRUE_PROJECT)
- /* Choose the initial sUnit vector to be approximately perpendicular
- * to the normal.
- */
- Normalize( norm );
-
- sUnit[i] = 0;
- sUnit[(i+1)%3] = S_UNIT_X;
- sUnit[(i+2)%3] = S_UNIT_Y;
-
- /* Now make it exactly perpendicular */
- w = Dot( sUnit, norm );
- sUnit[0] -= w * norm[0];
- sUnit[1] -= w * norm[1];
- sUnit[2] -= w * norm[2];
- Normalize( sUnit );
-
- /* Choose tUnit so that (sUnit,tUnit,norm) form a right-handed frame */
- tUnit[0] = norm[1]*sUnit[2] - norm[2]*sUnit[1];
- tUnit[1] = norm[2]*sUnit[0] - norm[0]*sUnit[2];
- tUnit[2] = norm[0]*sUnit[1] - norm[1]*sUnit[0];
- Normalize( tUnit );
-#else
- /* Project perpendicular to a coordinate axis -- better numerically */
- sUnit[i] = 0;
- sUnit[(i+1)%3] = S_UNIT_X;
- sUnit[(i+2)%3] = S_UNIT_Y;
-
- tUnit[i] = 0;
- tUnit[(i+1)%3] = (norm[i] > 0) ? -S_UNIT_Y : S_UNIT_Y;
- tUnit[(i+2)%3] = (norm[i] > 0) ? S_UNIT_X : -S_UNIT_X;
-#endif
-
- /* Project the vertices onto the sweep plane */
- for( v = vHead->next; v != vHead; v = v->next ) {
- v->s = Dot( v->coords, sUnit );
- v->t = Dot( v->coords, tUnit );
- }
- if( computedNormal ) {
- CheckOrientation( tess );
- }
-}
diff --git a/libtess/normal.h b/libtess/normal.h
deleted file mode 100644
index 01076b8..0000000
--- a/libtess/normal.h
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __normal_h_
-#define __normal_h_
-
-#include "tess.h"
-
-/* __gl_projectPolygon( tess ) determines the polygon normal
- * and project vertices onto the plane of the polygon.
- */
-void __gl_projectPolygon( GLUtesselator *tess );
-
-#endif
diff --git a/libtess/priorityq-heap.c b/libtess/priorityq-heap.c
deleted file mode 100644
index 869fb35..0000000
--- a/libtess/priorityq-heap.c
+++ /dev/null
@@ -1,259 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include <stddef.h>
-#include <assert.h>
-#include "priorityq-heap.h"
-#include "memalloc.h"
-
-#define INIT_SIZE 32
-
-#define TRUE 1
-#define FALSE 0
-
-#ifdef FOR_TRITE_TEST_PROGRAM
-#define LEQ(x,y) (*pq->leq)(x,y)
-#else
-/* Violates modularity, but a little faster */
-#include "geom.h"
-#define LEQ(x,y) VertLeq((GLUvertex *)x, (GLUvertex *)y)
-#endif
-
-/* really __gl_pqHeapNewPriorityQ */
-PriorityQ *pqNewPriorityQ( int (*leq)(PQkey key1, PQkey key2) )
-{
- PriorityQ *pq = (PriorityQ *)memAlloc( sizeof( PriorityQ ));
- if (pq == NULL) return NULL;
-
- pq->size = 0;
- pq->max = INIT_SIZE;
- pq->nodes = (PQnode *)memAlloc( (INIT_SIZE + 1) * sizeof(pq->nodes[0]) );
- if (pq->nodes == NULL) {
- memFree(pq);
- return NULL;
- }
-
- pq->handles = (PQhandleElem *)memAlloc( (INIT_SIZE + 1) * sizeof(pq->handles[0]) );
- if (pq->handles == NULL) {
- memFree(pq->nodes);
- memFree(pq);
- return NULL;
- }
-
- pq->initialized = FALSE;
- pq->freeList = 0;
- pq->leq = leq;
-
- pq->nodes[1].handle = 1; /* so that Minimum() returns NULL */
- pq->handles[1].key = NULL;
- return pq;
-}
-
-/* really __gl_pqHeapDeletePriorityQ */
-void pqDeletePriorityQ( PriorityQ *pq )
-{
- memFree( pq->handles );
- memFree( pq->nodes );
- memFree( pq );
-}
-
-
-static void FloatDown( PriorityQ *pq, long curr )
-{
- PQnode *n = pq->nodes;
- PQhandleElem *h = pq->handles;
- PQhandle hCurr, hChild;
- long child;
-
- hCurr = n[curr].handle;
- for( ;; ) {
- child = curr << 1;
- if( child < pq->size && LEQ( h[n[child+1].handle].key,
- h[n[child].handle].key )) {
- ++child;
- }
-
- assert(child <= pq->max);
-
- hChild = n[child].handle;
- if( child > pq->size || LEQ( h[hCurr].key, h[hChild].key )) {
- n[curr].handle = hCurr;
- h[hCurr].node = curr;
- break;
- }
- n[curr].handle = hChild;
- h[hChild].node = curr;
- curr = child;
- }
-}
-
-
-static void FloatUp( PriorityQ *pq, long curr )
-{
- PQnode *n = pq->nodes;
- PQhandleElem *h = pq->handles;
- PQhandle hCurr, hParent;
- long parent;
-
- hCurr = n[curr].handle;
- for( ;; ) {
- parent = curr >> 1;
- hParent = n[parent].handle;
- if( parent == 0 || LEQ( h[hParent].key, h[hCurr].key )) {
- n[curr].handle = hCurr;
- h[hCurr].node = curr;
- break;
- }
- n[curr].handle = hParent;
- h[hParent].node = curr;
- curr = parent;
- }
-}
-
-/* really __gl_pqHeapInit */
-void pqInit( PriorityQ *pq )
-{
- long i;
-
- /* This method of building a heap is O(n), rather than O(n lg n). */
-
- for( i = pq->size; i >= 1; --i ) {
- FloatDown( pq, i );
- }
- pq->initialized = TRUE;
-}
-
-/* really __gl_pqHeapInsert */
-/* returns LONG_MAX iff out of memory */
-PQhandle pqInsert( PriorityQ *pq, PQkey keyNew )
-{
- long curr;
- PQhandle free;
-
- curr = ++ pq->size;
- if( (curr*2) > pq->max ) {
- PQnode *saveNodes= pq->nodes;
- PQhandleElem *saveHandles= pq->handles;
-
- /* If the heap overflows, double its size. */
- pq->max <<= 1;
- pq->nodes = (PQnode *)memRealloc( pq->nodes,
- (size_t)
- ((pq->max + 1) * sizeof( pq->nodes[0] )));
- if (pq->nodes == NULL) {
- pq->nodes = saveNodes; /* restore ptr to free upon return */
- return LONG_MAX;
- }
- pq->handles = (PQhandleElem *)memRealloc( pq->handles,
- (size_t)
- ((pq->max + 1) *
- sizeof( pq->handles[0] )));
- if (pq->handles == NULL) {
- pq->handles = saveHandles; /* restore ptr to free upon return */
- return LONG_MAX;
- }
- }
-
- if( pq->freeList == 0 ) {
- free = curr;
- } else {
- free = pq->freeList;
- pq->freeList = pq->handles[free].node;
- }
-
- pq->nodes[curr].handle = free;
- pq->handles[free].node = curr;
- pq->handles[free].key = keyNew;
-
- if( pq->initialized ) {
- FloatUp( pq, curr );
- }
- assert(free != LONG_MAX);
- return free;
-}
-
-/* really __gl_pqHeapExtractMin */
-PQkey pqExtractMin( PriorityQ *pq )
-{
- PQnode *n = pq->nodes;
- PQhandleElem *h = pq->handles;
- PQhandle hMin = n[1].handle;
- PQkey min = h[hMin].key;
-
- if( pq->size > 0 ) {
- n[1].handle = n[pq->size].handle;
- h[n[1].handle].node = 1;
-
- h[hMin].key = NULL;
- h[hMin].node = pq->freeList;
- pq->freeList = hMin;
-
- if( -- pq->size > 0 ) {
- FloatDown( pq, 1 );
- }
- }
- return min;
-}
-
-/* really __gl_pqHeapDelete */
-void pqDelete( PriorityQ *pq, PQhandle hCurr )
-{
- PQnode *n = pq->nodes;
- PQhandleElem *h = pq->handles;
- long curr;
-
- assert( hCurr >= 1 && hCurr <= pq->max && h[hCurr].key != NULL );
-
- curr = h[hCurr].node;
- n[curr].handle = n[pq->size].handle;
- h[n[curr].handle].node = curr;
-
- if( curr <= -- pq->size ) {
- if( curr <= 1 || LEQ( h[n[curr>>1].handle].key, h[n[curr].handle].key )) {
- FloatDown( pq, curr );
- } else {
- FloatUp( pq, curr );
- }
- }
- h[hCurr].key = NULL;
- h[hCurr].node = pq->freeList;
- pq->freeList = hCurr;
-}
diff --git a/libtess/priorityq-heap.h b/libtess/priorityq-heap.h
deleted file mode 100644
index eba30e1..0000000
--- a/libtess/priorityq-heap.h
+++ /dev/null
@@ -1,114 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __priorityq_heap_h_
-#define __priorityq_heap_h_
-
-/* Use #define's so that another heap implementation can use this one */
-
-#define PQkey PQHeapKey
-#define PQhandle PQHeapHandle
-#define PriorityQ PriorityQHeap
-
-#define pqNewPriorityQ(leq) __gl_pqHeapNewPriorityQ(leq)
-#define pqDeletePriorityQ(pq) __gl_pqHeapDeletePriorityQ(pq)
-
-/* The basic operations are insertion of a new key (pqInsert),
- * and examination/extraction of a key whose value is minimum
- * (pqMinimum/pqExtractMin). Deletion is also allowed (pqDelete);
- * for this purpose pqInsert returns a "handle" which is supplied
- * as the argument.
- *
- * An initial heap may be created efficiently by calling pqInsert
- * repeatedly, then calling pqInit. In any case pqInit must be called
- * before any operations other than pqInsert are used.
- *
- * If the heap is empty, pqMinimum/pqExtractMin will return a NULL key.
- * This may also be tested with pqIsEmpty.
- */
-#define pqInit(pq) __gl_pqHeapInit(pq)
-#define pqInsert(pq,key) __gl_pqHeapInsert(pq,key)
-#define pqMinimum(pq) __gl_pqHeapMinimum(pq)
-#define pqExtractMin(pq) __gl_pqHeapExtractMin(pq)
-#define pqDelete(pq,handle) __gl_pqHeapDelete(pq,handle)
-#define pqIsEmpty(pq) __gl_pqHeapIsEmpty(pq)
-
-
-/* Since we support deletion the data structure is a little more
- * complicated than an ordinary heap. "nodes" is the heap itself;
- * active nodes are stored in the range 1..pq->size. When the
- * heap exceeds its allocated size (pq->max), its size doubles.
- * The children of node i are nodes 2i and 2i+1.
- *
- * Each node stores an index into an array "handles". Each handle
- * stores a key, plus a pointer back to the node which currently
- * represents that key (ie. nodes[handles[i].node].handle == i).
- */
-
-typedef void *PQkey;
-typedef long PQhandle;
-typedef struct PriorityQ PriorityQ;
-
-typedef struct { PQhandle handle; } PQnode;
-typedef struct { PQkey key; PQhandle node; } PQhandleElem;
-
-struct PriorityQ {
- PQnode *nodes;
- PQhandleElem *handles;
- long size, max;
- PQhandle freeList;
- int initialized;
- int (*leq)(PQkey key1, PQkey key2);
-};
-
-PriorityQ *pqNewPriorityQ( int (*leq)(PQkey key1, PQkey key2) );
-void pqDeletePriorityQ( PriorityQ *pq );
-
-void pqInit( PriorityQ *pq );
-PQhandle pqInsert( PriorityQ *pq, PQkey key );
-PQkey pqExtractMin( PriorityQ *pq );
-void pqDelete( PriorityQ *pq, PQhandle handle );
-
-
-#define __gl_pqHeapMinimum(pq) ((pq)->handles[(pq)->nodes[1].handle].key)
-#define __gl_pqHeapIsEmpty(pq) ((pq)->size == 0)
-
-#endif
diff --git a/libtess/priorityq-sort.h b/libtess/priorityq-sort.h
deleted file mode 100644
index 750bdc8..0000000
--- a/libtess/priorityq-sort.h
+++ /dev/null
@@ -1,124 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __priorityq_sort_h_
-#define __priorityq_sort_h_
-
-#include "priorityq-heap.h"
-
-#undef PQkey
-#undef PQhandle
-#undef PriorityQ
-#undef pqNewPriorityQ
-#undef pqDeletePriorityQ
-#undef pqInit
-#undef pqInsert
-#undef pqMinimum
-#undef pqExtractMin
-#undef pqDelete
-#undef pqIsEmpty
-
-/* Use #define's so that another heap implementation can use this one */
-
-#define PQkey PQSortKey
-#define PQhandle PQSortHandle
-#define PriorityQ PriorityQSort
-
-#define pqNewPriorityQ(leq) __gl_pqSortNewPriorityQ(leq)
-#define pqDeletePriorityQ(pq) __gl_pqSortDeletePriorityQ(pq)
-
-/* The basic operations are insertion of a new key (pqInsert),
- * and examination/extraction of a key whose value is minimum
- * (pqMinimum/pqExtractMin). Deletion is also allowed (pqDelete);
- * for this purpose pqInsert returns a "handle" which is supplied
- * as the argument.
- *
- * An initial heap may be created efficiently by calling pqInsert
- * repeatedly, then calling pqInit. In any case pqInit must be called
- * before any operations other than pqInsert are used.
- *
- * If the heap is empty, pqMinimum/pqExtractMin will return a NULL key.
- * This may also be tested with pqIsEmpty.
- */
-#define pqInit(pq) __gl_pqSortInit(pq)
-#define pqInsert(pq,key) __gl_pqSortInsert(pq,key)
-#define pqMinimum(pq) __gl_pqSortMinimum(pq)
-#define pqExtractMin(pq) __gl_pqSortExtractMin(pq)
-#define pqDelete(pq,handle) __gl_pqSortDelete(pq,handle)
-#define pqIsEmpty(pq) __gl_pqSortIsEmpty(pq)
-
-
-/* Since we support deletion the data structure is a little more
- * complicated than an ordinary heap. "nodes" is the heap itself;
- * active nodes are stored in the range 1..pq->size. When the
- * heap exceeds its allocated size (pq->max), its size doubles.
- * The children of node i are nodes 2i and 2i+1.
- *
- * Each node stores an index into an array "handles". Each handle
- * stores a key, plus a pointer back to the node which currently
- * represents that key (ie. nodes[handles[i].node].handle == i).
- */
-
-typedef PQHeapKey PQkey;
-typedef PQHeapHandle PQhandle;
-typedef struct PriorityQ PriorityQ;
-
-struct PriorityQ {
- PriorityQHeap *heap;
- PQkey *keys;
- PQkey **order;
- PQhandle size, max;
- int initialized;
- int (*leq)(PQkey key1, PQkey key2);
-};
-
-PriorityQ *pqNewPriorityQ( int (*leq)(PQkey key1, PQkey key2) );
-void pqDeletePriorityQ( PriorityQ *pq );
-
-int pqInit( PriorityQ *pq );
-PQhandle pqInsert( PriorityQ *pq, PQkey key );
-PQkey pqExtractMin( PriorityQ *pq );
-void pqDelete( PriorityQ *pq, PQhandle handle );
-
-PQkey pqMinimum( PriorityQ *pq );
-int pqIsEmpty( PriorityQ *pq );
-
-#endif
diff --git a/libtess/priorityq.c b/libtess/priorityq.c
deleted file mode 100644
index 8744edb..0000000
--- a/libtess/priorityq.c
+++ /dev/null
@@ -1,267 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include "gluos.h"
-#include <stddef.h>
-#include <assert.h>
-#include <limits.h> /* LONG_MAX */
-#include "memalloc.h"
-
-/* Include all the code for the regular heap-based queue here. */
-
-#include "priorityq-heap.c"
-
-/* Now redefine all the function names to map to their "Sort" versions. */
-
-#include "priorityq-sort.h"
-
-/* really __gl_pqSortNewPriorityQ */
-PriorityQ *pqNewPriorityQ( int (*leq)(PQkey key1, PQkey key2) )
-{
- PriorityQ *pq = (PriorityQ *)memAlloc( sizeof( PriorityQ ));
- if (pq == NULL) return NULL;
-
- pq->heap = __gl_pqHeapNewPriorityQ( leq );
- if (pq->heap == NULL) {
- memFree(pq);
- return NULL;
- }
-
- pq->keys = (PQHeapKey *)memAlloc( INIT_SIZE * sizeof(pq->keys[0]) );
- if (pq->keys == NULL) {
- __gl_pqHeapDeletePriorityQ(pq->heap);
- memFree(pq);
- return NULL;
- }
-
- pq->size = 0;
- pq->max = INIT_SIZE;
- pq->initialized = FALSE;
- pq->leq = leq;
- return pq;
-}
-
-/* really __gl_pqSortDeletePriorityQ */
-void pqDeletePriorityQ( PriorityQ *pq )
-{
- assert(pq != NULL);
- if (pq->heap != NULL) __gl_pqHeapDeletePriorityQ( pq->heap );
- if (pq->order != NULL) memFree( pq->order );
- if (pq->keys != NULL) memFree( pq->keys );
- memFree( pq );
-}
-
-
-#define LT(x,y) (! LEQ(y,x))
-#define GT(x,y) (! LEQ(x,y))
-#define Swap(a,b) if(1){PQkey *tmp = *a; *a = *b; *b = tmp;}else
-
-/* really __gl_pqSortInit */
-int pqInit( PriorityQ *pq )
-{
- PQkey **p, **r, **i, **j, *piv;
- struct { PQkey **p, **r; } Stack[50], *top = Stack;
- unsigned long seed = 2016473283;
-
- /* Create an array of indirect pointers to the keys, so that we
- * the handles we have returned are still valid.
- */
-/*
- pq->order = (PQHeapKey **)memAlloc( (size_t)
- (pq->size * sizeof(pq->order[0])) );
-*/
- pq->order = (PQHeapKey **)memAlloc( (size_t)
- ((pq->size+1) * sizeof(pq->order[0])) );
-/* the previous line is a patch to compensate for the fact that IBM */
-/* machines return a null on a malloc of zero bytes (unlike SGI), */
-/* so we have to put in this defense to guard against a memory */
-/* fault four lines down. from fossum@austin.ibm.com. */
- if (pq->order == NULL) return 0;
-
- p = pq->order;
- r = p + pq->size - 1;
- for( piv = pq->keys, i = p; i <= r; ++piv, ++i ) {
- *i = piv;
- }
-
- /* Sort the indirect pointers in descending order,
- * using randomized Quicksort
- */
- top->p = p; top->r = r; ++top;
- while( --top >= Stack ) {
- p = top->p;
- r = top->r;
- while( r > p + 10 ) {
- seed = seed * 1539415821 + 1;
- i = p + seed % (r - p + 1);
- piv = *i;
- *i = *p;
- *p = piv;
- i = p - 1;
- j = r + 1;
- do {
- do { ++i; } while( GT( **i, *piv ));
- do { --j; } while( LT( **j, *piv ));
- Swap( i, j );
- } while( i < j );
- Swap( i, j ); /* Undo last swap */
- if( i - p < r - j ) {
- top->p = j+1; top->r = r; ++top;
- r = i-1;
- } else {
- top->p = p; top->r = i-1; ++top;
- p = j+1;
- }
- }
- /* Insertion sort small lists */
- for( i = p+1; i <= r; ++i ) {
- piv = *i;
- for( j = i; j > p && LT( **(j-1), *piv ); --j ) {
- *j = *(j-1);
- }
- *j = piv;
- }
- }
- pq->max = pq->size;
- pq->initialized = TRUE;
- __gl_pqHeapInit( pq->heap ); /* always succeeds */
-
-#ifndef NDEBUG
- p = pq->order;
- r = p + pq->size - 1;
- for( i = p; i < r; ++i ) {
- assert( LEQ( **(i+1), **i ));
- }
-#endif
-
- return 1;
-}
-
-/* really __gl_pqSortInsert */
-/* returns LONG_MAX iff out of memory */
-PQhandle pqInsert( PriorityQ *pq, PQkey keyNew )
-{
- long curr;
-
- if( pq->initialized ) {
- return __gl_pqHeapInsert( pq->heap, keyNew );
- }
- curr = pq->size;
- if( ++ pq->size >= pq->max ) {
- PQkey *saveKey= pq->keys;
-
- /* If the heap overflows, double its size. */
- pq->max <<= 1;
- pq->keys = (PQHeapKey *)memRealloc( pq->keys,
- (size_t)
- (pq->max * sizeof( pq->keys[0] )));
- if (pq->keys == NULL) {
- pq->keys = saveKey; /* restore ptr to free upon return */
- return LONG_MAX;
- }
- }
- assert(curr != LONG_MAX);
- pq->keys[curr] = keyNew;
-
- /* Negative handles index the sorted array. */
- return -(curr+1);
-}
-
-/* really __gl_pqSortExtractMin */
-PQkey pqExtractMin( PriorityQ *pq )
-{
- PQkey sortMin, heapMin;
-
- if( pq->size == 0 ) {
- return __gl_pqHeapExtractMin( pq->heap );
- }
- sortMin = *(pq->order[pq->size-1]);
- if( ! __gl_pqHeapIsEmpty( pq->heap )) {
- heapMin = __gl_pqHeapMinimum( pq->heap );
- if( LEQ( heapMin, sortMin )) {
- return __gl_pqHeapExtractMin( pq->heap );
- }
- }
- do {
- -- pq->size;
- } while( pq->size > 0 && *(pq->order[pq->size-1]) == NULL );
- return sortMin;
-}
-
-/* really __gl_pqSortMinimum */
-PQkey pqMinimum( PriorityQ *pq )
-{
- PQkey sortMin, heapMin;
-
- if( pq->size == 0 ) {
- return __gl_pqHeapMinimum( pq->heap );
- }
- sortMin = *(pq->order[pq->size-1]);
- if( ! __gl_pqHeapIsEmpty( pq->heap )) {
- heapMin = __gl_pqHeapMinimum( pq->heap );
- if( LEQ( heapMin, sortMin )) {
- return heapMin;
- }
- }
- return sortMin;
-}
-
-/* really __gl_pqSortIsEmpty */
-int pqIsEmpty( PriorityQ *pq )
-{
- return (pq->size == 0) && __gl_pqHeapIsEmpty( pq->heap );
-}
-
-/* really __gl_pqSortDelete */
-void pqDelete( PriorityQ *pq, PQhandle curr )
-{
- if( curr >= 0 ) {
- __gl_pqHeapDelete( pq->heap, curr );
- return;
- }
- curr = -(curr+1);
- assert( curr < pq->max && pq->keys[curr] != NULL );
-
- pq->keys[curr] = NULL;
- while( pq->size > 0 && *(pq->order[pq->size-1]) == NULL ) {
- -- pq->size;
- }
-}
diff --git a/libtess/priorityq.h b/libtess/priorityq.h
deleted file mode 100644
index 750bdc8..0000000
--- a/libtess/priorityq.h
+++ /dev/null
@@ -1,124 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __priorityq_sort_h_
-#define __priorityq_sort_h_
-
-#include "priorityq-heap.h"
-
-#undef PQkey
-#undef PQhandle
-#undef PriorityQ
-#undef pqNewPriorityQ
-#undef pqDeletePriorityQ
-#undef pqInit
-#undef pqInsert
-#undef pqMinimum
-#undef pqExtractMin
-#undef pqDelete
-#undef pqIsEmpty
-
-/* Use #define's so that another heap implementation can use this one */
-
-#define PQkey PQSortKey
-#define PQhandle PQSortHandle
-#define PriorityQ PriorityQSort
-
-#define pqNewPriorityQ(leq) __gl_pqSortNewPriorityQ(leq)
-#define pqDeletePriorityQ(pq) __gl_pqSortDeletePriorityQ(pq)
-
-/* The basic operations are insertion of a new key (pqInsert),
- * and examination/extraction of a key whose value is minimum
- * (pqMinimum/pqExtractMin). Deletion is also allowed (pqDelete);
- * for this purpose pqInsert returns a "handle" which is supplied
- * as the argument.
- *
- * An initial heap may be created efficiently by calling pqInsert
- * repeatedly, then calling pqInit. In any case pqInit must be called
- * before any operations other than pqInsert are used.
- *
- * If the heap is empty, pqMinimum/pqExtractMin will return a NULL key.
- * This may also be tested with pqIsEmpty.
- */
-#define pqInit(pq) __gl_pqSortInit(pq)
-#define pqInsert(pq,key) __gl_pqSortInsert(pq,key)
-#define pqMinimum(pq) __gl_pqSortMinimum(pq)
-#define pqExtractMin(pq) __gl_pqSortExtractMin(pq)
-#define pqDelete(pq,handle) __gl_pqSortDelete(pq,handle)
-#define pqIsEmpty(pq) __gl_pqSortIsEmpty(pq)
-
-
-/* Since we support deletion the data structure is a little more
- * complicated than an ordinary heap. "nodes" is the heap itself;
- * active nodes are stored in the range 1..pq->size. When the
- * heap exceeds its allocated size (pq->max), its size doubles.
- * The children of node i are nodes 2i and 2i+1.
- *
- * Each node stores an index into an array "handles". Each handle
- * stores a key, plus a pointer back to the node which currently
- * represents that key (ie. nodes[handles[i].node].handle == i).
- */
-
-typedef PQHeapKey PQkey;
-typedef PQHeapHandle PQhandle;
-typedef struct PriorityQ PriorityQ;
-
-struct PriorityQ {
- PriorityQHeap *heap;
- PQkey *keys;
- PQkey **order;
- PQhandle size, max;
- int initialized;
- int (*leq)(PQkey key1, PQkey key2);
-};
-
-PriorityQ *pqNewPriorityQ( int (*leq)(PQkey key1, PQkey key2) );
-void pqDeletePriorityQ( PriorityQ *pq );
-
-int pqInit( PriorityQ *pq );
-PQhandle pqInsert( PriorityQ *pq, PQkey key );
-PQkey pqExtractMin( PriorityQ *pq );
-void pqDelete( PriorityQ *pq, PQhandle handle );
-
-PQkey pqMinimum( PriorityQ *pq );
-int pqIsEmpty( PriorityQ *pq );
-
-#endif
diff --git a/libtess/render.c b/libtess/render.c
deleted file mode 100644
index 89b442e..0000000
--- a/libtess/render.c
+++ /dev/null
@@ -1,505 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include "gluos.h"
-#include <assert.h>
-#include <stddef.h>
-#include "mesh.h"
-#include "tess.h"
-#include "render.h"
-
-#define TRUE 1
-#define FALSE 0
-
-/* This structure remembers the information we need about a primitive
- * to be able to render it later, once we have determined which
- * primitive is able to use the most triangles.
- */
-struct FaceCount {
- long size; /* number of triangles used */
- GLUhalfEdge *eStart; /* edge where this primitive starts */
- void (*render)(GLUtesselator *, GLUhalfEdge *, long);
- /* routine to render this primitive */
-};
-
-static struct FaceCount MaximumFan( GLUhalfEdge *eOrig );
-static struct FaceCount MaximumStrip( GLUhalfEdge *eOrig );
-
-static void RenderFan( GLUtesselator *tess, GLUhalfEdge *eStart, long size );
-static void RenderStrip( GLUtesselator *tess, GLUhalfEdge *eStart, long size );
-static void RenderTriangle( GLUtesselator *tess, GLUhalfEdge *eStart,
- long size );
-
-static void RenderMaximumFaceGroup( GLUtesselator *tess, GLUface *fOrig );
-static void RenderLonelyTriangles( GLUtesselator *tess, GLUface *head );
-
-
-
-/************************ Strips and Fans decomposition ******************/
-
-/* __gl_renderMesh( tess, mesh ) takes a mesh and breaks it into triangle
- * fans, strips, and separate triangles. A substantial effort is made
- * to use as few rendering primitives as possible (ie. to make the fans
- * and strips as large as possible).
- *
- * The rendering output is provided as callbacks (see the api).
- */
-void __gl_renderMesh( GLUtesselator *tess, GLUmesh *mesh )
-{
- GLUface *f;
-
- /* Make a list of separate triangles so we can render them all at once */
- tess->lonelyTriList = NULL;
-
- for( f = mesh->fHead.next; f != &mesh->fHead; f = f->next ) {
- f->marked = FALSE;
- }
- for( f = mesh->fHead.next; f != &mesh->fHead; f = f->next ) {
-
- /* We examine all faces in an arbitrary order. Whenever we find
- * an unprocessed face F, we output a group of faces including F
- * whose size is maximum.
- */
- if( f->inside && ! f->marked ) {
- RenderMaximumFaceGroup( tess, f );
- assert( f->marked );
- }
- }
- if( tess->lonelyTriList != NULL ) {
- RenderLonelyTriangles( tess, tess->lonelyTriList );
- tess->lonelyTriList = NULL;
- }
-}
-
-
-static void RenderMaximumFaceGroup( GLUtesselator *tess, GLUface *fOrig )
-{
- /* We want to find the largest triangle fan or strip of unmarked faces
- * which includes the given face fOrig. There are 3 possible fans
- * passing through fOrig (one centered at each vertex), and 3 possible
- * strips (one for each CCW permutation of the vertices). Our strategy
- * is to try all of these, and take the primitive which uses the most
- * triangles (a greedy approach).
- */
- GLUhalfEdge *e = fOrig->anEdge;
- struct FaceCount max, newFace;
-
- max.size = 1;
- max.eStart = e;
- max.render = &RenderTriangle;
-
- if( ! tess->flagBoundary ) {
- newFace = MaximumFan( e ); if( newFace.size > max.size ) { max = newFace; }
- newFace = MaximumFan( e->Lnext ); if( newFace.size > max.size ) { max = newFace; }
- newFace = MaximumFan( e->Lprev ); if( newFace.size > max.size ) { max = newFace; }
-
- newFace = MaximumStrip( e ); if( newFace.size > max.size ) { max = newFace; }
- newFace = MaximumStrip( e->Lnext ); if( newFace.size > max.size ) { max = newFace; }
- newFace = MaximumStrip( e->Lprev ); if( newFace.size > max.size ) { max = newFace; }
- }
- (*(max.render))( tess, max.eStart, max.size );
-}
-
-
-/* Macros which keep track of faces we have marked temporarily, and allow
- * us to backtrack when necessary. With triangle fans, this is not
- * really necessary, since the only awkward case is a loop of triangles
- * around a single origin vertex. However with strips the situation is
- * more complicated, and we need a general tracking method like the
- * one here.
- */
-#define Marked(f) (! (f)->inside || (f)->marked)
-
-#define AddToTrail(f,t) ((f)->trail = (t), (t) = (f), (f)->marked = TRUE)
-
-#define FreeTrail(t) if( 1 ) { \
- while( (t) != NULL ) { \
- (t)->marked = FALSE; t = (t)->trail; \
- } \
- } else /* absorb trailing semicolon */
-
-
-
-static struct FaceCount MaximumFan( GLUhalfEdge *eOrig )
-{
- /* eOrig->Lface is the face we want to render. We want to find the size
- * of a maximal fan around eOrig->Org. To do this we just walk around
- * the origin vertex as far as possible in both directions.
- */
- struct FaceCount newFace = { 0, NULL, &RenderFan };
- GLUface *trail = NULL;
- GLUhalfEdge *e;
-
- for( e = eOrig; ! Marked( e->Lface ); e = e->Onext ) {
- AddToTrail( e->Lface, trail );
- ++newFace.size;
- }
- for( e = eOrig; ! Marked( e->Rface ); e = e->Oprev ) {
- AddToTrail( e->Rface, trail );
- ++newFace.size;
- }
- newFace.eStart = e;
- /*LINTED*/
- FreeTrail( trail );
- return newFace;
-}
-
-
-#define IsEven(n) (((n) & 1) == 0)
-
-static struct FaceCount MaximumStrip( GLUhalfEdge *eOrig )
-{
- /* Here we are looking for a maximal strip that contains the vertices
- * eOrig->Org, eOrig->Dst, eOrig->Lnext->Dst (in that order or the
- * reverse, such that all triangles are oriented CCW).
- *
- * Again we walk forward and backward as far as possible. However for
- * strips there is a twist: to get CCW orientations, there must be
- * an *even* number of triangles in the strip on one side of eOrig.
- * We walk the strip starting on a side with an even number of triangles;
- * if both side have an odd number, we are forced to shorten one side.
- */
- struct FaceCount newFace = { 0, NULL, &RenderStrip };
- long headSize = 0, tailSize = 0;
- GLUface *trail = NULL;
- GLUhalfEdge *e, *eTail, *eHead;
-
- for( e = eOrig; ! Marked( e->Lface ); ++tailSize, e = e->Onext ) {
- AddToTrail( e->Lface, trail );
- ++tailSize;
- e = e->Dprev;
- if( Marked( e->Lface )) break;
- AddToTrail( e->Lface, trail );
- }
- eTail = e;
-
- for( e = eOrig; ! Marked( e->Rface ); ++headSize, e = e->Dnext ) {
- AddToTrail( e->Rface, trail );
- ++headSize;
- e = e->Oprev;
- if( Marked( e->Rface )) break;
- AddToTrail( e->Rface, trail );
- }
- eHead = e;
-
- newFace.size = tailSize + headSize;
- if( IsEven( tailSize )) {
- newFace.eStart = eTail->Sym;
- } else if( IsEven( headSize )) {
- newFace.eStart = eHead;
- } else {
- /* Both sides have odd length, we must shorten one of them. In fact,
- * we must start from eHead to guarantee inclusion of eOrig->Lface.
- */
- --newFace.size;
- newFace.eStart = eHead->Onext;
- }
- /*LINTED*/
- FreeTrail( trail );
- return newFace;
-}
-
-
-static void RenderTriangle( GLUtesselator *tess, GLUhalfEdge *e, long size )
-{
- /* Just add the triangle to a triangle list, so we can render all
- * the separate triangles at once.
- */
- assert( size == 1 );
- AddToTrail( e->Lface, tess->lonelyTriList );
-}
-
-
-static void RenderLonelyTriangles( GLUtesselator *tess, GLUface *f )
-{
- /* Now we render all the separate triangles which could not be
- * grouped into a triangle fan or strip.
- */
- GLUhalfEdge *e;
- int newState;
- int edgeState = -1; /* force edge state output for first vertex */
-
- CALL_BEGIN_OR_BEGIN_DATA( GL_TRIANGLES );
-
- for( ; f != NULL; f = f->trail ) {
- /* Loop once for each edge (there will always be 3 edges) */
-
- e = f->anEdge;
- do {
- if( tess->flagBoundary ) {
- /* Set the "edge state" to TRUE just before we output the
- * first vertex of each edge on the polygon boundary.
- */
- newState = ! e->Rface->inside;
- if( edgeState != newState ) {
- edgeState = newState;
- CALL_EDGE_FLAG_OR_EDGE_FLAG_DATA( edgeState );
- }
- }
- CALL_VERTEX_OR_VERTEX_DATA( e->Org->data );
-
- e = e->Lnext;
- } while( e != f->anEdge );
- }
- CALL_END_OR_END_DATA();
-}
-
-
-static void RenderFan( GLUtesselator *tess, GLUhalfEdge *e, long size )
-{
- /* Render as many CCW triangles as possible in a fan starting from
- * edge "e". The fan *should* contain exactly "size" triangles
- * (otherwise we've goofed up somewhere).
- */
- CALL_BEGIN_OR_BEGIN_DATA( GL_TRIANGLE_FAN );
- CALL_VERTEX_OR_VERTEX_DATA( e->Org->data );
- CALL_VERTEX_OR_VERTEX_DATA( e->Dst->data );
-
- while( ! Marked( e->Lface )) {
- e->Lface->marked = TRUE;
- --size;
- e = e->Onext;
- CALL_VERTEX_OR_VERTEX_DATA( e->Dst->data );
- }
-
- assert( size == 0 );
- CALL_END_OR_END_DATA();
-}
-
-
-static void RenderStrip( GLUtesselator *tess, GLUhalfEdge *e, long size )
-{
- /* Render as many CCW triangles as possible in a strip starting from
- * edge "e". The strip *should* contain exactly "size" triangles
- * (otherwise we've goofed up somewhere).
- */
- CALL_BEGIN_OR_BEGIN_DATA( GL_TRIANGLE_STRIP );
- CALL_VERTEX_OR_VERTEX_DATA( e->Org->data );
- CALL_VERTEX_OR_VERTEX_DATA( e->Dst->data );
-
- while( ! Marked( e->Lface )) {
- e->Lface->marked = TRUE;
- --size;
- e = e->Dprev;
- CALL_VERTEX_OR_VERTEX_DATA( e->Org->data );
- if( Marked( e->Lface )) break;
-
- e->Lface->marked = TRUE;
- --size;
- e = e->Onext;
- CALL_VERTEX_OR_VERTEX_DATA( e->Dst->data );
- }
-
- assert( size == 0 );
- CALL_END_OR_END_DATA();
-}
-
-
-/************************ Boundary contour decomposition ******************/
-
-/* __gl_renderBoundary( tess, mesh ) takes a mesh, and outputs one
- * contour for each face marked "inside". The rendering output is
- * provided as callbacks (see the api).
- */
-void __gl_renderBoundary( GLUtesselator *tess, GLUmesh *mesh )
-{
- GLUface *f;
- GLUhalfEdge *e;
-
- for( f = mesh->fHead.next; f != &mesh->fHead; f = f->next ) {
- if( f->inside ) {
- CALL_BEGIN_OR_BEGIN_DATA( GL_LINE_LOOP );
- e = f->anEdge;
- do {
- CALL_VERTEX_OR_VERTEX_DATA( e->Org->data );
- e = e->Lnext;
- } while( e != f->anEdge );
- CALL_END_OR_END_DATA();
- }
- }
-}
-
-
-/************************ Quick-and-dirty decomposition ******************/
-
-#define SIGN_INCONSISTENT 2
-
-static int ComputeNormal( GLUtesselator *tess, GLdouble norm[3], int check )
-/*
- * If check==FALSE, we compute the polygon normal and place it in norm[].
- * If check==TRUE, we check that each triangle in the fan from v0 has a
- * consistent orientation with respect to norm[]. If triangles are
- * consistently oriented CCW, return 1; if CW, return -1; if all triangles
- * are degenerate return 0; otherwise (no consistent orientation) return
- * SIGN_INCONSISTENT.
- */
-{
- CachedVertex *v0 = tess->cache;
- CachedVertex *vn = v0 + tess->cacheCount;
- CachedVertex *vc;
- GLdouble dot, xc, yc, zc, xp, yp, zp, n[3];
- int sign = 0;
-
- /* Find the polygon normal. It is important to get a reasonable
- * normal even when the polygon is self-intersecting (eg. a bowtie).
- * Otherwise, the computed normal could be very tiny, but perpendicular
- * to the true plane of the polygon due to numerical noise. Then all
- * the triangles would appear to be degenerate and we would incorrectly
- * decompose the polygon as a fan (or simply not render it at all).
- *
- * We use a sum-of-triangles normal algorithm rather than the more
- * efficient sum-of-trapezoids method (used in CheckOrientation()
- * in normal.c). This lets us explicitly reverse the signed area
- * of some triangles to get a reasonable normal in the self-intersecting
- * case.
- */
- if( ! check ) {
- norm[0] = norm[1] = norm[2] = 0.0;
- }
-
- vc = v0 + 1;
- xc = vc->coords[0] - v0->coords[0];
- yc = vc->coords[1] - v0->coords[1];
- zc = vc->coords[2] - v0->coords[2];
- while( ++vc < vn ) {
- xp = xc; yp = yc; zp = zc;
- xc = vc->coords[0] - v0->coords[0];
- yc = vc->coords[1] - v0->coords[1];
- zc = vc->coords[2] - v0->coords[2];
-
- /* Compute (vp - v0) cross (vc - v0) */
- n[0] = yp*zc - zp*yc;
- n[1] = zp*xc - xp*zc;
- n[2] = xp*yc - yp*xc;
-
- dot = n[0]*norm[0] + n[1]*norm[1] + n[2]*norm[2];
- if( ! check ) {
- /* Reverse the contribution of back-facing triangles to get
- * a reasonable normal for self-intersecting polygons (see above)
- */
- if( dot >= 0 ) {
- norm[0] += n[0]; norm[1] += n[1]; norm[2] += n[2];
- } else {
- norm[0] -= n[0]; norm[1] -= n[1]; norm[2] -= n[2];
- }
- } else if( dot != 0 ) {
- /* Check the new orientation for consistency with previous triangles */
- if( dot > 0 ) {
- if( sign < 0 ) return SIGN_INCONSISTENT;
- sign = 1;
- } else {
- if( sign > 0 ) return SIGN_INCONSISTENT;
- sign = -1;
- }
- }
- }
- return sign;
-}
-
-/* __gl_renderCache( tess ) takes a single contour and tries to render it
- * as a triangle fan. This handles convex polygons, as well as some
- * non-convex polygons if we get lucky.
- *
- * Returns TRUE if the polygon was successfully rendered. The rendering
- * output is provided as callbacks (see the api).
- */
-GLboolean __gl_renderCache( GLUtesselator *tess )
-{
- CachedVertex *v0 = tess->cache;
- CachedVertex *vn = v0 + tess->cacheCount;
- CachedVertex *vc;
- GLdouble norm[3];
- int sign;
-
- if( tess->cacheCount < 3 ) {
- /* Degenerate contour -- no output */
- return TRUE;
- }
-
- norm[0] = tess->normal[0];
- norm[1] = tess->normal[1];
- norm[2] = tess->normal[2];
- if( norm[0] == 0 && norm[1] == 0 && norm[2] == 0 ) {
- ComputeNormal( tess, norm, FALSE );
- }
-
- sign = ComputeNormal( tess, norm, TRUE );
- if( sign == SIGN_INCONSISTENT ) {
- /* Fan triangles did not have a consistent orientation */
- return FALSE;
- }
- if( sign == 0 ) {
- /* All triangles were degenerate */
- return TRUE;
- }
-
- /* Make sure we do the right thing for each winding rule */
- switch( tess->windingRule ) {
- case GLU_TESS_WINDING_ODD:
- case GLU_TESS_WINDING_NONZERO:
- break;
- case GLU_TESS_WINDING_POSITIVE:
- if( sign < 0 ) return TRUE;
- break;
- case GLU_TESS_WINDING_NEGATIVE:
- if( sign > 0 ) return TRUE;
- break;
- case GLU_TESS_WINDING_ABS_GEQ_TWO:
- return TRUE;
- }
-
- CALL_BEGIN_OR_BEGIN_DATA((unsigned int) (tess->boundaryOnly ? GL_LINE_LOOP
- : (tess->cacheCount > 3) ? GL_TRIANGLE_FAN
- : GL_TRIANGLES) );
-
- CALL_VERTEX_OR_VERTEX_DATA( v0->data );
- if( sign > 0 ) {
- for( vc = v0+1; vc < vn; ++vc ) {
- CALL_VERTEX_OR_VERTEX_DATA( vc->data );
- }
- } else {
- for( vc = vn-1; vc > v0; --vc ) {
- CALL_VERTEX_OR_VERTEX_DATA( vc->data );
- }
- }
- CALL_END_OR_END_DATA();
- return TRUE;
-}
diff --git a/libtess/render.h b/libtess/render.h
deleted file mode 100644
index 972d745..0000000
--- a/libtess/render.h
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __render_h_
-#define __render_h_
-
-#include "mesh.h"
-
-/* __gl_renderMesh( tess, mesh ) takes a mesh and breaks it into triangle
- * fans, strips, and separate triangles. A substantial effort is made
- * to use as few rendering primitives as possible (ie. to make the fans
- * and strips as large as possible).
- *
- * The rendering output is provided as callbacks (see the api).
- */
-void __gl_renderMesh( GLUtesselator *tess, GLUmesh *mesh );
-void __gl_renderBoundary( GLUtesselator *tess, GLUmesh *mesh );
-
-GLboolean __gl_renderCache( GLUtesselator *tess );
-
-#endif
diff --git a/libtess/sweep.c b/libtess/sweep.c
deleted file mode 100644
index 753fd14..0000000
--- a/libtess/sweep.c
+++ /dev/null
@@ -1,1362 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include "gluos.h"
-#include <assert.h>
-#include <stddef.h>
-#include <setjmp.h> /* longjmp */
-#include <limits.h> /* LONG_MAX */
-
-#include "mesh.h"
-#include "geom.h"
-#include "tess.h"
-#include "dict.h"
-#include "priorityq.h"
-#include "memalloc.h"
-#include "sweep.h"
-
-#define TRUE 1
-#define FALSE 0
-
-#ifdef FOR_TRITE_TEST_PROGRAM
-extern void DebugEvent( GLUtesselator *tess );
-#else
-#define DebugEvent( tess )
-#endif
-
-/*
- * Invariants for the Edge Dictionary.
- * - each pair of adjacent edges e2=Succ(e1) satisfies EdgeLeq(e1,e2)
- * at any valid location of the sweep event
- * - if EdgeLeq(e2,e1) as well (at any valid sweep event), then e1 and e2
- * share a common endpoint
- * - for each e, e->Dst has been processed, but not e->Org
- * - each edge e satisfies VertLeq(e->Dst,event) && VertLeq(event,e->Org)
- * where "event" is the current sweep line event.
- * - no edge e has zero length
- *
- * Invariants for the Mesh (the processed portion).
- * - the portion of the mesh left of the sweep line is a planar graph,
- * ie. there is *some* way to embed it in the plane
- * - no processed edge has zero length
- * - no two processed vertices have identical coordinates
- * - each "inside" region is monotone, ie. can be broken into two chains
- * of monotonically increasing vertices according to VertLeq(v1,v2)
- * - a non-invariant: these chains may intersect (very slightly)
- *
- * Invariants for the Sweep.
- * - if none of the edges incident to the event vertex have an activeRegion
- * (ie. none of these edges are in the edge dictionary), then the vertex
- * has only right-going edges.
- * - if an edge is marked "fixUpperEdge" (it is a temporary edge introduced
- * by ConnectRightVertex), then it is the only right-going edge from
- * its associated vertex. (This says that these edges exist only
- * when it is necessary.)
- */
-
-#define MAX(x,y) ((x) >= (y) ? (x) : (y))
-#define MIN(x,y) ((x) <= (y) ? (x) : (y))
-
-/* When we merge two edges into one, we need to compute the combined
- * winding of the new edge.
- */
-#define AddWinding(eDst,eSrc) (eDst->winding += eSrc->winding, \
- eDst->Sym->winding += eSrc->Sym->winding)
-
-static void SweepEvent( GLUtesselator *tess, GLUvertex *vEvent );
-static void WalkDirtyRegions( GLUtesselator *tess, ActiveRegion *regUp );
-static int CheckForRightSplice( GLUtesselator *tess, ActiveRegion *regUp );
-
-static int EdgeLeq( GLUtesselator *tess, ActiveRegion *reg1,
- ActiveRegion *reg2 )
-/*
- * Both edges must be directed from right to left (this is the canonical
- * direction for the upper edge of each region).
- *
- * The strategy is to evaluate a "t" value for each edge at the
- * current sweep line position, given by tess->event. The calculations
- * are designed to be very stable, but of course they are not perfect.
- *
- * Special case: if both edge destinations are at the sweep event,
- * we sort the edges by slope (they would otherwise compare equally).
- */
-{
- GLUvertex *event = tess->event;
- GLUhalfEdge *e1, *e2;
- GLdouble t1, t2;
-
- e1 = reg1->eUp;
- e2 = reg2->eUp;
-
- if( e1->Dst == event ) {
- if( e2->Dst == event ) {
- /* Two edges right of the sweep line which meet at the sweep event.
- * Sort them by slope.
- */
- if( VertLeq( e1->Org, e2->Org )) {
- return EdgeSign( e2->Dst, e1->Org, e2->Org ) <= 0;
- }
- return EdgeSign( e1->Dst, e2->Org, e1->Org ) >= 0;
- }
- return EdgeSign( e2->Dst, event, e2->Org ) <= 0;
- }
- if( e2->Dst == event ) {
- return EdgeSign( e1->Dst, event, e1->Org ) >= 0;
- }
-
- /* General case - compute signed distance *from* e1, e2 to event */
- t1 = EdgeEval( e1->Dst, event, e1->Org );
- t2 = EdgeEval( e2->Dst, event, e2->Org );
- return (t1 >= t2);
-}
-
-
-static void DeleteRegion( GLUtesselator *tess, ActiveRegion *reg )
-{
- if( reg->fixUpperEdge ) {
- /* It was created with zero winding number, so it better be
- * deleted with zero winding number (ie. it better not get merged
- * with a real edge).
- */
- assert( reg->eUp->winding == 0 );
- }
- reg->eUp->activeRegion = NULL;
- dictDelete( tess->dict, reg->nodeUp ); /* __gl_dictListDelete */
- memFree( reg );
-}
-
-
-static int FixUpperEdge( ActiveRegion *reg, GLUhalfEdge *newEdge )
-/*
- * Replace an upper edge which needs fixing (see ConnectRightVertex).
- */
-{
- assert( reg->fixUpperEdge );
- if ( !__gl_meshDelete( reg->eUp ) ) return 0;
- reg->fixUpperEdge = FALSE;
- reg->eUp = newEdge;
- newEdge->activeRegion = reg;
-
- return 1;
-}
-
-static ActiveRegion *TopLeftRegion( ActiveRegion *reg )
-{
- GLUvertex *org = reg->eUp->Org;
- GLUhalfEdge *e;
-
- /* Find the region above the uppermost edge with the same origin */
- do {
- reg = RegionAbove( reg );
- } while( reg->eUp->Org == org );
-
- /* If the edge above was a temporary edge introduced by ConnectRightVertex,
- * now is the time to fix it.
- */
- if( reg->fixUpperEdge ) {
- e = __gl_meshConnect( RegionBelow(reg)->eUp->Sym, reg->eUp->Lnext );
- if (e == NULL) return NULL;
- if ( !FixUpperEdge( reg, e ) ) return NULL;
- reg = RegionAbove( reg );
- }
- return reg;
-}
-
-static ActiveRegion *TopRightRegion( ActiveRegion *reg )
-{
- GLUvertex *dst = reg->eUp->Dst;
-
- /* Find the region above the uppermost edge with the same destination */
- do {
- reg = RegionAbove( reg );
- } while( reg->eUp->Dst == dst );
- return reg;
-}
-
-static ActiveRegion *AddRegionBelow( GLUtesselator *tess,
- ActiveRegion *regAbove,
- GLUhalfEdge *eNewUp )
-/*
- * Add a new active region to the sweep line, *somewhere* below "regAbove"
- * (according to where the new edge belongs in the sweep-line dictionary).
- * The upper edge of the new region will be "eNewUp".
- * Winding number and "inside" flag are not updated.
- */
-{
- ActiveRegion *regNew = (ActiveRegion *)memAlloc( sizeof( ActiveRegion ));
- if (regNew == NULL) longjmp(tess->env,1);
-
- regNew->eUp = eNewUp;
- /* __gl_dictListInsertBefore */
- regNew->nodeUp = dictInsertBefore( tess->dict, regAbove->nodeUp, regNew );
- if (regNew->nodeUp == NULL) longjmp(tess->env,1);
- regNew->fixUpperEdge = FALSE;
- regNew->sentinel = FALSE;
- regNew->dirty = FALSE;
-
- eNewUp->activeRegion = regNew;
- return regNew;
-}
-
-static GLboolean IsWindingInside( GLUtesselator *tess, int n )
-{
- switch( tess->windingRule ) {
- case GLU_TESS_WINDING_ODD:
- return (n & 1);
- case GLU_TESS_WINDING_NONZERO:
- return (n != 0);
- case GLU_TESS_WINDING_POSITIVE:
- return (n > 0);
- case GLU_TESS_WINDING_NEGATIVE:
- return (n < 0);
- case GLU_TESS_WINDING_ABS_GEQ_TWO:
- return (n >= 2) || (n <= -2);
- }
- /*LINTED*/
- assert( FALSE );
- /*NOTREACHED*/
- return GL_FALSE; /* avoid compiler complaints */
-}
-
-
-static void ComputeWinding( GLUtesselator *tess, ActiveRegion *reg )
-{
- reg->windingNumber = RegionAbove(reg)->windingNumber + reg->eUp->winding;
- reg->inside = IsWindingInside( tess, reg->windingNumber );
-}
-
-
-static void FinishRegion( GLUtesselator *tess, ActiveRegion *reg )
-/*
- * Delete a region from the sweep line. This happens when the upper
- * and lower chains of a region meet (at a vertex on the sweep line).
- * The "inside" flag is copied to the appropriate mesh face (we could
- * not do this before -- since the structure of the mesh is always
- * changing, this face may not have even existed until now).
- */
-{
- GLUhalfEdge *e = reg->eUp;
- GLUface *f = e->Lface;
-
- f->inside = reg->inside;
- f->anEdge = e; /* optimization for __gl_meshTessellateMonoRegion() */
- DeleteRegion( tess, reg );
-}
-
-
-static GLUhalfEdge *FinishLeftRegions( GLUtesselator *tess,
- ActiveRegion *regFirst, ActiveRegion *regLast )
-/*
- * We are given a vertex with one or more left-going edges. All affected
- * edges should be in the edge dictionary. Starting at regFirst->eUp,
- * we walk down deleting all regions where both edges have the same
- * origin vOrg. At the same time we copy the "inside" flag from the
- * active region to the face, since at this point each face will belong
- * to at most one region (this was not necessarily true until this point
- * in the sweep). The walk stops at the region above regLast; if regLast
- * is NULL we walk as far as possible. At the same time we relink the
- * mesh if necessary, so that the ordering of edges around vOrg is the
- * same as in the dictionary.
- */
-{
- ActiveRegion *reg, *regPrev;
- GLUhalfEdge *e, *ePrev;
-
- regPrev = regFirst;
- ePrev = regFirst->eUp;
- while( regPrev != regLast ) {
- regPrev->fixUpperEdge = FALSE; /* placement was OK */
- reg = RegionBelow( regPrev );
- e = reg->eUp;
- if( e->Org != ePrev->Org ) {
- if( ! reg->fixUpperEdge ) {
- /* Remove the last left-going edge. Even though there are no further
- * edges in the dictionary with this origin, there may be further
- * such edges in the mesh (if we are adding left edges to a vertex
- * that has already been processed). Thus it is important to call
- * FinishRegion rather than just DeleteRegion.
- */
- FinishRegion( tess, regPrev );
- break;
- }
- /* If the edge below was a temporary edge introduced by
- * ConnectRightVertex, now is the time to fix it.
- */
- e = __gl_meshConnect( ePrev->Lprev, e->Sym );
- if (e == NULL) longjmp(tess->env,1);
- if ( !FixUpperEdge( reg, e ) ) longjmp(tess->env,1);
- }
-
- /* Relink edges so that ePrev->Onext == e */
- if( ePrev->Onext != e ) {
- if ( !__gl_meshSplice( e->Oprev, e ) ) longjmp(tess->env,1);
- if ( !__gl_meshSplice( ePrev, e ) ) longjmp(tess->env,1);
- }
- FinishRegion( tess, regPrev ); /* may change reg->eUp */
- ePrev = reg->eUp;
- regPrev = reg;
- }
- return ePrev;
-}
-
-
-static void AddRightEdges( GLUtesselator *tess, ActiveRegion *regUp,
- GLUhalfEdge *eFirst, GLUhalfEdge *eLast, GLUhalfEdge *eTopLeft,
- GLboolean cleanUp )
-/*
- * Purpose: insert right-going edges into the edge dictionary, and update
- * winding numbers and mesh connectivity appropriately. All right-going
- * edges share a common origin vOrg. Edges are inserted CCW starting at
- * eFirst; the last edge inserted is eLast->Oprev. If vOrg has any
- * left-going edges already processed, then eTopLeft must be the edge
- * such that an imaginary upward vertical segment from vOrg would be
- * contained between eTopLeft->Oprev and eTopLeft; otherwise eTopLeft
- * should be NULL.
- */
-{
- ActiveRegion *reg, *regPrev;
- GLUhalfEdge *e, *ePrev;
- int firstTime = TRUE;
-
- /* Insert the new right-going edges in the dictionary */
- e = eFirst;
- do {
- assert( VertLeq( e->Org, e->Dst ));
- AddRegionBelow( tess, regUp, e->Sym );
- e = e->Onext;
- } while ( e != eLast );
-
- /* Walk *all* right-going edges from e->Org, in the dictionary order,
- * updating the winding numbers of each region, and re-linking the mesh
- * edges to match the dictionary ordering (if necessary).
- */
- if( eTopLeft == NULL ) {
- eTopLeft = RegionBelow( regUp )->eUp->Rprev;
- }
- regPrev = regUp;
- ePrev = eTopLeft;
- for( ;; ) {
- reg = RegionBelow( regPrev );
- e = reg->eUp->Sym;
- if( e->Org != ePrev->Org ) break;
-
- if( e->Onext != ePrev ) {
- /* Unlink e from its current position, and relink below ePrev */
- if ( !__gl_meshSplice( e->Oprev, e ) ) longjmp(tess->env,1);
- if ( !__gl_meshSplice( ePrev->Oprev, e ) ) longjmp(tess->env,1);
- }
- /* Compute the winding number and "inside" flag for the new regions */
- reg->windingNumber = regPrev->windingNumber - e->winding;
- reg->inside = IsWindingInside( tess, reg->windingNumber );
-
- /* Check for two outgoing edges with same slope -- process these
- * before any intersection tests (see example in __gl_computeInterior).
- */
- regPrev->dirty = TRUE;
- if( ! firstTime && CheckForRightSplice( tess, regPrev )) {
- AddWinding( e, ePrev );
- DeleteRegion( tess, regPrev );
- if ( !__gl_meshDelete( ePrev ) ) longjmp(tess->env,1);
- }
- firstTime = FALSE;
- regPrev = reg;
- ePrev = e;
- }
- regPrev->dirty = TRUE;
- assert( regPrev->windingNumber - e->winding == reg->windingNumber );
-
- if( cleanUp ) {
- /* Check for intersections between newly adjacent edges. */
- WalkDirtyRegions( tess, regPrev );
- }
-}
-
-
-static void CallCombine( GLUtesselator *tess, GLUvertex *isect,
- void *data[4], GLfloat weights[4], int needed )
-{
- GLdouble coords[3];
-
- /* Copy coord data in case the callback changes it. */
- coords[0] = isect->coords[0];
- coords[1] = isect->coords[1];
- coords[2] = isect->coords[2];
-
- isect->data = NULL;
- CALL_COMBINE_OR_COMBINE_DATA( coords, data, weights, &isect->data );
- if( isect->data == NULL ) {
- if( ! needed ) {
- isect->data = data[0];
- } else if( ! tess->fatalError ) {
- /* The only way fatal error is when two edges are found to intersect,
- * but the user has not provided the callback necessary to handle
- * generated intersection points.
- */
- CALL_ERROR_OR_ERROR_DATA( GLU_TESS_NEED_COMBINE_CALLBACK );
- tess->fatalError = TRUE;
- }
- }
-}
-
-static void SpliceMergeVertices( GLUtesselator *tess, GLUhalfEdge *e1,
- GLUhalfEdge *e2 )
-/*
- * Two vertices with idential coordinates are combined into one.
- * e1->Org is kept, while e2->Org is discarded.
- */
-{
- void *data[4] = { NULL, NULL, NULL, NULL };
- GLfloat weights[4] = { 0.5, 0.5, 0.0, 0.0 };
-
- data[0] = e1->Org->data;
- data[1] = e2->Org->data;
- CallCombine( tess, e1->Org, data, weights, FALSE );
- if ( !__gl_meshSplice( e1, e2 ) ) longjmp(tess->env,1);
-}
-
-static void VertexWeights( GLUvertex *isect, GLUvertex *org, GLUvertex *dst,
- GLfloat *weights )
-/*
- * Find some weights which describe how the intersection vertex is
- * a linear combination of "org" and "dest". Each of the two edges
- * which generated "isect" is allocated 50% of the weight; each edge
- * splits the weight between its org and dst according to the
- * relative distance to "isect".
- */
-{
- GLdouble t1 = VertL1dist( org, isect );
- GLdouble t2 = VertL1dist( dst, isect );
-
- weights[0] = 0.5 * t2 / (t1 + t2);
- weights[1] = 0.5 * t1 / (t1 + t2);
- isect->coords[0] += weights[0]*org->coords[0] + weights[1]*dst->coords[0];
- isect->coords[1] += weights[0]*org->coords[1] + weights[1]*dst->coords[1];
- isect->coords[2] += weights[0]*org->coords[2] + weights[1]*dst->coords[2];
-}
-
-
-static void GetIntersectData( GLUtesselator *tess, GLUvertex *isect,
- GLUvertex *orgUp, GLUvertex *dstUp,
- GLUvertex *orgLo, GLUvertex *dstLo )
-/*
- * We've computed a new intersection point, now we need a "data" pointer
- * from the user so that we can refer to this new vertex in the
- * rendering callbacks.
- */
-{
- void *data[4];
- GLfloat weights[4];
-
- data[0] = orgUp->data;
- data[1] = dstUp->data;
- data[2] = orgLo->data;
- data[3] = dstLo->data;
-
- isect->coords[0] = isect->coords[1] = isect->coords[2] = 0;
- VertexWeights( isect, orgUp, dstUp, &weights[0] );
- VertexWeights( isect, orgLo, dstLo, &weights[2] );
-
- CallCombine( tess, isect, data, weights, TRUE );
-}
-
-static int CheckForRightSplice( GLUtesselator *tess, ActiveRegion *regUp )
-/*
- * Check the upper and lower edge of "regUp", to make sure that the
- * eUp->Org is above eLo, or eLo->Org is below eUp (depending on which
- * origin is leftmost).
- *
- * The main purpose is to splice right-going edges with the same
- * dest vertex and nearly identical slopes (ie. we can't distinguish
- * the slopes numerically). However the splicing can also help us
- * to recover from numerical errors. For example, suppose at one
- * point we checked eUp and eLo, and decided that eUp->Org is barely
- * above eLo. Then later, we split eLo into two edges (eg. from
- * a splice operation like this one). This can change the result of
- * our test so that now eUp->Org is incident to eLo, or barely below it.
- * We must correct this condition to maintain the dictionary invariants.
- *
- * One possibility is to check these edges for intersection again
- * (ie. CheckForIntersect). This is what we do if possible. However
- * CheckForIntersect requires that tess->event lies between eUp and eLo,
- * so that it has something to fall back on when the intersection
- * calculation gives us an unusable answer. So, for those cases where
- * we can't check for intersection, this routine fixes the problem
- * by just splicing the offending vertex into the other edge.
- * This is a guaranteed solution, no matter how degenerate things get.
- * Basically this is a combinatorial solution to a numerical problem.
- */
-{
- ActiveRegion *regLo = RegionBelow(regUp);
- GLUhalfEdge *eUp = regUp->eUp;
- GLUhalfEdge *eLo = regLo->eUp;
-
- if( VertLeq( eUp->Org, eLo->Org )) {
- if( EdgeSign( eLo->Dst, eUp->Org, eLo->Org ) > 0 ) return FALSE;
-
- /* eUp->Org appears to be below eLo */
- if( ! VertEq( eUp->Org, eLo->Org )) {
- /* Splice eUp->Org into eLo */
- if ( __gl_meshSplitEdge( eLo->Sym ) == NULL) longjmp(tess->env,1);
- if ( !__gl_meshSplice( eUp, eLo->Oprev ) ) longjmp(tess->env,1);
- regUp->dirty = regLo->dirty = TRUE;
-
- } else if( eUp->Org != eLo->Org ) {
- /* merge the two vertices, discarding eUp->Org */
- pqDelete( tess->pq, eUp->Org->pqHandle ); /* __gl_pqSortDelete */
- SpliceMergeVertices( tess, eLo->Oprev, eUp );
- }
- } else {
- if( EdgeSign( eUp->Dst, eLo->Org, eUp->Org ) < 0 ) return FALSE;
-
- /* eLo->Org appears to be above eUp, so splice eLo->Org into eUp */
- RegionAbove(regUp)->dirty = regUp->dirty = TRUE;
- if (__gl_meshSplitEdge( eUp->Sym ) == NULL) longjmp(tess->env,1);
- if ( !__gl_meshSplice( eLo->Oprev, eUp ) ) longjmp(tess->env,1);
- }
- return TRUE;
-}
-
-static int CheckForLeftSplice( GLUtesselator *tess, ActiveRegion *regUp )
-/*
- * Check the upper and lower edge of "regUp", to make sure that the
- * eUp->Dst is above eLo, or eLo->Dst is below eUp (depending on which
- * destination is rightmost).
- *
- * Theoretically, this should always be true. However, splitting an edge
- * into two pieces can change the results of previous tests. For example,
- * suppose at one point we checked eUp and eLo, and decided that eUp->Dst
- * is barely above eLo. Then later, we split eLo into two edges (eg. from
- * a splice operation like this one). This can change the result of
- * the test so that now eUp->Dst is incident to eLo, or barely below it.
- * We must correct this condition to maintain the dictionary invariants
- * (otherwise new edges might get inserted in the wrong place in the
- * dictionary, and bad stuff will happen).
- *
- * We fix the problem by just splicing the offending vertex into the
- * other edge.
- */
-{
- ActiveRegion *regLo = RegionBelow(regUp);
- GLUhalfEdge *eUp = regUp->eUp;
- GLUhalfEdge *eLo = regLo->eUp;
- GLUhalfEdge *e;
-
- assert( ! VertEq( eUp->Dst, eLo->Dst ));
-
- if( VertLeq( eUp->Dst, eLo->Dst )) {
- if( EdgeSign( eUp->Dst, eLo->Dst, eUp->Org ) < 0 ) return FALSE;
-
- /* eLo->Dst is above eUp, so splice eLo->Dst into eUp */
- RegionAbove(regUp)->dirty = regUp->dirty = TRUE;
- e = __gl_meshSplitEdge( eUp );
- if (e == NULL) longjmp(tess->env,1);
- if ( !__gl_meshSplice( eLo->Sym, e ) ) longjmp(tess->env,1);
- e->Lface->inside = regUp->inside;
- } else {
- if( EdgeSign( eLo->Dst, eUp->Dst, eLo->Org ) > 0 ) return FALSE;
-
- /* eUp->Dst is below eLo, so splice eUp->Dst into eLo */
- regUp->dirty = regLo->dirty = TRUE;
- e = __gl_meshSplitEdge( eLo );
- if (e == NULL) longjmp(tess->env,1);
- if ( !__gl_meshSplice( eUp->Lnext, eLo->Sym ) ) longjmp(tess->env,1);
- e->Rface->inside = regUp->inside;
- }
- return TRUE;
-}
-
-
-static int CheckForIntersect( GLUtesselator *tess, ActiveRegion *regUp )
-/*
- * Check the upper and lower edges of the given region to see if
- * they intersect. If so, create the intersection and add it
- * to the data structures.
- *
- * Returns TRUE if adding the new intersection resulted in a recursive
- * call to AddRightEdges(); in this case all "dirty" regions have been
- * checked for intersections, and possibly regUp has been deleted.
- */
-{
- ActiveRegion *regLo = RegionBelow(regUp);
- GLUhalfEdge *eUp = regUp->eUp;
- GLUhalfEdge *eLo = regLo->eUp;
- GLUvertex *orgUp = eUp->Org;
- GLUvertex *orgLo = eLo->Org;
- GLUvertex *dstUp = eUp->Dst;
- GLUvertex *dstLo = eLo->Dst;
- GLdouble tMinUp, tMaxLo;
- GLUvertex isect, *orgMin;
- GLUhalfEdge *e;
-
- assert( ! VertEq( dstLo, dstUp ));
- assert( EdgeSign( dstUp, tess->event, orgUp ) <= 0 );
- assert( EdgeSign( dstLo, tess->event, orgLo ) >= 0 );
- assert( orgUp != tess->event && orgLo != tess->event );
- assert( ! regUp->fixUpperEdge && ! regLo->fixUpperEdge );
-
- if( orgUp == orgLo ) return FALSE; /* right endpoints are the same */
-
- tMinUp = MIN( orgUp->t, dstUp->t );
- tMaxLo = MAX( orgLo->t, dstLo->t );
- if( tMinUp > tMaxLo ) return FALSE; /* t ranges do not overlap */
-
- if( VertLeq( orgUp, orgLo )) {
- if( EdgeSign( dstLo, orgUp, orgLo ) > 0 ) return FALSE;
- } else {
- if( EdgeSign( dstUp, orgLo, orgUp ) < 0 ) return FALSE;
- }
-
- /* At this point the edges intersect, at least marginally */
- DebugEvent( tess );
-
- __gl_edgeIntersect( dstUp, orgUp, dstLo, orgLo, &isect );
- /* The following properties are guaranteed: */
- assert( MIN( orgUp->t, dstUp->t ) <= isect.t );
- assert( isect.t <= MAX( orgLo->t, dstLo->t ));
- assert( MIN( dstLo->s, dstUp->s ) <= isect.s );
- assert( isect.s <= MAX( orgLo->s, orgUp->s ));
-
- if( VertLeq( &isect, tess->event )) {
- /* The intersection point lies slightly to the left of the sweep line,
- * so move it until it''s slightly to the right of the sweep line.
- * (If we had perfect numerical precision, this would never happen
- * in the first place). The easiest and safest thing to do is
- * replace the intersection by tess->event.
- */
- isect.s = tess->event->s;
- isect.t = tess->event->t;
- }
- /* Similarly, if the computed intersection lies to the right of the
- * rightmost origin (which should rarely happen), it can cause
- * unbelievable inefficiency on sufficiently degenerate inputs.
- * (If you have the test program, try running test54.d with the
- * "X zoom" option turned on).
- */
- orgMin = VertLeq( orgUp, orgLo ) ? orgUp : orgLo;
- if( VertLeq( orgMin, &isect )) {
- isect.s = orgMin->s;
- isect.t = orgMin->t;
- }
-
- if( VertEq( &isect, orgUp ) || VertEq( &isect, orgLo )) {
- /* Easy case -- intersection at one of the right endpoints */
- (void) CheckForRightSplice( tess, regUp );
- return FALSE;
- }
-
- if( (! VertEq( dstUp, tess->event )
- && EdgeSign( dstUp, tess->event, &isect ) >= 0)
- || (! VertEq( dstLo, tess->event )
- && EdgeSign( dstLo, tess->event, &isect ) <= 0 ))
- {
- /* Very unusual -- the new upper or lower edge would pass on the
- * wrong side of the sweep event, or through it. This can happen
- * due to very small numerical errors in the intersection calculation.
- */
- if( dstLo == tess->event ) {
- /* Splice dstLo into eUp, and process the new region(s) */
- if (__gl_meshSplitEdge( eUp->Sym ) == NULL) longjmp(tess->env,1);
- if ( !__gl_meshSplice( eLo->Sym, eUp ) ) longjmp(tess->env,1);
- regUp = TopLeftRegion( regUp );
- if (regUp == NULL) longjmp(tess->env,1);
- eUp = RegionBelow(regUp)->eUp;
- FinishLeftRegions( tess, RegionBelow(regUp), regLo );
- AddRightEdges( tess, regUp, eUp->Oprev, eUp, eUp, TRUE );
- return TRUE;
- }
- if( dstUp == tess->event ) {
- /* Splice dstUp into eLo, and process the new region(s) */
- if (__gl_meshSplitEdge( eLo->Sym ) == NULL) longjmp(tess->env,1);
- if ( !__gl_meshSplice( eUp->Lnext, eLo->Oprev ) ) longjmp(tess->env,1);
- regLo = regUp;
- regUp = TopRightRegion( regUp );
- e = RegionBelow(regUp)->eUp->Rprev;
- regLo->eUp = eLo->Oprev;
- eLo = FinishLeftRegions( tess, regLo, NULL );
- AddRightEdges( tess, regUp, eLo->Onext, eUp->Rprev, e, TRUE );
- return TRUE;
- }
- /* Special case: called from ConnectRightVertex. If either
- * edge passes on the wrong side of tess->event, split it
- * (and wait for ConnectRightVertex to splice it appropriately).
- */
- if( EdgeSign( dstUp, tess->event, &isect ) >= 0 ) {
- RegionAbove(regUp)->dirty = regUp->dirty = TRUE;
- if (__gl_meshSplitEdge( eUp->Sym ) == NULL) longjmp(tess->env,1);
- eUp->Org->s = tess->event->s;
- eUp->Org->t = tess->event->t;
- }
- if( EdgeSign( dstLo, tess->event, &isect ) <= 0 ) {
- regUp->dirty = regLo->dirty = TRUE;
- if (__gl_meshSplitEdge( eLo->Sym ) == NULL) longjmp(tess->env,1);
- eLo->Org->s = tess->event->s;
- eLo->Org->t = tess->event->t;
- }
- /* leave the rest for ConnectRightVertex */
- return FALSE;
- }
-
- /* General case -- split both edges, splice into new vertex.
- * When we do the splice operation, the order of the arguments is
- * arbitrary as far as correctness goes. However, when the operation
- * creates a new face, the work done is proportional to the size of
- * the new face. We expect the faces in the processed part of
- * the mesh (ie. eUp->Lface) to be smaller than the faces in the
- * unprocessed original contours (which will be eLo->Oprev->Lface).
- */
- if (__gl_meshSplitEdge( eUp->Sym ) == NULL) longjmp(tess->env,1);
- if (__gl_meshSplitEdge( eLo->Sym ) == NULL) longjmp(tess->env,1);
- if ( !__gl_meshSplice( eLo->Oprev, eUp ) ) longjmp(tess->env,1);
- eUp->Org->s = isect.s;
- eUp->Org->t = isect.t;
- eUp->Org->pqHandle = pqInsert( tess->pq, eUp->Org ); /* __gl_pqSortInsert */
- if (eUp->Org->pqHandle == LONG_MAX) {
- pqDeletePriorityQ(tess->pq); /* __gl_pqSortDeletePriorityQ */
- tess->pq = NULL;
- longjmp(tess->env,1);
- }
- GetIntersectData( tess, eUp->Org, orgUp, dstUp, orgLo, dstLo );
- RegionAbove(regUp)->dirty = regUp->dirty = regLo->dirty = TRUE;
- return FALSE;
-}
-
-static void WalkDirtyRegions( GLUtesselator *tess, ActiveRegion *regUp )
-/*
- * When the upper or lower edge of any region changes, the region is
- * marked "dirty". This routine walks through all the dirty regions
- * and makes sure that the dictionary invariants are satisfied
- * (see the comments at the beginning of this file). Of course
- * new dirty regions can be created as we make changes to restore
- * the invariants.
- */
-{
- ActiveRegion *regLo = RegionBelow(regUp);
- GLUhalfEdge *eUp, *eLo;
-
- for( ;; ) {
- /* Find the lowest dirty region (we walk from the bottom up). */
- while( regLo->dirty ) {
- regUp = regLo;
- regLo = RegionBelow(regLo);
- }
- if( ! regUp->dirty ) {
- regLo = regUp;
- regUp = RegionAbove( regUp );
- if( regUp == NULL || ! regUp->dirty ) {
- /* We've walked all the dirty regions */
- return;
- }
- }
- regUp->dirty = FALSE;
- eUp = regUp->eUp;
- eLo = regLo->eUp;
-
- if( eUp->Dst != eLo->Dst ) {
- /* Check that the edge ordering is obeyed at the Dst vertices. */
- if( CheckForLeftSplice( tess, regUp )) {
-
- /* If the upper or lower edge was marked fixUpperEdge, then
- * we no longer need it (since these edges are needed only for
- * vertices which otherwise have no right-going edges).
- */
- if( regLo->fixUpperEdge ) {
- DeleteRegion( tess, regLo );
- if ( !__gl_meshDelete( eLo ) ) longjmp(tess->env,1);
- regLo = RegionBelow( regUp );
- eLo = regLo->eUp;
- } else if( regUp->fixUpperEdge ) {
- DeleteRegion( tess, regUp );
- if ( !__gl_meshDelete( eUp ) ) longjmp(tess->env,1);
- regUp = RegionAbove( regLo );
- eUp = regUp->eUp;
- }
- }
- }
- if( eUp->Org != eLo->Org ) {
- if( eUp->Dst != eLo->Dst
- && ! regUp->fixUpperEdge && ! regLo->fixUpperEdge
- && (eUp->Dst == tess->event || eLo->Dst == tess->event) )
- {
- /* When all else fails in CheckForIntersect(), it uses tess->event
- * as the intersection location. To make this possible, it requires
- * that tess->event lie between the upper and lower edges, and also
- * that neither of these is marked fixUpperEdge (since in the worst
- * case it might splice one of these edges into tess->event, and
- * violate the invariant that fixable edges are the only right-going
- * edge from their associated vertex).
- */
- if( CheckForIntersect( tess, regUp )) {
- /* WalkDirtyRegions() was called recursively; we're done */
- return;
- }
- } else {
- /* Even though we can't use CheckForIntersect(), the Org vertices
- * may violate the dictionary edge ordering. Check and correct this.
- */
- (void) CheckForRightSplice( tess, regUp );
- }
- }
- if( eUp->Org == eLo->Org && eUp->Dst == eLo->Dst ) {
- /* A degenerate loop consisting of only two edges -- delete it. */
- AddWinding( eLo, eUp );
- DeleteRegion( tess, regUp );
- if ( !__gl_meshDelete( eUp ) ) longjmp(tess->env,1);
- regUp = RegionAbove( regLo );
- }
- }
-}
-
-
-static void ConnectRightVertex( GLUtesselator *tess, ActiveRegion *regUp,
- GLUhalfEdge *eBottomLeft )
-/*
- * Purpose: connect a "right" vertex vEvent (one where all edges go left)
- * to the unprocessed portion of the mesh. Since there are no right-going
- * edges, two regions (one above vEvent and one below) are being merged
- * into one. "regUp" is the upper of these two regions.
- *
- * There are two reasons for doing this (adding a right-going edge):
- * - if the two regions being merged are "inside", we must add an edge
- * to keep them separated (the combined region would not be monotone).
- * - in any case, we must leave some record of vEvent in the dictionary,
- * so that we can merge vEvent with features that we have not seen yet.
- * For example, maybe there is a vertical edge which passes just to
- * the right of vEvent; we would like to splice vEvent into this edge.
- *
- * However, we don't want to connect vEvent to just any vertex. We don''t
- * want the new edge to cross any other edges; otherwise we will create
- * intersection vertices even when the input data had no self-intersections.
- * (This is a bad thing; if the user's input data has no intersections,
- * we don't want to generate any false intersections ourselves.)
- *
- * Our eventual goal is to connect vEvent to the leftmost unprocessed
- * vertex of the combined region (the union of regUp and regLo).
- * But because of unseen vertices with all right-going edges, and also
- * new vertices which may be created by edge intersections, we don''t
- * know where that leftmost unprocessed vertex is. In the meantime, we
- * connect vEvent to the closest vertex of either chain, and mark the region
- * as "fixUpperEdge". This flag says to delete and reconnect this edge
- * to the next processed vertex on the boundary of the combined region.
- * Quite possibly the vertex we connected to will turn out to be the
- * closest one, in which case we won''t need to make any changes.
- */
-{
- GLUhalfEdge *eNew;
- GLUhalfEdge *eTopLeft = eBottomLeft->Onext;
- ActiveRegion *regLo = RegionBelow(regUp);
- GLUhalfEdge *eUp = regUp->eUp;
- GLUhalfEdge *eLo = regLo->eUp;
- int degenerate = FALSE;
-
- if( eUp->Dst != eLo->Dst ) {
- (void) CheckForIntersect( tess, regUp );
- }
-
- /* Possible new degeneracies: upper or lower edge of regUp may pass
- * through vEvent, or may coincide with new intersection vertex
- */
- if( VertEq( eUp->Org, tess->event )) {
- if ( !__gl_meshSplice( eTopLeft->Oprev, eUp ) ) longjmp(tess->env,1);
- regUp = TopLeftRegion( regUp );
- if (regUp == NULL) longjmp(tess->env,1);
- eTopLeft = RegionBelow( regUp )->eUp;
- FinishLeftRegions( tess, RegionBelow(regUp), regLo );
- degenerate = TRUE;
- }
- if( VertEq( eLo->Org, tess->event )) {
- if ( !__gl_meshSplice( eBottomLeft, eLo->Oprev ) ) longjmp(tess->env,1);
- eBottomLeft = FinishLeftRegions( tess, regLo, NULL );
- degenerate = TRUE;
- }
- if( degenerate ) {
- AddRightEdges( tess, regUp, eBottomLeft->Onext, eTopLeft, eTopLeft, TRUE );
- return;
- }
-
- /* Non-degenerate situation -- need to add a temporary, fixable edge.
- * Connect to the closer of eLo->Org, eUp->Org.
- */
- if( VertLeq( eLo->Org, eUp->Org )) {
- eNew = eLo->Oprev;
- } else {
- eNew = eUp;
- }
- eNew = __gl_meshConnect( eBottomLeft->Lprev, eNew );
- if (eNew == NULL) longjmp(tess->env,1);
-
- /* Prevent cleanup, otherwise eNew might disappear before we've even
- * had a chance to mark it as a temporary edge.
- */
- AddRightEdges( tess, regUp, eNew, eNew->Onext, eNew->Onext, FALSE );
- eNew->Sym->activeRegion->fixUpperEdge = TRUE;
- WalkDirtyRegions( tess, regUp );
-}
-
-/* Because vertices at exactly the same location are merged together
- * before we process the sweep event, some degenerate cases can't occur.
- * However if someone eventually makes the modifications required to
- * merge features which are close together, the cases below marked
- * TOLERANCE_NONZERO will be useful. They were debugged before the
- * code to merge identical vertices in the main loop was added.
- */
-#define TOLERANCE_NONZERO FALSE
-
-static void ConnectLeftDegenerate( GLUtesselator *tess,
- ActiveRegion *regUp, GLUvertex *vEvent )
-/*
- * The event vertex lies exacty on an already-processed edge or vertex.
- * Adding the new vertex involves splicing it into the already-processed
- * part of the mesh.
- */
-{
- GLUhalfEdge *e, *eTopLeft, *eTopRight, *eLast;
- ActiveRegion *reg;
-
- e = regUp->eUp;
- if( VertEq( e->Org, vEvent )) {
- /* e->Org is an unprocessed vertex - just combine them, and wait
- * for e->Org to be pulled from the queue
- */
- assert( TOLERANCE_NONZERO );
- SpliceMergeVertices( tess, e, vEvent->anEdge );
- return;
- }
-
- if( ! VertEq( e->Dst, vEvent )) {
- /* General case -- splice vEvent into edge e which passes through it */
- if (__gl_meshSplitEdge( e->Sym ) == NULL) longjmp(tess->env,1);
- if( regUp->fixUpperEdge ) {
- /* This edge was fixable -- delete unused portion of original edge */
- if ( !__gl_meshDelete( e->Onext ) ) longjmp(tess->env,1);
- regUp->fixUpperEdge = FALSE;
- }
- if ( !__gl_meshSplice( vEvent->anEdge, e ) ) longjmp(tess->env,1);
- SweepEvent( tess, vEvent ); /* recurse */
- return;
- }
-
- /* vEvent coincides with e->Dst, which has already been processed.
- * Splice in the additional right-going edges.
- */
- assert( TOLERANCE_NONZERO );
- regUp = TopRightRegion( regUp );
- reg = RegionBelow( regUp );
- eTopRight = reg->eUp->Sym;
- eTopLeft = eLast = eTopRight->Onext;
- if( reg->fixUpperEdge ) {
- /* Here e->Dst has only a single fixable edge going right.
- * We can delete it since now we have some real right-going edges.
- */
- assert( eTopLeft != eTopRight ); /* there are some left edges too */
- DeleteRegion( tess, reg );
- if ( !__gl_meshDelete( eTopRight ) ) longjmp(tess->env,1);
- eTopRight = eTopLeft->Oprev;
- }
- if ( !__gl_meshSplice( vEvent->anEdge, eTopRight ) ) longjmp(tess->env,1);
- if( ! EdgeGoesLeft( eTopLeft )) {
- /* e->Dst had no left-going edges -- indicate this to AddRightEdges() */
- eTopLeft = NULL;
- }
- AddRightEdges( tess, regUp, eTopRight->Onext, eLast, eTopLeft, TRUE );
-}
-
-
-static void ConnectLeftVertex( GLUtesselator *tess, GLUvertex *vEvent )
-/*
- * Purpose: connect a "left" vertex (one where both edges go right)
- * to the processed portion of the mesh. Let R be the active region
- * containing vEvent, and let U and L be the upper and lower edge
- * chains of R. There are two possibilities:
- *
- * - the normal case: split R into two regions, by connecting vEvent to
- * the rightmost vertex of U or L lying to the left of the sweep line
- *
- * - the degenerate case: if vEvent is close enough to U or L, we
- * merge vEvent into that edge chain. The subcases are:
- * - merging with the rightmost vertex of U or L
- * - merging with the active edge of U or L
- * - merging with an already-processed portion of U or L
- */
-{
- ActiveRegion *regUp, *regLo, *reg;
- GLUhalfEdge *eUp, *eLo, *eNew;
- ActiveRegion tmp;
-
- /* assert( vEvent->anEdge->Onext->Onext == vEvent->anEdge ); */
-
- /* Get a pointer to the active region containing vEvent */
- tmp.eUp = vEvent->anEdge->Sym;
- /* __GL_DICTLISTKEY */ /* __gl_dictListSearch */
- regUp = (ActiveRegion *)dictKey( dictSearch( tess->dict, &tmp ));
- regLo = RegionBelow( regUp );
- eUp = regUp->eUp;
- eLo = regLo->eUp;
-
- /* Try merging with U or L first */
- if( EdgeSign( eUp->Dst, vEvent, eUp->Org ) == 0 ) {
- ConnectLeftDegenerate( tess, regUp, vEvent );
- return;
- }
-
- /* Connect vEvent to rightmost processed vertex of either chain.
- * e->Dst is the vertex that we will connect to vEvent.
- */
- reg = VertLeq( eLo->Dst, eUp->Dst ) ? regUp : regLo;
-
- if( regUp->inside || reg->fixUpperEdge) {
- if( reg == regUp ) {
- eNew = __gl_meshConnect( vEvent->anEdge->Sym, eUp->Lnext );
- if (eNew == NULL) longjmp(tess->env,1);
- } else {
- GLUhalfEdge *tempHalfEdge= __gl_meshConnect( eLo->Dnext, vEvent->anEdge);
- if (tempHalfEdge == NULL) longjmp(tess->env,1);
-
- eNew = tempHalfEdge->Sym;
- }
- if( reg->fixUpperEdge ) {
- if ( !FixUpperEdge( reg, eNew ) ) longjmp(tess->env,1);
- } else {
- ComputeWinding( tess, AddRegionBelow( tess, regUp, eNew ));
- }
- SweepEvent( tess, vEvent );
- } else {
- /* The new vertex is in a region which does not belong to the polygon.
- * We don''t need to connect this vertex to the rest of the mesh.
- */
- AddRightEdges( tess, regUp, vEvent->anEdge, vEvent->anEdge, NULL, TRUE );
- }
-}
-
-
-static void SweepEvent( GLUtesselator *tess, GLUvertex *vEvent )
-/*
- * Does everything necessary when the sweep line crosses a vertex.
- * Updates the mesh and the edge dictionary.
- */
-{
- ActiveRegion *regUp, *reg;
- GLUhalfEdge *e, *eTopLeft, *eBottomLeft;
-
- tess->event = vEvent; /* for access in EdgeLeq() */
- DebugEvent( tess );
-
- /* Check if this vertex is the right endpoint of an edge that is
- * already in the dictionary. In this case we don't need to waste
- * time searching for the location to insert new edges.
- */
- e = vEvent->anEdge;
- while( e->activeRegion == NULL ) {
- e = e->Onext;
- if( e == vEvent->anEdge ) {
- /* All edges go right -- not incident to any processed edges */
- ConnectLeftVertex( tess, vEvent );
- return;
- }
- }
-
- /* Processing consists of two phases: first we "finish" all the
- * active regions where both the upper and lower edges terminate
- * at vEvent (ie. vEvent is closing off these regions).
- * We mark these faces "inside" or "outside" the polygon according
- * to their winding number, and delete the edges from the dictionary.
- * This takes care of all the left-going edges from vEvent.
- */
- regUp = TopLeftRegion( e->activeRegion );
- if (regUp == NULL) longjmp(tess->env,1);
- reg = RegionBelow( regUp );
- eTopLeft = reg->eUp;
- eBottomLeft = FinishLeftRegions( tess, reg, NULL );
-
- /* Next we process all the right-going edges from vEvent. This
- * involves adding the edges to the dictionary, and creating the
- * associated "active regions" which record information about the
- * regions between adjacent dictionary edges.
- */
- if( eBottomLeft->Onext == eTopLeft ) {
- /* No right-going edges -- add a temporary "fixable" edge */
- ConnectRightVertex( tess, regUp, eBottomLeft );
- } else {
- AddRightEdges( tess, regUp, eBottomLeft->Onext, eTopLeft, eTopLeft, TRUE );
- }
-}
-
-
-/* Make the sentinel coordinates big enough that they will never be
- * merged with real input features. (Even with the largest possible
- * input contour and the maximum tolerance of 1.0, no merging will be
- * done with coordinates larger than 3 * GLU_TESS_MAX_COORD).
- */
-#define SENTINEL_COORD (4 * GLU_TESS_MAX_COORD)
-
-static void AddSentinel( GLUtesselator *tess, GLdouble t )
-/*
- * We add two sentinel edges above and below all other edges,
- * to avoid special cases at the top and bottom.
- */
-{
- GLUhalfEdge *e;
- ActiveRegion *reg = (ActiveRegion *)memAlloc( sizeof( ActiveRegion ));
- if (reg == NULL) longjmp(tess->env,1);
-
- e = __gl_meshMakeEdge( tess->mesh );
- if (e == NULL) longjmp(tess->env,1);
-
- e->Org->s = SENTINEL_COORD;
- e->Org->t = t;
- e->Dst->s = -SENTINEL_COORD;
- e->Dst->t = t;
- tess->event = e->Dst; /* initialize it */
-
- reg->eUp = e;
- reg->windingNumber = 0;
- reg->inside = FALSE;
- reg->fixUpperEdge = FALSE;
- reg->sentinel = TRUE;
- reg->dirty = FALSE;
- reg->nodeUp = dictInsert( tess->dict, reg ); /* __gl_dictListInsertBefore */
- if (reg->nodeUp == NULL) longjmp(tess->env,1);
-}
-
-
-static void InitEdgeDict( GLUtesselator *tess )
-/*
- * We maintain an ordering of edge intersections with the sweep line.
- * This order is maintained in a dynamic dictionary.
- */
-{
- /* __gl_dictListNewDict */
- tess->dict = dictNewDict( tess, (int (*)(void *, DictKey, DictKey)) EdgeLeq );
- if (tess->dict == NULL) longjmp(tess->env,1);
-
- AddSentinel( tess, -SENTINEL_COORD );
- AddSentinel( tess, SENTINEL_COORD );
-}
-
-
-static void DoneEdgeDict( GLUtesselator *tess )
-{
- ActiveRegion *reg;
-#ifndef NDEBUG
- int fixedEdges = 0;
-#endif
-
- /* __GL_DICTLISTKEY */ /* __GL_DICTLISTMIN */
- while( (reg = (ActiveRegion *)dictKey( dictMin( tess->dict ))) != NULL ) {
- /*
- * At the end of all processing, the dictionary should contain
- * only the two sentinel edges, plus at most one "fixable" edge
- * created by ConnectRightVertex().
- */
- if( ! reg->sentinel ) {
- assert( reg->fixUpperEdge );
- assert( ++fixedEdges == 1 );
- }
- assert( reg->windingNumber == 0 );
- DeleteRegion( tess, reg );
-/* __gl_meshDelete( reg->eUp );*/
- }
- dictDeleteDict( tess->dict ); /* __gl_dictListDeleteDict */
-}
-
-
-static void RemoveDegenerateEdges( GLUtesselator *tess )
-/*
- * Remove zero-length edges, and contours with fewer than 3 vertices.
- */
-{
- GLUhalfEdge *e, *eNext, *eLnext;
- GLUhalfEdge *eHead = &tess->mesh->eHead;
-
- /*LINTED*/
- for( e = eHead->next; e != eHead; e = eNext ) {
- eNext = e->next;
- eLnext = e->Lnext;
-
- if( VertEq( e->Org, e->Dst ) && e->Lnext->Lnext != e ) {
- /* Zero-length edge, contour has at least 3 edges */
-
- SpliceMergeVertices( tess, eLnext, e ); /* deletes e->Org */
- if ( !__gl_meshDelete( e ) ) longjmp(tess->env,1); /* e is a self-loop */
- e = eLnext;
- eLnext = e->Lnext;
- }
- if( eLnext->Lnext == e ) {
- /* Degenerate contour (one or two edges) */
-
- if( eLnext != e ) {
- if( eLnext == eNext || eLnext == eNext->Sym ) { eNext = eNext->next; }
- if ( !__gl_meshDelete( eLnext ) ) longjmp(tess->env,1);
- }
- if( e == eNext || e == eNext->Sym ) { eNext = eNext->next; }
- if ( !__gl_meshDelete( e ) ) longjmp(tess->env,1);
- }
- }
-}
-
-static int InitPriorityQ( GLUtesselator *tess )
-/*
- * Insert all vertices into the priority queue which determines the
- * order in which vertices cross the sweep line.
- */
-{
- PriorityQ *pq;
- GLUvertex *v, *vHead;
-
- /* __gl_pqSortNewPriorityQ */
- pq = tess->pq = pqNewPriorityQ( (int (*)(PQkey, PQkey)) __gl_vertLeq );
- if (pq == NULL) return 0;
-
- vHead = &tess->mesh->vHead;
- for( v = vHead->next; v != vHead; v = v->next ) {
- v->pqHandle = pqInsert( pq, v ); /* __gl_pqSortInsert */
- if (v->pqHandle == LONG_MAX) break;
- }
- if (v != vHead || !pqInit( pq ) ) { /* __gl_pqSortInit */
- pqDeletePriorityQ(tess->pq); /* __gl_pqSortDeletePriorityQ */
- tess->pq = NULL;
- return 0;
- }
-
- return 1;
-}
-
-
-static void DonePriorityQ( GLUtesselator *tess )
-{
- pqDeletePriorityQ( tess->pq ); /* __gl_pqSortDeletePriorityQ */
-}
-
-
-static int RemoveDegenerateFaces( GLUmesh *mesh )
-/*
- * Delete any degenerate faces with only two edges. WalkDirtyRegions()
- * will catch almost all of these, but it won't catch degenerate faces
- * produced by splice operations on already-processed edges.
- * The two places this can happen are in FinishLeftRegions(), when
- * we splice in a "temporary" edge produced by ConnectRightVertex(),
- * and in CheckForLeftSplice(), where we splice already-processed
- * edges to ensure that our dictionary invariants are not violated
- * by numerical errors.
- *
- * In both these cases it is *very* dangerous to delete the offending
- * edge at the time, since one of the routines further up the stack
- * will sometimes be keeping a pointer to that edge.
- */
-{
- GLUface *f, *fNext;
- GLUhalfEdge *e;
-
- /*LINTED*/
- for( f = mesh->fHead.next; f != &mesh->fHead; f = fNext ) {
- fNext = f->next;
- e = f->anEdge;
- assert( e->Lnext != e );
-
- if( e->Lnext->Lnext == e ) {
- /* A face with only two edges */
- AddWinding( e->Onext, e );
- if ( !__gl_meshDelete( e ) ) return 0;
- }
- }
- return 1;
-}
-
-int __gl_computeInterior( GLUtesselator *tess )
-/*
- * __gl_computeInterior( tess ) computes the planar arrangement specified
- * by the given contours, and further subdivides this arrangement
- * into regions. Each region is marked "inside" if it belongs
- * to the polygon, according to the rule given by tess->windingRule.
- * Each interior region is guaranteed be monotone.
- */
-{
- GLUvertex *v, *vNext;
-
- tess->fatalError = FALSE;
-
- /* Each vertex defines an event for our sweep line. Start by inserting
- * all the vertices in a priority queue. Events are processed in
- * lexicographic order, ie.
- *
- * e1 < e2 iff e1.x < e2.x || (e1.x == e2.x && e1.y < e2.y)
- */
- RemoveDegenerateEdges( tess );
- if ( !InitPriorityQ( tess ) ) return 0; /* if error */
- InitEdgeDict( tess );
-
- /* __gl_pqSortExtractMin */
- while( (v = (GLUvertex *)pqExtractMin( tess->pq )) != NULL ) {
- for( ;; ) {
- vNext = (GLUvertex *)pqMinimum( tess->pq ); /* __gl_pqSortMinimum */
- if( vNext == NULL || ! VertEq( vNext, v )) break;
-
- /* Merge together all vertices at exactly the same location.
- * This is more efficient than processing them one at a time,
- * simplifies the code (see ConnectLeftDegenerate), and is also
- * important for correct handling of certain degenerate cases.
- * For example, suppose there are two identical edges A and B
- * that belong to different contours (so without this code they would
- * be processed by separate sweep events). Suppose another edge C
- * crosses A and B from above. When A is processed, we split it
- * at its intersection point with C. However this also splits C,
- * so when we insert B we may compute a slightly different
- * intersection point. This might leave two edges with a small
- * gap between them. This kind of error is especially obvious
- * when using boundary extraction (GLU_TESS_BOUNDARY_ONLY).
- */
- vNext = (GLUvertex *)pqExtractMin( tess->pq ); /* __gl_pqSortExtractMin*/
- SpliceMergeVertices( tess, v->anEdge, vNext->anEdge );
- }
- SweepEvent( tess, v );
- }
-
- /* Set tess->event for debugging purposes */
- /* __GL_DICTLISTKEY */ /* __GL_DICTLISTMIN */
- tess->event = ((ActiveRegion *) dictKey( dictMin( tess->dict )))->eUp->Org;
- DebugEvent( tess );
- DoneEdgeDict( tess );
- DonePriorityQ( tess );
-
- if ( !RemoveDegenerateFaces( tess->mesh ) ) return 0;
- __gl_meshCheckMesh( tess->mesh );
-
- return 1;
-}
diff --git a/libtess/sweep.h b/libtess/sweep.h
deleted file mode 100644
index a4ccbf0..0000000
--- a/libtess/sweep.h
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __sweep_h_
-#define __sweep_h_
-
-#include "mesh.h"
-
-/* __gl_computeInterior( tess ) computes the planar arrangement specified
- * by the given contours, and further subdivides this arrangement
- * into regions. Each region is marked "inside" if it belongs
- * to the polygon, according to the rule given by tess->windingRule.
- * Each interior region is guaranteed be monotone.
- */
-int __gl_computeInterior( GLUtesselator *tess );
-
-
-/* The following is here *only* for access by debugging routines */
-
-#include "dict.h"
-
-/* For each pair of adjacent edges crossing the sweep line, there is
- * an ActiveRegion to represent the region between them. The active
- * regions are kept in sorted order in a dynamic dictionary. As the
- * sweep line crosses each vertex, we update the affected regions.
- */
-
-struct ActiveRegion {
- GLUhalfEdge *eUp; /* upper edge, directed right to left */
- DictNode *nodeUp; /* dictionary node corresponding to eUp */
- int windingNumber; /* used to determine which regions are
- * inside the polygon */
- GLboolean inside; /* is this region inside the polygon? */
- GLboolean sentinel; /* marks fake edges at t = +/-infinity */
- GLboolean dirty; /* marks regions where the upper or lower
- * edge has changed, but we haven't checked
- * whether they intersect yet */
- GLboolean fixUpperEdge; /* marks temporary edges introduced when
- * we process a "right vertex" (one without
- * any edges leaving to the right) */
-};
-
-#define RegionBelow(r) ((ActiveRegion *) dictKey(dictPred((r)->nodeUp)))
-#define RegionAbove(r) ((ActiveRegion *) dictKey(dictSucc((r)->nodeUp)))
-
-#endif
diff --git a/libtess/tess.c b/libtess/tess.c
deleted file mode 100644
index 17cc56f..0000000
--- a/libtess/tess.c
+++ /dev/null
@@ -1,634 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include "gluos.h"
-#include <stddef.h>
-#include <assert.h>
-#include <setjmp.h>
-#include "memalloc.h"
-#include "tess.h"
-#include "mesh.h"
-#include "normal.h"
-#include "sweep.h"
-#include "tessmono.h"
-#include "render.h"
-
-#define GLU_TESS_DEFAULT_TOLERANCE 0.0
-#define GLU_TESS_MESH 100112 /* void (*)(GLUmesh *mesh) */
-
-#define TRUE 1
-#define FALSE 0
-
-/*ARGSUSED*/ static void GLAPIENTRY noBegin( GLenum type ) {}
-/*ARGSUSED*/ static void GLAPIENTRY noEdgeFlag( GLboolean boundaryEdge ) {}
-/*ARGSUSED*/ static void GLAPIENTRY noVertex( void *data ) {}
-/*ARGSUSED*/ static void GLAPIENTRY noEnd( void ) {}
-/*ARGSUSED*/ static void GLAPIENTRY noError( GLenum errnum ) {}
-/*ARGSUSED*/ static void GLAPIENTRY noCombine( GLdouble coords[3], void *data[4],
- GLfloat weight[4], void **dataOut ) {}
-/*ARGSUSED*/ static void GLAPIENTRY noMesh( GLUmesh *mesh ) {}
-
-
-/*ARGSUSED*/ void GLAPIENTRY __gl_noBeginData( GLenum type,
- void *polygonData ) {}
-/*ARGSUSED*/ void GLAPIENTRY __gl_noEdgeFlagData( GLboolean boundaryEdge,
- void *polygonData ) {}
-/*ARGSUSED*/ void GLAPIENTRY __gl_noVertexData( void *data,
- void *polygonData ) {}
-/*ARGSUSED*/ void GLAPIENTRY __gl_noEndData( void *polygonData ) {}
-/*ARGSUSED*/ void GLAPIENTRY __gl_noErrorData( GLenum errnum,
- void *polygonData ) {}
-/*ARGSUSED*/ void GLAPIENTRY __gl_noCombineData( GLdouble coords[3],
- void *data[4],
- GLfloat weight[4],
- void **outData,
- void *polygonData ) {}
-
-/* Half-edges are allocated in pairs (see mesh.c) */
-typedef struct { GLUhalfEdge e, eSym; } EdgePair;
-
-#define MAX(a,b) ((a) > (b) ? (a) : (b))
-#define MAX_FAST_ALLOC (MAX(sizeof(EdgePair), \
- MAX(sizeof(GLUvertex),sizeof(GLUface))))
-
-
-GLUtesselator * GLAPIENTRY
-gluNewTess( void )
-{
- GLUtesselator *tess;
-
- /* Only initialize fields which can be changed by the api. Other fields
- * are initialized where they are used.
- */
-
- if (memInit( MAX_FAST_ALLOC ) == 0) {
- return 0; /* out of memory */
- }
- tess = (GLUtesselator *)memAlloc( sizeof( GLUtesselator ));
- if (tess == NULL) {
- return 0; /* out of memory */
- }
-
- tess->state = T_DORMANT;
-
- tess->normal[0] = 0;
- tess->normal[1] = 0;
- tess->normal[2] = 0;
-
- tess->relTolerance = GLU_TESS_DEFAULT_TOLERANCE;
- tess->windingRule = GLU_TESS_WINDING_ODD;
- tess->flagBoundary = FALSE;
- tess->boundaryOnly = FALSE;
-
- tess->callBegin = &noBegin;
- tess->callEdgeFlag = &noEdgeFlag;
- tess->callVertex = &noVertex;
- tess->callEnd = &noEnd;
-
- tess->callError = &noError;
- tess->callCombine = &noCombine;
- tess->callMesh = &noMesh;
-
- tess->callBeginData= &__gl_noBeginData;
- tess->callEdgeFlagData= &__gl_noEdgeFlagData;
- tess->callVertexData= &__gl_noVertexData;
- tess->callEndData= &__gl_noEndData;
- tess->callErrorData= &__gl_noErrorData;
- tess->callCombineData= &__gl_noCombineData;
-
- tess->polygonData= NULL;
-
- return tess;
-}
-
-static void MakeDormant( GLUtesselator *tess )
-{
- /* Return the tessellator to its original dormant state. */
-
- if( tess->mesh != NULL ) {
- __gl_meshDeleteMesh( tess->mesh );
- }
- tess->state = T_DORMANT;
- tess->lastEdge = NULL;
- tess->mesh = NULL;
-}
-
-#define RequireState( tess, s ) if( tess->state != s ) GotoState(tess,s)
-
-static void GotoState( GLUtesselator *tess, enum TessState newState )
-{
- while( tess->state != newState ) {
- /* We change the current state one level at a time, to get to
- * the desired state.
- */
- if( tess->state < newState ) {
- switch( tess->state ) {
- case T_DORMANT:
- CALL_ERROR_OR_ERROR_DATA( GLU_TESS_MISSING_BEGIN_POLYGON );
- gluTessBeginPolygon( tess, NULL );
- break;
- case T_IN_POLYGON:
- CALL_ERROR_OR_ERROR_DATA( GLU_TESS_MISSING_BEGIN_CONTOUR );
- gluTessBeginContour( tess );
- break;
- default:
- ;
- }
- } else {
- switch( tess->state ) {
- case T_IN_CONTOUR:
- CALL_ERROR_OR_ERROR_DATA( GLU_TESS_MISSING_END_CONTOUR );
- gluTessEndContour( tess );
- break;
- case T_IN_POLYGON:
- CALL_ERROR_OR_ERROR_DATA( GLU_TESS_MISSING_END_POLYGON );
- /* gluTessEndPolygon( tess ) is too much work! */
- MakeDormant( tess );
- break;
- default:
- ;
- }
- }
- }
-}
-
-
-void GLAPIENTRY
-gluDeleteTess( GLUtesselator *tess )
-{
- RequireState( tess, T_DORMANT );
- memFree( tess );
-}
-
-
-void GLAPIENTRY
-gluTessProperty( GLUtesselator *tess, GLenum which, GLdouble value )
-{
- GLenum windingRule;
-
- switch( which ) {
- case GLU_TESS_TOLERANCE:
- if( value < 0.0 || value > 1.0 ) break;
- tess->relTolerance = value;
- return;
-
- case GLU_TESS_WINDING_RULE:
- windingRule = (GLenum) value;
- if( windingRule != value ) break; /* not an integer */
-
- switch( windingRule ) {
- case GLU_TESS_WINDING_ODD:
- case GLU_TESS_WINDING_NONZERO:
- case GLU_TESS_WINDING_POSITIVE:
- case GLU_TESS_WINDING_NEGATIVE:
- case GLU_TESS_WINDING_ABS_GEQ_TWO:
- tess->windingRule = windingRule;
- return;
- default:
- break;
- }
-
- case GLU_TESS_BOUNDARY_ONLY:
- tess->boundaryOnly = (value != 0);
- return;
-
- default:
- CALL_ERROR_OR_ERROR_DATA( GLU_INVALID_ENUM );
- return;
- }
- CALL_ERROR_OR_ERROR_DATA( GLU_INVALID_VALUE );
-}
-
-/* Returns tessellator property */
-void GLAPIENTRY
-gluGetTessProperty( GLUtesselator *tess, GLenum which, GLdouble *value )
-{
- switch (which) {
- case GLU_TESS_TOLERANCE:
- /* tolerance should be in range [0..1] */
- assert(0.0 <= tess->relTolerance && tess->relTolerance <= 1.0);
- *value= tess->relTolerance;
- break;
- case GLU_TESS_WINDING_RULE:
- assert(tess->windingRule == GLU_TESS_WINDING_ODD ||
- tess->windingRule == GLU_TESS_WINDING_NONZERO ||
- tess->windingRule == GLU_TESS_WINDING_POSITIVE ||
- tess->windingRule == GLU_TESS_WINDING_NEGATIVE ||
- tess->windingRule == GLU_TESS_WINDING_ABS_GEQ_TWO);
- *value= tess->windingRule;
- break;
- case GLU_TESS_BOUNDARY_ONLY:
- assert(tess->boundaryOnly == TRUE || tess->boundaryOnly == FALSE);
- *value= tess->boundaryOnly;
- break;
- default:
- *value= 0.0;
- CALL_ERROR_OR_ERROR_DATA( GLU_INVALID_ENUM );
- break;
- }
-} /* gluGetTessProperty() */
-
-void GLAPIENTRY
-gluTessNormal( GLUtesselator *tess, GLdouble x, GLdouble y, GLdouble z )
-{
- tess->normal[0] = x;
- tess->normal[1] = y;
- tess->normal[2] = z;
-}
-
-void GLAPIENTRY
-gluTessCallback( GLUtesselator *tess, GLenum which, _GLUfuncptr fn)
-{
- switch( which ) {
- case GLU_TESS_BEGIN:
- tess->callBegin = (fn == NULL) ? &noBegin : (void (GLAPIENTRY *)(GLenum)) fn;
- return;
- case GLU_TESS_BEGIN_DATA:
- tess->callBeginData = (fn == NULL) ?
- &__gl_noBeginData : (void (GLAPIENTRY *)(GLenum, void *)) fn;
- return;
- case GLU_TESS_EDGE_FLAG:
- tess->callEdgeFlag = (fn == NULL) ? &noEdgeFlag :
- (void (GLAPIENTRY *)(GLboolean)) fn;
- /* If the client wants boundary edges to be flagged,
- * we render everything as separate triangles (no strips or fans).
- */
- tess->flagBoundary = (fn != NULL);
- return;
- case GLU_TESS_EDGE_FLAG_DATA:
- tess->callEdgeFlagData= (fn == NULL) ?
- &__gl_noEdgeFlagData : (void (GLAPIENTRY *)(GLboolean, void *)) fn;
- /* If the client wants boundary edges to be flagged,
- * we render everything as separate triangles (no strips or fans).
- */
- tess->flagBoundary = (fn != NULL);
- return;
- case GLU_TESS_VERTEX:
- tess->callVertex = (fn == NULL) ? &noVertex :
- (void (GLAPIENTRY *)(void *)) fn;
- return;
- case GLU_TESS_VERTEX_DATA:
- tess->callVertexData = (fn == NULL) ?
- &__gl_noVertexData : (void (GLAPIENTRY *)(void *, void *)) fn;
- return;
- case GLU_TESS_END:
- tess->callEnd = (fn == NULL) ? &noEnd : (void (GLAPIENTRY *)(void)) fn;
- return;
- case GLU_TESS_END_DATA:
- tess->callEndData = (fn == NULL) ? &__gl_noEndData :
- (void (GLAPIENTRY *)(void *)) fn;
- return;
- case GLU_TESS_ERROR:
- tess->callError = (fn == NULL) ? &noError : (void (GLAPIENTRY *)(GLenum)) fn;
- return;
- case GLU_TESS_ERROR_DATA:
- tess->callErrorData = (fn == NULL) ?
- &__gl_noErrorData : (void (GLAPIENTRY *)(GLenum, void *)) fn;
- return;
- case GLU_TESS_COMBINE:
- tess->callCombine = (fn == NULL) ? &noCombine :
- (void (GLAPIENTRY *)(GLdouble [3],void *[4], GLfloat [4], void ** )) fn;
- return;
- case GLU_TESS_COMBINE_DATA:
- tess->callCombineData = (fn == NULL) ? &__gl_noCombineData :
- (void (GLAPIENTRY *)(GLdouble [3],
- void *[4],
- GLfloat [4],
- void **,
- void *)) fn;
- return;
- case GLU_TESS_MESH:
- tess->callMesh = (fn == NULL) ? &noMesh : (void (GLAPIENTRY *)(GLUmesh *)) fn;
- return;
- default:
- CALL_ERROR_OR_ERROR_DATA( GLU_INVALID_ENUM );
- return;
- }
-}
-
-static int AddVertex( GLUtesselator *tess, GLdouble coords[3], void *data )
-{
- GLUhalfEdge *e;
-
- e = tess->lastEdge;
- if( e == NULL ) {
- /* Make a self-loop (one vertex, one edge). */
-
- e = __gl_meshMakeEdge( tess->mesh );
- if (e == NULL) return 0;
- if ( !__gl_meshSplice( e, e->Sym ) ) return 0;
- } else {
- /* Create a new vertex and edge which immediately follow e
- * in the ordering around the left face.
- */
- if (__gl_meshSplitEdge( e ) == NULL) return 0;
- e = e->Lnext;
- }
-
- /* The new vertex is now e->Org. */
- e->Org->data = data;
- e->Org->coords[0] = coords[0];
- e->Org->coords[1] = coords[1];
- e->Org->coords[2] = coords[2];
-
- /* The winding of an edge says how the winding number changes as we
- * cross from the edge''s right face to its left face. We add the
- * vertices in such an order that a CCW contour will add +1 to
- * the winding number of the region inside the contour.
- */
- e->winding = 1;
- e->Sym->winding = -1;
-
- tess->lastEdge = e;
-
- return 1;
-}
-
-
-static void CacheVertex( GLUtesselator *tess, GLdouble coords[3], void *data )
-{
- CachedVertex *v = &tess->cache[tess->cacheCount];
-
- v->data = data;
- v->coords[0] = coords[0];
- v->coords[1] = coords[1];
- v->coords[2] = coords[2];
- ++tess->cacheCount;
-}
-
-
-static int EmptyCache( GLUtesselator *tess )
-{
- CachedVertex *v = tess->cache;
- CachedVertex *vLast;
-
- tess->mesh = __gl_meshNewMesh();
- if (tess->mesh == NULL) return 0;
-
- for( vLast = v + tess->cacheCount; v < vLast; ++v ) {
- if ( !AddVertex( tess, v->coords, v->data ) ) return 0;
- }
- tess->cacheCount = 0;
- tess->emptyCache = FALSE;
-
- return 1;
-}
-
-
-void GLAPIENTRY
-gluTessVertex( GLUtesselator *tess, GLdouble coords[3], void *data )
-{
- int i, tooLarge = FALSE;
- GLdouble x, clamped[3];
-
- RequireState( tess, T_IN_CONTOUR );
-
- if( tess->emptyCache ) {
- if ( !EmptyCache( tess ) ) {
- CALL_ERROR_OR_ERROR_DATA( GLU_OUT_OF_MEMORY );
- return;
- }
- tess->lastEdge = NULL;
- }
- for( i = 0; i < 3; ++i ) {
- x = coords[i];
- if( x < - GLU_TESS_MAX_COORD ) {
- x = - GLU_TESS_MAX_COORD;
- tooLarge = TRUE;
- }
- if( x > GLU_TESS_MAX_COORD ) {
- x = GLU_TESS_MAX_COORD;
- tooLarge = TRUE;
- }
- clamped[i] = x;
- }
- if( tooLarge ) {
- CALL_ERROR_OR_ERROR_DATA( GLU_TESS_COORD_TOO_LARGE );
- }
-
- if( tess->mesh == NULL ) {
- if( tess->cacheCount < TESS_MAX_CACHE ) {
- CacheVertex( tess, clamped, data );
- return;
- }
- if ( !EmptyCache( tess ) ) {
- CALL_ERROR_OR_ERROR_DATA( GLU_OUT_OF_MEMORY );
- return;
- }
- }
- if ( !AddVertex( tess, clamped, data ) ) {
- CALL_ERROR_OR_ERROR_DATA( GLU_OUT_OF_MEMORY );
- }
-}
-
-
-void GLAPIENTRY
-gluTessBeginPolygon( GLUtesselator *tess, void *data )
-{
- RequireState( tess, T_DORMANT );
-
- tess->state = T_IN_POLYGON;
- tess->cacheCount = 0;
- tess->emptyCache = FALSE;
- tess->mesh = NULL;
-
- tess->polygonData= data;
-}
-
-
-void GLAPIENTRY
-gluTessBeginContour( GLUtesselator *tess )
-{
- RequireState( tess, T_IN_POLYGON );
-
- tess->state = T_IN_CONTOUR;
- tess->lastEdge = NULL;
- if( tess->cacheCount > 0 ) {
- /* Just set a flag so we don't get confused by empty contours
- * -- these can be generated accidentally with the obsolete
- * NextContour() interface.
- */
- tess->emptyCache = TRUE;
- }
-}
-
-
-void GLAPIENTRY
-gluTessEndContour( GLUtesselator *tess )
-{
- RequireState( tess, T_IN_CONTOUR );
- tess->state = T_IN_POLYGON;
-}
-
-void GLAPIENTRY
-gluTessEndPolygon( GLUtesselator *tess )
-{
- GLUmesh *mesh;
-
- if (setjmp(tess->env) != 0) {
- /* come back here if out of memory */
- CALL_ERROR_OR_ERROR_DATA( GLU_OUT_OF_MEMORY );
- return;
- }
-
- RequireState( tess, T_IN_POLYGON );
- tess->state = T_DORMANT;
-
- if( tess->mesh == NULL ) {
- if( ! tess->flagBoundary && tess->callMesh == &noMesh ) {
-
- /* Try some special code to make the easy cases go quickly
- * (eg. convex polygons). This code does NOT handle multiple contours,
- * intersections, edge flags, and of course it does not generate
- * an explicit mesh either.
- */
- if( __gl_renderCache( tess )) {
- tess->polygonData= NULL;
- return;
- }
- }
- if ( !EmptyCache( tess ) ) longjmp(tess->env,1); /* could've used a label*/
- }
-
- /* Determine the polygon normal and project vertices onto the plane
- * of the polygon.
- */
- __gl_projectPolygon( tess );
-
- /* __gl_computeInterior( tess ) computes the planar arrangement specified
- * by the given contours, and further subdivides this arrangement
- * into regions. Each region is marked "inside" if it belongs
- * to the polygon, according to the rule given by tess->windingRule.
- * Each interior region is guaranteed be monotone.
- */
- if ( !__gl_computeInterior( tess ) ) {
- longjmp(tess->env,1); /* could've used a label */
- }
-
- mesh = tess->mesh;
- if( ! tess->fatalError ) {
- int rc = 1;
-
- /* If the user wants only the boundary contours, we throw away all edges
- * except those which separate the interior from the exterior.
- * Otherwise we tessellate all the regions marked "inside".
- */
- if( tess->boundaryOnly ) {
- rc = __gl_meshSetWindingNumber( mesh, 1, TRUE );
- } else {
- rc = __gl_meshTessellateInterior( mesh );
- }
- if (rc == 0) longjmp(tess->env,1); /* could've used a label */
-
- __gl_meshCheckMesh( mesh );
-
- if( tess->callBegin != &noBegin || tess->callEnd != &noEnd
- || tess->callVertex != &noVertex || tess->callEdgeFlag != &noEdgeFlag
- || tess->callBeginData != &__gl_noBeginData
- || tess->callEndData != &__gl_noEndData
- || tess->callVertexData != &__gl_noVertexData
- || tess->callEdgeFlagData != &__gl_noEdgeFlagData )
- {
- if( tess->boundaryOnly ) {
- __gl_renderBoundary( tess, mesh ); /* output boundary contours */
- } else {
- __gl_renderMesh( tess, mesh ); /* output strips and fans */
- }
- }
- if( tess->callMesh != &noMesh ) {
-
- /* Throw away the exterior faces, so that all faces are interior.
- * This way the user doesn't have to check the "inside" flag,
- * and we don't need to even reveal its existence. It also leaves
- * the freedom for an implementation to not generate the exterior
- * faces in the first place.
- */
- __gl_meshDiscardExterior( mesh );
- (*tess->callMesh)( mesh ); /* user wants the mesh itself */
- tess->mesh = NULL;
- tess->polygonData= NULL;
- return;
- }
- }
- __gl_meshDeleteMesh( mesh );
- tess->polygonData= NULL;
- tess->mesh = NULL;
-}
-
-
-/*XXXblythe unused function*/
-#if 0
-void GLAPIENTRY
-gluDeleteMesh( GLUmesh *mesh )
-{
- __gl_meshDeleteMesh( mesh );
-}
-#endif
-
-
-
-/*******************************************************/
-
-/* Obsolete calls -- for backward compatibility */
-
-void GLAPIENTRY
-gluBeginPolygon( GLUtesselator *tess )
-{
- gluTessBeginPolygon( tess, NULL );
- gluTessBeginContour( tess );
-}
-
-
-/*ARGSUSED*/
-void GLAPIENTRY
-gluNextContour( GLUtesselator *tess, GLenum type )
-{
- gluTessEndContour( tess );
- gluTessBeginContour( tess );
-}
-
-
-void GLAPIENTRY
-gluEndPolygon( GLUtesselator *tess )
-{
- gluTessEndContour( tess );
- gluTessEndPolygon( tess );
-}
diff --git a/libtess/tess.h b/libtess/tess.h
deleted file mode 100644
index 93d5858..0000000
--- a/libtess/tess.h
+++ /dev/null
@@ -1,180 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __tess_h_
-#define __tess_h_
-
-#include <setjmp.h>
-#include "glu.h"
-#include "mesh.h"
-#include "dict.h"
-#include "priorityq.h"
-
-/*
- * PLC This symbol seems to be undefined with VC98
- */
-#ifndef GLAPIENTRY
-#define GLAPIENTRY
-#endif
-
-
-/* The begin/end calls must be properly nested. We keep track of
- * the current state to enforce the ordering.
- */
-enum TessState { T_DORMANT, T_IN_POLYGON, T_IN_CONTOUR };
-
-/* We cache vertex data for single-contour polygons so that we can
- * try a quick-and-dirty decomposition first.
- */
-#define TESS_MAX_CACHE 100
-
-typedef struct CachedVertex {
- GLdouble coords[3];
- void *data;
-} CachedVertex;
-
-struct GLUtesselator {
-
- /*** state needed for collecting the input data ***/
-
- enum TessState state; /* what begin/end calls have we seen? */
-
- GLUhalfEdge *lastEdge; /* lastEdge->Org is the most recent vertex */
- GLUmesh *mesh; /* stores the input contours, and eventually
- the tessellation itself */
-
- void (GLAPIENTRY *callError)( GLenum errnum );
-
- /*** state needed for projecting onto the sweep plane ***/
-
- GLdouble normal[3]; /* user-specified normal (if provided) */
- GLdouble sUnit[3]; /* unit vector in s-direction (debugging) */
- GLdouble tUnit[3]; /* unit vector in t-direction (debugging) */
-
- /*** state needed for the line sweep ***/
-
- GLdouble relTolerance; /* tolerance for merging features */
- GLenum windingRule; /* rule for determining polygon interior */
- GLboolean fatalError; /* fatal error: needed combine callback */
-
- Dict *dict; /* edge dictionary for sweep line */
- PriorityQ *pq; /* priority queue of vertex events */
- GLUvertex *event; /* current sweep event being processed */
-
- void (GLAPIENTRY *callCombine)( GLdouble coords[3], void *data[4],
- GLfloat weight[4], void **outData );
-
- /*** state needed for rendering callbacks (see render.c) ***/
-
- GLboolean flagBoundary; /* mark boundary edges (use EdgeFlag) */
- GLboolean boundaryOnly; /* Extract contours, not triangles */
- GLUface *lonelyTriList;
- /* list of triangles which could not be rendered as strips or fans */
-
- void (GLAPIENTRY *callBegin)( GLenum type );
- void (GLAPIENTRY *callEdgeFlag)( GLboolean boundaryEdge );
- void (GLAPIENTRY *callVertex)( void *data );
- void (GLAPIENTRY *callEnd)( void );
- void (GLAPIENTRY *callMesh)( GLUmesh *mesh );
-
-
- /*** state needed to cache single-contour polygons for renderCache() */
-
- GLboolean emptyCache; /* empty cache on next vertex() call */
- int cacheCount; /* number of cached vertices */
- CachedVertex cache[TESS_MAX_CACHE]; /* the vertex data */
-
- /*** rendering callbacks that also pass polygon data ***/
- void (GLAPIENTRY *callBeginData)( GLenum type, void *polygonData );
- void (GLAPIENTRY *callEdgeFlagData)( GLboolean boundaryEdge,
- void *polygonData );
- void (GLAPIENTRY *callVertexData)( void *data, void *polygonData );
- void (GLAPIENTRY *callEndData)( void *polygonData );
- void (GLAPIENTRY *callErrorData)( GLenum errnum, void *polygonData );
- void (GLAPIENTRY *callCombineData)( GLdouble coords[3], void *data[4],
- GLfloat weight[4], void **outData,
- void *polygonData );
-
- jmp_buf env; /* place to jump to when memAllocs fail */
-
- void *polygonData; /* client data for current polygon */
-};
-
-void GLAPIENTRY __gl_noBeginData( GLenum type, void *polygonData );
-void GLAPIENTRY __gl_noEdgeFlagData( GLboolean boundaryEdge, void *polygonData );
-void GLAPIENTRY __gl_noVertexData( void *data, void *polygonData );
-void GLAPIENTRY __gl_noEndData( void *polygonData );
-void GLAPIENTRY __gl_noErrorData( GLenum errnum, void *polygonData );
-void GLAPIENTRY __gl_noCombineData( GLdouble coords[3], void *data[4],
- GLfloat weight[4], void **outData,
- void *polygonData );
-
-#define CALL_BEGIN_OR_BEGIN_DATA(a) \
- if (tess->callBeginData != &__gl_noBeginData) \
- (*tess->callBeginData)((a),tess->polygonData); \
- else (*tess->callBegin)((a));
-
-#define CALL_VERTEX_OR_VERTEX_DATA(a) \
- if (tess->callVertexData != &__gl_noVertexData) \
- (*tess->callVertexData)((a),tess->polygonData); \
- else (*tess->callVertex)((a));
-
-#define CALL_EDGE_FLAG_OR_EDGE_FLAG_DATA(a) \
- if (tess->callEdgeFlagData != &__gl_noEdgeFlagData) \
- (*tess->callEdgeFlagData)((a),tess->polygonData); \
- else (*tess->callEdgeFlag)((a));
-
-#define CALL_END_OR_END_DATA() \
- if (tess->callEndData != &__gl_noEndData) \
- (*tess->callEndData)(tess->polygonData); \
- else (*tess->callEnd)();
-
-#define CALL_COMBINE_OR_COMBINE_DATA(a,b,c,d) \
- if (tess->callCombineData != &__gl_noCombineData) \
- (*tess->callCombineData)((a),(b),(c),(d),tess->polygonData); \
- else (*tess->callCombine)((a),(b),(c),(d));
-
-#define CALL_ERROR_OR_ERROR_DATA(a) \
- if (tess->callErrorData != &__gl_noErrorData) \
- (*tess->callErrorData)((a),tess->polygonData); \
- else (*tess->callError)((a));
-
-#endif
diff --git a/libtess/tessmono.c b/libtess/tessmono.c
deleted file mode 100644
index 2789814..0000000
--- a/libtess/tessmono.c
+++ /dev/null
@@ -1,208 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#include "gluos.h"
-#include <stdlib.h>
-#include "geom.h"
-#include "mesh.h"
-#include "tessmono.h"
-#include <assert.h>
-
-#define AddWinding(eDst,eSrc) (eDst->winding += eSrc->winding, \
- eDst->Sym->winding += eSrc->Sym->winding)
-
-/* __gl_meshTessellateMonoRegion( face ) tessellates a monotone region
- * (what else would it do??) The region must consist of a single
- * loop of half-edges (see mesh.h) oriented CCW. "Monotone" in this
- * case means that any vertical line intersects the interior of the
- * region in a single interval.
- *
- * Tessellation consists of adding interior edges (actually pairs of
- * half-edges), to split the region into non-overlapping triangles.
- *
- * The basic idea is explained in Preparata and Shamos (which I don''t
- * have handy right now), although their implementation is more
- * complicated than this one. The are two edge chains, an upper chain
- * and a lower chain. We process all vertices from both chains in order,
- * from right to left.
- *
- * The algorithm ensures that the following invariant holds after each
- * vertex is processed: the untessellated region consists of two
- * chains, where one chain (say the upper) is a single edge, and
- * the other chain is concave. The left vertex of the single edge
- * is always to the left of all vertices in the concave chain.
- *
- * Each step consists of adding the rightmost unprocessed vertex to one
- * of the two chains, and forming a fan of triangles from the rightmost
- * of two chain endpoints. Determining whether we can add each triangle
- * to the fan is a simple orientation test. By making the fan as large
- * as possible, we restore the invariant (check it yourself).
- */
-int __gl_meshTessellateMonoRegion( GLUface *face )
-{
- GLUhalfEdge *up, *lo;
-
- /* All edges are oriented CCW around the boundary of the region.
- * First, find the half-edge whose origin vertex is rightmost.
- * Since the sweep goes from left to right, face->anEdge should
- * be close to the edge we want.
- */
- up = face->anEdge;
- assert( up->Lnext != up && up->Lnext->Lnext != up );
-
- for( ; VertLeq( up->Dst, up->Org ); up = up->Lprev )
- ;
- for( ; VertLeq( up->Org, up->Dst ); up = up->Lnext )
- ;
- lo = up->Lprev;
-
- while( up->Lnext != lo ) {
- if( VertLeq( up->Dst, lo->Org )) {
- /* up->Dst is on the left. It is safe to form triangles from lo->Org.
- * The EdgeGoesLeft test guarantees progress even when some triangles
- * are CW, given that the upper and lower chains are truly monotone.
- */
- while( lo->Lnext != up && (EdgeGoesLeft( lo->Lnext )
- || EdgeSign( lo->Org, lo->Dst, lo->Lnext->Dst ) <= 0 )) {
- GLUhalfEdge *tempHalfEdge= __gl_meshConnect( lo->Lnext, lo );
- if (tempHalfEdge == NULL) return 0;
- lo = tempHalfEdge->Sym;
- }
- lo = lo->Lprev;
- } else {
- /* lo->Org is on the left. We can make CCW triangles from up->Dst. */
- while( lo->Lnext != up && (EdgeGoesRight( up->Lprev )
- || EdgeSign( up->Dst, up->Org, up->Lprev->Org ) >= 0 )) {
- GLUhalfEdge *tempHalfEdge= __gl_meshConnect( up, up->Lprev );
- if (tempHalfEdge == NULL) return 0;
- up = tempHalfEdge->Sym;
- }
- up = up->Lnext;
- }
- }
-
- /* Now lo->Org == up->Dst == the leftmost vertex. The remaining region
- * can be tessellated in a fan from this leftmost vertex.
- */
- assert( lo->Lnext != up );
- while( lo->Lnext->Lnext != up ) {
- GLUhalfEdge *tempHalfEdge= __gl_meshConnect( lo->Lnext, lo );
- if (tempHalfEdge == NULL) return 0;
- lo = tempHalfEdge->Sym;
- }
-
- return 1;
-}
-
-
-/* __gl_meshTessellateInterior( mesh ) tessellates each region of
- * the mesh which is marked "inside" the polygon. Each such region
- * must be monotone.
- */
-int __gl_meshTessellateInterior( GLUmesh *mesh )
-{
- GLUface *f, *next;
-
- /*LINTED*/
- for( f = mesh->fHead.next; f != &mesh->fHead; f = next ) {
- /* Make sure we don''t try to tessellate the new triangles. */
- next = f->next;
- if( f->inside ) {
- if ( !__gl_meshTessellateMonoRegion( f ) ) return 0;
- }
- }
-
- return 1;
-}
-
-
-/* __gl_meshDiscardExterior( mesh ) zaps (ie. sets to NULL) all faces
- * which are not marked "inside" the polygon. Since further mesh operations
- * on NULL faces are not allowed, the main purpose is to clean up the
- * mesh so that exterior loops are not represented in the data structure.
- */
-void __gl_meshDiscardExterior( GLUmesh *mesh )
-{
- GLUface *f, *next;
-
- /*LINTED*/
- for( f = mesh->fHead.next; f != &mesh->fHead; f = next ) {
- /* Since f will be destroyed, save its next pointer. */
- next = f->next;
- if( ! f->inside ) {
- __gl_meshZapFace( f );
- }
- }
-}
-
-#define MARKED_FOR_DELETION 0x7fffffff
-
-/* __gl_meshSetWindingNumber( mesh, value, keepOnlyBoundary ) resets the
- * winding numbers on all edges so that regions marked "inside" the
- * polygon have a winding number of "value", and regions outside
- * have a winding number of 0.
- *
- * If keepOnlyBoundary is TRUE, it also deletes all edges which do not
- * separate an interior region from an exterior one.
- */
-int __gl_meshSetWindingNumber( GLUmesh *mesh, int value,
- GLboolean keepOnlyBoundary )
-{
- GLUhalfEdge *e, *eNext;
-
- for( e = mesh->eHead.next; e != &mesh->eHead; e = eNext ) {
- eNext = e->next;
- if( e->Rface->inside != e->Lface->inside ) {
-
- /* This is a boundary edge (one side is interior, one is exterior). */
- e->winding = (e->Lface->inside) ? value : -value;
- } else {
-
- /* Both regions are interior, or both are exterior. */
- if( ! keepOnlyBoundary ) {
- e->winding = 0;
- } else {
- if ( !__gl_meshDelete( e ) ) return 0;
- }
- }
- }
- return 1;
-}
diff --git a/libtess/tessmono.h b/libtess/tessmono.h
deleted file mode 100644
index 7c35bd5..0000000
--- a/libtess/tessmono.h
+++ /dev/null
@@ -1,78 +0,0 @@
-/*
-** License Applicability. Except to the extent portions of this file are
-** made subject to an alternative license as permitted in the SGI Free
-** Software License B, Version 1.1 (the "License"), the contents of this
-** file are subject only to the provisions of the License. You may not use
-** this file except in compliance with the License. You may obtain a copy
-** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
-** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
-**
-** http://oss.sgi.com/projects/FreeB
-**
-** Note that, as provided in the License, the Software is distributed on an
-** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
-** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
-** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
-** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
-**
-** Original Code. The Original Code is: OpenGL Sample Implementation,
-** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
-** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
-** Copyright in any portions created by third parties is as indicated
-** elsewhere herein. All Rights Reserved.
-**
-** Additional Notice Provisions: The application programming interfaces
-** established by SGI in conjunction with the Original Code are The
-** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
-** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
-** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
-** Window System(R) (Version 1.3), released October 19, 1998. This software
-** was created using the OpenGL(R) version 1.2.1 Sample Implementation
-** published by SGI, but has not been independently verified as being
-** compliant with the OpenGL(R) version 1.2.1 Specification.
-**
-*/
-/*
-** Author: Eric Veach, July 1994.
-**
-** $Date$ $Revision$
-** $Header$
-*/
-
-#ifndef __tessmono_h_
-#define __tessmono_h_
-
-/* __gl_meshTessellateMonoRegion( face ) tessellates a monotone region
- * (what else would it do??) The region must consist of a single
- * loop of half-edges (see mesh.h) oriented CCW. "Monotone" in this
- * case means that any vertical line intersects the interior of the
- * region in a single interval.
- *
- * Tessellation consists of adding interior edges (actually pairs of
- * half-edges), to split the region into non-overlapping triangles.
- *
- * __gl_meshTessellateInterior( mesh ) tessellates each region of
- * the mesh which is marked "inside" the polygon. Each such region
- * must be monotone.
- *
- * __gl_meshDiscardExterior( mesh ) zaps (ie. sets to NULL) all faces
- * which are not marked "inside" the polygon. Since further mesh operations
- * on NULL faces are not allowed, the main purpose is to clean up the
- * mesh so that exterior loops are not represented in the data structure.
- *
- * __gl_meshSetWindingNumber( mesh, value, keepOnlyBoundary ) resets the
- * winding numbers on all edges so that regions marked "inside" the
- * polygon have a winding number of "value", and regions outside
- * have a winding number of 0.
- *
- * If keepOnlyBoundary is TRUE, it also deletes all edges which do not
- * separate an interior region from an exterior one.
- */
-
-int __gl_meshTessellateMonoRegion( GLUface *face );
-int __gl_meshTessellateInterior( GLUmesh *mesh );
-void __gl_meshDiscardExterior( GLUmesh *mesh );
-int __gl_meshSetWindingNumber( GLUmesh *mesh, int value,
- GLboolean keepOnlyBoundary );
-
-#endif
diff --git a/redhat/changelog b/redhat/changelog
deleted file mode 100644
index c1ea05f..0000000
--- a/redhat/changelog
+++ /dev/null
@@ -1,108 +0,0 @@
-$Version = "3.30";
-$Release = 2;
-
-$ChangeLog = '
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-1
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-2
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-3
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-4
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-5
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-6
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-7
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-8
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-9
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-10
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-11
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-12
-
- * Mon Mar 12 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.23-1
-
- * Tue Mar 13 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.23-2
-
- * Tue Mar 13 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.23-3
-
- * Fri Mar 16 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.24-1
-
- * Tue Apr 10 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.26-1
-
- * Wed Jan 16 2002 Stéphane Chatty
-- Generation of version 3.2.3-1
-
- * Thu Apr 4 2002 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.2.4-1
-
- * Wed Sep 18 2002 Stéphane Chatty <chatty@intuilab.com>
-- Generation of version 3.2.6-1
-
- * Mon Feb 17 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.6h-1
-- Mandrake 9 compilation
-- Removes installgpc in redhat/rules
-
- * Wed May 14 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.92-1
-- Mandrake 9 compilation
-
- * Sat May 17 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.93-1
-- Mandrake 9 compilation
-
- * Fri Jun 20 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.94-1
-- Mandrake 9 compilation
-
- * Fri Jun 20 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.94-2
-- Mandrake 9.1 compilation
-
- * Wed Oct 15 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.295-1
-- Mandrake 9 compilation
-
- * Tue Oct 28 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.295-2
-
- * Fri Nov 28 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.295-3
-
- * Mon Dec 15 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.296-1
-
- * Thu Oct 21 2004 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.30-1
-- Build a Mandrake 9.2 package
-
- * Thu Oct 21 2004 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.30-2
-- Build a Mandrake 10.0 package
-
-';
diff --git a/redhat/perl-Tk-Zinc.spec b/redhat/perl-Tk-Zinc.spec
deleted file mode 100644
index 082be8e..0000000
--- a/redhat/perl-Tk-Zinc.spec
+++ /dev/null
@@ -1,148 +0,0 @@
-Summary: Zinc, a canvas replacement for Tk
-Name: perl-Tk-Zinc
-Version: 3.296
-Release: 1
-Copyright: LGPL
-Vendor: Centre d'Etudes de la Navigation Aerienne
-Packager: Alexandre Lemort <lemort@intuilab.com>
-Distribution: Zinc
-Group: System Environment/Libraries
-Url: http://www.cena.fr/divisions/PII/
-Source: perl-Tk-Zinc-3.296.tar.gz
-Requires: perl-Tk
-BuildArchitectures: i386
-BuildRoot: /var/tmp/perl-Tk-Zinc-buildroot
-
-%description
-Zinc is a canvas like widget for the Tk toolkit. Its has been
- designed to provide a structured organization of its graphical
- components. It provides also advanced geometrical and graphical
- capabilities such as geometric construction (boolean ops),
- transformations, non rectangular clipping gradient fills, smart
- reliefs, etc.
-
-This contains the dynamic libraries that are necessary for
-running applications which use Zinc.
-
-%prep
-%setup -q -n perl-Tk-Zinc-%{version}
-
-%build
-./configure --enable-ptk=yes --enable-gl=damage --prefix=$RPM_BUILD_ROOT/usr --exec-prefix=$RPM_BUILD_ROOT/usr
-cd Perl
-./export2cpan
-cd ../export2cpan/tk-zinc
-perl Makefile.PL
-make
-
-%clean
-rm -rf $RPM_BUILD_ROOT
-
-%install
-rm -rf $RPM_BUILD_ROOT
-mkdirhier $RPM_BUILD_ROOT/usr/lib
-cd export2cpan/tk-zinc
-make PREFIX=$RPM_BUILD_ROOT/usr prefix=$RPM_BUILD_ROOT/usr INSTALLDIRS=perl install
-find $RPM_BUILD_ROOT/usr -type f -print | sed "s@^$RPM_BUILD_ROOT@@g" | grep -v Zinc.bs | grep -v .packlist > ../../perl-Tk-Zinc-%{version}-filelist
-
-%files -f perl-Tk-Zinc-%{version}-filelist
-%defattr(-,root,root)
-
-%changelog
-
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-1
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-2
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-3
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-4
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-5
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-6
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-7
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-8
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-9
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-10
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-11
-
- * Tue Oct 31 2000 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.19-12
-
- * Mon Mar 12 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.23-1
-
- * Tue Mar 13 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.23-2
-
- * Tue Mar 13 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.23-3
-
- * Fri Mar 16 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.24-1
-
- * Tue Apr 10 2001 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.1.26-1
-
- * Wed Jan 16 2002 Stéphane Chatty
-- Generation of version 3.2.3-1
-
- * Thu Apr 4 2002 Stéphane Chatty <chatty@cena.fr>
-- Generation of version 3.2.4-1
-
- * Wed Sep 18 2002 Stéphane Chatty <chatty@intuilab.com>
-- Generation of version 3.2.6-1
-
- * Mon Feb 17 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.6h-1
-- Mandrake 9 compilation
-- Removes installgpc in redhat/rules
-
- * Wed May 14 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.92-1
-- Mandrake 9 compilation
-
- * Sat May 17 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.93-1
-- Mandrake 9 compilation
-
- * Fri Jun 20 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.94-1
-- Mandrake 9 compilation
-
- * Fri Jun 20 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.2.94-2
-- Mandrake 9.1 compilation
-
- * Wed Oct 15 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.295-1
-- Mandrake 9 compilation
-
- * Tue Oct 28 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.295-2
-
- * Fri Nov 28 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.295-3
-
- * Mon Dec 15 2003 Alexandre Lemort <lemort@intuilab.com>
-- Generation of version 3.296-1
-
-
diff --git a/redhat/rules b/redhat/rules
deleted file mode 100644
index 7835f8c..0000000
--- a/redhat/rules
+++ /dev/null
@@ -1,31 +0,0 @@
-$Summary = "Zinc, a canvas replacement for Tk";
-$Name = "perl-Tk-Zinc";
-$Copyright = "LGPL";
-$Vendor = "Centre d'Etudes de la Navigation Aerienne";
-$Url = "http://www.cena.fr/divisions/PII/";
-$Distribution = "Zinc";
-$Group = "System Environment/Libraries";
-$BuildArchitectures = "i386";
-$Requires = "perl-Tk";
-
-$Build = "cd Perl
-./export2cpan
-cd ../export2cpan/tk-zinc
-perl Makefile.PL
-make";
-
-$Install = "rm -rf \$RPM_BUILD_ROOT
-mkdirhier \$RPM_BUILD_ROOT/usr/lib
-cd export2cpan/tk-zinc
-make PREFIX=\$RPM_BUILD_ROOT/usr prefix=\$RPM_BUILD_ROOT/usr INSTALLDIRS=perl pure_install
-find \$RPM_BUILD_ROOT/usr -type f -print | sed \"s\@^\$RPM_BUILD_ROOT\@\@g\" \| grep -v Zinc.bs | grep -v .packlist > ../../$Name-\%{version}-filelist";
-
-$Description = "Zinc is a canvas like widget for the Tk toolkit. Its has been
- designed to provide a structured organization of its graphical
- components. It provides also advanced geometrical and graphical
- capabilities such as geometric construction (boolean ops),
- transformations, non rectangular clipping gradient fills, smart
- reliefs, etc.
-
-This contains the dynamic libraries that are necessary for
-running applications which use Zinc.";
diff --git a/sandbox/Controls.pm b/sandbox/Controls.pm
deleted file mode 100644
index 55f6b6a..0000000
--- a/sandbox/Controls.pm
+++ /dev/null
@@ -1,224 +0,0 @@
-
-package Controls;
-
-$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'};
- }
- $sx = 1.0 + ($lx - $self->{'cur_x'})/$maxx;
- $sy = 1.0 + ($ly - $self->{'cur_y'})/$maxy;
- $self->{'cur_x'} = $lx;
- $self->{'cur_y'} = $ly;
- $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);
- }
-}
-
-
diff --git a/sandbox/alledges.pl b/sandbox/alledges.pl
deleted file mode 100644
index e8893a9..0000000
--- a/sandbox/alledges.pl
+++ /dev/null
@@ -1,47 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $defaultfont = '-b&h-lucida-bold-r-normal-*-*-140-*-*-p-*-iso10646-1';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 300,
-# -render => 1,
- -backcolor => "grey50", # this will be transparent in the doc
- )->pack();
-
-
-my $i = 1;
-my $x = 40;
-my $y = 40;
-foreach my $contour ( (['left'], ['right'], ['top'], ['bottom'],
- ['top', 'bottom'], ['left','right'], ['left','top'], ['contour'],
- ['oblique'], ['counteroblique'],['oblique','counteroblique']) ) {
- my $tab = $zinc->add('tabular', 1, 1, -position => [$x, $y],
- -labelformat => "a5a5+0+0",
- );
- my $contour_text = "['" . join ("','",@{$contour}) . "']";
- $zinc->itemconfigure($tab, 0,
- -text => $contour_text,
- -border => $contour,
- -alignment => "center",
- -filled => 1,
- -backcolor => "gray95",
-);
- $i++;
- if ($i == 5) {
- $x = 40;
- $y = $y + 50;
- $i = 1;
- }
- else {
- $x = $x + 160;
- }
-}
-
-
-
-MainLoop();
diff --git a/sandbox/allgradients.pl b/sandbox/allgradients.pl
deleted file mode 100644
index bd7a4d6..0000000
--- a/sandbox/allgradients.pl
+++ /dev/null
@@ -1,64 +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 Tk;
-use Tk::Zinc;
-use strict;
-
-my ($grp,, $s, $i);
-my $defaultfont = '-b&h-lucida-bold-r-normal-*-*-140-*-*-p-*-iso10646-1';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 300,
- -render => 1,
- -backcolor => "red", # this will be transparent in the doc
- )->pack();
-
-
-$zinc->gname('black|white', 'axial 1');
-$zinc->gname('black|white/90', 'axial 2');
-$zinc->gname('black|white/30', 'axial 3');
-$zinc->gname('black|black:0/30', 'axial 4');
-$zinc->gname('white|black(-14 -20', 'radial 1');
-$zinc->gname('white:50 0 70|black 50|white 100(0 0', 'radial 2');
-$zinc->gname('white|black:80[-14 -20', 'path 1');
-$zinc->gname('white|white 30|black:80[-14 -20', 'path 2');
-
-$grp = $zinc->add('group', 1);
-$zinc->add('rectangle', $grp, [0, 0, 70, 50],
- -filled => 1,
- -fillcolor => 'white',
- );
-$zinc->add('rectangle', $grp, [0, 0, 70, 50],
- -filled => 1,
- -linewidth => 1, # to help making the background transparent with gimp!
-
- -fillcolor => 'axial 1',
- -tags => ['rect']);
-$zinc->add('text', $grp,
- -text => 'axial 1',
- -anchor => 'center',
- -position => [35, -10],
- -tags => ['txt']);
-$zinc->translate($grp, 20, 30);
-$i = 1;
-foreach $s (('axial 2', 'axial 3', 'axial 4', 'radial 1',
- 'radial 2', 'path 1', 'path 2')) {
- $grp = $zinc->clone($grp);
- $zinc->addtag("g$grp", 'withtag', "$grp*attrs"); #, $grp, 0);
- $zinc->itemconfigure(".$grp.txt",
- -text => $s);
- $zinc->itemconfigure(".$grp.rect",
- -fillcolor => $s);
- $i++;
- if ($i == 5) {
- $zinc->translate($grp, -3*100, 80);
- $i = 1;
- }
- else {
- $zinc->translate($grp, 100, 0);
- }
-}
-
-
-MainLoop();
diff --git a/sandbox/allgradients.tcl b/sandbox/allgradients.tcl
deleted file mode 100644
index eaab25b..0000000
--- a/sandbox/allgradients.tcl
+++ /dev/null
@@ -1,48 +0,0 @@
-
-lappend auto_path ..
-package require Tkzinc
-
-set defaultfont -b&h-lucida-bold-r-normal-*-*-140-*-*-p-*-iso10646-1
-zinc .zinc -width 700 -height 300 -render 1 -backcolor red
-pack .zinc
-
-
-puts start
-.zinc gname black|white {axial 1}
-#.zinc gname {=conical 70 |white|gray20 50|white} {axial 2}
-.zinc gname {=conical 70 |red|yellow 50|red} {axial 2}
-.zinc gname {=axial -50 -50 50 50|black|white} {axial 3}
-.zinc gname {=axial 30|black|black;0} {axial 4}
-.zinc gname {=radial -50 -50 50 50|white|black} {radial 1}
-.zinc gname {=radial 0 0|white;50 0 70|black 50|white 100} {radial 2}
-.zinc gname {=path -14 -20|white|black;80} {path 1}
-.zinc gname {=path -14 -20|white|white 30|black;80} {path 2}
-puts end
-
-set grp [.zinc add group 1]
-#.zinc add rectangle $grp {0 0 70 50} -filled 1 -fillcolor white
-.zinc add rectangle $grp {0 0 200 300} -filled 1 -linewidth 1 \
- -fillcolor {axial 1} -tags rect
-.zinc add text $grp -text {axial 1} -anchor center -position {35 -10} \
- -tags txt
-
-.zinc translate $grp 20 30
-
-set i 1
-foreach s {{axial 2} {axial 3} {axial 4} {radial 1}
- {radial 2} {path 1} {path 2}} {
-
- set grp [.zinc clone $grp]
- .zinc addtag "g$grp" withtag "$grp*attrs"
- .zinc itemconfigure ".$grp.txt" -text $s
- .zinc itemconfigure ".$grp.rect" -fillcolor $s
- incr i
-
- if {$i == 5} {
- .zinc translate $grp [expr -3*100] 80
- set i 1
- } else {
- .zinc translate $grp 100 0
- }
-}
-
diff --git a/sandbox/alllineshapes.pl b/sandbox/alllineshapes.pl
deleted file mode 100644
index c2bafc3..0000000
--- a/sandbox/alllineshapes.pl
+++ /dev/null
@@ -1,47 +0,0 @@
-#!/usr/bin/perl
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr
-
-use Tk;
-use Tk::Zinc;
-use strict;
-
-my $defaultfont = '-b&h-lucida-bold-r-normal-*-*-140-*-*-p-*-iso10646-1';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 420,
-# -render => 1,
-# -backcolor => "red", # this will be transparent in the doc
- )->pack();
-
-
-my $i = 1;
-my $x = 20;
-my $y = 20;
-foreach my $lineshape ( qw(straight rightlightning leftlightning
- rightcorner leftcorner doublerightcorner
- doubleleftcorner) ) {
- my $wpt = $zinc->add('waypoint', 1, 1,
- -position => [$x, $y],
- -labelformat => "a5a5+0+0",
- -leaderanchors => '% 100x100',
- -leadershape => $lineshape,
- -labeldistance => 120,
- );
- $zinc->itemconfigure($wpt, 0,
- -text => $lineshape,
- -alignment => "center",
- );
- $i++;
- if ($i == 4) {
- $x = 20;
- $y = $y + 150;
- $i = 1;
- }
- else {
- $x = $x + 210;
- }
-}
-
-
-
-MainLoop();
diff --git a/sandbox/allreliefs.pl b/sandbox/allreliefs.pl
deleted file mode 100644
index 891a16f..0000000
--- a/sandbox/allreliefs.pl
+++ /dev/null
@@ -1,54 +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 Tk;
-use Tk::Photo;
-use Tk::Zinc;
-use strict;
-
-my ($grp,, $s, $i);
-my $defaultfont = '-adobe-helvetica-bold-r-normal-*-100-*-*-*-*-*-*';
-my $mw = MainWindow->new();
-my $zinc = $mw->Zinc(-width => 700, -height => 300,
- -render => 1,
- -backcolor => "red", # this will be transparent in the doc
- )->pack();
-
-
-$grp = $zinc->add('group', 1);
-$zinc->add('rectangle', $grp, [0, 0, 70, 50],
- -filled => 1,
- -fillcolor => 'tan',
- -linecolor => 'tan',
- -linewidth => 6,
- -relief => 'raised',
- -tags => ['attrs']);
-$zinc->add('text', $grp,
- -text => 'raised',
- -anchor => 'center',
- -font => $defaultfont,
- -position => [35, -10],
- -tags => ['attrs']);
-$zinc->translate($grp, 20, 30);
-$i = 1;
-foreach $s (('sunken', 'ridge', 'groove',
- 'roundraised', 'roundsunken', 'roundridge', 'roundgroove',
- 'raisedrule', 'sunkenrule')) {
- $grp = $zinc->clone($grp);
- $zinc->addtag("g$grp", 'withtag', 'attrs', $grp, 0);
- $zinc->itemconfigure("attrs && g$grp",
- -text => $s,
- -relief => $s);
- $i++;
- if ($i == 5) {
- $zinc->translate($grp, -3*100, 80);
- $i = 1;
- }
- else {
- $zinc->translate($grp, 100, 0);
- }
-}
-
-
-MainLoop();
diff --git a/sandbox/allreliefs.tcl b/sandbox/allreliefs.tcl
deleted file mode 100644
index 291a02b..0000000
--- a/sandbox/allreliefs.tcl
+++ /dev/null
@@ -1,30 +0,0 @@
-# $Id$
-# these simple samples have been developped by C. Mertz mertz@cena.fr and N. Banoun banoun@cena.fr
-
-lappend auto_path [file join [file dirname [info script]] ..]
-package require Tkzinc
-
-set defaultfont "-adobe-helvetica-bold-r-normal-*-100-*-*-*-*-*-*"
-zinc .z -width 700 -height 300 -render 1 -backcolor gray
-pack .z
-
-set grp [.z add group 1]
-.z add rectangle $grp {0 0 70 50} -filled 1 -fillcolor tan -linecolor tan \
- -linewidth 6 -relief raised -tags attrs
-.z add text $grp -text raised -anchor center -font $defaultfont \
- -position {35 -10} -tags texts
-.z translate $grp 20 30
-
-set i 1
-foreach s {sunken ridge groove roundraised roundsunken roundridge roundgroove raisedrule sunkenrule} {
- set grp [.z clone $grp]
- .z itemconfigure "$grp.texts" -text $s
- .z itemconfigure "$grp.attrs" -relief $s
- incr i
- if {$i == 5} {
- .z translate $grp [expr -3*100] 80
- set i 1
- } else {
- .z translate $grp 100 0
- }
-}
diff --git a/sandbox/bouton-down.xpm b/sandbox/bouton-down.xpm
deleted file mode 100644
index f3c41c2..0000000
--- a/sandbox/bouton-down.xpm
+++ /dev/null
@@ -1,342 +0,0 @@
-/* XPM */
-static char *on[] = {
-/* width height num_colors chars_per_pixel */
-" 90 86 249 2",
-/* colors */
-"b1 s mask c none",
-".. c #f8fcf8",
-".# c #080808",
-".a c #101010",
-".b c #181818",
-".c c #202020",
-".d c #f8f4f0",
-".e c #605858",
-".f c #484040",
-".g c #383030",
-".h c #282020",
-".i c #201818",
-".j c #302020",
-".k c #181010",
-".l c #100808",
-".m c #e0ccc0",
-".n c #806860",
-".o c #503830",
-".p c #f8e4d8",
-".q c #805848",
-".r c #c8bcb0",
-".s c #887870",
-".t c #f8dcc8",
-".u c #f0d4c0",
-".v c #d8bca8",
-".w c #605048",
-".x c #b89c88",
-".y c #b09480",
-".z c #403028",
-".A c #785848",
-".B c #f8b490",
-".C c #705040",
-".D c #885840",
-".E c #f8ece0",
-".F c #d8ccc0",
-".G c #988c80",
-".H c #c8ac98",
-".I c #584840",
-".J c #f8ccb0",
-".K c #886858",
-".L c #f8bc98",
-".M c #382820",
-".N c #a07058",
-".O c #684838",
-".P c #906048",
-".Q c #b07050",
-".R c #a06040",
-".S c #f0e4d8",
-".T c #d0c4b8",
-".U c #b0a498",
-".V c #908478",
-".W c #706058",
-".X c #c09c80",
-".Y c #a07860",
-".Z c #c89470",
-".0 c #f8b488",
-".1 c #b88460",
-".2 c #805840",
-".3 c #b07858",
-".4 c #a87050",
-".5 c #a06848",
-".6 c #986040",
-".7 c #b87048",
-".8 c #b06840",
-".9 c #f0dcc8",
-"#. c #e8d4c0",
-"## c #d0bca8",
-"#a c #b09c88",
-"#b c #f8d4b8",
-"#c c #907868",
-"#d c #e8c4a8",
-"#e c #887060",
-"#f c #d8b498",
-"#g c #c8a488",
-"#h c #705848",
-"#i c #e0b490",
-"#j c #b08c70",
-"#k c #685040",
-"#l c #c89c78",
-"#m c #f8bc90",
-"#n c #906850",
-"#o c #a07050",
-"#p c #b87850",
-"#q c #b07048",
-"#r c #a86840",
-"#s c #f8e4d0",
-"#t c #e0ccb8",
-"#u c #d8c4b0",
-"#v c #c0ac98",
-"#w c #f8dcc0",
-"#x c #a08c78",
-"#y c #d8bca0",
-"#z c #988470",
-"#A c #f8cca8",
-"#B c #786050",
-"#C c #987860",
-"#D c #d8ac88",
-"#E c #d0a480",
-"#F c #604838",
-"#G c #b08460",
-"#H c #584030",
-"#I c #785840",
-"#J c #d09c70",
-"#K c #c89468",
-"#L c #c08c60",
-"#M c #b07850",
-"#N c #906040",
-"#O c #a87048",
-"#P c #a06840",
-"#Q c #f0d4b8",
-"#R c #e0c4a8",
-"#S c #d0b498",
-"#T c #c8ac90",
-"#U c #c0a488",
-"#V c #b09478",
-"#W c #e0bc98",
-"#X c #a08468",
-"#Y c #c09c78",
-"#Z c #f8c498",
-"#0 c #907058",
-"#1 c #886850",
-"#2 c #806048",
-"#3 c #f8bc88",
-"#4 c #a07858",
-"#5 c #b88458",
-"#6 c #b07040",
-"#7 c #f8d4b0",
-"#8 c #e8c4a0",
-"#9 c #d8b490",
-"a. c #d0ac88",
-"a# c #f8cca0",
-"aa c #c8a480",
-"ab c #b89470",
-"ac c #b08c68",
-"ad c #f8c490",
-"ae c #d0a478",
-"af c #a88460",
-"ag c #c89c70",
-"ah c #c09468",
-"ai c #987050",
-"aj c #b88c60",
-"ak c #f8bc80",
-"al c #906848",
-"am c #b08458",
-"an c #a87850",
-"ao c #886040",
-"ap c #a07048",
-"aq c #e0dcd0",
-"ar c #a09c90",
-"as c #807870",
-"at c #e8dcc8",
-"au c #e0d4c0",
-"av c #c8bca8",
-"aw c #c0b4a0",
-"ax c #605850",
-"ay c #a89c88",
-"az c #f0dcc0",
-"aA c #a09480",
-"aB c #887868",
-"aC c #403830",
-"aD c #b09c80",
-"aE c #685848",
-"aF c #907860",
-"aG c #605040",
-"aH c #705840",
-"aI c #483828",
-"aJ c #f8f4e8",
-"aK c #b8b4a8",
-"aL c #b0aca0",
-"aM c #989488",
-"aN c #787068",
-"aO c #f8ecd8",
-"aP c #f0e4d0",
-"aQ c #706860",
-"aR c #d8ccb8",
-"aS c #d0c4b0",
-"aT c #b8ac98",
-"aU c #585048",
-"aV c #b0a490",
-"aW c #504840",
-"aX c #f8e4c8",
-"aY c #988c78",
-"aZ c #e0ccb0",
-"a0 c #d8c4a8",
-"a1 c #908470",
-"a2 c #c8b498",
-"a3 c #c0ac90",
-"a4 c #b8a488",
-"a5 c #f8dcb8",
-"a6 c #786858",
-"a7 c #e8cca8",
-"a8 c #706050",
-"a9 c #a89478",
-"b. c #e0c4a0",
-"b# c #d8bc98",
-"ba c #a08c70",
-"bb c #d0b490",
-"bc c #988468",
-"bd c #c8ac88",
-"be c #302820",
-"bf c #c0a480",
-"bg c #b89c78",
-"bh c #887058",
-"bi c #e0bc90",
-"bj c #584838",
-"bk c #b09470",
-"bl c #806850",
-"bm c #a88c68",
-"bn c #f8cc98",
-"bo c #786048",
-"bp c #504030",
-"bq c #c8a478",
-"br c #987858",
-"bs c #b89468",
-"bt c #886848",
-"bu c #c8c4b8",
-"bv c #888478",
-"bw c #686058",
-"bx c #484038",
-"by c #282018",
-"bz c #c8bca0",
-"bA c #a89c80",
-"bB c #e8d4b0",
-"bC c #d8c4a0",
-"bD c #c8b490",
-"bE c #b8a480",
-"bF c #a08c68",
-"bG c #e0d4b8",
-"bH c #f0e4c8",
-"bI c #d8ccb0",
-"bJ c #706048",
-"bK c #e0dcc8",
-"bL c #c0bca8",
-"bM c #807868",
-"bN c #f8f4e0",
-"bO c #d8d4c0",
-"bP c #787060",
-"bQ c #f0ecd8",
-"bR c #e8e4d0",
-"bS c #c8c4b0",
-"bT c #b0ac98",
-"bU c #f8fcf0",
-"bV c #f8fce8",
-"bW c #505048",
-"bX c #484840",
-"bY c #303028",
-"bZ c #282820",
-"b0 c #181810",
-"b2 c #000000",
-/* pixels */
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1.0a#.J#waO.E.................E.p#w#ba#adb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1ad#A.taJ...d....#.bG#D#D#D#D#D#D#D#9#.bG........aJ#s#7bnb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#baO......#t#D#L.7.8.8.8.8.8#r.8.8.8.8.8.8.8.8.7#L#DbG......#s#Ab1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1a##s.d..aJb.#L.8.8#r#r#r#r#r#r#r.8#r.8#r.8#r#6.8#6.8#6#6.8.8.8#Kb.aJ...d#w#3b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#m#sbU..bG#J#r#r#r#r#r#r#r#r#r#r#r#r#r#r#r#r#r#r#r#r#O#r#O#r#O.8#q.8.8.8#J#.....#s#Zb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#m.t....b..7.8#r#r#r#r.R.R#P.R.R#P.R#P#P#P#P.5#P#P.5#P.5#P.5#r#O#r#O#O#O#O#q#q#q#pb.....aX#mb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1a5.d..b..7#r#r#r.R.R.R.R.R#P.6.6#P.6.6.6.P.R.6.6al#P.5.6.5#Pal.5al#P.5#P#r#O#O#O#6#q#q#p#d..aJ#bb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1a#aJ...9#5#r#r#r.R.R#P.R.6.6.6.6.6#N#N#N.P#N#N.Pal.6.6.P#Nal.P.P.Pal.5.Pal.5al.5#O#O#O#q#q#q#q#KaP...Ea#b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#7.daJae#r#r#r.R.R#P.6.6.6.6#N#N#Naoaoaoaoaobtaoaoaoaobtbt.Pbt.P.P.P.P.Pal.P.Palalalal.5ap#O#q#q#q#q#DaJ.d#wb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#3.t...9#p#r#r#r.R#P.6.6.6#N#Naoaoao.2.Dbt.q.2.q.2.2.q.q.q.q.2.2#2.2#2#2#2.qbtbtal.Palalalai#o#o#o.4.Q#p#M#LaP..#sa#b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1ak.E..b.#r#r.R.R.R.6.6.6#Naoao.D.D.2.q.q#I#I#I#F.z.M.ib0.#.#.#.#.#.#.#b0.i.MaI#F.q.q#2bt.P.Palalal.5ap#O.4#M#M#p#d...E.Bb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1a#aJ.d.Z#r#r.R#P.R.6.6#Nao.D.D.2.2#2.2#I.O.zby.#.#.#.#aC.gaQaQ.WaQbw.WaQ.gaC.#.#.#.#byaC.C#2#1bt#n#naiai#o#o.4#M#M#M#E..aJ#mb1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1a#.daJ.Z#r#r.R#P.6.6#N#N.Dao.2.2.q#I#IaI.i.#.#.caUbv.UaRaRaR#uaSaS#uaSaS##aS#####a.saW.c.#.#.i.o.q.qbt#nalai#o#o.4#M#M#p#EaJ.da#b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1a#.daJ#p#r#P.R.R.6.6#Naoao.2.2#2#IaH.M.a.#b0.e.UaRaRaRaRaR.TaR.TaS#uaSaS#uaS##aS###########aax.a.#.a.z.A#1bt#n#nai#o#oan#M#MahaJ.d#Zb1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1ad.E..#p#r.R#P.R.6#N#Nao.D.2.q.2#I.z.l.#bYbv.FaRaRaRaRaRaRaRaR#u.TaR.TaRaSaSaSaS##aS########bzbzbzaBbe.#.laI#2#1#n#nai#o.4an.3#pah...E#3b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1.E...Z#r#P#r.R.6#N#N.D.2.2.2#I#Hb0.#.caV.FaRaRaR.F.TaR.FaR.TaR.FaR.TaR.TaR#uaSbIaSaSaS########bzbz#Sbz#x.i.#b0#F#1#n#naiai.4an.3#p#E...Eb1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1.t..ae#r#r#r.6.6#Nao.D#2.2.A#Ibe.#.aas.F.TaR.F.T.FaR.FaR.F.FaR.FaR.FaRaRaRaRaRaR.TbIaS##aS##########bz#Sbz#SbP.k.#.M#2#1#nai#o#4anam#p#i..aXb1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1#A..b.#r#r#P.6.6#Naoao.2.2#I.Ob0.#.faSaRaRaR.F.F.FbO.F.FbO.FbO.FbKbOauauauau.m.maR#taR#ubIaSaS######bz##bz#Sa2a2a3bx.#.b#h#1#nai#o#4.3am#5bB...Jb1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1a#.d.9#r#r#P.R.6#N#N.D#2.2.A#F.#.#as.F.F.F.F.F.F.FbO.FbObObKbKbKaubRbRbRatbKatbKat#.bK#.aRaRaRbIaS######bzbz#Sbz#Sa2.Ha6.#.l#k#n#0br#o#4.3am#L.S.dadb1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1aO..#5#r#r.R.6#N#Nbt.2.2#IaI.l.baLaRaR.F.F.FbO.FbObObObKbKbRbRbRbR.p.S.S.S.p.S#saPaPaPaP#.auau#tbIbI##a0####bz#Sbz#Sa2.Ha9.a.lbx#n#0br#4#4.3#5ah..aOb1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1#7..#D#r#r#Pal.6.Pao.2.2.qaC.#.cbTaR.F.FaR.F.FbO.FbKbKbKbRbR.E.E.E.SaO.EaOaObQaObQ.p.S#saPaPbH.9bH#tbGbI#ua0#####Sa2a2a2a2a2a9be.#bp#nbr.N#4am.1.1b....Jb1b1b1b1b1b1b1",
-"b1b1b1b1b1b1ad.d.S#6#r#P#P.6#Nao.q.2bo#H.#bYbSaR.F.F.F.FbObObObK.SbR.S.E.E.E.E.E.E.E.EbQ.EaOaO.SbQ#saPaPaPaPbH.9.9.9#taZ#ta0bzbzbza2#SbD.H#T#UbZ.#aG#0br.Nafam.1#L.EaJbnb1b1b1b1b1b1",
-"b1b1b1b1b1b1#w..ah#r#r#P.6.P#Nbt.2#2#F.#.baSaR.F.FaRbObObOaqaq.S.E.E.E.E.E.EbN.EbN.E.E.E.EbQ.EbQaObQ.paP#saPaP.9.9#.az#.#.aZa0.vbz#Sa2a2a2#Ta3a4.a.l#k#0br#4af.1aj#E..#wb1b1b1b1b1b1",
-"b1b1b1b1b1ad.dbG.8#r.5.R.P#Nao.2.q#k.a.bbT.FaR.F.F.FbO.FbKbRbR.E.E.EbNaJbNbNaJbNaJbNbN.EbN.EaOaO.SaO.S#saPaPaP.9bH.9#.az#Q#.aZaZ#ybz#S#S#TbD#Tbda9.a.kblbrbr#4#Gaj#LaP.d#mb1b1b1b1b1",
-"b1b1b1b1b1#b..#L#r#r#P.6.Pao.q#2#I.i.#aMaR.T.F.F.FbObKaq.S.E.EaJbNaJaJ.EaJaJaJaJaJaJaJbN.E.E.E.E.EbQaObQaP#saPaPbH.9bHaz#.#QbGbG#R.vbza2a2.H#T#TbdaF.#.h.Kbr.Yaf#Gaj#l..a5b1b1b1b1b1",
-"b1b1b1b1b1aJ.9.8#r.5.5al#Nbt#2.2.z.#.eaRaR.FbO.FbObKbRbR.E.EaJbNaJaJaJaJaJaJaJaJaJaJ.EaJbNbN.E.EbQaO.pbQ.p.SaPaP.9bH.9#.az#.#Q#QbGa0#R#S#SbD#T#T#Ua3aG.#aCbrbraf#Gaj#L.SaJb1b1b1b1b1",
-"b1b1b1b1.J..#J#r#O#P.6#Nbt.q.2#k.lbYaR.FaR.F.FbObKbR.E.E.EaJ.EaJaJaJaJaJaJaJaJaJaJaJaJaJaJ.EbN.E.E.EbQaO.S#saP#sbH.9.9az#.azbG#QbG.JbB#y#Sa2#Ta3#Tbd#U.h.l#Bbr.Yafajah#W..#Ab1b1b1b1",
-"b1b1b1b1#saJ.8#O#r.5al.Pbt.q.Aby.#bTaRaR.F.F.FbObK.S.E.EaJbNaJaJaJaJaJaJaJaJaJaJaJaJaJaJaJaJ.EbN.EbQ.E.SaOaP.paPaP.9bHazaz#.azbG#QbBbB.vbz#SbD#T#Ubd#gba.#.M#0.Yaf#GbsahaJaOb1b1b1b1",
-"b1b1b1#m..#R#q#r.5.6.P.Pbt#2bj.#aUaR.F.T.F.F.FbKbR.E.EaJ.EaJaJaJaJaJ.daJbU.d.d.dbU.daJaJaJbNaJ.E.E.EaOaO.SaOaPaPaPbH.9.9#.az.u#Q#tbBbBa7#y#S#T#T#T#U#Ubdbx.##k#C.Yaf.1ah.u..adb1b1b1",
-"b1b1b1#b..ah#r#O.5al.Pbt.q.A.i.a.raR.TaRbO.FbKbR.E.E.EbNaJaJaJaJaJbU.dbV.d.dbV.dbV.dbVaJaJaJaJbNbN.E.EbQaO.S.paPaPaPbH.9az#.azbG#QbBbB#dbB#y#SbD#T#Ubd#Ubg.k.c#0.Ybmacaha....Jb1b1b1",
-"b1b1b1aOaJ.8#q#r.5al.Pbt.q#F.#aQaRaRaR.F.FbObKbR.E.EbNaJaJaJaJaJbUbUbU.dbUbV.dbU.dbUaJ.daJaJ.EaJ.E.EbQ.E.SaOaPaP#s.9.9atazaz#.#QbG#tbB#dbB#y#S#Tbd#UbdbfbfaE.#bo.YbmacbsahaJaXb1b1b1",
-"b1b1b1.dbB.8#O.5.5al.Pbt.Abe.#aw.TaR.F.TbObKbR.p.E.EbN.EaJaJaJ.dbUbU.dbV.d..bUbU..bUaJbUaJaJaJaJbN.E.E.EbQbQ.paPaPaPbH.9#.az#.#Q#QbBbB#d#R#Rb#bD#Tbd#U#Ubfba.#bY#C.Yacbsab.9.db1b1b1",
-"b1b1a#..#D#q#O#O.5.Pbt#2#I.laU.TaR.TaR.F.F.mbR.E.E.EaJaJaJaJaJaJ.dbUbU.dbU..bU....bU....aJaJaJaJ.EbN.E.E.paO.S#saPaP.9bH.9azaz#.#Q#t#tbBa7#R#ybb#T#Ubd#Ubfaabx.lbh#Xacahab#d..#Ab1b1",
-"b1b1#A..#L#q#O#Oalal.P#2aC.#.GaR.TaR.FbOaubR.EbQ.EbN.EbNaJaJaJ.dbV.d..bUbU........bU..bU.daJaJaJbN.E.E.EaObQ.paPaPaPbH.9az#.#.#QbG.JbB#dbB#db.#SbD#Tbdbfbfbfbh.#.I#Cbmababa...#7b1b1",
-"b1b1#b..#6#q#O.5alalbt.qby.baR.TaRaR.TbObObR.S.E.EbNaJaJaJaJaJaJ.dbUbUbU..............bUbUaJaJaJ.EbN.EbQ.EbQ.S#saPaP.9.9atazazbG#QbGbBbB#d#Rb.b#bbbd#U#Ubf.Xbf.abe#Xbmababae..#bb1b1",
-"b1b1.p.S.7#q#O.4ai.P#1#2.#aUaSaRaRaR.FbKbR.p.EaObN.EbNaJaJaJ.daJbUbU....bU............bUbUbUaJaJaJ.E.E.EbQ.pbQ.S#saP.9bHaz#.az#QbG.JbB#dbB#db.b.#S#Tbd#Ubfbf#Ybp.lbcbmababagaJaOb1b1",
-"b1b1aO#..7.Q.4.5al#nbt#F.#.saSaR.TaR.F.mbRaObQ.E.E.EaJaJaJaJaJbV.d.......................daJaJaJ.EbNbQ.EaObQ#saPaPaP.9.9ataz#..ubG#tbBaZa7#Rb.b.#9#Tbdbfbf.Xbf#B.#blbaab#Y#laP.Eb1b1",
-"b1b1..#d#p#q.4ap#o.PbtaC.#awaS#u.TaR.FauatbQ.EaO.EbN.EaJaJaJaJ.dbV.dbU..................bUaJaJaJbNbN.E.EbQaO.S.paP.9bH.9az#.azbG#QbBbB#da7#db.b.#S#Tbd#Ubfbf#Yba.#bjbmab#Y#l.9.db1b1",
-"b1b1..#9#p#M.4#oai#n#2.j.##uaSaR.TaRaRbObR.SaO.EbN.EaJbNaJaJaJbU.dbU....................bUbUaJaJ.E.E.E.EbQ.pbQaPaP.9.9ataz#.azbG#QbBbB#d#R#Rb.b.#9#Tbdbfbf.X#Y#Y.#bYbabg#YbqbG..b1b1",
-"b1b1..#i#p#M.4#oai#n#2by.gaSaS#u.TaRauat.S.pbQaO.EbN.EaJaJaJaJaJbU....................bU.daJaJaJbNbN.EbQaO.S.paP#saPbHazat#Q.u#Q#tbB#dbBa7#db.b.#Wbbbd#gbfbf#Ybf.M.hbaab#Yaa#Q..b1b1",
-"b1b1..b##p#M#M.4al#nbl.kbxaSaSaSaRaR.FataOaOaObQ.E.EbNaJaJaJaJaJaJbUbVbU................bU.daJ.EaJ.E.E.EaObQ#saPaP.9.9atazazbG#Q#tbBbB#R#d#R#Wb.#Wbbbdbf.Xbf#Y#YaC.kbabg#Yaa#Q..b1b1",
-"b1b1..#W#p#pan#oai#nbt.#.WaS#u#u.TaRauataP.SaO.E.E.E.E.EaJaJaJaJaJaJ.dbUbUbU....bUbUbUbUbUaJaJbN.E.EbQaObQ.paPaPaP.9bH.9#.azbG#Q#tbB#dbBa7b.b.b.#Wbbbd#U#Ybf#Y#Y#k.#babgbf#EbG..b1b1",
-"b1b1..#W#p#M#M#oai#nbl.#aQaSaSaSbIaR.Fat.paO.SaObQ.EbNbN.EaJaJaJaJaJaJ.daJbUbUaJ.dbUbU.daJaJaJ.EbN.EaObQ.pbQ#saP.9bH.9az#.az#QbG.JbB#d#R#Rb.b.#W#Wbb#gbfbf#Ybg#YaG.#babg.X#Eaz..b1b1",
-"b1b1..#W#p#Man.4ai#n#1b2.WaS##aSaSaR#tataP.SaOaOaO.EbQ.EbN.EaJaJaJaJaJaJaJaJ.daJaJaJaJaJaJbNbN.E.EbQ.EbQ.paPaP#saP.9.9azaz#.bG#QbBbBbB#d#db.b.#W#Wbbbdbfbf#Ybf#YaG.#a9bEaaaa.u..b1b1",
-"b1b1.daZ#p#5.3#o#o#nbl.#.W##aSaSaS#u.FataP#saP.SbQbQ.E.E.EbN.E.EbNaJaJaJaJaJaJaJaJaJaJaJaJaJ.E.E.EbQaOaObQ#saP.9bHazataz#.#Q#Q#tbBaZa7#R#R#Wb.#W#Wbb#gbfbf#Ybgbf#k.#babEbfa..9.db1b1",
-"b1b1.p.9#5#pan.4br#n#1.#.WaS##aSaSaRaR#.aP.SaPaO.paOaO.EbQ.E.EbN.E.EaJbNaJaJaJaJbNbN.EbN.E.E.E.EbQaObQ.S#saPaPaP.9.9.9az#.#QbGbBbB#da7#db.b.b.b##Wa.aabf.X#Y#Y#YaEb2a9.X#Ua..E.pb1b1",
-"b1b1aO.E#p#5.3#oai#n#1.#.W##aS##aS#uaRataP#saP.SaObQ.pbQ.EbQ.E.E.EbN.E.E.EbN.EbN.EaJ.E.E.EbQaObQaObQ.paPaPaPaP.9.9ataz#.bGaz#t.JaZa7#R#Rb.#W#W#W#9bbaabf#Ybg#Y#YaG.#a9bE#ga.aJ.pb1b1",
-"b1b1#b..#p#5#4#4.Nbr#1.abx####aS##aSaRau.9aP#saP.S.pbQbQ.paObQ.E.E.EbN.EbN.E.E.E.E.EbN.E.EaO.EbQ.paJbQ#s#saPbHbH.9az#.az#QbGbBbB#dbB#db.b.b.#W#W#9a.aabf#Ybfbgbf.z.ba9bE#ga...#wb1b1",
-"b1b1#7..#l#p#5an#o#0#1by.g######aS#ubIau.9aP#saP#saP.S.pbQbQaObQbQ.EbQ.E.E.E.EbN.E.EbQbQaObQ.SaObQaPaOaPbHaPbH.9atazazbG#..J#tbBa7#R#db.b.#Wb##W#9a.aabfbg#Y#YaabY.ha9#Ubdbz..#Ab1b1",
-"b1b1ad..#i#5am#4#4br.Kbe.#######aS##aSaRau.9aPaPaP#sbQ#s.S.pbQ.SaOaObQ.EbQaObQbQbQbQaOaOaO.SaO.paPaO#saP#sbH.9bHazaz#.#Q#Q#tbBa7a7#db.b.#W#W#W#9bbaabf#Y#Y#Y#Ybf.#aCbAa4bdaz...Lb1b1",
-"b1b1b1.d#.#5.3#4#4br#1aC.#a3#########u#ubG.9.9.9aPaPaPaPaOaP.SaObQ.SaOaOaObQ.SaOaO.pbQ.S.SaOaPaP#saPaPaXbHbH.9az#.#.#QbGbGbBbB#d#R#Rb.b.#W#W#W#9a.aabf#Ybg#Ybf#X.#aU.y#U#T.p.db1b1b1",
-"b1b1b1#saJ#5am.3#4br#0#h.#bM########aSbI#t.9bH.9.9aP#saPaP#saP#s.S.p.S.S.S.pbQ.S.SaO.p#sbQaP#saPaPbHaPbHbHbHazazaz#.#QbG.JbB#dbB#R#8b.#W#W#W#9#Wa.aa#Ybf#Ybgbf#B.##e#a#Ubb.d#sb1b1b1",
-"b1b1b1.J..aa#5#G#4br#0.K.laWbz#########ubG#..9.9bH.9.9aPaPaPaPaP#saPaP#saOaP.paP.paPaPaP#saPaPbHaPbHbHbH.9azazazbGazbB#tbBa7aZ#db.b.b.#W#Wb##9#9#Ebf#Y#Y#Ybfaabx.aa9a4#T##...Jb1b1b1",
-"b1b1b1.0..bB#5#G#4#4#0#1bZb0bzbz#########ubGaz#..9.9bH.9.9aP#saPaPaP#saPaPaPaPaPaPaP#saPaPaPbHaP.9.9.9.9azazaz#..ubB#tbB#dbB#R#db.b.#W#W#W#9bia.aa#Y#YbE#Y#Ybf.kbYbAa4#T.p...0b1b1b1",
-"b1b1b1b1.paJ.1#G#G#4br.Kbx.#a1bz##bC####bI#taz.9azat.9bH.9.9.9.9aPaPaP#saPaP#saPaPaP.9bH.9.9.9.9.9.9#.az#.#.#.#QbBbG.JbBbB#d#Rb.b.b.#Wb##9#W#9#Ebf#Ybf#Ybfbfbh.#ax#aa3#TbU#sb1b1b1b1",
-"b1b1b1b1#A..#i.1af#4#Cbrbl.l.Ibzbz##bC#####uaZ#.azaz#.azatbHbH.9.9.9.9.9.9.9.9.9.9bH.9.9bH.9at.9az#.azazazbGazbG#QbBbB#d#d#R#8b.#W#W#W#W#9#9a.aa#Y#Y#Y#YbfbfaC.aaY.x#v.9..#Ab1b1b1b1",
-"b1b1b1b1b1.E.Saj#Gaf#4#0.KbY.#.x#Sbzav#######taz#.#.az.9az#.azat.9.9bHbH.9bH.9bH.9.9.9at.9bHaz#.azaz#.azbG#Q#tbBbB#dbBa7#Rb.b.b.b.b##W#9bi#D#Ebfbfbg#Y#Ybfbk.#aCbAaV#TaJaJb1b1b1b1b1",
-"b1b1b1b1b1#b..bq#G#G.Y#C#0aE.#a8bz#SbzbzbC##a0aZbGaz#.#.#.azatazazazat.9#.az#.az#.azataz#.az#.azaz#.azbG#QbG#QbB#dbBa7#R#db.b.#W#W#W#9#9#9a.bf#Y#Y#Y#YbfaaaE.#aBaVa3##..#bb1b1b1b1b1",
-"b1b1b1b1b1.0.daP.1#Gafbrbr.Kby.a#vbz#Sbzbz##a0aZ.u#Q#.azaz#.az#.azatazazazataz#.az#.az#.azaz#.#.bG#QbG#QbB#QbB#dbB#d#R#Rb.b.#W#W#W#9#W#9#D#Ebf#Y#Ybgbfbfbg.abZayaVa2aJ.d#3b1b1b1b1b1",
-"b1b1b1b1b1b1#b..#g#Gaf.Y#CaFaE.#aW#Sbz#S#Sbz####aZbG#QbG#Q#.az#.az.u#.#.az#.az#.az#.azbGazbG#Q#Q#QbGbBbBbB#dbB#d#R#Ra7#Wb.#W#W#W#9#9#9#Da.bf#Y#Ybf#Ybfaabx.#aNaV.H##..#wb1b1b1b1b1b1",
-"b1b1b1b1b1b1.0.d.Ebs#Gaf.Y#Cbhbe.#bA#Sbzbz#Sbzbz.vaZ#QbG#QbG#QbG#QbGaz#Q#.#Q#.#QbG#QbG#QbG#QbGbGbB#QbBbB#dbBa7#Ra7b.b.b.#W#W#Wb##9bi#Da.bf#Y#Y#Y#Ybfbfbm.#.gaya3aw.d.d.Bb1b1b1b1b1b1",
-"b1b1b1b1b1b1b1.J..#dbsafaf#CaF#B.a.ha2.H#Sbz#Sbz#ya0bB#QbG#QbG#QbG.u#QbG#QbG#QbG#QbG#QbG#QbBbB.JbBbB#d#dbB#R#R#db.b.b.#W#W#W#9#9bi#D#9#Eaa#Y#Y#Ybfbfaa.h.a.VaVaw.p..#Ab1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1aO..#Yacbm.Y#CaFbx.#.wa2a2a2a2#Sbz#ya0#RbBbBbB#t#QbGbG#QbG#QbG#Q#tbBbBbBbB#tbBaZ#d#dbB#R#R#db.b.b.b.#W#Wb#b#bi#9#Da.aabf#Y#Ybfbfbfaabj.#axaV#vav..#sb1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1#m.d.Sbsacbm.Y#CaF.h.##ca2a2a2a2#Sbzbz#y.vbB.JbBbB.JbBbBbBbBbBbB.JbBbB#dbB#d#dbBa7#R#Ra7b.b.b.b.#W#W#W#W#9bi#9#Da.bfbq#Y#Ybgbf#Ybfbh.#.gayaTbLaJ.d.Lb1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1#7...9bsbmbmbcbcbh.k.aa9.Ha2.Ha2#S#S#Sbz#ya0#dbBaZ#dbB#dbB#dbBaZ#d#dbB#dbB#d#R#R#d#db.b.b.#W#W#W#Wb##9#9#9a.a.bf#Ybf#Y#Y#Ybfaaba.a.baMaTaw.E...Jb1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1aX..#dbsbm#X#X#ca8.a.a#UbD.HbD.Ha2a2#Sbz#S.va7#dbB#dbBaZ#dbB#da7aZ#d#R#R#R#R#8b.b.b.b.#W#W#W#Wb##9bi#9a.aabf#Y#Y#Y#Ybfbfaabg.a.a.saTaw.p...tb1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1.E..a3#jac#X#XbcaG.#bZ#U#T#T.HbD.Ha2#S#S#S#y#y#y#R#d#d#R#R#R#R#d#Ra7#8b.b.b.b.#W#W#W#W#Wb##9bia.a.a.aa#Y#Y#Y#Ybgbfbfbfbg.h.#bMbTawbu...Eb1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1.L.E.d.Xabbabmbcbc.I.#.h#x#T#T#T#T#T#TbDa2#S#S#S#y#yb.a7#8#Rb.b.b.#Wb.b.#W#W#W#Wb##Wb##9bibba.aabfbf#Y#Ybgbf#Ybf#YbfbF.i.#bwaLaw.r.d.E.0b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1.0.d.dbfab#jba#Xbc.I.l.aba#U#T#T#Ta3#T#T#TbD#TbDbDb##S#S#fb.#Wb.b.#W#Wb.#W#W#W#Wa.bbbba.aaaabfbf#Ybgbf#Y#Ybfbfbfbm.a.abwbTaw.rbU.d.Lb1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1bn.d.d.Hbkbkba#X#za6.a.#a8bda3#U#Tbda3#Ta3#T#T#TbbbDbbbD#9#Sbbbbbbbbbbbbbbbbbbbdbdaaaabfbf#Y#Y#Y#Y#Y#YbfbfaabJ.#.abvaLbLbu.d.d#mb1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1#AaJ...H#Vbkbaba#z.n.i.#aCbEbd#U#Ubd#Ubd#Ubd#U#Tbd#Tbd#TbDbb#Tbd#Tbdbd#gbdaabf.Xbfbf#Y#Y#Ybg#Y#YbfbfbfbgbY.#.c.Gawawbu..aJ#mb1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#ZbN..bHbg#V#Vbabaa1aC.#.aa8bd#Ubda3bda3bdbd#U#U#U#Ubd#g#Uaa#gbf#gbfbfbfbf.X#Y#Y#Ybg#Y#Ybf#Ybfbf#YbJ.a.#.f.UaKbLaJ...p.0b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#m.t...Ebf#V#Va9ba#x.W.i.#.i#c#Ubf#Ubf#U#U#U#U#Ubf#Ubfbf#Ubfbfbf.Xbf.Xbf#Y#Ybgbf#Ybfbg#Ybfbf#C.i.#.hasawaK.r.d...t.0b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#A...d.ubEaDa9a9#xaY.I.l.#bea6bfbfbfbfbfbfbfbfbfbfbfbfbfbf.Xbf#Y#Y#Y#Ybgbf#Ybg#Ybfbfbl.h.#.a.e.UaKbLaJbUbU#7b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#Z.E..bQa3bEaDaDbAa9a1bxb0.#.a.I#Xbfbfbfbfbf.Xbf.X#Y.X#Y#Y#Y#Ybg#Ybg#Y#Ybfbf#Xbj.a.#.bbWaraKbLbu.d...E#Zb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#w.d..aPa3bEaDaDbA#xaA.wbZ.#.#.ibp#B#X#Y#Y#Y#Ybg#Ybg#Ybg#Y#Ybf#Ybcblbp.b.#.#bYbwaLaLbL.r.d..aJ#bb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#Z#s.....pa3.xa4#a#aayaAa1aUbY.#.#.#.#bebYaGaGaGaGaG#kaGbYbe.#.#.#.#.gaxaMaLaKbLbuaJ....aX#mb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1a#aX.....Eaz#UaVa4#a#aayayayaNax.fbY.h.#.#.#.#.#.#.#.hbYbX.easaLaLaLbL.rbN.d....#sadb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1ad.t.d...daOava3a3aTaTaTaVaVaV.UaV.UbTbTbTbTaLaLaLaLaLaw.r.r.rbu.dbU...daX#Zb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#7#s......aJ.pavbzbzbzawbzavavavav.ravavav.raS.TbuaJ.d......#s#7b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1ad#A.t.E........aJaJaO.E.E.E.EaJ.EaJ.d.d........aJ#s#A#Zb1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1#3a##b#w.p.E...........d.....EaO#w#wa##3b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-"b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1b1",
-};
diff --git a/sandbox/bouton.xpm b/sandbox/bouton.xpm
deleted file mode 100644
index ea8065f..0000000
--- a/sandbox/bouton.xpm
+++ /dev/null
@@ -1,329 +0,0 @@
-/* XPM */
-static char *on[] = {
-/* width height num_colors chars_per_pixel */
-" 90 86 236 2",
-/* colors */
-".b s mask c none",
-".. c #f8fcf8",
-".# c #f8fcf0",
-".a c #f8fce8",
-".c c #f8f4f0",
-".d c #f8f4e8",
-".e c #f8f4e0",
-".f c #f8ece0",
-".g c #f8ecd8",
-".h c #f8ecd0",
-".i c #f8e4d8",
-".j c #f8e4d0",
-".k c #f8e4c8",
-".l c #f8dcc8",
-".m c #f8dcc0",
-".n c #f8dcb8",
-".o c #f8d4b0",
-".p c #f8ccb0",
-".q c #f8cca8",
-".r c #f8cca0",
-".s c #f8cc98",
-".t c #f8c498",
-".u c #f8c490",
-".v c #f8bc98",
-".w c #f8bc90",
-".x c #f8bc88",
-".y c #f8bc80",
-".z c #f8b490",
-".A c #f8b488",
-".B c #f0ecd8",
-".C c #f0e4d8",
-".D c #f0e4d0",
-".E c #f0e4c8",
-".F c #f0dcc8",
-".G c #f0dcc0",
-".H c #f0d4b8",
-".I c #f0d4b0",
-".J c #f0ccb0",
-".K c #f0cca8",
-".L c #e8e4d0",
-".M c #e8dcc8",
-".N c #e8d4b8",
-".O c #e8d4b0",
-".P c #e8ccb8",
-".Q c #e8ccb0",
-".R c #e8cca8",
-".S c #e8c4a8",
-".T c #e8c4a0",
-".U c #e8c498",
-".V c #e8bc98",
-".W c #e0c4a8",
-".X c #e0c4a0",
-".Y c #e0c498",
-".Z c #e0bc98",
-".0 c #e0bc90",
-".1 c #e0b488",
-".2 c #e0b480",
-".3 c #e0ac88",
-".4 c #e0ac80",
-".5 c #d8d4c0",
-".6 c #d8bca0",
-".7 c #d8bc98",
-".8 c #d8b498",
-".9 c #d8b490",
-"#. c #d8b488",
-"## c #d8ac88",
-"#a c #d8ac80",
-"#b c #d8ac78",
-"#c c #d8a478",
-"#d c #d8a470",
-"#e c #d89c70",
-"#f c #d0c4b0",
-"#g c #d0bca8",
-"#h c #d0bca0",
-"#i c #d0b498",
-"#j c #d0b490",
-"#k c #d0ac88",
-"#l c #d0a480",
-"#m c #d0a478",
-"#n c #d0a470",
-"#o c #d09c70",
-"#p c #d09c68",
-"#q c #d09468",
-"#r c #d09460",
-"#s c #c8bcb0",
-"#t c #c8bca8",
-"#u c #c8b498",
-"#v c #c8a480",
-"#w c #c89c70",
-"#x c #c89468",
-"#y c #c88c60",
-"#z c #c88c58",
-"#A c #c88458",
-"#B c #c88450",
-"#C c #c0ac98",
-"#D c #c0ac90",
-"#E c #c0a478",
-"#F c #c09c78",
-"#G c #c08c68",
-"#H c #c08c60",
-"#I c #c08458",
-"#J c #c08450",
-"#K c #c07850",
-"#L c #c07848",
-"#M c #c07048",
-"#N c #b8b4a0",
-"#O c #b8aca0",
-"#P c #b8a490",
-"#Q c #b8a488",
-"#R c #b8a480",
-"#S c #b89c80",
-"#T c #b89470",
-"#U c #b88c60",
-"#V c #b87848",
-"#W c #b87048",
-"#X c #b87040",
-"#Y c #b86840",
-"#Z c #b09c80",
-"#0 c #b09470",
-"#1 c #b08c68",
-"#2 c #b07850",
-"#3 c #b06840",
-"#4 c #a8a490",
-"#5 c #a88c68",
-"#6 c #a87858",
-"#7 c #a87050",
-"#8 c #a86840",
-"#9 c #a08c70",
-"a. c #a07050",
-"a# c #a07048",
-"aa c #a06038",
-"ab c #989488",
-"ac c #989480",
-"ad c #988c80",
-"ae c #988c78",
-"af c #988460",
-"ag c #987860",
-"ah c #987858",
-"ai c #986848",
-"aj c #986038",
-"ak c #985838",
-"al c #908470",
-"am c #908468",
-"an c #906040",
-"ao c #906038",
-"ap c #905838",
-"aq c #888478",
-"ar c #887870",
-"as c #887868",
-"at c #887060",
-"au c #887058",
-"av c #886850",
-"aw c #886848",
-"ax c #885030",
-"ay c #807060",
-"az c #807058",
-"aA c #806858",
-"aB c #806850",
-"aC c #805838",
-"aD c #787070",
-"aE c #787068",
-"aF c #787060",
-"aG c #786860",
-"aH c #786048",
-"aI c #785840",
-"aJ c #785030",
-"aK c #784830",
-"aL c #706860",
-"aM c #706058",
-"aN c #706050",
-"aO c #705848",
-"aP c #705840",
-"aQ c #705038",
-"aR c #704830",
-"aS c #704828",
-"aT c #686060",
-"aU c #686058",
-"aV c #686050",
-"aW c #685850",
-"aX c #685848",
-"aY c #685840",
-"aZ c #684028",
-"a0 c #605048",
-"a1 c #605040",
-"a2 c #604838",
-"a3 c #604028",
-"a4 c #585048",
-"a5 c #584840",
-"a6 c #584838",
-"a7 c #583820",
-"a8 c #504840",
-"a9 c #504038",
-"b. c #504030",
-"b# c #503828",
-"ba c #503020",
-"bb c #503018",
-"bc c #484840",
-"bd c #484038",
-"be c #484030",
-"bf c #483828",
-"bg c #483020",
-"bh c #403838",
-"bi c #403830",
-"bj c #403828",
-"bk c #403028",
-"bl c #403020",
-"bm c #383830",
-"bn c #383030",
-"bo c #383028",
-"bp c #382820",
-"bq c #382018",
-"br c #382010",
-"bs c #302828",
-"bt c #302820",
-"bu c #302818",
-"bv c #302018",
-"bw c #302010",
-"bx c #301810",
-"by c #282828",
-"bz c #282820",
-"bA c #282020",
-"bB c #282018",
-"bC c #281810",
-"bD c #201818",
-"bE c #201810",
-"bF c #201008",
-"bG c #181818",
-"bH c #181810",
-"bI c #181010",
-"bJ c #181008",
-"bK c #180808",
-"bL c #100808",
-"bM c #080808",
-"bN c #080800",
-"bO c #080000",
-"bP c #000000",
-/* pixels */
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.A.r.p.m.g.f.................f.i.m.n.r.u.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.u.q.l.d.........P.N##############.8.N.N.........d.j.o.s.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.n.i.......P###I#L#3#3#3#3#3#3#3#Y#3#X#Y#X#3#Y#L#y##.N.......j.q.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.r.j.c...d.X#x#3#3#3#3#3#3#3#X#3#X#X#X#3#X#X#3#X#X#X#W#X#X#X#Y#q.X.d...c.m.x.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.w.j.#...N#o#3#3#3#3#3#3#3#X#X#3#X#X#3#X#X#X#X#X#W#X#W#W#X#X#W#W#X#W#X#Y#m.N.....j.t.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.w.l.....X#K#3#3#3#3#3#3#Y#X#X#X#3#X#X#W#X#W#X#W#W#W#X#W#X#W#W#W#W#W#V#V#M#V#W#M#I.X.....k.w.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.n.c...X#W#3#3#3#3#3#X#3#X#X#3#X#X#W#X#W#X#W#X#W#W#W#V#L#V#L#V#L#V#L#V#L#W#L#W#L#V#W#M#J.W...d.n.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.r.d...F#I#3#3#3#3#3#X#3#X#X#3#X#WaxaZbbbCbFbPbPbPbPbPbPbPbFbxbaaZap#L#L#L#K#L#L#K#L#L#K#L#K#M#q.D...f.r.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.o.c.d#m#3#3#3#3#3#X#X#3#X#XaaaZbrbPbPbPbPbibmaEaFaFaGaFaGaGbmbmbPbPbPbPbqaZ#8#K#K#K#K#K#L#K#L#K#K#M##.d.c.m.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.x.l...F#J#3#3#3#3#Y#X#X#3#XaSbCbPbPbDa4ad#t.E.D.F.E.F.F.F.F.G.G.G.G.G#Nala4bGbPbPbCaJ#J#J#J#J#J#J#J#K#J#K#x.D...j.r.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.y.f...X#3#3#3#3#X#X#3#X#8a7bKbPbIaU#t.D.j.D.D.j.F.D.F.E.F.E.F.F.G.G.G.N.G.G.H.N#CaWbLbPbJa3#W#J#K#J#J#J#J#J#K#J.Q...f.z.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.r.d.c#o#3#3#3#3#X#3#X#Xa3bObPbsac.D.j.D.j.D.j.D.D.j.D.j.D.E.F.E.M.F.M.G.G.N.G.N.H.N.N.OalbAbPbMaR#I#A#I#B#I#J#J#K#K#a...d.w.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.r.c.d#o#3#3#3#3#X#X#XaxbFbPbD#N.D.i.D.D.j.D.D.i.D.j.D.j.D.D.D.D.E.F.E.F.M.G.F.N.G.G.N.N.N.Q.O#ZbHbPbEan#A#I#I#A#A#I#A#I#a.d.c.r.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.r.c.d#J#3#3#3#X#X#3#XbabPbIaq.D.i.j.D.D.g.B.i.B.i.g.C.i.D.j.D.j.D.D.D.E.F.F.F.G.G.G.N.N.H.N.Q.Q.Q.QaybLbPba#z#A#z#I#B#I#B#I#q.d.c.t.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.u.f..#J#3#3#3#X#X#XaabEbPbc.M.D.g.D.B.g.g.C.i.B.i.g.B.i.g.C.C.j.D.j.D.D.D.F.E.F.M.G.G.N.G.N.N.N.Q.Q.R.R.6bebPbE#2#A#z#z#z#z#A#I#p...f.w.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.f..#o#3#3#X#X#X#WapbNbPaq.j.C.j.B.i.C.C.B.g.g.g.B.g.g.B.i.B.g.C.i.D.j.j.D.D.F.E.F.M.G.G.N.G.N.N.N.Q.Q.W.R.WaybPbNa##z#I#z#I#z#z#A##...f.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.l..#l#3#3#X#3#X#WaSbNbL#s.j.D.g.B.i.B.g.g.i.g.B.f.g.f.f.g.g.g.C.g.B.i.C.D.j.D.D.F.E.F.F.M.G.N.G.N.N.O.Q.Q.R.R.S#QbMbMaC#y#y#z#y#I#z#A.0...k.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.q...X#3#3#X#X#X#XaSbPbD#s.j.B.B.i.C.g.f.g.f.B.f.f.f.f.B.f.B.f.f.g.B.i.B.i.C.D.j.D.D.F.F.F.G.G.G.N.H.N.N.Q.Q.R.W.W.T#SbAbPaC#y#z#y#z#y#y#z.Q...p.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.r.c.F#W#X#X#3#X#WaxbPby.M.D.B.i.i.B.g.f.B.f.f.f.f.f.B.f.f.f.f.f.B.f.g.B.g.B.g.D.C.j.D.D.F.E.M.G.N.G.N.N.N.Q.Q.W.R.W.W.X.8bBbPai#y#y#y#z#z#y#y.C.c.u.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.g..#J#3#X#3#W#XakbMbL.M.j.g.C.B.g.f.B.f.f.f.f.f.f.e.f.e.e.f.e.f.f.f.f.f.g.C.g.g.D.D.j.D.E.F.F.M.F.N.G.N.H.N.Q.Q.R.W.R.X.X#jbMbM#7#p#r#q#y#y#y#o...g.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.o..###X#3#X#X#X#3bJbL#s.D.D.C.i.g.g.B.f.f.e.f.e.e.d.f.d.f.d.e.d.e.f.e.f.B.f.f.B.C.B.i.D.D.D.E.F.G.F.G.G.N.N.N.O.Q.R.R.W.X.Z.X#SbLbJ#H#x#r#q#r#r#r.X...p.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.u.c.C#V#3#X#X#W#VbCbP#4.h.D.g.g.B.f.B.f.f.f.f.e.d.d.f.d.e.d.d.d.d.d.e.f.e.f.f.B.f.g.g.i.D.j.D.D.E.M.G.F.N.G.N.N.Q.O.W.Q.X.S.X.X.ZambPbl#q#p#q#q#x#q#q.f.d.s.b.b.b.b.b.b",
-".b.b.b.b.b.b.m..#x#Y#X#W#W#WaZbPaT.j.C.g.C.B.g.B.f.f.f.e.e.d.f.d.d.d.d.d.d.d.d.d.d.d.f.e.f.f.B.g.C.B.j.C.D.D.F.F.F.G.N.G.N.H.P.Q.Q.W.S.W.X.Z.Z.Ya1bPaQ#p#p#q#p#q#x##...m.b.b.b.b.b.b",
-".b.b.b.b.b.u.c.N#X#X#X#X#W#8bNbs.h.D.j.C.g.i.f.g.f.f.e.d.d.d.d.d.d.d.d.d.d.d.d.d.d.d.d.e.f.e.f.f.g.B.C.j.D.j.D.F.F.M.G.N.G.N.N.Q.Q.R.W.T.X.X.Z.Z.ZbBbM#U#q#p#q#p#q#q.D.c.w.b.b.b.b.b",
-".b.b.b.b.b.n..#y#X#W#W#W#LbrbP#t.D.j.C.g.C.f.B.f.e.f.d.f.f.d.d.d.d.d.d.d.d.d.d.d.d.d.d.d.e.f.f.B.f.g.g.C.D.D.D.E.F.G.F.G.N.N.N.O.Q.Q.R.W.X.X.X.Z.7#FbPb##p#o#p#q#p#q#a...n.b.b.b.b.b",
-".b.b.b.b.b.d.F#3#W#X#W#LaxbPa4.D.D.D.g.C.g.B.f.f.f.e.f.d.d.d.d.d.d.c.#.d.c.c.#.c.d.d.d.f.d.e.f.f.g.B.C.B.j.D.D.F.F.M.F.N.G.N.N.Q.O.W.R.W.X.X.Z.Z.Z.9a9bPa.#o#p#o#o#p#q.C.d.b.b.b.b.b",
-".b.b.b.b.p..#o#W#X#W#V#VbwbI.N.C.j.C.g.C.g.f.g.f.e.d.d.d.d.d.c.#.c.a.c.#.c.a.c.a.c.d.d.d.e.f.e.f.f.B.g.i.D.j.D.E.F.F.G.N.G.N.H.Q.Q.Q.R.W.T.X.Z.7.Z.9#kbMbu#e#e#o#p#o#p.Z...q.b.b.b.b",
-".b.b.b.b.j.d#X#X#W#V#MajbPaE.D.D.D.i.B.g.B.f.f.f.f.e.d.d.d.d.#.#.#.c.#.d.#.c.#.c.a.d.d.d.d.d.f.f.f.g.B.B.i.D.D.D.F.E.M.G.N.G.N.N.Q.R.Q.W.X.X.X.Z.Z.9.0aXbP#6#d#e#e#e#o#p.c.g.b.b.b.b",
-".b.b.b.w...W#W#X#L#V#LbgbP#f.D.j.D.h.C.i.f.B.f.f.d.f.d.d.d.d.#.c.#.d.#...#.#...#.c.#.d.d.d.d.e.f.f.f.C.g.C.j.D.D.F.F.G.G.G.N.N.O.Q.Q.W.T.W.Z.X.Z.7.0.9#FbPbf#c#n#n#o#e#o.H...u.b.b.b",
-".b.b.b.n..#x#X#L#W#V#WbOa4.D.j.D.C.i.C.g.B.f.f.e.e.d.d.d.c.d.c.#.#.c.#...#.....#.#...d.d.d.d.f.f.f.f.B.g.D.D.D.D.E.M.G.F.N.N.N.P.Q.Q.R.W.X.X.X.Z.Z.9.9.9b.bM#w#c#c#e#d#o.0...p.b.b.b",
-".b.b.b.i.d#X#V#V#L#KaKbP#4.j.F.D.j.B.g.g.f.g.f.f.d.d.d.d.d.d.#.c.#.#.c.........#...#.d.c.d.d.e.f.e.B.g.C.g.C.j.D.F.F.M.G.N.G.N.Q.O.Q.R.W.X.X.Z.7.Z.9.0#.agbPaw#c#m#c#m#e#o.c.k.b.b.b",
-".b.b.b.c.Q#W#M#V#L#KbqbL.F.D.D.j.C.i.C.B.g.f.e.f.e.d.d.d.d.d.c.a.#...#.............#.#.d.d.d.d.f.f.f.g.B.C.j.D.D.F.E.G.G.N.G.N.P.Q.Q.R.S.W.X.X.Z.Z.9.9.9#.bMbk#c#c#c#c#c#c.F.c.b.b.b",
-".b.b.r..#a#V#V#L#K#JbMa4.F.l.D.D.j.B.g.g.f.B.f.d.f.d.d.d.c.a.c.....................#...#.d.d.f.e.f.f.C.g.i.D.D.D.F.F.M.G.G.N.N.O.Q.Q.R.W.X.X.Z.Z.Z.9.0#.#.b.bM#b#a#c#c#c#n.S...q.b.b",
-".b.b.q..#x#M#L#K#KaobPae.E.D.D.j.C.g.i.f.g.f.e.f.d.d.d.d.c.d.#...#...................d.d.d.e.d.f.f.f.g.B.C.j.D.D.E.M.G.G.N.G.N.Q.O.W.R.S.W.Z.X.Z.7.0.9#.#.avbP#1#a#c#a#b#c.0...o.b.b",
-".b.b.n..#X#L#K#K#JaRbP#f.F.F.k.D.D.D.B.B.g.f.f.e.e.d.d.d.d.#.c.a.#...................#.c.d.d.f.e.f.B.B.i.B.D.D.F.F.F.G.G.N.N.N.Q.Q.Q.R.W.X.X.Z.Z.7.9.9#.###FbPaH.4#a#a#c#a#c...n.b.b",
-".b.b.i.C#L#L#L#J#JbgbP.F.E.D.D.D.i.j.i.C.B.g.f.f.d.f.d.d.d.d.#.......................#.#.d.d.e.f.e.f.B.g.C.j.D.D.F.F.G.G.N.N.H.Q.Q.R.W.S.X.X.Z.Z.Z.0.9#.###.bPb..3#a.4#a#a#c.d.f.b.b",
-".b.b.i.N#L#K#K#J#Kbwbn.G.F.F.F.D.D.D.B.i.g.f.e.f.e.d.d.d.c.a.c.#...................#.#.d.d.e.d.f.f.g.g.C.i.D.D.F.E.G.M.N.G.N.N.O.Q.Q.R.W.X.X.Y.Z.9.9#..9#a#.bpbt.2.1#a.4#a#a.D.g.b.b",
-".b.b...Q#K#K#J#J#AbJbd.G.E.F.D.j.j.B.i.g.g.B.f.f.e.d.d.d.d.d.d.#.#.#.................#.c.d.d.e.f.f.B.B.g.D.j.D.E.F.M.G.G.N.N.P.Q.Q.R.W.S.Z.X.Z.Z.7.0#.#.###.bkbH.1#..1.1.4#a.F.c.b.b",
-".b.b...9#K#J#J#K#IbPaG.F.F.E.E.D.D.j.D.g.C.f.f.f.e.f.d.d.d.d.d.d.#.#.#.#.....#.#.#.#.#.d.d.f.f.f.B.f.g.C.j.D.D.F.F.G.G.N.N.N.P.O.Q.W.R.X.X.Z.7.Z.9.9.9#.###aaYbP.1.1.1#..2##.H...b.b",
-".b.b...0#K#J#J#A#AbPaL.G.F.F.F.j.D.i.D.g.g.B.g.f.f.f.e.e.d.d.d.d.d.d.d.a.#.a.c.#.#.c.d.d.e.e.f.e.g.B.i.B.D.j.F.E.M.F.G.G.N.H.Q.Q.R.R.W.X.X.X.Z.7.0.9#.###.##aYbP.0.1.1.1#..2.N...b.b",
-".b.b...8#J#J#J#I#AbPaL.G.G.E.F.F.j.D.j.C.i.g.B.f.B.f.f.f.e.d.d.d.d.d.d.c.d.d.d.d.d.d.d.d.d.f.f.B.f.i.B.j.D.D.D.F.F.G.G.N.N.N.Q.Q.Q.W.S.X.X.Z.Z.0.9.9#.#.#a#.aYbP.0.0.1.1.1#..H...b.b",
-".b.b...Z#K#J#I#A#zbPaL.G.G.G.F.E.D.j.D.D.D.C.g.B.f.f.e.e.f.f.f.d.d.d.d.d.d.d.d.d.d.e.d.f.f.f.f.B.g.B.C.j.D.D.E.F.M.G.G.N.N.P.Q.Q.R.R.W.Z.X.Z.Z.7.9#.#.######aYbP.0.0.0.0.1.1.N...b.b",
-".b.b...Z#K#A#A#A#IbPaG.G.G.G.M.F.F.D.D.j.i.B.g.g.g.f.B.f.f.e.e.f.d.e.d.d.d.d.e.f.e.d.f.f.e.B.g.g.C.g.j.D.D.F.F.F.G.G.N.N.N.O.Q.W.R.W.X.X.Z.Z.7.0.9.9#.###a#.aYbP.Z.0.0.0.1.0.G...b.b",
-".b.b...Z#J#I#I#z#zbPaG.N.G.G.F.E.F.F.D.D.D.j.B.i.B.B.f.B.f.f.f.e.f.d.f.f.e.f.e.d.f.f.f.f.B.f.B.B.g.D.D.D.D.E.F.M.G.G.G.N.N.Q.Q.Q.W.S.X.X.Z.Z.9.9.9#.#.#a#.##aPbP.V.Z.0.0.0.3.G...b.b",
-".b.b.c.Q#I#B#z#z#zbJbd.G.N.G.G.F.E.F.F.D.j.C.j.C.g.i.B.f.B.f.f.f.f.f.f.e.f.f.f.f.f.f.f.B.f.g.g.d.j.C.j.D.D.M.F.G.G.G.N.N.N.Q.R.R.R.W.Z.X.Z.Z.7.0#.#.#a###.#.bjbI.U.Z.V.Z.0.0.F.c.b.b",
-".b.b.i.M#I#z#I#z#ybvbn.G.N.G.G.G.F.F.F.j.D.D.D.B.D.B.B.i.B.g.B.f.B.f.f.f.f.e.f.f.B.g.B.g.g.C.B.D.B.j.D.E.E.F.M.G.G.N.N.N.Q.Q.Q.S.W.X.X.Z.Z.7.9.9.9#.#.#a###.bpbo.Y.V.Z.Z.Z.0.f.i.b.b",
-".b.b.g.f#J#A#z#y#zbgbP.N.G.N.G.G.G.M.E.F.D.E.j.D.j.i.C.g.C.B.g.g.B.f.B.g.B.B.B.B.g.B.g.C.B.i.j.i.j.D.k.E.F.F.G.G.N.G.N.Q.Q.Q.W.W.T.X.Z.Z.Z.9.0#.#.#####.#.#.bPa6.T.U.Y.V.Z.0.d.i.b.b",
-".b.b.n..#A#I#z#y#yaQbP#h.N.G.N.G.G.G.F.F.F.D.D.D.D.D.j.D.g.C.B.i.B.g.g.B.i.B.g.g.C.i.B.i.D.D.D.D.D.k.E.E.E.G.G.G.N.N.N.O.Q.R.R.W.X.Y.X.Z.7.0.9.9#.###a###.#0bPay.T.T.U.Y.V.Z...m.b.b",
-".b.b.p..#m#z#z#z#y#7bPal.N.N.G.N.N.G.G.F.F.F.F.j.D.D.D.j.D.j.C.C.i.C.C.i.B.i.C.C.g.D.i.D.D.j.D.E.D.E.E.E.G.G.G.N.N.N.Q.Q.Q.R.W.T.X.X.7.Z.0.8#.#.#.#a#.#..1aubP#R.T.T.X.T.U.Q...q.b.b",
-".b.b.u...8#z#y#y#r#qbNa4.N.N.N.N.G.M.G.G.G.F.E.F.F.D.D.D.D.D.D.h.D.D.g.D.i.D.C.h.D.j.D.D.j.D.D.D.E.F.E.G.G.G.N.N.N.N.Q.Q.R.W.W.X.X.Z.Z.Z.9.9#.#.#a#.###..9b.bM.K.S.T.T.U.Y.G...v.b.b",
-".b.b.b.c.N#z#z#y#r#qblbL.N.H.N.G.N.G.N.M.G.M.F.F.E.F.E.D.j.D.j.D.D.j.D.D.D.D.j.D.D.D.D.D.E.F.F.F.F.E.G.G.G.N.G.N.P.Q.Q.R.W.R.X.Z.Z.Z.7.9.0.9#.#####a#.#..1bMa9.K.R.T.S.T.T.C.c.b.b.b",
-".b.b.b.j.d#y#y#y#q#qaIbPae.N.N.N.G.N.G.N.G.G.G.M.F.E.F.F.F.F.D.D.D.D.D.D.D.D.D.D.F.D.F.D.F.E.M.G.G.G.G.G.N.N.N.Q.O.Q.R.R.W.X.X.X.Z.Z.0.7.9#.#.###a#.#.#.agbPam.K.R.K.T.S.T.c.j.b.b.b",
-".b.b.b.p..#a#z#q#r#p#ybMa5.Q.P.N.N.N.N.G.N.G.G.G.G.G.F.E.F.E.F.F.F.F.F.F.F.F.F.F.E.F.F.F.F.F.F.G.G.M.N.N.N.N.O.P.Q.Q.R.W.T.X.X.Z.Z.7.9.9#.#.#.#a#.###..0bfbM.X.Q.K.R.R.T.H...p.b.b.b",
-".b.b.b.A...N#y#r#q#p#pb#bP#u.Q.P.N.G.N.N.G.N.N.N.G.M.G.G.G.M.F.E.F.E.F.E.F.E.F.F.F.F.G.M.G.G.G.G.G.N.G.G.N.N.Q.Q.R.R.W.W.X.X.Z.Z.Z.9.0.9#.#####.###..1#EbPa5.J.Q.Q.S.K.K.C...A.b.b.b",
-".b.b.b.b.j.d#r#q#p#q#p#6bPaM.O.Q.Q.N.N.N.N.G.N.F.N.G.N.M.M.G.G.M.F.F.G.G.G.G.G.G.M.G.G.G.G.G.G.N.N.G.N.Q.P.Q.Q.Q.R.W.S.X.X.Z.Z.7.9.0.9#.#.###a###.#..9aObP#D.I.Q.J.Q.R.S.#.j.b.b.b.b",
-".b.b.b.b.q...0#x#q#p#o#pbubL.6.Q.Q.Q.N.H.N.N.G.N.G.N.G.G.N.G.G.G.G.G.M.G.M.G.G.G.G.G.G.G.N.N.N.G.N.N.Q.N.Q.R.Q.R.W.T.X.Z.X.Z.Z.0.7.9#.#.###.#.#a#..1#kbMbn.H.I.I.O.J.Q.G...q.b.b.b.b",
-".b.b.b.b.b.d.C#q#p#q#p#eahbPa8.W.Q.Q.Q.Q.N.N.N.N.N.G.N.N.G.N.N.G.N.N.N.N.N.N.N.N.N.N.N.N.N.N.N.N.Q.N.Q.R.Q.R.R.W.W.X.X.X.Z.Z.7.9.9#.#.###.#a###.#..0b.bP#Q.H.H.O.I.R.J.d.d.b.b.b.b.b",
-".b.b.b.b.b.n..###p#p#o#e#db#bP#P.R.W.Q.Q.Q.Q.P.H.N.N.N.N.G.N.G.N.N.G.G.G.G.N.G.N.N.N.N.N.N.N.N.Q.Q.Q.Q.Q.R.W.W.X.X.X.Z.Z.Z.9.9.0#.#.###.#a###.#..0#TbPa4.G.H.N.H.J.I.G...n.b.b.b.b.b",
-".b.b.b.b.b.A.c.F#q#o#p#e#o#GbMbz.R.Q.W.Q.Q.O.Q.Q.Q.N.N.H.N.N.N.N.G.N.N.N.N.N.N.N.G.N.N.P.Q.Q.Q.Q.Q.R.R.W.W.S.X.X.Z.Z.Z.Z.9.Z.9#..9###.#a#.#.#..1.0bDbM.W.G.H.H.H.N.I.d.d.w.b.b.b.b.b",
-".b.b.b.b.b.b.n...0#p#o#d#n#caIbPa0.W.R.W.R.Q.Q.O.Q.Q.Q.Q.Q.P.N.P.N.P.N.P.N.P.P.Q.Q.Q.Q.O.Q.Q.R.Q.R.W.R.S.X.X.X.Z.X.Z.7.9.0.9#..9#.#a#.###a#.#..0a2bPar.G.G.N.G.H.H.F.c.m.b.b.b.b.b.b",
-".b.b.b.b.b.b.A.c.d#p#e#o#c#c#bbkbP#9.W.R.W.R.W.R.Q.Q.Q.O.Q.O.Q.Q.Q.Q.Q.Q.Q.O.Q.O.Q.Q.Q.Q.R.Q.W.R.W.R.X.X.X.X.Y.Z.Z.Z.9.0.9#.#.#.#a#.#a#.#.#..0afbPbc.G.G.G.G.G.H.H.c.c.z.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.p...S#e#o#c#c#c#obIbM#Q.W.W.W.R.W.R.W.Q.R.Q.Q.Q.Q.Q.Q.Q.Q.Q.Q.Q.Q.R.Q.R.W.R.W.W.S.X.X.X.X.X.Z.Z.Z.7.9.0.9#..9#.#a#.#####.#..0#TbMbG.N.l.G.G.G.H.G.g...q.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.i..###d#c#n#a#c#1bLbM.7.T.W.W.S.W.R.W.R.W.R.Q.W.R.Q.W.R.R.W.R.R.W.R.W.R.W.R.X.X.X.X.Z.Z.Z.Z.7.9.0.9.9#..9#.#a###.#a#.#..0#kbMbL#g.k.l.F.G.G.G.F...j.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.w.c.B#c#c#c#c#a.2ahbPbB#i.X.X.X.W.W.S.W.W.W.R.S.W.R.R.W.R.W.W.W.S.W.S.X.X.X.X.X.Z.X.Z.Z.7.Z.0.7.9#..9#.###a#.###a#.#..0#lbBbP#O.j.E.k.l.F.G.G.d.c.v.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.o...N#m#c#c#a#a.1aubPbB#S.X.X.X.X.X.X.T.W.X.W.T.W.W.W.S.X.S.X.X.X.Z.X.X.X.Z.Z.Z.Z.Z.7.0.9.9#..9#.#.#.#a#.#a#.#.#..0#TbHbPac.j.E.j.k.E.l.G.f...p.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.j...R#c#b#a#a.3.1aubLbM#Z.Z.X.Z.X.X.X.X.X.X.X.Y.X.Y.X.X.X.Y.X.X.X.Z.Z.Z.Z.Z.7.Z.9.0.9.9#..9#.#.###a###.###.#..0#TbMbLac.j.D.j.l.D.k.l.g...l.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.f...W#c.4#a.1#a.1#TbMbPaA.Z.Z.X.Z.Z.X.Z.X.Z.X.X.X.Z.X.Z.X.Z.Z.Z.Z.Z.7.Z.7.0.9.9.9.9#..9#.#####a#.#a#.#.#..0aNbPbI#s.g.j.j.j.D.k.D.g...f.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.v.f.c.0#a.4.1.1.1.1#vbBbPbi#j.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.Z.7.Z.Z.7.Z.7.Z.9.9.0.8.0.9#.#.#.#.#a#.#a#.###.#..0#lbpbPbs.5.g.j.h.j.D.j.E.j...f.A.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.A.c.c.Z#a.2#..0.1.0.Va1bPbMaB.7.Z.7.Z.Z.7.Z.Z.7.Z.7.Z.Z.9.Z.9.0.9.0.9.9#.#.#.#.#.#####.#a###.#.#..1aBbMbPaL.g.g.g.g.j.h.j.j.i...d.v.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.t.c.c.R#..1.1.0.0.0.Y#0bAbPbI#9.0.9.9.0.9.9.0.9.0.9.9.0.9.9.9.9#..9#.#.###.#####a#.#a#.#.#.#.#5bIbPbs#N.f.g.g.h.i.g.j.h.f.c.d.v.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.q.d...Q.1.1.0.0.Z.V.Z.TazbLbPbBat.0.9.9.0.9.9.9.9.9.9#..9#..9#.#.#.###.###a#.###a#.#.#.aubBbPbIaq.e.f.g.g.g.g.g.h.D.f...d.v.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.t.f...F.1.0.0.Z.Z.U.U.T.7aNbHbPbMa2#0.9#..9#.#.#.#..9#.#.###.###a#.#a#.###a#.#.#0a2bMbPbDaD.L.f.g.f.g.f.g.g.i.g.d...i.A.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.w.k...f.Z.0.0.Y.Z.T.T.S.K.KambobPbPbIb.au#0#.#.#.#a#.###a#.#a###.###a#0aub.bIbPbPbhab.e.f.g.g.f.g.f.g.g.g.g.c...l.A.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.q...c.G.Z.V.U.Y.T.T.T.R.K.J#hatbdbPbPbPbPbtbtaYaYaYaYaYaYaYbtbtbPbPbPbPbcad.5.e.g.f.g.g.f.g.g.g.f.g.d.c...o.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.t.f...C.Q.Y.T.T.S.K.R.R.Q.O.I.H.H#PasaVbibtbPbPbPbPbPbPbPbsbiaTaq#N.f.e.g.f.g.f.g.f.g.f.g.f.g.e.c...f.u.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.m.c...D.R.T.T.T.K.R.J.Q.I.N.H.H.G.G.F.l.k.j.j.j.j.j.g.g.g.g.g.g.g.f.g.f.g.g.f.g.f.g.f.e.d...d.n.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.t.j.....D.Q.S.R.K.Q.Q.I.I.H.H.H.G.G.G.F.l.E.j.D.j.j.j.i.g.g.g.f.g.f.g.f.g.g.f.g.e.d.....k.w.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.r.k.....f.G.R.J.Q.I.N.H.H.G.G.G.G.l.E.j.E.j.D.h.j.g.h.g.g.g.f.g.g.f.g.f.e.#.c...k.u.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.u.m.c...c.B.G.I.J.H.H.G.H.G.G.l.l.k.k.j.j.j.j.h.i.g.g.g.g.f.g.e.c.#...c.k.s.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.o.j.......d.C.E.G.G.G.G.G.E.l.D.D.j.D.h.j.g.i.g.f.d.#.....#.i.o.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.u.q.k.f...c.....d.d.g.f.f.f.f.e.f.d.c.d.......#.d.j.o.t.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.w.r.n.m.i.f.....#.........c.f.g.l.n.r.w.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-".b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b.b",
-};
diff --git a/sandbox/conical.tcl b/sandbox/conical.tcl
deleted file mode 100644
index 63dd7c0..0000000
--- a/sandbox/conical.tcl
+++ /dev/null
@@ -1,18 +0,0 @@
-
-lappend auto_path ..
-package require Tkzinc
-
-set defaultfont -b&h-lucida-bold-r-normal-*-*-140-*-*-p-*-iso10646-1
-zinc .zinc -width 700 -height 500 -render 1
-pack .zinc
-
-
-.zinc gname {=radial 0 0 |white|gray30} test1
-.zinc gname {=conical 70 |white|gray30 50 50|white} test2
-
-set grp [.zinc add group 1]
-#.zinc add rectangle $grp {0 0 70 50} -filled 1 -fillcolor white
-.zinc add rectangle $grp {60 60 360 360} -filled 1 -linewidth 1 \
- -fillcolor test2 -tags rect
-
-.zinc add rectangle $grp {140 140 280 280} -filled 1 -fillcolor gray
diff --git a/sandbox/contours.tcl b/sandbox/contours.tcl
deleted file mode 100644
index ce6d3ac..0000000
--- a/sandbox/contours.tcl
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/usr/local/bin/wish -f
-
-load ../tkzinc3.2.so
-package require Img
-
-set top 1
-set lw 8
-
-set r [zinc .r -backcolor gray -relief sunken]
-pack .r -expand t -fill both
-.r configure -width 800 -height 500
-.r scale $top 1 -1
-#.r configure -drawbboxes t
-set view [.r add group $top -tags controls]
-#set poly [.r add curve $view "50 -150 300 -150 300 -300 50 -300 50 -150" \
-# -closed t -fillcolor tan]
-set poly [.r add curve $view "50 -150 50 -300 300 -300 300 -150 50 -150" \
- -closed t -fillcolor tan -linecolor tan -linewidth 2 -relief raised]
-.r scale $poly 2.0 2.0
-.r translate $poly -60 150
-set rect [.r add rectangle $view "50 -200 100 -50"]
-set ellipse [.r add arc $view "150 -200 300 -350"]
-set arc [.r add arc $view "-25 -150 125 -300"]
-.r scale $arc 2.0 2.0
-.r translate $arc -60 150
-
-set mp [.r add curve $view "" \
- -linecolor yellow -fillcolor tan -fillpattern AlphaStipple8 \
- -markercolor red -tags "poly" -linewidth $lw -filled t -closed t]
-
-.r contour $mp add $poly
-.r contour $mp addhole $ellipse
-.r contour $mp addhole $rect
-.r contour $mp add $arc
-
-.r itemconfigure $mp -relief raised -visible t
-.r lower $mp
-
-#.r remove $arc $ellipse $rect $poly
-.r remove $rect $arc $ellipse
-
-#.r itemconfigure $poly -relief raised -linewidth 8
-
-# "50 -200 100 -200 100 -50 50 -50 50 -200"
-source "controls.tcl"
diff --git a/sandbox/controls.tcl b/sandbox/controls.tcl
deleted file mode 100644
index d865020..0000000
--- a/sandbox/controls.tcl
+++ /dev/null
@@ -1,158 +0,0 @@
-set tlbbox [.r add group $top -sensitive f -visible f -tags currentbbox]
-.r add rectangle $tlbbox "-3 -3 +3 +3"
-set trbbox [.r add group $top -sensitive f -visible f -tags currentbbox]
-.r add rectangle $trbbox "-3 -3 +3 +3"
-set blbbox [.r add group $top -sensitive f -visible f -tags currentbbox]
-.r add rectangle $blbbox "-3 -3 +3 +3"
-set brbbox [.r add group $top -sensitive f -visible f -tags currentbbox]
-.r add rectangle $brbbox "-3 -3 +3 +3"
-.r add rectangle $top "0 0 1 1" -linecolor red -tags "lasso" -visible f -sensitive f
-
-#
-# Controls for the window transform.
-#
-proc press {lx ly action} {
- global x y angle
- set x $lx
- set y $ly
- set angle [expr atan2($y, $x)]
- bind .r "<Motion>" "$action %x %y"
-}
-
-proc motion {lx ly} {
- global x y
- set it [.r find withtag controls]
- if {$it != ""} {
- set it [.r group [lindex $it 0]]
- }
- set res [.r transform $it "$lx $ly $x $y"]
- set nx [lindex $res 0]
- set ny [lindex $res 1]
- set ox [lindex $res 2]
- set oy [lindex $res 3]
- .r translate controls [expr $nx - $ox] [expr $ny - $oy]
- set x $lx
- set y $ly
-}
-
-proc zoom {lx ly} {
- global x y
-
- if {$lx > $x} {
- set maxx $lx
- } else {
- set maxx $x
- }
- if {$ly > $y} {
- set maxy $ly
- } else {
- set maxy $y
- }
- set sx [expr 1.0 + double($lx - $x)/$maxx]
- set sy [expr 1.0 + double($ly - $y)/$maxy]
- set x $lx
- set y $ly
- .r scale controls $sx $sy
-}
-
-proc rotate {lx ly} {
- global angle
-
- set langle [expr atan2($ly, $lx)]
- .r rotate controls [expr -($langle-$angle)]
- set angle $langle
-}
-
-proc release {} {
- bind .r "<Motion>" ""
-}
-
-proc start_lasso {lx ly} {
- global top x y cx cy
- set x $lx
- set y $ly
- set cx $lx
- set cy $ly
- set coords [.r transform $top "$x $y"]
- set fx [lindex $coords 0]
- set fy [lindex $coords 1]
- .r coords lasso "$fx $fy $fx $fy"
- .r itemconfigure lasso -visible t
- .r raise lasso
- bind .r "<Motion>" "lasso %x %y"
-}
-
-proc lasso {lx ly} {
- global top x y cx cy
- set cx $lx
- set cy $ly
- set coords [.r transform $top "$x $y $lx $ly"]
- set fx [lindex $coords 0]
- set fy [lindex $coords 1]
- set fcx [lindex $coords 2]
- set fcy [lindex $coords 3]
- .r coords lasso "$fx $fy $fcx $fcy"
-}
-
-proc fin_lasso {} {
- global x y cx cy
-
- bind .r "<Motion>" ""
- .r itemconfigure lasso -visible f
-# puts "x=$x, y=$y, cx=$cx, cy=$cy"
- puts "enclosed='[.r find enclosed $x $y $cx $cy]', overlapping='[.r find overlapping $x $y $cx $cy]'"
-}
-
-proc getrect {x y} {
- list [expr $x-3] [expr $y-3] [expr $x+3] [expr $y+3]
-}
-
-proc showbox {} {
- global top tlbbox trbbox blbbox brbbox
-
- if { ! [.r hastag current currentbbox]} {
- if {[catch {.r find withtag current} item] } {
- return
- }
- set coords [.r transform $top [.r bbox current]]
- set xo [lindex $coords 0]
- set yo [lindex $coords 1]
- set xc [lindex $coords 2]
- set yc [lindex $coords 3]
-
- .r coords $tlbbox "$xo $yo"
- .r coords $trbbox "$xc $yo"
- .r coords $brbbox "$xc $yc"
- .r coords $blbbox "$xo $yc"
- .r itemconfigure currentbbox -visible t
- }
-}
-
-proc hidebox {lx ly} {
- set next [.r find closest $lx $ly]
- if {[llength $next] > 1} {
- set next [lindex $next 0]
- }
- if { $next == "" || ! [.r hastag $next currentbbox] ||\
- [.r hastag current currentbbox]} {
- .r itemconfigure currentbbox -visible f
- }
-}
-
-
-bind .r "<ButtonPress-1>" "start_lasso %x %y"
-bind .r "<ButtonRelease-1>" fin_lasso
-
-bind .r "<ButtonPress-2>" {puts "at point='[.r find closest %x %y]'"}
-
-bind .r "<ButtonPress-3>" "press %x %y motion"
-bind .r "<ButtonRelease-3>" release
-
-bind .r "<Shift-ButtonPress-3>" "press %x %y zoom"
-bind .r "<Shift-ButtonRelease-3>" release
-
-bind .r "<Control-ButtonPress-3>" "press %x %y rotate"
-bind .r "<Control-ButtonRelease-3>" release
-
-.r bind current "<Enter>" showbox
-.r bind current "<Leave>" {hidebox %x %y}
diff --git a/sandbox/defs.tcl b/sandbox/defs.tcl
deleted file mode 100644
index a2e55cd..0000000
--- a/sandbox/defs.tcl
+++ /dev/null
@@ -1,1097 +0,0 @@
-# defs.tcl --
-#
-# This file contains support code for the Tcl/Tk test suite.It is
-# It is normally sourced by the individual files in the test suite
-# before they run their tests. This improved approach to testing
-# was designed and initially implemented by Mary Ann May-Pumphrey
-# of Sun Microsystems.
-#
-# Copyright (c) 1990-1994 The Regents of the University of California.
-# Copyright (c) 1994-1996 Sun Microsystems, Inc.
-# Copyright (c) 1998-1999 by Scriptics Corporation.
-# All rights reserved.
-#
-# RCS: @(#) $Id$
-
-# Initialize wish shell
-
-if {[info exists tk_version]} {
- tk appname tktest
- wm title . tktest
-} else {
-
- # Ensure that we have a minimal auto_path so we don't pick up extra junk.
-
- set auto_path [list [info library]]
-}
-
-# create the "tcltest" namespace for all testing variables and procedures
-
-namespace eval tcltest {
- set procList [list test cleanupTests dotests saveState restoreState \
- normalizeMsg makeFile removeFile makeDirectory removeDirectory \
- viewFile bytestring set_iso8859_1_locale restore_locale \
- safeFetch threadReap]
- if {[info exists tk_version]} {
- lappend procList setupbg dobg bgReady cleanupbg fixfocus
- }
- foreach proc $procList {
- namespace export $proc
- }
-
- # setup ::tcltest default vars
- foreach {var default} {verbose b match {} skip {}} {
- if {![info exists $var]} {
- variable $var $default
- }
- }
-
- # Tests should not rely on the current working directory.
- # Files that are part of the test suite should be accessed relative to
- # ::tcltest::testsDir.
-
- set originalDir [pwd]
- set tDir [file join $originalDir [file dirname [info script]]]
- cd $tDir
- variable testsDir [pwd]
- cd $originalDir
-
- # Count the number of files tested (0 if all.tcl wasn't called).
- # The all.tcl file will set testSingleFile to false, so stats will
- # not be printed until all.tcl calls the cleanupTests proc.
- # The currentFailure var stores the boolean value of whether the
- # current test file has had any failures. The failFiles list
- # stores the names of test files that had failures.
-
- variable numTestFiles 0
- variable testSingleFile true
- variable currentFailure false
- variable failFiles {}
-
- # Tests should remove all files they create. The test suite will
- # check the current working dir for files created by the tests.
- # ::tcltest::filesMade keeps track of such files created using the
- # ::tcltest::makeFile and ::tcltest::makeDirectory procedures.
- # ::tcltest::filesExisted stores the names of pre-existing files.
-
- variable filesMade {}
- variable filesExisted {}
-
- # ::tcltest::numTests will store test files as indices and the list
- # of files (that should not have been) left behind by the test files.
-
- array set ::tcltest::createdNewFiles {}
-
- # initialize ::tcltest::numTests array to keep track fo the number of
- # tests that pass, fial, and are skipped.
-
- array set numTests [list Total 0 Passed 0 Skipped 0 Failed 0]
-
- # initialize ::tcltest::skippedBecause array to keep track of
- # constraints that kept tests from running
-
- array set ::tcltest::skippedBecause {}
-
- # tests that use thread need to know which is the main thread
-
- variable ::tcltest::mainThread 1
- if {[info commands testthread] != {}} {
- puts "Tk with threads enabled is known to have problems with X"
- set ::tcltest::mainThread [testthread names]
- }
-}
-
-# If there is no "memory" command (because memory debugging isn't
-# enabled), generate a dummy command that does nothing.
-
-if {[info commands memory] == ""} {
- proc memory args {}
-}
-
-# ::tcltest::initConfig --
-#
-# Check configuration information that will determine which tests
-# to run. To do this, create an array ::tcltest::testConfig. Each
-# element has a 0 or 1 value. If the element is "true" then tests
-# with that constraint will be run, otherwise tests with that constraint
-# will be skipped. See the README file for the list of built-in
-# constraints defined in this procedure.
-#
-# Arguments:
-# none
-#
-# Results:
-# The ::tcltest::testConfig array is reset to have an index for
-# each built-in test constraint.
-
-proc ::tcltest::initConfig {} {
-
- global tcl_platform tcl_interactive tk_version
-
- catch {unset ::tcltest::testConfig}
-
- # The following trace procedure makes it so that we can safely refer to
- # non-existent members of the ::tcltest::testConfig array without causing an
- # error. Instead, reading a non-existent member will return 0. This is
- # necessary because tests are allowed to use constraint "X" without ensuring
- # that ::tcltest::testConfig("X") is defined.
-
- trace variable ::tcltest::testConfig r ::tcltest::safeFetch
-
- proc ::tcltest::safeFetch {n1 n2 op} {
- if {($n2 != {}) && ([info exists ::tcltest::testConfig($n2)] == 0)} {
- set ::tcltest::testConfig($n2) 0
- }
- }
-
- set ::tcltest::testConfig(unixOnly) \
- [expr {$tcl_platform(platform) == "unix"}]
- set ::tcltest::testConfig(macOnly) \
- [expr {$tcl_platform(platform) == "macintosh"}]
- set ::tcltest::testConfig(pcOnly) \
- [expr {$tcl_platform(platform) == "windows"}]
-
- set ::tcltest::testConfig(unix) $::tcltest::testConfig(unixOnly)
- set ::tcltest::testConfig(mac) $::tcltest::testConfig(macOnly)
- set ::tcltest::testConfig(pc) $::tcltest::testConfig(pcOnly)
-
- set ::tcltest::testConfig(unixOrPc) \
- [expr {$::tcltest::testConfig(unix) || $::tcltest::testConfig(pc)}]
- set ::tcltest::testConfig(macOrPc) \
- [expr {$::tcltest::testConfig(mac) || $::tcltest::testConfig(pc)}]
- set ::tcltest::testConfig(macOrUnix) \
- [expr {$::tcltest::testConfig(mac) || $::tcltest::testConfig(unix)}]
-
- set ::tcltest::testConfig(nt) [expr {$tcl_platform(os) == "Windows NT"}]
- set ::tcltest::testConfig(95) [expr {$tcl_platform(os) == "Windows 95"}]
-
- # The following config switches are used to mark tests that should work,
- # but have been temporarily disabled on certain platforms because they don't
- # and we haven't gotten around to fixing the underlying problem.
-
- set ::tcltest::testConfig(tempNotPc) [expr {!$::tcltest::testConfig(pc)}]
- set ::tcltest::testConfig(tempNotMac) [expr {!$::tcltest::testConfig(mac)}]
- set ::tcltest::testConfig(tempNotUnix) [expr {!$::tcltest::testConfig(unix)}]
-
- # The following config switches are used to mark tests that crash on
- # certain platforms, so that they can be reactivated again when the
- # underlying problem is fixed.
-
- set ::tcltest::testConfig(pcCrash) [expr {!$::tcltest::testConfig(pc)}]
- set ::tcltest::testConfig(macCrash) [expr {!$::tcltest::testConfig(mac)}]
- set ::tcltest::testConfig(unixCrash) [expr {!$::tcltest::testConfig(unix)}]
-
- # Set the "fonts" constraint for wish apps
-
- if {[info exists tk_version]} {
- set ::tcltest::testConfig(fonts) 1
- catch {destroy .e}
- entry .e -width 0 -font {Helvetica -12} -bd 1
- .e insert end "a.bcd"
- if {([winfo reqwidth .e] != 37) || ([winfo reqheight .e] != 20)} {
- set ::tcltest::testConfig(fonts) 0
- }
- destroy .e
- catch {destroy .t}
- text .t -width 80 -height 20 -font {Times -14} -bd 1
- pack .t
- .t insert end "This is\na dot."
- update
- set x [list [.t bbox 1.3] [.t bbox 2.5]]
- destroy .t
- if {[string match {{22 3 6 15} {31 18 [34] 15}} $x] == 0} {
- set ::tcltest::testConfig(fonts) 0
- }
-
- # Test to see if we have are running Unix apps on Exceed,
- # which won't return font failures (Windows-like), which is
- # not what we want from ann X server (other Windows X servers
- # operate as expected)
-
- set ::tcltest::testConfig(noExceed) 1
- if {$::tcltest::testConfig(unixOnly) && \
- [catch {font actual "\{xyz"}] == 0} {
- puts "Running X app on Exceed, skipping problematic font tests..."
- set ::tcltest::testConfig(noExceed) 0
- }
- }
-
- # Skip empty tests
-
- set ::tcltest::testConfig(emptyTest) 0
-
- # By default, tests that expost known bugs are skipped.
-
- set ::tcltest::testConfig(knownBug) 0
-
- # By default, non-portable tests are skipped.
-
- set ::tcltest::testConfig(nonPortable) 0
-
- # Some tests require user interaction.
-
- set ::tcltest::testConfig(userInteraction) 0
-
- # Some tests must be skipped if the interpreter is not in interactive mode
-
- set ::tcltest::testConfig(interactive) $tcl_interactive
-
- # Some tests must be skipped if you are running as root on Unix.
- # Other tests can only be run if you are running as root on Unix.
-
- set ::tcltest::testConfig(root) 0
- set ::tcltest::testConfig(notRoot) 1
- set user {}
- if {$tcl_platform(platform) == "unix"} {
- catch {set user [exec whoami]}
- if {$user == ""} {
- catch {regexp {^[^(]*\(([^)]*)\)} [exec id] dummy user}
- }
- if {($user == "root") || ($user == "")} {
- set ::tcltest::testConfig(root) 1
- set ::tcltest::testConfig(notRoot) 0
- }
- }
-
- # Set nonBlockFiles constraint: 1 means this platform supports
- # setting files into nonblocking mode.
-
- if {[catch {set f [open defs r]}]} {
- set ::tcltest::testConfig(nonBlockFiles) 1
- } else {
- if {[catch {fconfigure $f -blocking off}] == 0} {
- set ::tcltest::testConfig(nonBlockFiles) 1
- } else {
- set ::tcltest::testConfig(nonBlockFiles) 0
- }
- close $f
- }
-
- # Set asyncPipeClose constraint: 1 means this platform supports
- # async flush and async close on a pipe.
- #
- # Test for SCO Unix - cannot run async flushing tests because a
- # potential problem with select is apparently interfering.
- # (Mark Diekhans).
-
- if {$tcl_platform(platform) == "unix"} {
- if {[catch {exec uname -X | fgrep {Release = 3.2v}}] == 0} {
- set ::tcltest::testConfig(asyncPipeClose) 0
- } else {
- set ::tcltest::testConfig(asyncPipeClose) 1
- }
- } else {
- set ::tcltest::testConfig(asyncPipeClose) 1
- }
-
- # Test to see if we have a broken version of sprintf with respect
- # to the "e" format of floating-point numbers.
-
- set ::tcltest::testConfig(eformat) 1
- if {[string compare "[format %g 5e-5]" "5e-05"] != 0} {
- set ::tcltest::testConfig(eformat) 0
- }
-
- # Test to see if execed commands such as cat, echo, rm and so forth are
- # present on this machine.
-
- set ::tcltest::testConfig(unixExecs) 1
- if {$tcl_platform(platform) == "macintosh"} {
- set ::tcltest::testConfig(unixExecs) 0
- }
- if {($::tcltest::testConfig(unixExecs) == 1) && \
- ($tcl_platform(platform) == "windows")} {
- if {[catch {exec cat defs}] == 1} {
- set ::tcltest::testConfig(unixExecs) 0
- }
- if {($::tcltest::testConfig(unixExecs) == 1) && \
- ([catch {exec echo hello}] == 1)} {
- set ::tcltest::testConfig(unixExecs) 0
- }
- if {($::tcltest::testConfig(unixExecs) == 1) && \
- ([catch {exec sh -c echo hello}] == 1)} {
- set ::tcltest::testConfig(unixExecs) 0
- }
- if {($::tcltest::testConfig(unixExecs) == 1) && \
- ([catch {exec wc defs}] == 1)} {
- set ::tcltest::testConfig(unixExecs) 0
- }
- if {$::tcltest::testConfig(unixExecs) == 1} {
- exec echo hello > removeMe
- if {[catch {exec rm removeMe}] == 1} {
- set ::tcltest::testConfig(unixExecs) 0
- }
- }
- if {($::tcltest::testConfig(unixExecs) == 1) && \
- ([catch {exec sleep 1}] == 1)} {
- set ::tcltest::testConfig(unixExecs) 0
- }
- if {($::tcltest::testConfig(unixExecs) == 1) && \
- ([catch {exec fgrep unixExecs defs}] == 1)} {
- set ::tcltest::testConfig(unixExecs) 0
- }
- if {($::tcltest::testConfig(unixExecs) == 1) && \
- ([catch {exec ps}] == 1)} {
- set ::tcltest::testConfig(unixExecs) 0
- }
- if {($::tcltest::testConfig(unixExecs) == 1) && \
- ([catch {exec echo abc > removeMe}] == 0) && \
- ([catch {exec chmod 644 removeMe}] == 1) && \
- ([catch {exec rm removeMe}] == 0)} {
- set ::tcltest::testConfig(unixExecs) 0
- } else {
- catch {exec rm -f removeMe}
- }
- if {($::tcltest::testConfig(unixExecs) == 1) && \
- ([catch {exec mkdir removeMe}] == 1)} {
- set ::tcltest::testConfig(unixExecs) 0
- } else {
- catch {exec rm -r removeMe}
- }
- }
-}
-
-::tcltest::initConfig
-
-
-# ::tcltest::processCmdLineArgs --
-#
-# Use command line args to set the verbose, skip, and
-# match variables. This procedure must be run after
-# constraints are initialized, because some constraints can be
-# overridden.
-#
-# Arguments:
-# none
-#
-# Results:
-# ::tcltest::verbose is set to <value>
-
-proc ::tcltest::processCmdLineArgs {} {
- global argv
-
- # The "argv" var doesn't exist in some cases, so use {}
- # The "argv" var doesn't exist in some cases.
-
- if {(![info exists argv]) || ([llength $argv] < 2)} {
- set flagArray {}
- } else {
- set flagArray $argv
- }
-
- if {[catch {array set flag $flagArray}]} {
- puts stderr "Error: odd number of command line args specified:"
- puts stderr " $argv"
- exit
- }
-
- # Allow for 1-char abbreviations, where applicable (e.g., -match == -m).
- # Note that -verbose cannot be abbreviated to -v in wish because it
- # conflicts with the wish option -visual.
-
- foreach arg {-verbose -match -skip -constraints} {
- set abbrev [string range $arg 0 1]
- if {([info exists flag($abbrev)]) && \
- ([lsearch -exact $flagArray $arg] < \
- [lsearch -exact $flagArray $abbrev])} {
- set flag($arg) $flag($abbrev)
- }
- }
-
- # Set ::tcltest::workingDir to [pwd].
- # Save the names of files that already exist in ::tcltest::workingDir.
-
- set ::tcltest::workingDir [pwd]
- foreach file [glob -nocomplain [file join $::tcltest::workingDir *]] {
- lappend ::tcltest::filesExisted [file tail $file]
- }
-
- # Set ::tcltest::verbose to the arg of the -verbose flag, if given
-
- if {[info exists flag(-verbose)]} {
- set ::tcltest::verbose $flag(-verbose)
- }
-
- # Set ::tcltest::match to the arg of the -match flag, if given
-
- if {[info exists flag(-match)]} {
- set ::tcltest::match $flag(-match)
- }
-
- # Set ::tcltest::skip to the arg of the -skip flag, if given
-
- if {[info exists flag(-skip)]} {
- set ::tcltest::skip $flag(-skip)
- }
-
- # Use the -constraints flag, if given, to turn on constraints that are
- # turned off by default: userInteractive knownBug nonPortable. This
- # code fragment must be run after constraints are initialized.
-
- if {[info exists flag(-constraints)]} {
- foreach elt $flag(-constraints) {
- set ::tcltest::testConfig($elt) 1
- }
- }
-}
-
-::tcltest::processCmdLineArgs
-
-
-# ::tcltest::cleanupTests --
-#
-# Remove files and dirs created using the makeFile and makeDirectory
-# commands since the last time this proc was invoked.
-#
-# Print the names of the files created without the makeFile command
-# since the tests were invoked.
-#
-# Print the number tests (total, passed, failed, and skipped) since the
-# tests were invoked.
-#
-
-proc ::tcltest::cleanupTests {{calledFromAllFile 0}} {
- set tail [file tail [info script]]
-
- # Remove files and directories created by the :tcltest::makeFile and
- # ::tcltest::makeDirectory procedures.
- # Record the names of files in ::tcltest::workingDir that were not
- # pre-existing, and associate them with the test file that created them.
-
- if {!$calledFromAllFile} {
-
- foreach file $::tcltest::filesMade {
- if {[file exists $file]} {
- catch {file delete -force $file}
- }
- }
- set currentFiles {}
- foreach file [glob -nocomplain [file join $::tcltest::workingDir *]] {
- lappend currentFiles [file tail $file]
- }
- set newFiles {}
- foreach file $currentFiles {
- if {[lsearch -exact $::tcltest::filesExisted $file] == -1} {
- lappend newFiles $file
- }
- }
- set ::tcltest::filesExisted $currentFiles
- if {[llength $newFiles] > 0} {
- set ::tcltest::createdNewFiles($tail) $newFiles
- }
- }
-
- if {$calledFromAllFile || $::tcltest::testSingleFile} {
-
- # print stats
-
- puts -nonewline stdout "$tail:"
- foreach index [list "Total" "Passed" "Skipped" "Failed"] {
- puts -nonewline stdout "\t$index\t$::tcltest::numTests($index)"
- }
- puts stdout ""
-
- # print number test files sourced
- # print names of files that ran tests which failed
-
- if {$calledFromAllFile} {
- puts stdout "Sourced $::tcltest::numTestFiles Test Files."
- set ::tcltest::numTestFiles 0
- if {[llength $::tcltest::failFiles] > 0} {
- puts stdout "Files with failing tests: $::tcltest::failFiles"
- set ::tcltest::failFiles {}
- }
- }
-
- # if any tests were skipped, print the constraints that kept them
- # from running.
-
- set constraintList [array names ::tcltest::skippedBecause]
- if {[llength $constraintList] > 0} {
- puts stdout "Number of tests skipped for each constraint:"
- foreach constraint [lsort $constraintList] {
- puts stdout \
- "\t$::tcltest::skippedBecause($constraint)\t$constraint"
- unset ::tcltest::skippedBecause($constraint)
- }
- }
-
- # report the names of test files in ::tcltest::createdNewFiles, and
- # reset the array to be empty.
-
- set testFilesThatTurded [lsort [array names ::tcltest::createdNewFiles]]
- if {[llength $testFilesThatTurded] > 0} {
- puts stdout "Warning: test files left files behind:"
- foreach testFile $testFilesThatTurded {
- puts "\t$testFile:\t$::tcltest::createdNewFiles($testFile)"
- unset ::tcltest::createdNewFiles($testFile)
- }
- }
-
- # reset filesMade, filesExisted, and numTests
-
- set ::tcltest::filesMade {}
- foreach index [list "Total" "Passed" "Skipped" "Failed"] {
- set ::tcltest::numTests($index) 0
- }
-
- # exit only if running Tk in non-interactive mode
-
- global tk_version tcl_interactive
- if {[info exists tk_version] && !$tcl_interactive} {
- exit
- }
- } else {
-
- # if we're deferring stat-reporting until all files are sourced,
- # then add current file to failFile list if any tests in this file
- # failed
-
- incr ::tcltest::numTestFiles
- if {($::tcltest::currentFailure) && \
- ([lsearch -exact $::tcltest::failFiles $tail] == -1)} {
- lappend ::tcltest::failFiles $tail
- }
- set ::tcltest::currentFailure false
- }
-}
-
-
-# test --
-#
-# This procedure runs a test and prints an error message if the test fails.
-# If ::tcltest::verbose has been set, it also prints a message even if the
-# test succeeds. The test will be skipped if it doesn't match the
-# ::tcltest::match variable, if it matches an element in
-# ::tcltest::skip, or if one of the elements of "constraints" turns
-# out not to be true.
-#
-# Arguments:
-# name - Name of test, in the form foo-1.2.
-# description - Short textual description of the test, to
-# help humans understand what it does.
-# constraints - A list of one or more keywords, each of
-# which must be the name of an element in
-# the array "::tcltest::testConfig". If any of these
-# elements is zero, the test is skipped.
-# This argument may be omitted.
-# script - Script to run to carry out the test. It must
-# return a result that can be checked for
-# correctness.
-# expectedAnswer - Expected result from script.
-
-proc ::tcltest::test {name description script expectedAnswer args} {
- incr ::tcltest::numTests(Total)
-
- # skip the test if it's name matches an element of skip
-
- foreach pattern $::tcltest::skip {
- if {[string match $pattern $name]} {
- incr ::tcltest::numTests(Skipped)
- return
- }
- }
- # skip the test if it's name doesn't match any element of match
-
- if {[llength $::tcltest::match] > 0} {
- set ok 0
- foreach pattern $::tcltest::match {
- if {[string match $pattern $name]} {
- set ok 1
- break
- }
- }
- if {!$ok} {
- incr ::tcltest::numTests(Skipped)
- return
- }
- }
- set i [llength $args]
- if {$i == 0} {
- set constraints {}
- } elseif {$i == 1} {
-
- # "constraints" argument exists; shuffle arguments down, then
- # make sure that the constraints are satisfied.
-
- set constraints $script
- set script $expectedAnswer
- set expectedAnswer [lindex $args 0]
- set doTest 0
- if {[string match {*[$\[]*} $constraints] != 0} {
-
- # full expression, e.g. {$foo > [info tclversion]}
-
- catch {set doTest [uplevel #0 expr $constraints]}
-
- } elseif {[regexp {[^.a-zA-Z0-9 ]+} $constraints] != 0} {
-
- # something like {a || b} should be turned into
- # $::tcltest::testConfig(a) || $::tcltest::testConfig(b).
-
- regsub -all {[.a-zA-Z0-9]+} $constraints \
- {$::tcltest::testConfig(&)} c
- catch {set doTest [eval expr $c]}
- } else {
-
- # just simple constraints such as {unixOnly fonts}.
-
- set doTest 1
- foreach constraint $constraints {
- if {![info exists ::tcltest::testConfig($constraint)]
- || !$::tcltest::testConfig($constraint)} {
- set doTest 0
-
- # store the constraint that kept the test from running
-
- set constraints $constraint
- break
- }
- }
- }
- if {$doTest == 0} {
- incr ::tcltest::numTests(Skipped)
- if {[string first s $::tcltest::verbose] != -1} {
- puts stdout "++++ $name SKIPPED: $constraints"
- }
-
- # add the constraint to the list of constraints the kept tests
- # from running
-
- if {[info exists ::tcltest::skippedBecause($constraints)]} {
- incr ::tcltest::skippedBecause($constraints)
- } else {
- set ::tcltest::skippedBecause($constraints) 1
- }
- return
- }
- } else {
- error "wrong # args: must be \"test name description ?constraints? script expectedAnswer\""
- }
- memory tag $name
- set code [catch {uplevel $script} actualAnswer]
- if {$code != 0 || [string compare $actualAnswer $expectedAnswer] != 0} {
- incr ::tcltest::numTests(Failed)
- set ::tcltest::currentFailure true
- if {[string first b $::tcltest::verbose] == -1} {
- set script ""
- }
- puts stdout "\n==== $name $description FAILED"
- if {$script != ""} {
- puts stdout "==== Contents of test case:"
- puts stdout $script
- }
- if {$code != 0} {
- if {$code == 1} {
- puts stdout "==== Test generated error:"
- puts stdout $actualAnswer
- } elseif {$code == 2} {
- puts stdout "==== Test generated return exception; result was:"
- puts stdout $actualAnswer
- } elseif {$code == 3} {
- puts stdout "==== Test generated break exception"
- } elseif {$code == 4} {
- puts stdout "==== Test generated continue exception"
- } else {
- puts stdout "==== Test generated exception $code; message was:"
- puts stdout $actualAnswer
- }
- } else {
- puts stdout "---- Result was:\n$actualAnswer"
- }
- puts stdout "---- Result should have been:\n$expectedAnswer"
- puts stdout "==== $name FAILED\n"
- } else {
- incr ::tcltest::numTests(Passed)
- if {[string first p $::tcltest::verbose] != -1} {
- puts stdout "++++ $name PASSED"
- }
- }
-}
-
-# ::tcltest::dotests --
-#
-# takes two arguments--the name of the test file (such
-# as "parse.test"), and a pattern selecting the tests you want to
-# execute. It sets ::tcltest::matching to the second argument, calls
-# "source" on the file specified in the first argument, and restores
-# ::tcltest::matching to its pre-call value at the end.
-#
-# Arguments:
-# file name of tests file to source
-# args pattern selecting the tests you want to execute
-#
-# Results:
-# none
-
-proc ::tcltest::dotests {file args} {
- set savedTests $::tcltest::match
- set ::tcltest::match $args
- source $file
- set ::tcltest::match $savedTests
-}
-
-proc ::tcltest::openfiles {} {
- if {[catch {testchannel open} result]} {
- return {}
- }
- return $result
-}
-
-proc ::tcltest::leakfiles {old} {
- if {[catch {testchannel open} new]} {
- return {}
- }
- set leak {}
- foreach p $new {
- if {[lsearch $old $p] < 0} {
- lappend leak $p
- }
- }
- return $leak
-}
-
-set ::tcltest::saveState {}
-
-proc ::tcltest::saveState {} {
- uplevel #0 {set ::tcltest::saveState [list [info procs] [info vars]]}
-}
-
-proc ::tcltest::restoreState {} {
- foreach p [info procs] {
- if {[lsearch [lindex $::tcltest::saveState 0] $p] < 0} {
- rename $p {}
- }
- }
- foreach p [uplevel #0 {info vars}] {
- if {[lsearch [lindex $::tcltest::saveState 1] $p] < 0} {
- uplevel #0 "unset $p"
- }
- }
-}
-
-proc ::tcltest::normalizeMsg {msg} {
- regsub "\n$" [string tolower $msg] "" msg
- regsub -all "\n\n" $msg "\n" msg
- regsub -all "\n\}" $msg "\}" msg
- return $msg
-}
-
-# makeFile --
-#
-# Create a new file with the name <name>, and write <contents> to it.
-#
-# If this file hasn't been created via makeFile since the last time
-# cleanupTests was called, add it to the $filesMade list, so it will
-# be removed by the next call to cleanupTests.
-#
-proc ::tcltest::makeFile {contents name} {
- set fd [open $name w]
- fconfigure $fd -translation lf
- if {[string index $contents [expr {[string length $contents] - 1}]] == "\n"} {
- puts -nonewline $fd $contents
- } else {
- puts $fd $contents
- }
- close $fd
-
- set fullName [file join [pwd] $name]
- if {[lsearch -exact $::tcltest::filesMade $fullName] == -1} {
- lappend ::tcltest::filesMade $fullName
- }
-}
-
-proc ::tcltest::removeFile {name} {
- file delete $name
-}
-
-# makeDirectory --
-#
-# Create a new dir with the name <name>.
-#
-# If this dir hasn't been created via makeDirectory since the last time
-# cleanupTests was called, add it to the $directoriesMade list, so it will
-# be removed by the next call to cleanupTests.
-#
-proc ::tcltest::makeDirectory {name} {
- file mkdir $name
-
- set fullName [file join [pwd] $name]
- if {[lsearch -exact $::tcltest::filesMade $fullName] == -1} {
- lappend ::tcltest::filesMade $fullName
- }
-}
-
-proc ::tcltest::removeDirectory {name} {
- file delete -force $name
-}
-
-proc ::tcltest::viewFile {name} {
- global tcl_platform
- if {($tcl_platform(platform) == "macintosh") || \
- ($::tcltest::testConfig(unixExecs) == 0)} {
- set f [open $name]
- set data [read -nonewline $f]
- close $f
- return $data
- } else {
- exec cat $name
- }
-}
-
-#
-# Construct a string that consists of the requested sequence of bytes,
-# as opposed to a string of properly formed UTF-8 characters.
-# This allows the tester to
-# 1. Create denormalized or improperly formed strings to pass to C procedures
-# that are supposed to accept strings with embedded NULL bytes.
-# 2. Confirm that a string result has a certain pattern of bytes, for instance
-# to confirm that "\xe0\0" in a Tcl script is stored internally in
-# UTF-8 as the sequence of bytes "\xc3\xa0\xc0\x80".
-#
-# Generally, it's a bad idea to examine the bytes in a Tcl string or to
-# construct improperly formed strings in this manner, because it involves
-# exposing that Tcl uses UTF-8 internally.
-
-proc ::tcltest::bytestring {string} {
- encoding convertfrom identity $string
-}
-
-# Locate tcltest executable
-
-if {![info exists tk_version]} {
- set tcltest [info nameofexecutable]
-
- if {$tcltest == "{}"} {
- set tcltest {}
- }
-}
-
-set ::tcltest::testConfig(stdio) 0
-catch {
- catch {file delete -force tmp}
- set f [open tmp w]
- puts $f {
- exit
- }
- close $f
-
- set f [open "|[list $tcltest tmp]" r]
- close $f
-
- set ::tcltest::testConfig(stdio) 1
-}
-catch {file delete -force tmp}
-
-# Deliberately call the socket with the wrong number of arguments. The error
-# message you get will indicate whether sockets are available on this system.
-
-catch {socket} msg
-set ::tcltest::testConfig(socket) \
- [expr {$msg != "sockets are not available on this system"}]
-
-#
-# Internationalization / ISO support procs -- dl
-#
-
-if {[info commands testlocale]==""} {
-
- # No testlocale command, no tests...
- # (it could be that we are a sub interp and we could just load
- # the Tcltest package but that would interfere with tests
- # that tests packages/loading in slaves...)
-
- set ::tcltest::testConfig(hasIsoLocale) 0
-} else {
- proc ::tcltest::set_iso8859_1_locale {} {
- set ::tcltest::previousLocale [testlocale ctype]
- testlocale ctype $::tcltest::isoLocale
- }
-
- proc ::tcltest::restore_locale {} {
- testlocale ctype $::tcltest::previousLocale
- }
-
- if {![info exists ::tcltest::isoLocale]} {
- set ::tcltest::isoLocale fr
- switch $tcl_platform(platform) {
- "unix" {
-
- # Try some 'known' values for some platforms:
-
- switch -exact -- $tcl_platform(os) {
- "FreeBSD" {
- set ::tcltest::isoLocale fr_FR.ISO_8859-1
- }
- HP-UX {
- set ::tcltest::isoLocale fr_FR.iso88591
- }
- Linux -
- IRIX {
- set ::tcltest::isoLocale fr
- }
- default {
-
- # Works on SunOS 4 and Solaris, and maybe others...
- # define it to something else on your system
- #if you want to test those.
-
- set ::tcltest::isoLocale iso_8859_1
- }
- }
- }
- "windows" {
- set ::tcltest::isoLocale French
- }
- }
- }
-
- set ::tcltest::testConfig(hasIsoLocale) \
- [string length [::tcltest::set_iso8859_1_locale]]
- ::tcltest::restore_locale
-}
-
-#
-# procedures that are Tk specific
-#
-
-if {[info exists tk_version]} {
-
- # If the main window isn't already mapped (e.g. because the tests are
- # being run automatically) , specify a precise size for it so that the
- # user won't have to position it manually.
-
- if {![winfo ismapped .]} {
- wm geometry . +0+0
- update
- }
-
- # The following code can be used to perform tests involving a second
- # process running in the background.
-
- # Locate the tktest executable
-
- set ::tcltest::tktest [info nameofexecutable]
- if {$::tcltest::tktest == "{}"} {
- set ::tcltest::tktest {}
- puts stdout \
- "Unable to find tktest executable, skipping multiple process tests."
- }
-
- # Create background process
-
- proc ::tcltest::setupbg args {
- if {$::tcltest::tktest == ""} {
- error "you're not running tktest so setupbg should not have been called"
- }
- if {[info exists ::tcltest::fd] && ($::tcltest::fd != "")} {
- cleanupbg
- }
-
- # The following code segment cannot be run on Windows prior
- # to Tk 8.1b3 due to a channel I/O bug (bugID 1495).
-
- global tcl_platform
- set ::tcltest::fd [open "|[list $::tcltest::tktest -geometry +0+0 -name tktest] $args" r+]
- puts $::tcltest::fd "puts foo; flush stdout"
- flush $::tcltest::fd
- if {[gets $::tcltest::fd data] < 0} {
- error "unexpected EOF from \"$::tcltest::tktest\""
- }
- if {[string compare $data foo]} {
- error "unexpected output from background process \"$data\""
- }
- fileevent $::tcltest::fd readable bgReady
- }
-
- # Send a command to the background process, catching errors and
- # flushing I/O channels
-
- proc ::tcltest::dobg {command} {
- puts $::tcltest::fd "catch [list $command] msg; update; puts \$msg; puts **DONE**; flush stdout"
- flush $::tcltest::fd
- set ::tcltest::bgDone 0
- set ::tcltest::bgData {}
- tkwait variable ::tcltest::bgDone
- set ::tcltest::bgData
- }
-
- # Data arrived from background process. Check for special marker
- # indicating end of data for this command, and make data available
- # to dobg procedure.
-
- proc ::tcltest::bgReady {} {
- set x [gets $::tcltest::fd]
- if {[eof $::tcltest::fd]} {
- fileevent $::tcltest::fd readable {}
- set ::tcltest::bgDone 1
- } elseif {$x == "**DONE**"} {
- set ::tcltest::bgDone 1
- } else {
- append ::tcltest::bgData $x
- }
- }
-
- # Exit the background process, and close the pipes
-
- proc ::tcltest::cleanupbg {} {
- catch {
- puts $::tcltest::fd "exit"
- close $::tcltest::fd
- }
- set ::tcltest::fd ""
- }
-
- # Clean up focus after using generate event, which
- # can leave the window manager with the wrong impression
- # about who thinks they have the focus. (BW)
-
- proc ::tcltest::fixfocus {} {
- catch {destroy .focus}
- toplevel .focus
- wm geometry .focus +0+0
- entry .focus.e
- .focus.e insert 0 "fixfocus"
- pack .focus.e
- update
- focus -force .focus.e
- destroy .focus
- }
-}
-
-# threadReap --
-#
-# Kill all threads except for the main thread.
-# Do nothing if testthread is not defined.
-#
-# Arguments:
-# none.
-#
-# Results:
-# Returns the number of existing threads.
-
-if {[info commands testthread] != {}} {
- proc ::tcltest::threadReap {} {
- testthread errorproc ThreadNullError
- while {[llength [testthread names]] > 1} {
- foreach tid [testthread names] {
- if {$tid != $::tcltest::mainThread} {
- catch {testthread send -async $tid {testthread exit}}
- update
- }
- }
- }
- testthread errorproc ThreadError
- return [llength [testthread names]]
- }
-} else {
- proc ::tcltest::threadReap {} {
- return 1
- }
-}
-
-# Need to catch the import because it fails if defs.tcl is sourced
-# more than once.
-
-catch {namespace import ::tcltest::*}
-return
diff --git a/sandbox/fvwm.xbm b/sandbox/fvwm.xbm
deleted file mode 100644
index 82c76c4..0000000
--- a/sandbox/fvwm.xbm
+++ /dev/null
@@ -1,21 +0,0 @@
-#define fvwm_width 58
-#define fvwm_height 26
-static char fvwm_bits[] = {
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x00, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0xfc, 0x1b, 0xd8, 0xc0, 0xc0, 0xe6, 0x38, 0x00, 0xfc, 0x1b, 0xcc, 0xe0,
- 0x60, 0xf7, 0x7d, 0x00, 0x30, 0x18, 0xcc, 0xe0, 0x60, 0xb3, 0x6d, 0x00,
- 0x30, 0x38, 0xc6, 0xf1, 0x31, 0x9b, 0x67, 0x00, 0x30, 0x30, 0x86, 0xb1,
- 0x31, 0xcf, 0x73, 0x00, 0x38, 0x30, 0x83, 0x99, 0x99, 0xc7, 0x31, 0x00,
- 0x38, 0x30, 0x83, 0x99, 0x99, 0xc3, 0x30, 0x00, 0x18, 0xb0, 0x81, 0x8d,
- 0x8d, 0xc1, 0x30, 0x00, 0x18, 0xb0, 0x81, 0x8d, 0x8d, 0xc1, 0x30, 0x00,
- 0x1c, 0xf0, 0x80, 0x87, 0xc7, 0xe0, 0x38, 0x00, 0x1c, 0x60, 0x00, 0x03,
- 0xc3, 0x60, 0x18, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
- 0x00, 0x00, 0x00, 0x00};
diff --git a/sandbox/lines.pl b/sandbox/lines.pl
deleted file mode 100644
index 5e7fc6e..0000000
--- a/sandbox/lines.pl
+++ /dev/null
@@ -1,35 +0,0 @@
-#!/usr/bin/perl -w
-
-use Tk;
-use Tk::Zinc;
-
-$mw = MainWindow->new();
-
-$top = 1;
-$zinc = $mw->Zinc(-render => 1,
- -borderwidth => 0,
- -highlightthickness => 0,
- -relief => 'sunken',
- -takefocus => 1,
-# -tile => $papier
- );
-$zinc->pack(-expand => 1, -fill => 'both');
-$zinc->configure(-width => 500, -height => 500);
-
-print "coucou\n";
-$view = $zinc->add('group', $top, -tags => "controls");
-$mp3 = $zinc->add('curve', $view, [20, 280, 100, 430, 200, 430],
- -linewidth => 9,
- -closed => 0,
- -linestyle => 'dashed',
- -joinstyle => 'round',
-# -firstend => [3, 12, 8],
-# -lastend => "12 12 8",
- -capstyle => 'round',
- -linecolor => 'red:100');
-
-$mw->Tk::bind('<p>', sub { print "perfs: ", join(',', $zinc->monitor()), "\n" });
-$mw->Tk::bind('<t>', sub { $zinc->remove($mp3); });
-$mw->Tk::bind('<q>', sub { exit(0); });
-$zinc->focusFollowsMouse();
-MainLoop();
diff --git a/sandbox/logo.gif b/sandbox/logo.gif
deleted file mode 100644
index ce78abd..0000000
--- a/sandbox/logo.gif
+++ /dev/null
Binary files differ
diff --git a/sandbox/smooth.tcl b/sandbox/smooth.tcl
deleted file mode 100644
index 9260f7b..0000000
--- a/sandbox/smooth.tcl
+++ /dev/null
@@ -1,34 +0,0 @@
-#!/usr/local/bin/wish -f
-
-load ../tkzinc3.2.so
-package require Img
-
-set top 1
-set points "50 -150 100 -50 270 -130 220 -200 200 -180 180 -300 140 -320 70 -300"
-set lw 3
-
-set r [zinc .r -backcolor gray -relief sunken]
-pack .r -expand t -fill both
-.r configure -width 800 -height 500
-.r scale $top 1 -1
-#.r configure -drawbboxes t
-set view [.r add group $top -tags controls]
-
-
-set smooth [.r smooth $points]
-set fit [.r fit $points 0.1]
-
-
-set mp [.r add curve $view $smooth \
- -linecolor yellow -fillcolor tan -fillpattern AlphaStipple8 \
- -tags "bezier" -linewidth $lw]
-set mp2 [.r add curve $view $fit \
- -linecolor yellow -fillcolor tan -fillpattern AlphaStipple8 \
- -tags "bezier" -linewidth $lw]
-set poly [.r add curve $view $points -marker AtcSymbol9]
-set poly2 [.r add curve $view $points -marker AtcSymbol9]
-
-.r translate $mp2 300 0
-.r translate $poly2 300 0
-
-source "controls.tcl"
diff --git a/sandbox/testarc.tcl b/sandbox/testarc.tcl
deleted file mode 100644
index b48b537..0000000
--- a/sandbox/testarc.tcl
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/usr/local/bin/wish -f
-
-load ../tkzinc3.2.so
-package require Img
-
-set top 1
-
-#image create photo logo -file logo.gif
-#image create photo papier -file texture-paper.xpm
-#image create photo penguin -file xpenguin.png
-#image create photo papier -file texture-paper.xpm
-
-set r [zinc .r -backcolor gray -relief sunken -render 0]
-pack .r -expand t -fill both
-.r configure -width 800 -height 500
-#.r configure -drawbboxes t
-.r scale $top 1 -1
-set view [.r add group $top -tags "controls"]
-.r translate $view 200 -200
-set view2 [.r add group $top]
-.r translate $view2 300 -200
-
-set arc [.r add arc $view "50 -10 200 -100" -filled t -closed t -pieslice t \
- -fillcolor "white|darkslateblue" -linewidth 1 \
- -startangle 0 -extent 120]
-#set arc [.r add arc $view "50 -10 200 -100" -filled t -closed t -pieslice t -fillcolor "#ff0000|#00ff00" -linewidth 0]
-#.r add arc $view "60 -20 190 -90" -filled t -closed t -pieslice t -fillcolor "white|darkslateblue" -linewidth 1 -linecolor white
-
-#set arc2 [.r clone $arc -linecolor red -firstend "8 10 5"]
-#.r rotate $arc2 10
-#.r translate $arc2 100 -100
-
-#.r add icon $view2 -image penguin
-set cliparc [.r add arc $view "-100 100 100 -100" -filled t \
- -fillcolor tan ]
-.r lower $cliparc
-#.r rotate $cliparc 20 0 0
-#.r translate $cliparc 100 -40
-#.r itemconfigure $view2 -clip $cliparc
-bind .r <1> ".r rotate $cliparc [expr 3.14/3] 0 0"
-source "controls.tcl"
-.r bind $cliparc <1> {puts a}
-puts "[ .r bind $cliparc <1> ]\n"
-
diff --git a/sandbox/testbezier.pl b/sandbox/testbezier.pl
deleted file mode 100644
index 82948fc..0000000
--- a/sandbox/testbezier.pl
+++ /dev/null
@@ -1,190 +0,0 @@
-#!/usr/bin/perl -w
-
-
-use Tk;
-use Tk::Zinc;
-use Controls;
-use Tk::Photo;
-require Tk::PNG;
-
-
-$top = 1;
-$lw = 8;
-$arrow = [8, 10, 6];
-
-#
-# Cap, Filled, Border, Relief, Title
-#
-@show = (
- ['round', 0, 1, 'flat', 'CapRound'],
- ['butt', 0, 1, 'flat', 'CapButt'],
- ['projecting', 0, 1, 'flat', 'CapProjecting'],
- ['round', 0, 1, 'sunken', 'Sunken'],
- ['round', 0, 1, 'raised', 'Raised'],
- ['round', 0, 1, 'groove', 'Groove'],
- ['round', 0, 1, 'ridge', 'Ridge'],
- ['round', 1, 1, 'roundsunken', 'RoundSunken'],
- ['round', 1, 1, 'roundraised', 'RoundRaised'],
- ['round', 1, 1, 'roundgroove', 'RoundGroove'],
- ['round', 1, 1, 'roundridge', 'RoundRidge'],
- ['round', 1, 1, 'sunkenrule', 'SunkenRule'],
- ['round', 1, 1, 'raisedrule', 'RaisedRule'],
- ['round', 1, 0, 'flat', 'Fill'],
- ['round', 1, 1, 'flat', 'FillBorder']);
-
-$mw = MainWindow->new();
-#$logo = $mw->Photo(-file => "logo.gif");
-$papier = $mw->Photo(-file => "texture-paper.xpm");
-
-$zinc = $mw->Zinc(-render => 1,
- -lightangle => 120,
- -borderwidth => 0,
- -highlightthickness => 0,
- -relief => 'sunken',
- -takefocus => 1,
- -backcolor => 'red'
- # -tile => $papier
- );
-$zinc->pack(-expand => 1, -fill => 'both');
-$zinc->configure(-width => 500, -height => 500);
-$zinc->scale($top, 1, -1);
-
-$view = $zinc->add('group', $top,
- -tags => 'controls');
-$clipbez = $zinc->add('bezier', $view, [20, -20,
- 890, -20,
- 890, -900,
- 20, -400],
- -linewidth => 0,
- -filled => 1,
- -fillcolor => 'tan');
-#$zinc->itemconfigure($view,
-# -clip => $clipbez);
-
-#
-# Create the model
-#
-$model = $zinc->add('group', $view);
-$mp = $zinc->add('bezier', $model, [50, -150,
- 100, -50,
- 270, -130,
- 220, -200,
- 200, -180,
- 180, -300,
- 140, -160,
- 70, -300],
- -fillcolor => 'tan',
- -tags => 'bezier',
- -linewidth =>$lw);
-#$zinc->add('rectangle', $model, [50, -150, 100, -50]);
-@bbox = $zinc->bbox($mp);
-@bbox = $zinc->transform($model, \@bbox);
-$x = ($bbox[2] + $bbox[0]) / 2;
-$y = $bbox[1] + 5;
-$zinc->add('text', $model,
- -text => 'CapRound',
- -color => 'blue',
- -alignment => 'center',
- -anchor => 's',
- -tags => 'title',
- -position => [$x, $y]);
-
-#
-# Now clone for each variation on the polygon
-#
-$col = 0;
-$row = 0;
-foreach $current (@show) {
- ($cap, $filled, $border, $relief, $title) = @{$current};
- $grp = $zinc->clone($model);
- $zinc->translate($grp, $col * 240, $row * (-290 - (2 * $lw)));
- $zinc->itemconfigure($zinc->find('withtag', "$grp*bezier"),
- -capstyle => $cap,
- -filled => $filled,
- -linewidth => $border ? $lw : 0,
- -relief => $relief,
- -linecolor => $relief eq 'flat' ? 'yellow' : 'tan');
- $zinc->itemconfigure($zinc->find('withtag', "$grp*title"),
- -text => $title);
- $col++;
- if ($col >= 4) {
- $col = 0;
- $row++;
- }
-}
-
-#
-# Suppress the model
-#
-$zinc->remove($model);
-
-my @coords = (
-10, 0, 40, 0, 70, 0,
-70, 0, 80, 0, 80, 10,
-80, 10, 80, 40, 80, 70,
-80, 70, 80, 80, 70, 80,
-70, 80, 40, 80, 10, 80,
-10, 80, 0, 80, 0, 70,
-0, 70, 0, 40, 0, 10,
-0, 10, 0, 0, 10, 0);
-$zinc->add('bezier', $view, \@coords);
-
-#
-# Some optional graphic features
-$closed = 0;
-#set smooth 0
-$arrows = 'none';
-
-sub toggle_arrows {
- if ($arrows eq 'none') {
- $arrows = 'first';
- $f = $arrow;
- $l = '';
- }
- elsif ($arrows eq 'first') {
- $arrows = 'last';
- $f = '';
- $l = $arrow;
- }
- elsif ($arrows eq 'last') {
- $arrows = 'both';
- $f = $arrow;
- $l = $arrow;
- }
- elsif ($arrows eq 'both') {
- $arrows = 'none';
- $f = '';
- $l = '';
- }
- $zinc->itemconfigure('bezier',
- -firstend => $f,
- -lastend => $l)
-}
-
-
-sub toggle_closed {
- $closed = !$closed;
- foreach $ curve ($zinc->find('withtag', 'bezier')) {
- if ($closed) {
- @coords = $zinc->coords($curve, 0, 0);
- $zinc->coords($curve, 'add', \@coords);
- }
- else {
- $zinc->coords($curve, 'remove', -1)
- }
- }
-}
-
-$zinc->Tk::focus();
-
-$zinc->Tk::bind('<a>', \&toggle_arrows);
-$zinc->Tk::bind('<c>', \&toggle_closed);
-
-$zinc->Tk::bind('<Shift-1>',
- sub {my $ev = $zinc->XEvent();
- my $it = $zinc->find('closest', $ev->x, $ev->y);
- print "$it ", $zinc->verticeat($it, $ev->x, $ev->y), "\n"});
-$zinc->Tk::bind('<Shift-ButtonRelease-1>', sub {Tk::break});
-
-new Controls($zinc);
-MainLoop();
diff --git a/sandbox/testbezier.tcl b/sandbox/testbezier.tcl
deleted file mode 100644
index 4b1af0b..0000000
--- a/sandbox/testbezier.tcl
+++ /dev/null
@@ -1,131 +0,0 @@
-#!/usr/local/bin/wish -f
-
-load ../tkzinc3.2.so
-package require Img
-
-set top 1
-set lw 8
-set arrow "8 10 6"
-
-
-#
-# Cap Filled Border Relief Title
-#
-set show {\
- {round f 1 flat CapRound}\
- {butt f 1 flat CapButt}\
- {projecting f 1 flat CapProjecting}\
- {round f 1 sunken Sunken}\
- {round f 1 raised Raised}\
- {round f 1 groove Groove}\
- {round f 1 ridge Ridge}\
- {round t 1 sunken FilledSunken}\
- {round t 1 raised FilledRaised}\
- {round t 1 groove FilledGroove}\
- {round t 1 ridge FilledRidge}\
- {round t 0 flat Fill}\
- {round t 1 flat FillBorder}}
-
-image create photo logo -file /usr/share/toccata/images/logo.gif
-#image create photo papier -file /usr/share/toccata/images/dgtexture-dragstrip.xpm
-
-set r [zinc .r -backcolor gray -relief sunken]
-pack .r -expand t -fill both
-.r configure -width 1024 -height 800
-.r scale $top 1 -1
-#.r configure -drawbboxes t
-set view [.r add group $top -tags controls]
-
-#
-# Create the model
-#
-set model [.r add group $view]
-set mp [.r add bezier $model "50 -150 100 -50 270 -130 220 -200 200 -180 180 -300 140 -160 70 -300" \
- -linecolor yellow -fillcolor tan -fillpattern AlphaStipple8 \
- -tags "bezier" -linewidth $lw]
-#.r add rectangle $model "50 -150 100 -50"
-set bbox [.r transform $model [.r bbox $mp]]
-set x [expr ([lindex $bbox 2] + [lindex $bbox 0]) / 2]
-set y [expr [lindex $bbox 1] + 5]
-.r add text $model -text "CapRound" -color blue -alignment center -anchor s -tags "title" \
- -position "$x $y"
-
-#
-# Now clone for each variation on the polygon
-#
-set col 0
-set row 0
-foreach current $show {
- foreach {cap filled border relief title} $current {
- set grp [.r clone $model]
- .r translate $grp [expr $col * 240] [expr $row * (-290 - (2 * $lw))]
- .r itemconfigure [.r find withtag "bezier" $grp] \
- -capstyle $cap -filled $filled \
- -linewidth [expr $border ? $lw : 0] \
- -relief $relief -linecolor [expr $relief == flat ? yellow : tan]
- .r itemconfigure [.r find withtag "title" $grp] -text $title
- incr col
- if {$col >= 4} {
- set col 0
- incr row
- }
- }
-}
-
-#
-# Suppress the model
-#
-.r remove $model
-
-
-#
-# Some optional graphic features
-set closed 0
-#set smooth 0
-set arrows none
-
-proc toggle_arrows { } {
- global arrows arrow
- if {$arrows == "none"} {
- set arrows first
- set f $arrow
- set l ""
- } elseif {$arrows == "first"} {
- set arrows last
- set f ""
- set l $arrow
- } elseif {$arrows == "last"} {
- set arrows both
- set f $arrow
- set l $arrow
- } elseif {$arrows == "both"} {
- set arrows none
- set f ""
- set l ""
- }
- .r itemconfigure bezier -firstend $f -lastend $l
-}
-
-
-proc toggle_closed { } {
- global closed
- set closed [expr ! $closed]
- foreach curve [.r find withtag "bezier"] {
- if {$closed} {
- .r coords $curve add [.r coords $curve 0]
- } {
- .r coords $curve remove -1
- }
- }
-
-}
-
-focus .r
-
-bind .r "<a>" toggle_arrows
-bind .r "<c>" toggle_closed
-
-bind .r "<Shift-1>" {set it [.r find closest %x %y]; puts "$it [.r verticeat $it %x %y]"}
-bind .r "<Shift-ButtonRelease-1>" {break}
-
-source "controls.tcl"
diff --git a/sandbox/testbitmaps.tcl b/sandbox/testbitmaps.tcl
deleted file mode 100644
index 27a519b..0000000
--- a/sandbox/testbitmaps.tcl
+++ /dev/null
@@ -1,86 +0,0 @@
-#!/usr/local/bin/wish -f
-
-lappend auto_path ..
-package require Tkzinc
-package require Img
-
-set r [zinc .r -render 1 -backcolor gray -relief sunken]
-set top 1
-pack .r -expand t -fill both
-.r configure -width 500 -height 800
-
-set r [.r add rectangle $top "30 50 80 100" -filled t -fillpattern AlphaStipple0 -linewidth 1]
-.r translate $r -55 -75
-.r rotate $r 45
-.r translate $r 55 75
-
-.r add text $top -position "50 110" -text "0"
-.r add rectangle $top "100 50 150 100" -filled t -fillpattern AlphaStipple1
-.r add text $top -position "120 110" -text "1"
-.r add rectangle $top "170 50 220 100" -filled t -fillpattern AlphaStipple2
-.r add text $top -position "190 110" -text "2"
-.r add rectangle $top "240 50 290 100" -filled t -fillpattern AlphaStipple3
-.r add text $top -position "260 110" -text "3"
-.r add rectangle $top "310 50 360 100" -filled t -fillpattern AlphaStipple4
-.r add text $top -position "330 110" -text "4"
-.r add rectangle $top "380 50 430 100" -filled t -fillpattern AlphaStipple5
-.r add text $top -position "400 110" -text "5"
-
-.r add rectangle $top "30 150 80 200" -filled t -fillpattern AlphaStipple6
-.r add text $top -position "50 210" -text "6"
-.r add rectangle $top "100 150 150 200" -filled t -fillpattern AlphaStipple7
-.r add text $top -position "120 210" -text "7"
-.r add rectangle $top "170 150 220 200" -filled t -fillpattern AlphaStipple8
-.r add text $top -position "190 210" -text "8"
-.r add rectangle $top "240 150 290 200" -filled t -fillpattern AlphaStipple9
-.r add text $top -position "260 210" -text "9"
-.r add rectangle $top "310 150 360 200" -filled t -fillpattern AlphaStipple10
-.r add text $top -position "330 210" -text "10"
-.r add rectangle $top "380 150 430 200" -filled t -fillpattern AlphaStipple11
-.r add text $top -position "400 210" -text "11"
-
-.r add rectangle $top "100 250 150 300" -filled t -fillpattern AlphaStipple12
-.r add text $top -position "120 310" -text "12"
-.r add rectangle $top "170 250 220 300" -filled t -fillpattern AlphaStipple13
-.r add text $top -position "190 310" -text "13"
-.r add rectangle $top "240 250 290 300" -filled t -fillpattern AlphaStipple14
-.r add text $top -position "260 310" -text "14"
-.r add rectangle $top "310 250 360 300" -filled t -fillpattern AlphaStipple15
-.r add text $top -position "330 310" -text "15"
-
-.r add text $top -position "180 360" -text "AlphaStipple" \
- -font "-*-lucida-bold-r-normal-*-14-*-*-*-*-*-*-*"
-
-for {set i 0} {$i < 22} {incr i} {
- set num [expr $i + 1]
- .r add waypoint $top 0 \
- -position "[expr 40 + ($i % 8)*60] [expr 420 + ($i / 8)*45]" \
- -symbol "AtcSymbol$num"
- .r add text $top \
- -position "[expr 36 + ($i % 8)*60] [expr 430 + ($i / 8)*45]" \
- -text "$num" \
- -font "-*-helvetica-medium-r-*-*-*-120-*-*-*-*-*-*"
-}
-
-.r add text $top -position "180 560" -text "AtcSymbol" \
- -font "-*-lucida-bold-r-normal-*-14-*-*-*-*-*-*-*"
-
-
-set im [image create bitmap toto -background "red" -file fvwm.xbm]
-set icim [.r add icon 1 -image $im -position {0 0}]
-.r rotate $icim 20
-.r scale $icim 1.2 1.2
-.r translate $icim 50 320
-#.r add icon 1 -image $im -position {300 10}
-#.r add rectangle 1 {10 10 100 100} -tile $im -filled 1
-#$im configure -background red
-
-set icbit [.r add icon 1 -image @fvwm.xbm -position {100 400}]
-
-#.r bind $icbit <Enter> ".r itemconfigure $icbit -color red; \
-# $im configure -file fvwm.xbm -foreground black"
-#.r bind $icbit <Leave> ".r itemconfigure $icbit -color black; \
-# $im configure -file trash.xbm -foreground red "
-
-#.r bind $icim <Enter> "$im configure -background black"
-#.r bind $icim <Leave> "$im configure -background red"
diff --git a/sandbox/testicon.tcl b/sandbox/testicon.tcl
deleted file mode 100644
index fd8ba39..0000000
--- a/sandbox/testicon.tcl
+++ /dev/null
@@ -1,102 +0,0 @@
-#!/usr/local/bin/wish -f
-
-load ../tkzinc3.2.so
-package require Img
-
-set top 1
-
-image create photo penguin -file xpenguin.png
-image create photo bouton -file bouton.xpm
-image create photo boutond -file bouton-down.xpm
-set mask "fvwm.xbm"
-
-set r [zinc .r -backcolor gray -relief sunken -render 1 -borderwidth 20]
-pack .r -expand t -fill both
-.r configure -width 800 -height 500
-#.r configure -drawbboxes t
-.r scale $top 1 -1
-set view [.r add group $top -tags "controls"]
-
-proc maskicon {x y group mask color anchor} {
- .r add icon $group -mask "@$mask" -position "$x $y" -anchor $anchor -color $color
- .r add rectangle $group [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-}
-
-proc imageicon {x y group image anchor} {
- .r add icon $group -image $image -position "$x $y" -anchor $anchor
- .r add rectangle $group [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-}
-
-set x 50.0
-set y -100.0
-maskicon $x $y $view $mask yellow sw
-set x [expr $x + 100.0]
-maskicon $x $y $view $mask pink s
-set x [expr $x + 100.0]
-maskicon $x $y $view $mask violet se
-set x 50
-set y -150
-maskicon $x $y $view $mask lightblue w
-set x [expr $x + 100.0]
-maskicon $x $y $view $mask blue center
-set x [expr $x + 100.0]
-maskicon $x $y $view $mask darkblue e
-set x 50.0
-set y -200.0
-maskicon $x $y $view $mask violet nw
-set x [expr $x + 100.0]
-maskicon $x $y $view $mask pink n
-set x [expr $x + 100.0]
-maskicon $x $y $view $mask yellow ne
-set x2 500.0
-set y2 -300.0
-imageicon $x2 $y2 $view penguin center
-
-.r add icon $view -image bouton -position "$x2 $y2" -anchor center
-.r add icon $view -image boutond -position [list [expr $x2 + 50] $y2] -anchor center
-.r add text $view -text essai -position "$x2 $y2"
-
-#
-# Clip
-#
-puts "crée les clips"
-set clip [.r add rectangle $view "50 -10 600 -300" -filled t \
- -linewidth 0 -fillcolor darkgray]
-#.r rotate $clip [expr 3.14159 / 4]; #bug le rectangle forme un bonnet
-# d'ane sous certains angles.
-.r lower $clip
-.r itemconfigure $view -clip $clip
-
-.r addtag test withtype icon
-.r bind test "<Shift-ButtonPress-1>" "testpress %x %y"
-.r bind test "<Shift-ButtonRelease-1>" testrelease
-
-proc testpress {lx ly} {
- global testx testy
- set testx $lx
- set testy $ly
- .r bind test "<Motion>" "testmotion %x %y"
-}
-
-proc testmotion {lx ly} {
- global testx testy
- set it [.r find withtag test]
- if {$it != ""} {
- set it [.r group [lindex $it 0]]
- }
- set res [.r transform $it "$lx $ly $testx $testy"]
- set nx [lindex $res 0]
- set ny [lindex $res 1]
- set ox [lindex $res 2]
- set oy [lindex $res 3]
- .r translate current [expr $nx - $ox] [expr $ny - $oy]
- set testx $lx
- set testy $ly
-}
-proc testrelease {} {
- .r bind test "<Motion>" ""
-}
-
-source controls.tcl
diff --git a/sandbox/testplug.pl b/sandbox/testplug.pl
deleted file mode 100644
index 418c91a..0000000
--- a/sandbox/testplug.pl
+++ /dev/null
@@ -1,51 +0,0 @@
-#!/usr/bin/perl
-
-use Tk;
-
-$mw = MainWindow->new();
-
-$zinc = $mw->Zinc(-backcolor => 'gray',
- -relief => 'sunken',
- -width => 800,
- -height => 500)->pack(-expand => 1,
- -fill => 'both');
-$top = 1;
-#$ent = $zinc->Entry();
-#$entryitem = $zinc->add('window', $top,
-# -window => $ent,
-# -position => [100, 100]);
-$dcontainer = $zinc->Frame(-container => 1);
-$did = $dcontainer->id();
-$vcontainer = $zinc->Frame(-container => 1);
-$vid = $vcontainer->id();
-#print "container id is $id\n";
-
-$dlabel = $zinc->add('text', $top,
- -text => "Digistrips",
- -position => [150, 30]);
-$zinc->bind($dlabel, '<1>', sub { $zinc->itemconfigure($vlabel, -color => 'black');
- $zinc->itemconfigure($dlabel, -color => 'red');
- $zinc->itemconfigure($vcontitem, -visible => 0);
- $zinc->itemconfigure($dcontitem, -visible => 1); });
-$vlabel = $zinc->add('text', $top,
- -text => "Virtuosi",
- -position => [250, 30]);
-$zinc->bind($vlabel, '<1>', sub { $zinc->itemconfigure($dlabel, -color => 'black');
- $zinc->itemconfigure($vlabel, -color => 'red');
- $zinc->itemconfigure($dcontitem, -visible => 0);
- $zinc->itemconfigure($vcontitem, -visible => 1); });
-$dcontitem = $zinc->add('window', $top,
- -window => $dcontainer,
- -position => [50, 75],
- -visible => 0);
-$vcontitem = $zinc->add('window', $top,
- -window => $vcontainer,
- -position => [50, 75],
- -visible => 0);
-
-$mw->update();
-
-system("digistripsIII -stan --use $did -style standalone-1024x768 &");
-system("virtuosi -g 1024x768 -use $vid &");
-
-MainLoop();
diff --git a/sandbox/testpoly.tcl b/sandbox/testpoly.tcl
deleted file mode 100644
index 2a16288..0000000
--- a/sandbox/testpoly.tcl
+++ /dev/null
@@ -1,157 +0,0 @@
-#!/usr/local/bin/wish -f
-
-lappend auto_path ..
-package require Tkzinc
-package require Img
-
-set top 1
-set lw 8
-set marker AtcSymbol9
-set arrow "8 10 6"
-
-
-#
-# Cap Join Filled Border Relief Title
-#
-set show {\
- {round round f 1 flat JoinRound}\
- {round bevel f 1 flat JoinBevel}\
- {round miter f 1 flat JoinMiter}\
- {butt round f 1 flat CapButt}\
- {projecting round f 1 flat CapProjecting}\
- {round round f 1 sunken Sunken}\
- {round round f 1 raised Raised}\
- {round round f 1 groove Groove}\
- {round round f 1 ridge Ridge}\
- {round round t 1 sunken FilledSunken}\
- {round round t 1 raised FilledRaised}\
- {round round t 1 groove FilledGroove}\
- {round round t 1 ridge FilledRidge}\
- {round round f 0 flat Marker}\
- {round round t 0 flat Fill}\
- {round round t 1 flat FillBorder}}
-
-image create photo logo -file logo.gif
-#image create photo papier -file /usr/share/toccata/images/dgtexture-dragstrip.xpm
-
-set r [zinc .r -backcolor gray -relief sunken -render 0]
-pack .r -expand t -fill both
-.r configure -width 1024 -height 800
-.r scale $top 1 -1
-#.r configure -drawbboxes t
-set view [.r add group $top -tags controls]
-
-#
-# Create the model
-#
-set model [.r add group $view]
-set mp [.r add curve $model "50 -150 100 -50 270 -130 220 -200 200 -180 180 -300 140 -160 70 -300" \
- -linecolor yellow -fillcolor tan -fillpattern AlphaStipple8 \
- -markercolor red -tags "poly" -linewidth $lw]
-.r add rectangle $model "50 -150 100 -50"
-set bbox [.r transform $model [.r bbox $mp]]
-set x [expr ([lindex $bbox 2] + [lindex $bbox 0]) / 2]
-set y [expr [lindex $bbox 1] + 5]
-.r add text $model -text "CapRound" -color blue -alignment center -anchor s -tags "title" \
- -position "$x $y"
-
-#
-# Now clone for each variation on the polygon
-#
-proc linecol { relief } {
- if {[string compare $relief flat]} {
- return yellow
- } else {
- return tan
- }
-}
-
-set col 0
-set row 0
-foreach current $show {
- foreach {cap join filled border relief title} $current {
- set grp [.r clone $model]
- .r translate $grp [expr $col * 240] [expr $row * (-290 - (2 * $lw))]
- .r itemconfigure [.r find withtag "$grp*poly"] \
- -capstyle $cap -joinstyle $join -filled $filled \
- -linewidth [expr $border ? $lw : 0] -relief $relief \
- -linecolor [linecol $relief]
- .r itemconfigure [.r find withtag "$grp*title"] -text $title
- incr col
- if {$col >= 4} {
- set col 0
- incr row
- }
- }
-}
-
-#
-# Suppress the model
-#
-.r remove $model
-
-
-#
-# Some optional graphic features
-set closed 0
-set marks 0
-#set smooth 0
-set arrows none
-
-proc toggle_arrows { } {
- global arrows arrow
- if {$arrows == "none"} {
- set arrows first
- set f $arrow
- set l ""
- } elseif {$arrows == "first"} {
- set arrows last
- set f ""
- set l $arrow
- } elseif {$arrows == "last"} {
- set arrows both
- set f $arrow
- set l $arrow
- } elseif {$arrows == "both"} {
- set arrows none
- set f ""
- set l ""
- }
- .r itemconfigure poly -firstend $f -lastend $l
-}
-
-proc toggle_marks { } {
- global marks marker
- set marks [expr ! $marks]
- if {$marks} {
- .r itemconfigure poly -marker $marker
- } {
- .r itemconfigure poly -marker ""
- }
-}
-
-#proc toggle_smooth { } {
-# global smooth
-# set smooth [expr ! $smooth]
-# .r itemconfigure poly -smoothed $smooth
-#}
-
-proc toggle_closed { } {
- global closed
- set closed [expr ! $closed]
- foreach curve [.r find withtag "poly"] {
- .r itemconfigure $curve -closed $closed
- }
-
-}
-
-focus .r
-
-bind .r "<a>" toggle_arrows
-bind .r "<c>" toggle_closed
-bind .r "<m>" toggle_marks
-
-bind .r "<Shift-1>" {set it [.r find closest %x %y]; puts "$it [.r verticeat $it %x %y]"}
-bind .r "<Shift-ButtonRelease-1>" {break}
-
-source "controls.tcl"
diff --git a/sandbox/testrect.pl b/sandbox/testrect.pl
deleted file mode 100644
index 8a4d399..0000000
--- a/sandbox/testrect.pl
+++ /dev/null
@@ -1,99 +0,0 @@
-#!/usr/bin/perl -w
-
-use Tk;
-use Tk::Zinc;
-
-use Controls;
-
-$mw = MainWindow->new();
-
-
-###################################################
-# creation zinc
-###################################################
-$top = 1;
-$zinc_width = 800;
-$zinc_height = 500;
-
-$zinc = $mw->Zinc(-backcolor => 'gray65', -relief => 'sunken');
-$zinc->pack(-expand => 1, -fill => 'both');
-$zinc->configure(-width => $zinc_width, -height => $zinc_height);
-
-#$zinc->configure(-drawbboxes => 1);
-
-#print "cells ", $zinc->cells(), " visual ", $zinc->visual(), " ", $zinc->visualsavailable(), "\n";
-
-$zinc->scale($top, 1, -1);
-$view = $zinc->add('group', $top, -tags => ["controls"]);
-$zinc->translate($view, 300, -200);
-$view2 = $zinc->add('group', $top);
-$zinc->translate($view2, 100, -50);
-
-
-#$rect0 = $zinc->add('rectangle', $view [100, -105, 200, -305],
-# -filled => t,
-# -fillcolor => "white|cadetblue3");
-
-$color1 = 'darkslateblue';
-$color2 = '#f0ffff';
-$gangle = 0;
-$shades = 8;
-$rect1 = $zinc->add('rectangle', $view, [-50, 100, 50, -100],
- -filled => 1,
- -relief => 'flat',
- -linewidth => 1,
- -fillpattern => 'AlphaStipple7',
- -fillcolor => "$color1|$color2/$gangle%$shades");
-#
-# Mire
-$zinc->add('curve', $view, [-10, 0, 10, 0],
- -linecolor => 'red');
-$zinc->add('curve', $view, [0, -10, 0, 10],
- -linecolor => 'red');
-
-$handle = $zinc->add('arc', $view, [-3, -106, 3, -112],
- -filled => 1,
- -fillcolor => 'red');
-$zinc->bind($handle, '<B1-Motion>', \&adjustcontrol);
-
-sub adjustcontrol {
- my $ev = $zinc->XEvent();
- my $x;
- my $y;
- my ($xo, $yo, $xc, $yc) = $zinc->coords($rect1);
-
- ($x, $y) = $zinc->transform($view, [$ev->x, 0]);
- if ($x < $xo) {
- $x = $xo;
- }
- elsif ($x > $xc) {
- $x = $xc;
- }
- $zinc->coords($handle, [$x - 3, $yc-6, $x + 3, $yc-12]);
- $x = ($x - $xo)*100/($xc-$xo);
- $zinc->itemconfigure($rect1,
- -fillcolor => "$color1 0 $x|$color2/$gangle%$shades");
-}
-
-#
-# 72 61 139 = DarkSlateBlue
-#
-# 240 255 255 = azure
-#
-#set rect2 [.r add rectangle $view "202 -320 302 -350" -filled t -fillcolor darkgray -linewidth 2]
-
-#set rect3 [.r add rectangle $view "250 -100 350 -300" -filled t -relief raised -linewidth 4 -fillcolor "white|cadetblue3" -linecolor white]
-
-#set rect4 [.r add rectangle $view2 "0 0 101 -81" -linewidth 2 -linecolor darkgray -filled t]
-#.r itemconfigure $rect4 -fillcolor "white|darkslateblue"
-
-#set rect5 [.r add rectangle $view2 "0 0 101 -81" -linewidth 2 -linecolor blue -filled t -fillcolor blue -relief sunken]
-#.r translate $rect5 0 -90
-
-
-new Controls($zinc);
-
-MainLoop();
-
-
-1;
diff --git a/sandbox/testrelief.pl b/sandbox/testrelief.pl
deleted file mode 100644
index 79c9a31..0000000
--- a/sandbox/testrelief.pl
+++ /dev/null
@@ -1,73 +0,0 @@
-#!/usr/bin/perl -w
-
-use Tk;
-use Tk::Zinc;
-use Controls;
-
-$top = 1;
-$lw = 8;
-
-$mw = MainWindow->new();
-$zinc = $mw->Zinc(-backcolor => 'gray',
- -relief => 'sunken',
- -lightangle => 120,
- -render => 1);
-$zinc->pack(-expand => 1,
- -fill => 'both');
-$zinc->configure(-width => 1024,
- -height => 800);
-$zinc->scale($top, 1, -1);
-
-$view = $zinc->add('group', $top, -tags => 'controls');
-
-sub polypoints {
- ($ox, $oy, $rad, $n, $startangle) = @_;
-
- $step = 2 * 3.14159 / $n;
- $startangle = $startangle*3.14159/180;
- $coords = [];
- for ($i = 0; $i < $n; $i++) {
- $x = $ox + ($rad * cos($i * $step + $startangle));
- $y = $oy + ($rad * sin($i * $step + $startangle));
- push(@{$coords}, $x, $y);
- }
- push(@{$coords}, $coords->[0], $coords->[1]);
- return $coords
-}
-
-$zinc->add('curve', $view, polypoints(200, -200, 100, 40, 0),
- -relief => 'raised',
- -linewidth => $lw,
- -smoothrelief => 1,
- -fillcolor => 'lightblue',
- -linecolor => 'lightblue',
- -filled => 1);
-
-$zinc->add('curve', $view, polypoints(450, -200, 100, 40, 0),
- -relief => 'raised',
- -linewidth => $lw,
- -smoothrelief => 1,
- -fillcolor => 'tan',
- -linecolor => 'tan',
- -filled => 1);
-
-$zinc->add('curve', $view, polypoints(700, -200, 100, 40, 0),
- -relief => 'sunken',
- -linewidth => $lw,
- -smoothrelief => 1,
- -fillcolor => 'tan',
- -linecolor => 'tan',
- -closed => 1,
- -filled => 1);
-
-$zinc->add('curve', $view, polypoints(200, -450, 100, 7, -45),
- -relief => 'sunken',
- -linewidth => $lw,
- -fillcolor => 'tan',
- -linecolor => 'tan',
- -filled => 1);
-
-
-new Controls($zinc);
-MainLoop();
-
diff --git a/sandbox/testrelief.tcl b/sandbox/testrelief.tcl
deleted file mode 100644
index e75cc71..0000000
--- a/sandbox/testrelief.tcl
+++ /dev/null
@@ -1,45 +0,0 @@
-#!/usr/local/bin/wish -f
-
-load ../tkzinc3.2.so
-
-set top 1
-set lw 8
-
-set r [zinc .r -backcolor gray -relief sunken -lightangle 120 -render 0]
-pack .r -expand t -fill both
-.r configure -width 1024 -height 800
-.r scale $top 1 -1
-
-set view [.r add group $top -tags controls]
-
-proc polypoints { ox oy rad n startangle } {
- set step [expr 2 * 3.14159 / $n]
- set startangle [expr $startangle*3.14159/180]
- set coords ""
- for {set i 0} {$i < $n} {incr i} {
- set x [expr $ox + ($rad * cos($i * $step + $startangle))];
- set y [expr $oy + ($rad * sin($i * $step + $startangle))];
- lappend coords $x $y;
- }
- lappend coords [lindex $coords 0] [lindex $coords 1]
- return $coords
-}
-
-set poly [ .r add curve $view [polypoints 200 -200 100 40 0] \
- -relief raised -linewidth $lw -smoothrelief 1 \
- -fillcolor lightblue -linecolor lightblue -filled t]
-
-set poly [ .r add curve $view [polypoints 450 -200 100 40 0] \
- -relief raised -linewidth $lw \
- -fillcolor tan -linecolor tan -filled t]
-
-set poly [ .r add curve $view [polypoints 700 -200 100 40 0] \
- -relief sunken -linewidth $lw \
- -fillcolor tan -linecolor tan -filled t]
-
-set poly [ .r add curve $view [polypoints 200 -450 100 4 -45] \
- -relief sunken -linewidth $lw \
- -fillcolor tan -linecolor tan -filled t]
-
-
-source "controls.tcl"
diff --git a/sandbox/testshape.pl b/sandbox/testshape.pl
deleted file mode 100644
index 5897912..0000000
--- a/sandbox/testshape.pl
+++ /dev/null
@@ -1,132 +0,0 @@
-#!/usr/bin/perl -w
-
-use Tk;
-use Tk::Zinc;
-use Controls;
-
-$mw = MainWindow->new();
-
-$top = 1;
-$zinc = $mw->Zinc(-render => 1,
- -borderwidth => 0,
-# -fullreshape => 0,
- -relief => 'sunken');
-$zinc->pack(-expand => 1, -fill => 'both');
-$zinc->configure(-width => 500, -height => 500);
-
-$zinc->gname('white:40 0 60|black 50|white 100(0 0', 'oeil');
-$zinc->gname('white:0 0 10|black:100 100/0', 'oeil2');
-$zinc->gname('white:100|black:100(-35 -25', 'boule');
-$zinc->gname('white:100|black:100(-15 -100', 'arrondi');
-$zinc->gname('white:100|black:100/45', 'cyl');
-$zinc->gname('white|black[50 0', 'path');
-
-# $arc = $zinc->add('arc', $top, [50, 50, 200, 100],
-# -visible => 0);
-#$zinc->itemconfigure($top, -clip => $arc);
-
-$view = $zinc->add('group', $top, -tags => "controls");
-# $cv = $zinc->add('curve', $view, [50, 50, 100, 150, 270, 70,
-# 220, 0, 200, 20, 180, 100,
-# 140, 40, 70, 100],
-# -visible => 1,
-# -closed => 1,
-# -filled => 1);
-
-$g1 = $zinc->add('group', $view);
-$zinc->translate($g1, 100, 300);
-$rect = $zinc->add('rectangle', $g1, [-40,-50, 40,50],
- -filled => 1,
- -fillcolor => 'path'
- );
-$g2 = $zinc->add('group', $view);
-$zinc->translate($g2, 200, 300);
-$arc = $zinc->add('arc', $g2, [0,0, 100,100],
- -filled => 1,
- -linecolor => 'white',
- -fillcolor => 'boule',
- -startangle => 120,
- -extent => 120,
- -closed => 1,
- -pieslice => 1,
-# -fillcolor => 'tan'
- );
-$arc2 = $zinc->add('arc', $view, [90,0, 160,50],
- -visible => 0,
- -linewidth => 0,
- -filled => 1,
- -fillcolor => 'brown');
-$g3 = $zinc->add('group', $view);
-$zinc->translate($g3, 300, 300);
-$cv3 = $zinc->add('curve', $g3,
-# [[-50, -40], [0, 0], [-50, 40], [50, 40], [50, -40]],
- [-50, -40, 0, 0, -50, 40, 50, 40, 50, -40],
- -visible => 0,
- -filled => 1,
- -fillcolor => "#ffffff:100 0 28|#66848c:100 80|#7192aa:100 100/270"
-# -fillcolor => 'cyl'
-);
-
-# $rect = $zinc->add('rectangle', $view, [200,230, 220,250],
-# -visible => 1,
-# -linewidth => 2,
-# -relief => 'sunken',
-# -filled => 1,
-# -linecolor => 'white',
-# -fillcolor => 'tan');
-$cv2 = $zinc->add('curve', $view, [],
- -visible => 1,
- -linewidth => 2,
- -linecolor => 'white',
- -fillcolor => 'tan',
- -fillrule => 'positive',
- -relief => 'sunken',
- -closed => 1,
- -filled => 1);
-$text = $zinc->add('text', $view,
- -visible => 1,
- -text => 'Un Texte ICI°°°°°',
- -position => [200, 100],
- -color => '#008000');
-$zinc->contour($cv2, 'add', 1, [[20, 20], [20, 100, 'c'], [120, 100], [120, 20]]);
-$zinc->contour($cv2, 'add', -1, [40, 40, 80, 40, 80, 80, 40, 80]);
-$zinc->contour($cv2, 'add', 1, [60, 50, 60, 60, 70, 60, 70, 50]);
-$zinc->contour($cv2, 'add', -1, [90, 70, 150, 70, 150, 150, 90, 150]);
-$zinc->contour($cv2, 'add', 1, [200, 200, 200, 220, 220, 220, 220, 200]);
-$zinc->contour($cv2, 'add', -1, [100, 10, 180, 10, 180, 60, 100, 60]);
-
-$zinc->contour($cv2, 'add', 1, $arc2);
-$zinc->contour($cv2, 'add', 1, $text);
-
-# $rect2 = $zinc->add('rectangle', $view, [40,81, 80,130],
-# -visible => 1,
-# -linewidth => 1,
-# -relief => 'sunken',
-# -filled => 1,
-# -linecolor => 'white',
-# -fillcolor => 'tan');
-
-new Controls($zinc);
-
-$zinc->Tk::bind('<a>', sub {print "hop\n", $zinc->contour($cv2, 'remove', 1);});
-$zinc->Tk::bind('<b>', sub {my ($x,$y,$c) = $zinc->coords($cv2, 0, 1);
- if ($c eq 'c') {
- $zinc->coords($cv2, 0, 1, [[20, 100]]);
- }
- else {
- $zinc->coords($cv2, 0, 1, [[20, 100, 'c']]);
- }});
-$zinc->Tk::bind('<1>', sub {
- my $ev = $zinc->XEvent();
- my $it = $zinc->find('closest', $ev->x, $ev->y);
- print "Closest: $it\n";
-# my @t = $zinc->vertexat($it, $ev->x, $ev->y);
-# print "VertexAt: ", join(', ', @t), "\n";
- $zinc->bind($cv2, '<1>', sub { print "zou\n";});
- $zinc->coords($cv2, 0, [[100,0]]);
- print $zinc->bind($cv2, '<1>'), "\n";
- });
-
-$zinc->focusFollowsMouse();
-
-MainLoop();
diff --git a/sandbox/testshape.tcl b/sandbox/testshape.tcl
deleted file mode 100644
index 2ed5327..0000000
--- a/sandbox/testshape.tcl
+++ /dev/null
@@ -1,18 +0,0 @@
-#!/usr/local/bin/wish -f
-
-load ../tkzinc3.2.so
-
-set top 1
-
-set r [zinc .r -render 0 -borderwidth 0 -fullreshape 0 -relief sunken]
-pack $r -expand t -fill both
-$r configure -width 500 -height 500
-
-set arc [.r add arc $top "50 50 200 150" -visible 1 -closed 0 -filled 0 -fillcolor white -extent 200 -pieslice 0]
-
-set cv [.r add curve $top "50 50 100 150 270 70 220 0 200 20 180 -100 140 40 70 -100" \
- -visible 0]
-
-.r rotate $arc [expr 3.14/10] 125 100
-
-.r itemconfigure $top -clip $cv
diff --git a/sandbox/testtext.tcl b/sandbox/testtext.tcl
deleted file mode 100644
index 44d3d8f..0000000
--- a/sandbox/testtext.tcl
+++ /dev/null
@@ -1,138 +0,0 @@
-lappend auto_path ..
-
-package require Tkzinc
-package require Img
-
-set mask "/usr/X11R6/include/X11/bitmaps/fvwm.xbm"
-
-set r [zinc .r -backcolor gray -relief sunken \
- -insertbackground red -insertwidth 10 -render 0]
-pack .r -expand t -fill both
-.r configure -width 800 -height 500
-# .r configure -drawbboxes t
-set top [.r add group 1]
-.r addtag controls withtag $top
-
-.r add rectangle $top "-50 0 +50 1" -composescale 0
-.r add rectangle $top "0 -50 1 +50" -composescale 0
-
-set x 50.0
-set y 100.0
-.r add text $top -text "Ancrage Sud Ouest" -position "$x $y" -anchor sw \
- -color yellow
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x [expr $x + 200.0]
-.r add text $top -text "Ancrage Sud" -position "$x $y" -anchor s -color pink
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x [expr $x + 200.0]
-.r add text $top -text "Ancrage Sud Est" -position "$x $y" -anchor se \
- -color violet -overstriked y
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x 50
-set y 150
-.r add text $top -text "Ancrage Ouest" -position "$x $y" -anchor w -color lightblue
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x [expr $x + 200.0]
-.r add text $top -text "Ancrage Central" -position "$x $y" -anchor center -color blue
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x [expr $x + 200.0]
-.r add text $top -text "Ancrage Est" -position "$x $y" -anchor e -color darkblue
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x 50.0
-set y 200.0
-.r add text $top -text "Ancrage Nord Ouest" -position "$x $y" -anchor nw \
- -color violet -underlined y
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x [expr $x + 200.0]
-.r add text $top -text "Ancrage Nord" -position "$x $y" -anchor n -color pink
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x [expr $x + 200.0]
-.r add text $top -text "Ancrage Nord Est" -position "$x $y" -anchor ne -color yellow
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x 150
-set y 300
-.r add text $top -text "Ce texte tient sur plusieurs lignes.\nLes alignements :\n- à gauche\n- à droite\n- au centre\nsont également mis en évidence.\n" -position "$x $y" -anchor center
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x 400
-set y 300
-set anim [.r add text $top -text "Ce texte tient sur plusieurs lignes.\nLes alignements :\n- à gauche\n- à droite\n- au centre\nsont également mis en évidence.\nLe texte central montre l'utilisation\nd'un espacement des lignes programmable." -position "$x $y" -anchor center -alignment center -spacing -5 -font {times 14 bold italic}]
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-set x 650
-set y 300
-.r add text $top -text "Ce texte tient sur plusieurs lignes.\nLes alignements :\n- à gauche\n- à droite\n- au centre\nsont également mis en évidence.\n" -position "$x $y" -anchor center -alignment right
-.r add rectangle $top [list [expr $x - 3.0] [expr $y - 3.0] \
- [expr $x + 3.0] [expr $y + 3.0]] -filled 1 -fillcolor red
-
-
-.r addtag text withtype text
-.r bind text "<1>" {textB1press %x %y}
-.r bind text "<B1-Motion>" {textB1move %x %y}
-.r bind text "<Shift-B1-Motion>" {textB1move %x %y}
-.r bind text "<Shift-1>" {.r select adjust current @%x,%y}
-.r bind text "<KeyPress>" {.r insert [.r focus] insert %A}
-.r bind text "<Shift-KeyPress>" {.r insert [.r focus] insert %A}
-.r bind text "<Return>" {.r insert [.r focus] insert \n}
-.r bind text "<Control-h>" textBs
-.r bind text "<BackSpace>" textBs
-.r bind text "<Delete>" textBs
-.r bind text "<Control-d>" {.r dchars text sel.first sel.last}
-.r bind text "<Control-v>" {.r insert [.r focus] insert [selection get]}
-
-proc textB1press {x y} {
- .r cursor current "@$x,$y"
- .r focus current
- focus .r
- .r select from current "@$x,$y"
-}
-
-proc textB1move {x y} {
- .r select to current "@$x,$y"
-}
-
-proc textBs { } {
- set item [.r focus]
- set i [expr [.r index $item insert] - 1]
- if { $i >= 0 } {
- .r dchars $item $i
- }
-}
-
-#
-# Add controls to the main group
-#
-source controls.tcl
-
-#
-# Line spacing animation (crude).
-#
-if {0} {
- set i 0
- while {1} {
- update
- after 200
- .r itemconfigure $anim -spacing [expr ($i % 20) - 5]
- incr i
- }
-}
diff --git a/sandbox/testwind.tcl b/sandbox/testwind.tcl
deleted file mode 100644
index 5ff7f76..0000000
--- a/sandbox/testwind.tcl
+++ /dev/null
@@ -1,19 +0,0 @@
-#!/usr/local/bin/wish -f
-
-load ../tkzinc3.2.so
-
-set top 1
-
-set r [zinc .r -backcolor gray -relief sunken]
-pack .r -expand t -fill both
-.r configure -width 800 -height 500
-
-.r addtag controls withtag $top
-
-set ent [entry .r.entry]
-set wind [.r add window $top -window $ent -position "100 100"]
-
-set container [frame .r.cont -container t]
-set id [winfo id $container]
-puts "container id is $id\n"
-set cont [.r add window $top -window $container -position "200 200"]
diff --git a/sandbox/testzinc.pl b/sandbox/testzinc.pl
deleted file mode 100644
index f25f9de..0000000
--- a/sandbox/testzinc.pl
+++ /dev/null
@@ -1,503 +0,0 @@
-#!/usr/bin/perl -w
-
-
-use Tk;
-use Tk::Zinc;
-use Tk::Photo;
-use Tk::ZincText;
-#use ZincText;
-use Controls;
-
-$map_path = "/usr/share/toccata/maps";
-
-$mw = MainWindow->new();
-$logo = $mw->Photo(-file => "logo.gif");
-
-
-###################################################
-# creation zinc
-###################################################
-$top = 1;
-$scale = 1.0;
-$center_x = 0.0;
-$center_y = 0.0;
-$zinc_width = 800;
-$zinc_height = 500;
-$delay = 2000;
-$rate = 0.3;
-%tracks = ();
-
-$zinc = $mw->Zinc(-render => 2, -backcolor => 'gray65', -relief => 'sunken');
-$zinc->pack(-expand => 1, -fill => 'both');
-$zinc->configure(-width => $zinc_width, -height => $zinc_height);
-#$radar = $top;
-$radar = $zinc->add('group', $radar, -tags => ['controls', 'radar']);
-$zinc->configure(-overlapmanager => $radar);
-
-new ZincText($zinc);
-###################################################
-# Création fonctions de contrôle à la souris
-###################################################
-new Controls($zinc);
-
-###################################################
-# creation panneau controle
-###################################################
-$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 => 'Quit',
- -command => \&exit)->grid(-row => 3,
- -column => 2);
-
-
-###################################################
-# 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.
-###################################################
-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);
- $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;
-# $track->{'vx'} = 10;
- $d = (rand() > 0.5) ? 1 : -1;
- $track->{'vy'} = (8.0 + rand(10.0)) * $d;
-# $track->{'vy'} = -10;
- $zinc->itemconfigure($item,
- -lastasfirst => 1,
- -symbolcolor => 'red',
- -position => [$track->{'x'}, $track->{'y'}],
- -speedvector => [$track->{'vx'}, $track->{'vy'}],
- -speedvectorsensitive => 1,
- -speedvectorwidth => 2,
- -speedvectormark => 1,
- -speedvectorticks => 1,
- -labeldistance => 30,
- -markersize => 20,
- -historycolor => 'gray30',
- -filledhistory => 0,
- -circlehistory => 1,
- -labelformat => "x71x50+0+0 a0a0^0^0 a0a0^0>1 a0a0>2>1 a0a0>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 => "AFR001");
- $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 { #print_current($zinc);
- $zinc->itemconfigure('current', $zinc->currentpart(),
- -border => 'contour')};
- my $b_off = sub { #print_current($zinc);
- $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 { #print_current($zinc);
- $zinc->itemconfigure('current',
- -historycolor => 'red',
- -symbolcolor => 'red',
- -markercolor => 'red',
- -leaderwidth => 2,
- -leadercolor => 'red',
- -speedvectorwidth => 2,
- -speedvectorcolor => 'red')});
- $zinc->bind($item, '<Leave>',
- sub { #print_current($zinc);
- $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();
-
-sub print_current {
- my ($zinc) = @_;
- my $current;
-
- $current = $zinc->find('withtag', 'current');
- print join(' ', $current), "\n";
-# print ref($zinc->itemcget($current, -position)) ? 'ref' : 'pas ref', "\n";
-# print 'tout ';
-# for $attr ($zinc->itemconfigure($current)) {
-# print (join(',', @$attr));
-# }
-# print "\n\n";
-# print '-position ', join(',', $zinc->itemconfigure($current, -position)), "\n\n";
-}
-
-###################################################
-# 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;
- }
- }
-}
-
-sub stick_wp {
- my ($zinc) = @_;
- my $ev = $zinc->XEvent();
-
- if ($just_wiped) {
- $just_wiped = 0;
- return;
- }
- my ($x, $y) = $zinc->transform('radar', [$ev->x, $ev->y]);
- my $wp = $zinc->add('waypoint', 'radar', 2,
- -position => [$x, $y],
- -connectioncolor => 'red',
- -symbolcolor => 'red',
- -labelformat => 'a2a2+0+0',
- -tags => ['text']);
- $zinc->itemconfigure($wp, 0,
- -text => "$x".'@'."$y",
- -color => 'red',
- -filled => 1,
- -backcolor => 'gray55');
- $zinc->bind($wp.':position', '<1>', [\&wipe_wp]);
-}
-
-sub wipe_wp {
- my ($zinc) = @_;
- $zinc->remove('current');
- $just_wiped = 1;
-}
-
-$zinc->Tk::bind('<2>', [\&stick_wp]);
-
-
-###################################################
-# creation macro
-###################################################
-#$macro = $zinc->add("tabular", $radar, 10,
-# -labelformat => "x40x20+0+0 x40x20+40+0"
-# );
-#$zinc->itemconfigure($macro, 0 , -text => "une");
-#$zinc->itemconfigure($macro, 1, -text => "macro");
-#$zinc->itemconfigure($macro, -connecteditem => $track);
-#$zinc->bind($macro.":0", "<Enter>", [ \&borders, "on"]);
-#$zinc->bind($macro.":0", "<Leave>", [ \&borders, "off"]);
-
-###################################################
-# creation ministrip
-###################################################
-$ministrip = $zinc->add("tabular", $radar, 10,
- -labelformat => "x80x20+0+0",
- -position => [100, 10]);
-$zinc->itemconfigure($ministrip, 0 , -text => 'ministrip');
-$zinc->bind($ministrip.':0', '<Enter>',
- sub {$zinc->itemconfigure('current', 0, -border => 'contour')});
-$zinc->bind($ministrip.':0', '<Leave>',
- sub {$zinc->itemconfigure('current', 0, -border => '')});
-
-###################################################
-# creation map
-###################################################
-$mw->videomap("load", "$map_path/videomap_paris-w_90_2", 0, "paris-w");
-$mw->videomap("load", "$map_path/videomap_orly", 17, "orly");
-$mw->videomap("load", "$map_path/hegias_parouest_TE.vid", 0, "paris-ouest");
-
-$map = $zinc->add("map", $radar,
- -color => 'gray80');
-$zinc->itemconfigure($map,
- -mapinfo => 'orly');
-
-$map2 = $zinc->add("map", $radar,
- -color => 'gray60',
- -filled => 1,
- -priority => 0,
- -fillpattern => AlphaStipple6);
-$zinc->itemconfigure($map2,
- -mapinfo => 'paris-ouest');
-
-$map3 = $zinc->add("map", $radar,
- -color => 'gray50');
-$zinc->itemconfigure($map3,
- -mapinfo => "paris-w");
-
-
-###################################################
-# Map info
-###################################################
-#$mw->mapinfo('mpessai', 'create');
-#$mw->mapinfo('mpessai', 'add', 'text', 'normal', 'simple', 0, 200, "Et voilà");
-#$mw->mapinfo('mpessai', 'add', 'line', 'simple', 0, 0, 0, 0, 200);
-#$mw->mapinfo('mpessai', 'add', 'line', 'simple', 5, -100, 100, 0, 0);
-#$zinc->itemconfigure($map3, -mapinfo => 'mpessai');
-
-#$c1= $zinc->add('curve', $radar, [],
-# -filled => 1,
-# -linewidth => 1,
-# -fillcolor => 'blue');
-#$zinc->coords($c1, [200, 200, 300, 200, 300, 300, 200, 300]);
-#$zinc->bind($c1, '<1>', sub {$zinc->coords($c1, 'remove', 0);});
-#$zinc->bind($c1, '<2>', sub {$zinc->coords($c1, 'add', 0, [0, 0]);});
-#$zinc->bind($c1, '<3>', sub {$zinc->coords($c1, []);});
-#my $c = $zinc->add('curve', $radar, [],
-# -filled => 1,
-# -fillcolor => 'red');
-#$zinc->contour($c, 'union', [100, 0, 0, 0, 0, 100, 100, 100]);
-#$zinc->contour($c, 'diff', [75, 75, 25, 75, 25, 25, 75, 25]);
-#print join(' ', $zinc->coords($c, 0)), "\n";
-#print join(' ', $zinc->coords($c, 1)), "\n";
-
-
-###################################################
-# Rafraichissement des pistes
-###################################################
-$zinc->repeat($delay, [\&refresh, $zinc]);
-
-sub refresh {
- my ($zinc) = @_;
- my $t;
-
- foreach $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 $part = $zinc->currentpart;
- my $contour = "noborder";
- $contour = "contour" if ($onoff eq 'on');
- $zinc->itemconfigure('current', $part, -border => $contour) if ($part >= 0);
-}
-
-sub finditems {
- my($cornerx, $cornery) = @_;
-
- print "--- enclosed --->",
- join('|', $zinc->find('enclosed',$origx, $origy, $cornerx, $cornery)),"\n";
- print "--- overlapping --->",
- join('|',$zinc->find('overlapping',$origx, $origy, $cornerx, $cornery)),"\n\n";
-}
-
-
-MainLoop();
-
-
-1;
diff --git a/sandbox/textexpand.tcl b/sandbox/textexpand.tcl
deleted file mode 100644
index f690281..0000000
--- a/sandbox/textexpand.tcl
+++ /dev/null
@@ -1,6 +0,0 @@
-zinc .z
-pack .z
-
-proc createItem {type params} {
- if 1 [concat .z add $type 1 $params]
-}
diff --git a/sandbox/texture-bois1.xpm b/sandbox/texture-bois1.xpm
deleted file mode 100644
index a7a6e5f..0000000
--- a/sandbox/texture-bois1.xpm
+++ /dev/null
@@ -1,320 +0,0 @@
-/* XPM */
-static char *on[] = {
-/* width height num_colors chars_per_pixel */
-" 256 256 57 1",
-/* colors */
-". c #f8dca8",
-"# c #f8d4a8",
-"a c #f8d4a0",
-"b c #f8d498",
-"c c #f8cca8",
-"d c #f8cca0",
-"e c #f8cc98",
-"f c #f8cc90",
-"g c #f8c4a0",
-"h c #f8c498",
-"i c #f8c490",
-"j c #f8c488",
-"k c #f8bc98",
-"l c #f8bc90",
-"m c #f8bc88",
-"n c #f8bc80",
-"o c #f8b490",
-"p c #f8b488",
-"q c #f8b480",
-"r c #f8b478",
-"s c #f8ac88",
-"t c #f8ac80",
-"u c #f8ac78",
-"v c #f8ac70",
-"w c #f8a478",
-"x c #f8a470",
-"y c #f8b488",
-"z c #f8b480",
-"A c #f8b478",
-"B c #f8ac88",
-"C c #f8ac80",
-"D c #f8ac78",
-"E c #f8ac70",
-"F c #f8ac68",
-"G c #f8a480",
-"H c #f8a478",
-"I c #f8a470",
-"J c #f8a468",
-"K c #f8ac80",
-"L c #f8ac78",
-"M c #f8ac70",
-"N c #f8a478",
-"O c #f8a470",
-"P c #f8a468",
-"Q c #f89c70",
-"R c #f89c68",
-"S c #f8ac78",
-"T c #f8a478",
-"U c #f8a470",
-"V c #f8a468",
-"W c #f89c70",
-"X c #f89c68",
-"Y c #f0a470",
-"Z c #f0a468",
-"0 c #f09c68",
-"1 c #f09068",
-"2 c #e09068",
-/* pixels */
-"hhehliieid#hqDqliifiiiiiihllhhkllyykhkhdhlpplhggeeehhilmmmllmpppqDDzqmihhhhhhilmODpmqDphhhihhmpqklllpCqlgllllppkhlqDqlhilqtqlhlqplkhltzplmpppmpmqmmmqmmmmquummqqnqqmquEuumlqtppplmqqqpmmpOqmOthuqqqpmmmmqmmmmmiieeefeeefiiimnqnmnqqEIuqquqihhlmlmmmmmmqqlilihilm",
-"illmmmllhhilmmpmiimmqqqpllmppppClopplpppklpplkhhlliiillmopptqCCCmmpmmliiliiihilmlllltLDqqtqplmpmqtohhlollpplopplpmlmlllplmpmmpmqCpllpppmpppmllllmlihiihhhiiiheeiiijmmquuutpqlhghmllilllliqlhmldmqpqmqqqqmmmljmiiifeiiiimebaeeeeeiiimqqmmmmlhlmpmlllllllilililill",
-"llmmlmlllpqqplmmmmmnqmmmlllpppyCCtzLNNKUCCKKLCCCDqqqtDqtqzDLCtzCDDAtztDDDDtqqqqqqqCqzCCqCDCqqpqpzCCqpCqpCCtqqppqqpppqqqppmpqtCCCNppCDpptqtqqppmqmmlilllimihhhhhheehimmmqllmppllptqlllmpqmqllpmlpiilmmmmmeeddeeeeieeeeeijiiiifiiilimqqqqqpqpmmpmmlmmmmqqqlmmpmmmm",
-"mqttqppqDqqCDuqpqrruqqmmCCDLNLNTUNKLNLNKCCKNUUUTDDDDLLCzqCCCzpppqqpmpqqpqqzqqmpqppqpqqzCppqqpppplpqCCDCCqmpCqpqCtqqqCqpmqppqCDDzCppCCztLCzttqqpqmmmmqqqqpmmmmmmilhlmmllqqmmqpmlmililmppmplmmlmpmmmmmqqmiliiiimmmjiiiiiijiiiiiijjmlmnqqqtmmpmllhhlmmpqpmmmmppmmlm",
-"DHMMDqDDDqqDDLCnEEIEDDDDIMNUUNNTLNLsyCClolppCCypmmmpqqpmlmmllmppliililiilmqqqmmmmlihkhlimmppllhilhggilpllklpplltmmllllmmllmmpmppppmmpqqtpqqmmlihllmqqmqnmmpmpmpmqpqutmmquqqqqqmllllpqqmmpmqtpqqpppmqqmlhiiehiiiimjjmjiijimnnnmmmmmqtuqqqquuqpqqqqqtqqqpmtqtqqtuu",
-"DDLDtqqqmppqqqqquDEDrqqqpppCCzqCpCClmCCpmompyBplmmmmmmmllllllllpmllmmpmmlmmppmmmCplihhdglllmlhhhhhhhppmlhhhlkhhlhlllhiklhhlkillmpppllmpmilppmmmmmqqqqqqqqquuuquuqDOODuuDqqqqDEDruDuDtuuttqtDtuDqEOOOVPDqqqqqqqrqrurvvuuvuuvuvvuuuuvJIuuuDOOuqqtqqqqtqqqqquqqqqDD",
-"pqqpmllmlmmmmlmpmqqqmliimmqCCCCCpCzppzCCtqtzCtztpqqqqppqppllppplmlilmmmmlllliililllmpmpqhilmlihlhllqDCplhhliihlllmmmilihhhhihlmpppllmllllmnqqqtutquuqqquqtquququpCNDqqqCrqqqrrrqqqtqpmpqmpmmmmlmlmqtqqmmmmmmnqqqjiimmjjmqnqqqqqnqqquqqqqpqqpmllhihiilllmhihhhimm",
-"qqqqpmmmplillmmlmmquqqqqppqzCtqCzppqpppCllllppqCmqqqmmmpmlmpDNKtmliilmmlDrqmmlmpllmpmlillllplhhihhllllihimllhlmpDtmhdgiliihhillmpihmpihipmppmmmmmmmllimmmliiiililqDqmlpmimmmmmnnlpqqplllllihllhlmqtruqqmpnmqqqrqrqqqqnqqmiiimnmmqqqqqmmpmpqqqqqmppmmlillillmlmpq",
-"mmpmllmpliillmmlmpqpqqqpmlmpqqtqpqCppmllllpppDKCmqCDzqlhlmppqqCzpmppmmllipqCqpmqptqppllpplillllmkihhhhllmptqplllmihlmqqDpmiilmqqlililmlilmmjlmmqmpmmmmmmmmlillmmtptqqpmmmmmmnnnmmpqqqqqqppplllmpqpmpnpmmmmleimmimjmjmmiiijmjmnqmmmmpmpqqtqppqtqpmmlpmlmqqmmlmpqp",
-"pqqqmpqqppmmmlllqDqqmppmmmpqtDCDmomlllkillllmppmtqmlllmlllllpppsqqqtqqpmpmqqqppqmqpmmlilmppllppllllhilillpppllhlppquDDDDDplhhilmpmlhhhilimqqqmmlmmmmmlllpmmmmpqqpllllllmpmiimmqqllmpqpqpllmmppppqqqqqqmmmpmehmmmiiiiiiiimmmlmqnmmmmmmmmmppmllllltquqqmpqmmmqquDu",
-"mpmppmppqqtqppmpmmlhhillhlmmqpqqtqqqppppqtqpqztpmmqDDqplDCtCpqypqqqqqqpqzqqqzqqqCDqptpmmpDDpmqpiqmmmllmppmmmmlmlmilqqpmmiihehlmmqqmmmmnqqqnnnmnqtqutuqqqqqqqqqqqtqtttqqtqqpmmmmntqttqtqqqqqtqqqqqqpmmmliqqnlimnmmiliiiljqmmjmnmmpqqqpmlmllmppqqtmpmpmpmmqqpmpmli",
-"pmpqqqqpmmpqmmmmCzqqqqtDtuDDCuDDDCCtCzDzCCDCCDDtLDqzDDLMNOLLLCCCLDLDDDDDDzqzDDDDLLCtLDqqpCCqpqqpDtqpmmqqqqmppqqmqqmqqnppDDuDuqqqpmqqqqqnqnmmmmqumqnqqqqnpmpmpmpmllmmqpmlmmmmmpmmmpmmpmllmppmpmllmlmmmmqpmnpiiilimmjiilmmqnmimmmimmmmllllmmppmlllipqmquuqlmmmqqqq",
-"tqtDDLDtMHMOUXOOOOMLLDDDDMHDuDOOpqpqqtqpmqpmpppmDqqqqqptmmptCCCzqqqqzzDDzqmqCzqpqtmpCzppmmmpqqCDzqmmmpmmqppqqqqmtqtDqqqqpmmmllilnpnqqqmimmqqnqnnmmlmmpnpqqnqmqmqqqqqqqpmhhhlpqttolmopqtqtpqppqttqtqqquuEquuuqqqqmmmmmmmqrqmmmmmmhilmlilippptuwtpqrtqqDDquutuDDOO",
-"qqmqqtqqmllmpqmmlmpzqmmlllmilmpqqqqzCCqplmplllllmmpzqlhdkllllllkhhhhilmmmlilmmiimplhmpllphhllhhlmliillllmmmlmmmmllmqpmilqmlllmqtliimmmmjmnnnmmmmmpnqqqtrqtqtuuuupmmllpqppppqtuwIIHuuHIIHIIHuuuuHDuuqqrDIvEIFJIJJuvuuuruuxvuvvuqqmqquuuuwqqtIOXOEDIMDOOOODDDqqqqq",
-"liliililhihiilllilmqqmllihhillmmtqpqttqplmpmlmppDmiihhhmmpllhhggiihilmqtlhhhihhhmlihlihllhhhhddchedhimmlmllillmliimmmiheqmjhedeeiimmjiimmmiiffijliihiimpmmpmqqquvuuruvxuIxuttwttutqpqpqpttqppmpmqnpmmmmmmmmmqnmnquvvurqruuvxxrqruuvuxuIIwutqqllhhehlmliihiiiilmm",
-"ihihhhhihhlililmppqCCmiilillmmlllkhhhlhhhllllppqmihlmilmCqlhhhghhehhimqqmihhhhilpmlhhhhheddhlpleedeimqqqmmliiimmiiiiedeheiliihehimqqidaaaeeiieeeihhdehiiddddeimmmnqquvtptqtttpoohhdgllmlihllllklhhiihehhmihehiiiiimmiieemmqrqmimqqqmllllmpplllllmlmqqlhelmmliheh",
-"qqqtDuqqpmqqqtMUqqmqqqqtDuDMIDuDODqtqmptDqqtDqqqpqCDDpmppDOOCmlllllqpklppmlhhhgddhhipidlllhimle#ddddghd#hdddddgheheemjeimiimieeeehiimmiiiiieeimmiieeeiedeeeeeeehiiinqnmiimmqmliimqqrqmmqihimmmiillllqmmqmmmmmheedeiiiililmmmiilljnnqnjjnmnnmmlnqtqplimmlqmmppmmm",
-"qqqqmlmmqmqqlhmpqqmpqmpnlllmlliihhhmpqpmLCqCzqpqlllmmmptmpqpmpqDpmpDDqpqpppqmpmpmzqmppmlmmmmmmlhllllllhhhihhhdddiieimieeadeimilihehilqquqmmihiimmmiilmmimifeeheeeefjmnmnmqpnpnpqmmqqqmmpuqtuuqqqmpmqDqpqqqqqqmmmmppqqtutqppmllilnmmnmnnrqqqrqruuqqrqquEIqqqqqqpq",
-"qDDDpllpmmqqilquqpmlllllqmlmmllmlllpCLqllllmplpqDphlptqplllihllmmllqCqmhilmmmlllqCLqmDLpqqtppmpqtqqqpqqtppqqpmllmmlmpmhhhilptqpmDuqqmqqqOJEuuruuqruuruuuqqmmmmmmmmpmmmpquuqtqtuuutqtuuqqqqttqppqmpqtDqmmpmmqqmmmpmmmpqqqqqqquqtqvrqrruvEuuruuqqqqDuqmllmuqmmmmqq",
-"imtqmlilhhlmllqqCqpmmmmpqmllmmmmtqplpqmhllllmmpptpmlllihqpmppmpmpllqCqlhlllmppmledhhdlphdhhhdddhilhhhlpDqtDCztDLqqpmuqlmqppqqqikiillliilmmliihiiimmjlimjrqqqqrrururqqqnqqqqttuqpqpmmppllllmqpmmplqqqDqllihlmmmmmqpmilmpmqqpqquuqqmjmmmqqrqqqqqmilmmmlillqqpmpmqu",
-"CDNONDDCUNNHCDLCLDCqCCDDLCzCDKLNOULCDUUDNDqtCDCqmqDCplmpmlhdhhlpppqqpmllqmllqqqpphmplmqmllmpmlllhhlllhlphhhdddipllilqmlllihlllhgilmmmlmlihiihfhilmmmiiilimqqqmpqmpmmmqpmpmmpqppppllpmlllpmppttqtqCtyCtmplllmpmppmmmhhilmmmlmmmmlqnqqqqqqlmqtqqtqpppqtDHtmptOHDtq",
-"CtpppCtqCppmptCpLKCzCLLLCmlppqpppppqqDCqCqpmCOLCONLDDDCtDDCDCDDCmqtqpmppCpllmpllldhlllmplllmpmihlmqDqlhlqqmlhhlpllhlplillkhhlhkliliihehhiiliieieieilihhiimmqmmmmmmmlpqqlqpmmpttDtttCttDIDtpqtuDHCLCqCCqqqppqqpmpmmplilmmpmmmppmmimmqmmmqpqtuttuuCuttDDqpqtqCCtDO",
-"CppqCCCCllllpKONzCzpyCKCKypzKCypLqptKDqpllhhmzCpODpmqCqipqCDDqmlqCDDCtqDODtqqppppqmlqtttpqttttppllpqpihhmllhhhhhpplkppkopmopopopmmmpquDDqqqnpmmmqqqruqqtqqqnqnqqpqqmmtqpqtttqtCHqppqtptCtppppsqttCCpCCppqpppppmpquuqqruuqqqqqquutqquHDtuDCttqtppllllppplCqpmlmCN",
-"lpsCLCCslkkkkpCCyCCyzKCypplpyplhOpilqqpmpmlllpmllCUDpmpCllllihhlhlmpmmpmpqCqpqDDDXtlpCqqmptqpmlltpmqqmpDppppqqppLCplpplppoppppptDCtquqqntrtqqqqqnmmqqqnqvqqqtuuqpqtqpuDuptCttppptpppollpklpttppplCppptppppmppompuqqqqqqmqqqqpmmmqppqtqpmttmppqpplppolllllpptpppp",
-"DCKNNUULNDDNNNCzNYULNYUKCKKCKLKCLLDNUOzzppqqqpqqCzqpmppphllhhhllhhipplllqNqhlmlllmlpqtqphlmpqpmlhhhhltCzqzqtzqpmCCptppptppptsttpppqpmpqtmmmpqqqqimplilmmqpmqqqmiipqmmqqqmptqppptpllpmllmlppppCDtptCCCCCDpllmpmllmmmquuqliqnpmlmummqtqpqCqqpptpkllqCqptCpNHLNLNOU",
-"CqCLCCCsppompCLNKNSKLTTKUUTSUYYTLNDOYUNOCDLDLLOUOOLNNLOOzCCqtCqpqppqqpppmqmhlhdhlllhhlhghhllllhhllllhlllCtzqqpmlpmolplolspstpptompnppmqqqpmmmllilmmmilmmiihilmlhimmmpqtpmpppppppmpptCCCHtDNDDONDYWNCCLNONtpppppplilimliiilmilehnlilqqmmqlCDpCNNHNUNCCCOOCCCtCtpq",
-"olpsmpplCpolmpCLpppppqpmppllpDzpqqppDCqCzCCppmpCCqqztqqCpqpqzCqmOODLDDDLDNCDDtqDtqqppqqmtqCqtqqpqzqplillllllpmpmppppppppplpppppoDCDDztCDqqqqqqpmmpqpmmlmppmpqqqpmmmmpDqqqqqDOUOLNOOLDtplpqCqpqqmlllpptqqqmllllpqqtqqqqqtuDuuuutDDtDELDtDCWVCqCqpLtmlhhhlllmmpmll",
-"ppCLtCCtppppopppOLCDKzzLLCCCLTNCqzqzDzpqCqqpppqzCppDCmlqmpqCDONCqppppmppqpllllmtqztqqCtqpqqCCCCDqCDzqqpmqqqCDDDCCCCCCCzpLCCNCGHCqqqpqpqqqqqqqurqtutqqttuqquuuqpqntDruDLDDqqqzqpmillllllhmqqqptqppppqCCpkmpqqtqquqmqqqqqqqqmmqmmqDqpqCqqqlmlmlhglihlqzqDOCDCDDDCq",
-"ihmmihlilmmmpmpqpmlpmllpmqqpmqqqptqCLCpqpmmpCDNDDqqNDppCpqDCDLLOCCzCDDDDLNDmlqCpppqmlmllhlmqqqqzppppqCzqCCCqCzqqpppppmppllllllmlpppmpmpmpmmpqmppmmlllmpqmpmllilimnqqmmnqqqmmpqqqpqtqqMODqtztqDCqCqmmpmmmhmmpmiihiiiimmliiihimlimmiiimmpnqCtDONtLDDDDCmlmmmmmllil",
-"DtCtpmplmmmmmqqqmmmqpmmqmqqqpppqilmpqpimlllmpppmpmpqqmpqmpqmlllllmmppqCqqqCphpqhmpqppmpmlmpzzpqplmlmpqtmpmmpmpompmpmppppzpptptCppqqqqqqqqqqmqqpmlihiiimppmlhhimpinqniiimmmqqqDLOqqnmllmlmpmmmmmmlhllmppmqqtnpmpmmmmpqnmlnpmmqqmqrpjlmnpqpDCmpqmhihilmmqqmmmmmqqq",
-"qmnqmmqmqqpppmpmlllmliillmppmmmlmppqCplpmppppmmmlpqqpppqpqpmllllppqpqCDCpmqplqCmhlmmmmmlilpppmmmmmpmmpppmpppqqCCmqppmppqplmplmpmlhlllmllmmmmpmqpqpmpqppqqpmllpqunqrrqnqrqqqqmmmjqmmmmmmqqnmmmmmmqDDMDqqmmmmiiimimmmmmlmlhieimmhiqnmjimiihqqlmqqpDrqqmqqqhhiimmmn",
-"lhlmmqDqmllmnpmlquuqmmmlilmmqqpmppmmmlhmkmqqmptDlpplllmmllllpqplmqqmpqCqOppqllqqmmzppllilmmqmmmpmpppllmmlmllmlmmmmllmlmmmllmllmlllllppmllhihihhehdhiihehihhiilllffijifiifiimmmmlqmqqqmmnmmliilmmilillmqqqqqmiiieehiheeijlmlmqmiliiiimmmmlmlilhiqimmiimjhmmmqmmml",
-"qmlilmptlpCtpollkllloohkloplkklpqmmqqmmmmmmmlmqzlmqDVtlimmmtEDqmmppqqqqCqpmpqqpplmqzDqmlhlpppoopppmllpolkkllkllplliillmllmllillmlillmmpmmqqmiiiimiiiliiinnmmnqqrilmmmmmnuqnmmmmimiijmmlillmpppppllplilmqutmmmmiilimillmmlihllmlimmmmmquummmllhilillillllnppllllm",
-"qtppptDCCLOLtCCCDNCpCCCCCCCDCDNNMEOOPMDEnqqqnpmmqCqmqnpDDtpmpmmlqqCCtCCDzqpmmpqCmmmpmpmpllppppopzqmllllklllllllmlllilmmmmpqqqmihiiilmmmmqqqmmmiiifhijmjmlmiiiiiiimmnmmmmqqqmmmmmmmmmjmlimmppmlllmpqllilmqqqmqqmiiiiiiihillmlllllmqnmimmmmllillllllilmqqmpmpmpqqu",
-"NMDDLDLDLOUNLCDNCDCtDCtCCtCCNNNLDDDMLDDDDDDDODqqtDDDDtqNMDtqqtCttCDDCDLNDDDtpqDLtqqqqqsqpqCLCCCCzLCzpCypklkhhhiliihhilllmmmmmlmmllpmmmmmmmmllmmiiiiiiiiimmmmmmmmmimmmmmlnmmmmmmmjjmmmmpqqtqttttpqtutqqqpnqquvurqqqqqqqqmmmpppmppruqmmlllqmlllllimmmmpzqqDEDDuDHO",
-"nppqqqpppCDCtpplppppCtmppppptqqpqqqtqqqqCqnppqqpmqDDLzpqpqDDDMMDDLLNLLOVqCCCCtztACqCqzqpCCCLCKLLLLLDKLLKCCCtqqqqppmmmpmpmmllllmplmmpmpmpqmmmmmihmmijmlimmjmmmmmmiiimqqmmmmmmqqnqnqqqnquEutuuutttpqutqqqqqqmmqqrqrrqrquuuqtutqttuqqrqqqnpmmmpquDDDDtqDMICqCtqpmpq",
-"pmqnqqtztLONLNCCtDCDOLCCCDLDCCCtLLNLDCDLqtpmllpqpqplttpplpqsqCplmpqqpqCCpmmpqqplqmlmqqmimmppppppqzzzyCKCCCCCCzqpmmmmpmmmqqquqmlihlmmpqquvuqqqqmimmmqqquvqqqmmmmmmmmqqqqnqqqruuurDEIEqqqutuqtqqplmpqmpmqpmmilimmmmmmmmmnqqqmppqqpnqqrtrtutuDutuDODzqpzDCmpmppqqqu",
-"OODDDDDCMOTLHNONLLCpCDCDNNNONLNNMOOLDLNOOUOODCzDLNCtLNLHDNCzsCCpmppqppqqDpmlqqqpqmlimpmmlpppppppqzzppppollpmppliiilimmmmqqqqqmmmmmpqqqqqqqqruurqqqqqqqruvvurqruurtrruruquuuuuuruuEEuqmqrtqpqttqptuutqqpmmqqmnmnmqqqmmmqqqpmmpqppuuuDuqqqtDDupmqtqqmmqqqpquDDuDHO",
-"DqqqqmmlpqppmpppqtpmqpqCCDCCDDDDpCCCCCCCCDLCCqppCNNLUUNLNNCCCNOCDLOOEDDDDqppqCtqzqqqqqCqpqqACzqqzDLzppzyCptpqqqmppmqqtqqmmmmmmqqqqqpqmmmmimqruqrrqqnmmmnqnnpnqqqurtrqqquqrqqrrqnqqqqqqtuqtqtuDuuuwDutqqmmmqqqqqqrruuqqquuuttuuuuEEEuqqmqlmpqqqDILLDDDNDDtqqppmpm",
-"lmmpqqttmpqqtCtpqzqpCCqzDqmpzCzplpCDCCDCCtpppqpplCpopppCppplpCClpqqqplilllmmmmllmpzDzqqqmmqCqqppzLLzzCCCCCppqqmpmmmmmmmmlmqqpmmmlliimmmlpmmqqmmmqnnmmimqmmmmmmjjmpnqmmnqqqqqtuqqDDEEDuuDHuqqtqpmlpqqqqmlhihiiiimelnnlimmlmmlillpmmmqqqqDIODDqtqqDDCqmqqmpqppmlll",
-"mmmmqtqmmpqpppuOptLUVLqqpCtmpCtmppCNODppqppqCCqpsqtpCCNNoppppCCpqpqCDqtCqpqpmlheelmllmmilliihihimmlillllkhllpmllmmmmmmpqmmimmqqmmqplipqmmlmmmimqqmlqqqmqqquuuuuutuuuqtqtuEOOEuqqqmpqqqlhmmmpqqqqlmllmlmmmmmmmmmimqrqmmmmmmlllllmmmmmqquuqutqqmlmlqqpllmlmmpqttql",
-"mmpqqqtuttqqmpptmlppqpppCDLtqLODNDLLKtppCCCCDCCCCCLNCCCpqCpppppoqmpqqqqqmmllliihhimmqpmmlmlihhhilmmmpplhghkllliiiilmiljlqmmmiiiihililiiliimqqmmnlhilmilmllimmmmlmmqqmmpnmqqqqqqqqqpmpmqqpmmmqqqqppmppquuuuurqqnmimnmmqqmpqtqqqqtqqqnmmmmmmppqttuCqpnDDtmppmqqqml",
-"mqruuuDOOECqppqtDqqtqCDOELOLDDMUUUOONDDLqCDCCCqCNKtqCCDLNONDDNCqqmmmllmplliiihhhilpqDqmlimmmiiimilmmmplhhhikiiiilmmmmmminqqmliimlhlmmllmilmqqnmmilmmmllmmllmpqmlilllmlllilillmpqquuqpqDOutqpqpqqlmlmmqqumqqqnqqqqqqqqqqqqqtuttqqmnmmmllllmmmmqtDDqmtHMtpqqquuttt",
-"qqtuqqDDutqtqqqtqpqqqqqzLDDODqCDCtqCqqCNOUUVUOUVUDqtCLNNCqBqCtCtqqpmmmpnDLIDtqmmmmqDLqmmmmmliiimimmmomplkklillilmmmmqqnqmpmqnqqrtqppmmqqqqqmnqqqqrutqqqqmlilmnpmmmmpmmmmpppmmmpqqqCtqquDuuqqqqqqlllllmmmimqmqquurqjmmqqqmqqqtqppruqrtqurqqqpqquDDtDDDqqupmptqpmt",
-"nmmmmmmmmmpqqqtpqCqqtztqCqpzDqmpqqqqqqCEqzDtqqqCDDLUVODDDLDOOUOOMLDDDDDDqqqqqppppmpDLqqqqmmmmmmjililillkllllllmmqqnqnqqqlmmnqquuquqmlpqmunmlmmnqqtuquuqppmpmppqqpqqqqtqqqrqtqtqtDHDOODDtnqqqqqqqlmpmpmllimmlimmnihhimqqmlllpmpqqqqqnqqqqqttuDDDDHEOOtmpDtqpppill",
-"qmiilmlihllmplmmmmlhehhimiippmlimmpqqqqLqqqqqqqqqmptCqzDmmlmmmmmttAtqCqqqtDCDEVXCtADqqpqqqmnrDErDMOONDtpmpqtqpqqqqmmmmliijmmmnmmlqtmmqqimmlimmmipmmpqqqmuutqmqqtnpmqquuDqtqquDuuLDtCDHuqpqqrqnmmllmpmpmliliilmmihfjqqqmlmmlllllmiiiiimmpqqtqqpqpqqqqpllmpmmmllll",
-"qmmmqqqpmpqpmllptCqmmmpmmllmmmlliiilmmmmiifhhiiilhhiilqOqpmmpmllimmmmnqpmnnqnqqDqCCplmmmnmmnrrAAimmmlihhpptqqpmqqnmlmiihiimmmiiihmmmmmmliihhimmillimmllpqmihhimppmmmmpqqqnppnpmmllhlpmlhmmqmmliillllllllqqqqqrqnmmquqqmqqpllllllmmmqqqqqmpmlllhilmpmmllhhhkhlpql",
-"rqqqrvuuuDutqpquzDDqqqqmtDuqpmqqErqqnmlilihiiliiihilihmDpmllmihimmmmmqrqquDDqihehlmlilpqqmmiieeeeehddehhhlmpmimlqnmmmmieeimmmiimlhilliimihedimnmihhllehmplhhimqqqmlhlilltqmllihhllpqDtqmhiiiiimmllihiiimmmlmmnmhqqnqnmuJqnppqtqtnqqqqmlihihhhimpltODqpmlpqtptOIt",
-"pqqpmppqmqpmpCCpDDqlmllpmqLDqpmmtmmpqppqqqppmqqpqqmllmpmqqquqpqmlmilmtzpdihmmhiehhlpqmmmlmjimrqnlliiihhiliiedeimhhlkihklmllpplklmlilmmlllqnpqqquilpqpmmmmihipuqlimmiilmiehhehimmpplmquqtqqtHqhiqimihhmqqlimmmmmqhilmmllmpmmmmmmluqpmlmpmlmpruqttqqqqmptIXDmilppp",
-"qqDDDDztlqtsptplCDqlpqqtLCqCDCqplqqiimmhqqqqqqqqqDDDDDqqqqqpmpnqmpmmqqmhqqqqqlmhdehhiheheeeeeiieiiiiiiiihiihehimhklllhhhplpttpmpuurqqpieilliiihmpmllmqqqlpqpmpqqquunmqqqtrttqtttmqpptqpmqDODplllmmmiiimmmmpqmmlmllmqqpmlutpmmppmqtqqqtttqqqqpmmmmqqtqqqDDDtDDDzp",
-"mpqtDDplmpzCCCqsmCqptCplqlllpmllqNIqpqqllmlmppqqqDDDCqqlqqqDtqpmqqqCDLuqmDqqpmqlllillihiilihiiiiiillllljlmpnlmmqlmpqqqpmtqqqtmpqqqqqqmidmqmmmiimtmihllllmmllmmmlnrqmlmqmlmmppmmmlmmmqtmmqDOIuutqqqqpmmmlqpmqmlmmmllpqmmltqmmqtqtlmpmmmmquqpqpmlpmmpppqtqDtqqCDDD",
-"ODqzDLDCLtpqCCCNCDDLULqDCqqDtppDHuqttqppmpppmmmmlmpmqDLDqqqqqmllihilquzqlqmlmqDmqppqqqqqqqqmmmmmmmqqnmmmmqqqqqqqpqquttqqqppqpmlmmmmmmmieimmilieiqplmqqmhpmlmptqmlmrqnqmmqqtutqtuppllqqptplqLDqqDvEvurtqqqqnpmqquDuqqqttDuqppquDupuDuqqqqqqpmqqqqmqpqqqqqODCppqLO",
-"VDqCMHDD0DppqqptzppDLqCYCDNUUzqDLCpzLDCqCDDCpplllmlilmpqqmlhhillmmllmlmmqtmmpqCqllmpqpmpmpmmmiljlmpmpmmpmmmqqqqmmmmmmmmmiimmmmmqpppmpmllelimpmllilmpqpmmhmqqmmqtjqqrqqqmqpmmlillutqpqppqIqtOOtqHIOEutrqqqpqqtqtutqqtqqquDutrutqmqDDDttqtmmpqqqqqtuqqtDDuDOOMLDDL",
-"CqmtCqppLCqptCpllllCDllDppqqCtmlzLLpC0UtpCLLDCptqtqpmpmlpmpqCqqmDtqqqpmlqqlpnmqmlllmmmlimlmmmiiihimmmlmpmllmqtqmqpmllllimmmmlllmqmmmmmmpmpqquqqqmppmmmppmqqppqqqqqrqqmqqIqqttqtDqqquDuqDOOODDOODqqqmmmlilmqqtmmmhimpplllqqqqqpmllmppnqqpqtuqqtqqquuqtEHtqtLNDCtq",
-"qqCOMDzDqCCCCCCppDLOUqmCqDDqqCtplCKppKCkhoCNLCKCpqCDOU00mqDUXUDqCpptppppqplptlppqmlmppmlmmlmqmllimmpmmmqpqpqqqqqrqpnmnmmqqqmmimmlmmmmpqqmqmmpmlmuuutpqqqxutruIutuEEDuuuEqpmqODqtmpptDtqDpqqptDtmqqmllmlimmptqmlllmqutqmmllppqqqqqqqqtDuqtDEtqqqtmqqqqtqqqqtqpppt",
-"DqDOODDUtUUDCDCtLVNqCNUVCU0CpqLOsKTNKBployNTKCpompmlpqCDCqpqDLDCOLtzCtCOUDpLNppptpllpmppmllqqqmjpqtqpmqtqqrqmlmpqmmmmqqqmnqpmmqrqqtqqqqtqtmilihihhlmmppqmpqpmpqqmnquqqqtpiltDtlhqpmmqmpDummuOtqtqququuuqtqqqqpqquqpqqqqpqquuutuHOuqqtDumpqtpllqqlqtqqqtmCDNLDCqq",
-"qtzDDLDDCqtpCLCppmpDLDqpVNDDDDLOKNUKCNLWYCyKCpoC0mlqlpzlpCDqpqCqptNUNzsLKKCHNDCUNDtDHDqtqqqmqDDqplmpmppmqmpphpuqqqruuuqqqqqnmqqqlpmlpqqqpqplhhihhimpqqqqmhhiquqpimmnqqnqqpmllptEqqpqtDqqtpqNPODDODqpqqqqpqqtqtqtpppmpppppmpmpqqqqpqmmpqtrqquDDutJEutuIDqDOUONUOC",
-"qqppqDLLLLDCDNCqplpqDCDCNCqzCDNOUKCBKUBlNKCKKKKNUtCCqNOCqCCCqpllCpCNCppCtCppCCCCHqptDDtquHEDDOEuItuuuuutqtuIuDIuvuIIvuqqiiillmmquuuttuwupqqpqtttqqqqqqpmmpqqqqquqqqqqtuuIIDuuuDItEPODtDPUDtDHCtDutqqpqqqqpqqqpppmmmpmmlmlllllllhqmpmpnqqDtqDDutDuutqtDDttDqllpqm",
-"DzqqqqqttDCCDNNNqppqCCCDAppqCDDCpCYNCCsKNKCCCKCCpDDCCOUDOCCUULtCNKCCCpCKCNCpCNKsLtpqCCqppqtqpqqpppqqmlplkipplppillmppmmlqqpqqqqqttttqttqtttqpqtqtqttqtqqqtuuqpqtqqnqqqquutqpqpppltDDpmptqqqDDqmmqqutqpqqpqqpqqpqpptqtppmpqpqppliqpqpqqtqtqqpqmqqqutqmpmpENDpmqCt",
-"qqqqqqppqzCCCCLNUOLLDDLLtqqqqqpqCCKCLTCCCNCBCCKBpDLCCLCNppqDNLDNYNLNNNTWNTNKTUNNUDtCDDtpDDDqqqDDqptqomplqttpmppmqqquuuuutqpmqqpmmppmppqptutpppppmqpqqqttqqmpqqpmmmmmmmqmmmpppmmmmpquuqpmmpuOHqpqpqtqtqqtqqttttqttuuuutqqttttuttqqqmqqtqqtqqqqqqqEIOuqqtqqqqppqpm",
-"lmpqCCCzDNDCpqszNLHCCqtqtCDCqpqtLCGstCpoCCCttNUHzCCDDqtNpCDCqCCDNKGCKNNTKNNWYGBNWUONNNDDUODtDOOIttuuqtutuHuqpqpqllppqpllmlllppplppqpppqppqpmpqqqqpmpppqqpmlmqqplnqpnpmmmlpqqppppqqpqDDtputqqmpqDqqqqtuttttqqqtqtqtqppqppqqqqqqqqqpqqqqpmmpppmppqquuqpqqDmpqqqpml",
-"qqCqDDDOLOTDCCCtqtzqpqztqCDCCDDDstOCoppDCHCpCDNCCtCLCtCMpNOCCLNNKGCCCCCCGCKWWCpWNNNDDLNNutqqDDtqqpqppqtplpplmlhkmppttqtttpppppppmttqpppppqqqqttpquqqqqqqqquuutuuquuuttqqlpqqppqqqqqppqqDqqqqqquDHDtDDMHDutttqpqpqqpmlmmpqpmlppmppmppqpqplmmmpnpmpqqpmpqqOONLLDDD",
-"OOOLDDDLDDNLDNNLLNODDLNLzCDDLNOLNtCqH0NGDHDDCCtpCptNCCNCoppptCLNKKKKKKNNNNKNTKGYCNCCCLHDDDCDDDtqtqpppuupqDututmpolptuwuwttqpppppqtutqqtqttuttuqpqqqutuuutuIxuquuqqqruuuuutttuuHHtuDutqDIqtHOOOOOLDDDDDDDtqqqtqtqttqpppqttqqqqqqpqqqqqqqquuuquIIHEEDuDEDuNEDNDDDD",
-"DLOOLCztCDLDCLCCDLLqppqqNDCCNVUDHLXNDODOCCHNOHCtNzNLCNUpCpCNTNCNGNNNNWYYNTKCNNNWWONCHUODOONDDtDDHutqqHIqtOuptplpqttHIHHHuuwuwIIRuIOOIIIOuDIIIIutmmppmpmmqqtqqpmmqmqmpqquuqmpuOIuqqqqutqmttqqpqtqpqqqpppqqqtqtuuwuuuttuuututuwuutqqqtqtuIDtqptDEDuuttDXOOtCCDNLDD",
-"mqCqqpqqCqqDDqqqNppqmlpqpmmpmpmlqDOW0UtDDDMOOVVOMOUNLVNCDNDLNLNLNCHUNCtNNNONONNNWNHNGGNNWGCHNNHHquIuuIDtuIOIDuutIuuOItqutttuuttptpqqqttututqtqttqplimmllllilhlmpunmmmimqqlhlmlllqqpmllqtqpqqtpmpptNptpCpptCtppppHIHutppqqpqquuruqttuRXItqqttuutqDMDDDDCqqqtzCCCs",
-"tDDDzqCDDpmqqpmqplpplpqpillilpmmlpmtDtqqmppqtDHDDOOOUY0UNNTOUUUUNUUNOWYWWOQQOWRW1WTWNWWN0WNNQHCHDIOIHEutIDwutqtqpmpppmtElllmpqqtqpppmlmppppqqqqpuqppqtqpmmplmlppumimlilmqlhmpppqpmpmmmpqqqtDDtqtosCoptHCsCtptttppplllmppqmmqqqrullmqtqpmttpppqttpqCqqqzqpppppppl",
-"CCCqtqtqUDtLDCCDCNLzpCDlpqqpmutlmqpipmmpmpqppqqpqCDuDODtDDDHHNONUWYOW01UWXWOOQXWWNNQWW1WWQQXUQOWIIHOIuttDuqqppppqpmpmlpuqqmlllllqpmpmlllmlmpqppmlmmmmmmmqqqqpppqqmiimlimqmlmpmqtppmpqtqpqqtDDtqqqCqqpCDDNDCtCLDtplhhllqqplilmmqrklppmlppqppmmpqtqqCqpqppLCqqCDCt",
-"DCqqqtzCLCqCDCqCLKCtllphmppmmpmhptmhllllqqqqpmmlmqqqpqplppppqtCtCttCCsptCtpppppptoossCHttCHDtttDutqutppqqttmlilmmlmppmllqpppmpmpqqpqppmmpmppttqpqqtttttuttttqqqqqqqrqqquqqqtuttuDuDDIDDDEHEOIMHDHOCHqODNOONDNOONwtpllpqtlliiilmqllmplpqtllpppqqqqDDDqqmpDqppCCCt",
-"NLDCKNNNDCCLNNLCNCCDzptCplpttpmlimlllllllppmmmplmmqqqqqpmpmppqqtpmmtuqtqDDututuuHsppptDtDwDtppmppmmqqmlppqqplhlpqpquuuttqqqqtqtqqqqqtqpqqqqquuuutuuuutuutuuutqtquvPIIuuIuuIOPIIOIOXOOOIOOOOHIOIILNCOCWOUNONUOUOUDwuttqtqpmpmlmqqlppppqttmptutttqtCDDDDCDCqptCLLK",
-"OTUTUUUUNTUWUWUW0LNYONVWOuDPVuqtpqqqDqmpmqqpmlmlpqqqmpmppppmppppqDDqqOEplllllmpptpopptHHtDtqmlpmlllppppqptuuppptIuuuHIuuqtttqppmqqpqqmpqqpppmqqqmppmlllmqqqqqpqqquIvqmnqqquwHDHuuDOIuttDIDuttDDttCtDCDCtCDNONCNOHIOIDuuIuIEuuuuuuuuuHHEDIOOIHDHIOMOUOMLNOONOUWWX",
-"CHNNNNNWCHNNNNNNUNOONLODUDDHDtqqOIDQVDqDtDDutqpqqqqqqmmmqqpppmppquqlmtqiqqpmpppqhhlllpuuqtqmmmnmppppmqqqqttttqqttutpmmpplpqttututqnqnpmpmnqqmmmppmmmlmlmlpmpmmmpqnqmmllilmpmqqqqqtqqppqtDHDDIOIDqtLNDtqqqtCDtqCOIHIDHuDwDIIuttuuHDHIIIHIOROOwDIOXODMOHDDCDLCDDLN",
-"sCCNGCNNNNTNCKNWLTUNLOUCDDtqCDIHDttOWDtVtDODCDDDqrqqqqtuuqqqmpqpuqmmmqqquuqpmmqqttuHuuIHXWPHvIIxqtqmpqtppmmmpqqpqtutpqtuuuuuqqppqqpqpqqqquuutqqqqqpppppqpmppppqtrqnmmnqqqpmpqtqptqppqqqqpqtquHDqqqXO0LONtqqqqqCOHuppmpplqttmllmmmptuttttttutqtuDOqqtDDtCqtCCtpst",
-"tCCtstCNNCtspstCNNNLDCttDHDDutquDDDOOVOHDDDDDDDIrvIJIvuuPuuIRItuODqtuEIEQIuqtuuuqtqqqtuuvurqqqqrpqqtttuEtutuIIutqppqwDtpppllmmmliiihmqqqmmmmiihhhhhilmmmqqtuuuutrqqquurqqqtIHuttuDuuuuHuuuttuttqDtmtNODqqtCDCttCqqqtqtttpmihhllopppmpmqtutqpqtttqtDOODCquW0NCDCp",
-"pssspstCsssCHNCGCNUNHDDtppqtqpqtODCqtDDDqtCuCuDDuuIEuuquqqtuDttuDqquOOIIEuquuuqptqquxuqtuqqqqqqnpquuwuuuqpmlmpllilmpqplhmmlllllmtqmmmqqmmmmmmmnnpppqppppqqqtuuuuuuuvuExuIuuIIIIPQROOIHDHDuuDIIDwCtCDUXUODDHHDDLOOIHuuuuqtqpqppqpqquutttqpppqtqqtpqqtttqpCuCtCCCt",
-"CCDCttCCtCHNOUONpDNLCCCtqtqqqppqIODDqqDDMHMDDtqqquDuqmpqpEWXOItqIuEOIEutIIuIJIxuIuuQWRuxqtqrrqqmlpppqttpuqpllmpplptqqpmmpqtpmlptuqmmmqnmqqmqtrttmmmmlmilllmmmpmpnnnqqqmmmmmllpqptttqppmlppmpppppqqDDDDDDqtqtDHOXWVOIDDttutDwHttttuHIIIDwOOIIIIHuuDDDDDDHDCHUXOtp",
-"CHDHCNNOWONNNHNDGUWXOOOONHDHDtuupqqqqppmINODtqqpuDEEqqqtqDHqppqtuDuuuqmquuttqttuutptuttqqqqqqqnqqtqmpuDtutpqqttuqqqpmpqtppqqlmpqqqqmnqqtuqqqqqqmmpmlmmpmqqpppmmlmmpnmmmlpquttutqmpmpmmpppmpppmmllmqqpmompmmpqqDLIutqtqqqtttttttpttttttDIIDtqtqqtqqtqutDCqtDW1YNt",
-"pppptDOXWODttqtttNUONDHNutuDIHIIODHDOOIDqqttqqttqqtqqqppltHDHNHtmpmpmlptuuuqpmqtwHuqquuupmmpqqqquutppDIuqpqqtqqquttqtuuIuttqtqtuqruuurvIvuqnqqmmppppppqqqtqqpppmqqnmmmpqmqtqpqqmsqsqttuututtqpppmpqqqtqttqtqqpqpqqpppqppttCCppppqpmpmqqppllllpppppppqqppIOHqptGt",
-"pppppttuttqppppplptppomptqqtuttuDqmpptDttDuCqtCDqpmqtqqqlptCDtplqqpppqtuPQXOwttupuuplttqqtqnqqtrqtqqqutqtquIHtqtuttuIIHDIuttuuutuuvurqqvurruuvrrtqqqpppqqppmpmppnqqqqquvIIIuuuDIttutuuwwtuuuttttuDDDDDDODDDDDDqquuuuDDuDNOOOHCCCqttttqppmppqttqqqqqtqtqtHOHpkppk",
-"uttqqqppqpqqttqqCNDCtttqtsqqtqqqODtqqtDDMDDtqqqqDDDCDOUW20NCpCLWOIDIDuuwuIIIuqtqtwIwuuwuuuqtqurtqttuttttxtuIuqqtmlmpqqpmpmlllpmlrqqrqqqnqqrruuuuuutqqqqtqqqqqqqtruuuuuEIDEDutqtIuuwuuuuuttwuuuuuDDDtqqqDtqtDHDDDDCDDDHDDDNONNHGHwuuHIwutttuuuutqtqtqtqtqlttttDHt",
-"tuuDHutqDuttuuuuNOONDDHutqtuHuHHDDDCqqqqttqpmmmpqqqppCN0WUUXWLCNROOQOIuuttttttttuqpqttttttqqqqpmpmmllilqpmlpmlhmmpmlmpppqpmmmppmqjmqrqnmmmqqnmmmmmllllllmmllllllmnqnpnpqqpqtqpmqppmppopmppqpppppmpqmmmqummmqqtqqmmmpqqppppCCsppsDDuuDDIIHuuwDHIIIIDuuuuHODtDHtCN",
-"qqtuvIutvuuuuuuIuPOIEIIEOwIOPOIPOOOutDHDODqqpppmptutmpmmlpqppmpplptqtqpppqqqqqpltqmlpmpmpmllqplmmllmppqqqpptwtqpqqtqqpqquuuttqtutppqtqttqqtqtqpmmquuqqmmillmmqqqlmmlimmqmpqqqqppqquqmmmpmqqqqqqqmmpqtpqtqqqqpmpqqlptutpmllpqqpllmppmmppmqqtqqqqqpqqqqtqtuutpqtuq",
-"mpqqqqqqlpquuqmlmprqqqqpqqpttqttDDDttDDDOODDuDDDuHIutqppppqtppqqpDODtqqtmppqtDDDutqqqqppqtpputqutuutqtuuIuwIIIwIuwuuuuuwuwxuuuuuuuquutquuttuuxutqqqqmliilmmllilmlmmllmmmpmmllmmmmpnmmmmmmmqmmmmillmmmmmqqpqqmmmqIqmpqpmqtqpqpqqttuuttuuuqqqqpmpmqttqqqqmmpmmqqtq",
-"mpmplmptqqqtqqpqmmqmpmpmpqqppqttmppmpqqqqpppqqttIIIDDHIuDHIIHIORtLOHCtCDtDDCDNNDIIHIHDuuIIEIIutwqtqqpmptqqmpmmptpmmmpqqpmmppmmlmliillilhmlllmpmmmmmmmqpqiliiiiiiqpmmpqpmqqmmmmqqqmppmqqqmqqqqqqqmlmpppqtqqpmplmppllpqpmlqpmmmmqtmmpmmqqpqqqqmpmpmqmpppmhlmqpmpqp",
-"tqqpmmqqqqmpqppquuqpmqqqqttpqtuqpqqqqqtqpmmpqtqqqpqqtqtutuDDuDHODtqqDODqLHDuCDDtqtqtqtqquttqqplmmmpmllmpqpmlhklmppllmmpmmpqtqqppqpqttutuppmmmmmmpmmmquuuqqqqpqqtuxExEIuutuuuuutqrqqruuuuuuuuuvIIqtqtruuuvuuuuuuuqqquIutqtqttuttupqpmppmpmlmmmmmmqqppmqmlmpqqpqmq",
-"uqqpqpqplmpuqqmmuqqqqqqtmqqppqtpqpqqqqpqqqqqpmppqqtqpmqqppmpmpqqpplltCqppppmpqtplmpppmpppplltqmppqqqmmquqqpmpqqqtqmpqqpmllmmpmlimmpnqqqmqquqqqtuqtqqqqqqqqqmmmmmquuutuuuqqtuutqpqqqqqqrqurqqqqqqqqtuutuqttqtqtqqHuqqqqtttqtuHuttuqqtqqqqqqqpqqqqtqqqqqqplmmpmqtu",
-"qpmmmmmlqpqquqqqqqruuuuuptuuuutqqqpqqpppqqppmmllqtDuqpqDqqpppmppmpqplmplllllppqppqqqttqquqmpttpqmqqpmpqtmmllmppmqpmppmmltqttutqqqqqqqqqmillmlmpqqnmmmmliillmillllpqqpmqmpmpmmmmmllllllmmmliiliillmmpqqmliililllillllllmmqqpqppqquuqqqpmpqpqqpqpmmpmmmpmmlllmpmqt",
-"qmllllllqmllillqmqquuquuwuDIIHDHDDDHDDuDDDDDtqtummpqpmqCmmmmmmmmmpqppmppppqppqpmppppqqqpttmlpmlmmmmmmmqqpqtqqqqpqtqtqtqpqqpmpppmqqqqqqmlliiilmmlilililmmlmmpqqqqqqtqqqtqmmllilllhiiiihilihhiilililmlmmmhllmlmqqmhlmpttppuqqpqpqtuqqqqmmpihhehhhhhlllhhlhmllmpmmm",
-"pqmliimmqppnplilmmmmmlmutqqttqqutqqtqqqtuDDuCuDOODDLDCqDqqqtqtqqppppqDtpmpppqtqputqqttqpuuqqtqqututqtqtuqvIutqtqqtuuuqtqxurttrttqturqurqqmllmmieihiihilpmmqqmmmmmpmlmmlilllilhiiiimmilmpqmllmiiimppmpqpmimllpqpmppmllmqqpplmmlllmlillhhiliillmllimqpmlllihimqpmm",
-"qqqpmpmpmmppmpqqqqqmllquqppqppqppppmppmpumpDDpmqDLOMDDDNDDDLLDDDDHEHHLOOuDDDIONDuuuuuuuwtuttqqpqqqqqrtrqpmmpmqmmqpmqtuqmpqttqmmmmiilmiiiiimiiiiilmmlmmpnmmmmlihlplilmllhhillpmmlmmmpqqmmqqnpqplmtuqqqtqppmpmpmmmpmompppmlhillhlmillillpqmlmmpmlilmpmqqmmqlmtupmq",
-"uutqtqtqttrtqqqtnqqmilmqllpplpqqlmmmlilhpmmtqllqpqqqqqqqCqqqtqpqqCDDDDCDCttCDLuppppmmppqmpmpmllliiiiilmmmqqqmiihlhilmpmllmmlhhhlmmiiiihimmmmpnqqmqqmpqqqqpqqqmnqqqpqttpmpmpppppppqqqqqqtquqquqqqqtuttuuquuuqtqqpqtqtqqttpppmpmptqqqqqqqumpqqqpppmmllmqtumlmqqpqt",
-"pmpmmmmmnqpmmmmqpmqqpmuwmmtqmputmpqtqqpqmmmpmlmpmpmppmpmqpmpmlmmppqttqqpmpmlmpmkmmmlllmpmmlllllhmmiiiihiilpmlihilllmpppmllliilpqqmlilllmlmmqnqqqqqrtquuqqqqrqqquwuuuxuutuuurtrttqquqqquuuuuuuuququvuuuuuutqqqqqqllpppquItqqqpppqqqqpnppqpqtqmlmmtpmlmmpqutqpmmqq",
-"qtqqqqppppmmppqqmqmmmpqumpqplptllmpqqppqpppmmppmpmmpmppmpmmpmlmplmpppppmppppppmlmppmlllmplllllllmliihiihimnqmmmmlmmpmmmmpmpmpqtuuqnqqqnqqqruuqqqllmlmmmmlilmlilmmmppmpmmmpmmlmpnlmmmlilmqtqqqqmqpqtqqpqqlllmlmpqmmpmpqtuuuttqqtuuuuuuuuuuuuuutqtuutqtqqquIuqptuu",
-"qtquturuuuutuuvxuurqqqqutuuqpuupqqqqpmmmtqqmpqqlpmlmppmlmmomplppppppmppppqqqqtppmmppmmmlppmmpmmmqnmmqqqqqqqqqqqnqttqqpppqqqqpmmmuqqrrqqnmqurqqmmiiilmqqmqqqqmlmplllillllpmlllllpmpqpmlilmmmlmlilillilmliiilllmpqppllmmlipllmmlpqtqtqtutumpqqquuuuquuuutuquuqquuu",
-"iillmmpqqqpmpqpqqrtqqquuDutttIIqututttuuDDttuDtpqttqtqtqppqqqpqtqqqqppqqpqtttttqtttttttqtuttqtttvuqqqrqnqmnpqqqpqtqqpmmmllmpppmlmjmmmmiiiimmmiiemmpquvxuuuquqqqrtqpppqqttuuqqpqqqquuuqqpmqmmqmlmlmlmptqpllmmlmmqplhilplhllikhhhhihiillmlmlillilitmlmmlmmlmpmpqpl",
-"hlillmpqlliililiilililmpmhlllmplmllmqqqqqtqqtqqqttttttttpqtttqqtqtCtttttDNONMOOHuuuutttutuuttqtuuniiiiiiiimmmmmnmllihhhhhilmmmpmihiiiheemmmmmmmmlmmmpqqmliiliilmplilmppmmpqpmlllmmmppmmmqtqpqqmqpqqqqrtqmmppmmppqqptuuttqtqtqpmqppllmmmmtqqpmlllqlillhhilmlmpmid",
-"mmmmmpmqpmmpqqqpqqmmliiilhlllllmlilmqqplhilplhlmlmppmlmmpqtuqpptqCDDDDCtpqtqtqqptqpmlmpqmpqpmlqtrmiiiqqqlmqqmmmmtqpmmpmmppmlllllnmmmmmlmnmmmiimmqqpmnqmiihlillmqmlllmpmllmpqpmlmmlmmnppmqqqmqlillmmllllipqtqqpqqqpqqqppmllpttuuIuuqqpqqpqtqqmmqqqmpuupmmqmpquupm",
-"mppppmppmpqqqqpqmpqtqttqqpmlllmpppllkhhhlmlllilllhhhillqhhllpmmphiimqqqqjmqqnnmnmmllmmmpmpnmmpqqmmqqqmmqnnqvvunqqqquuqtqqqqqqququtqqqpmqllhimmihhimmpmmlheeeheilmilmmhehmmmmmlliiiiiliiiihiiimliimmmmmmmimmmmmppqqqqpmlmlmmlmlmmlmppmpmmqppmppppmmpmlimmppmmpqqq",
-"ppqqttuuttttppmppqqtqtttqqpqqpppuqqpqpmlllmllllmplhilllpplhihllqmmlliiieimnnqmnqmmmqqqqiqutqqqqqqqrrqqqqqqruuqqntqqqqqquqtqmqqqpqmpqqmlmpmmpttqmpqqqquuqqmmmmpqqqqqquqpqqqqqqmmimmmmmnmmmjlimiieiiiiimmmlilliiihhehiiehhihiihiklhhilllhlhhhhllmlmpqmlillmmlliiih",
-"hilliihllmlllikidhhhhhilllmlpmmllllmmppmppppmppqpmlllillilllplmpqpmmlimmmmqqmmmnqqqqtqqqtqqqquqmqmqqnmmnqmmmmmmmmmmlihimmmmliiihillpmlhhillmmqqpnqqqqqqqqqqqqquuqmpqqqqquuuuuuqtqqqqqqqnqqqrqqqqqqqmnqqrqqmqppqqqmqqqpmqhihhikiilllllllihilllllihhiheddeiimlmlli",
-"lllllllhihlihhllihlllillehhlihhhhhhllmmpmmmmllmlmpmmpmpmpppqqppmqqqqqqruqurnqmnnmmmlimmmmqmmmqmliiiiiiimmmmjmmmnqqqmmmmqmpmmilihilmppmlihillmpmpmpqmmqqqhiihehimpmmpmmmqrqqmmqqummjmmmmlmmnqqnnqqnmmpnnpmpnpmpqqqtrutqqqqqqqtqqttqqqppmlpplmmllhlmmpmmmmllmmppqq",
-"mpmpqqqttuqtqqqqhililhhhmlmlllllmlihikihihhhhhhhhlmpmptuIuqplilmpqtqqmpqqqqmmmmlilqqqqmlmmlmmqmiiheiiilmhiihiiilmmmmllmmmmqmlmlipqqqqqqmpqqqqqqqmqqtuqqmqtqqmquuqmpmqmpqtqqqqqqqmmmmmmmmmqqmmllmmiimmqmmqqpmmlllmimqqnqqqqmqqqtqqqtqqqpmqqqqttuuqqqqqqqqmmpmnmqm",
-"pmpmmppmqqtqqqtttqttuuqpqtqqqqqqmmlllmmmpllllilihlmllimpmmliihhiiiliiheeililiiiimmqqqqpqlmllmmmlmmmmqqnqqruruuurqqqqqrtquuvuquuuqqqqqqqqmqqqmmmmmqqqqqqmlnpiilmpqmnpmqqqqtrtqqqmuuqqqtqqqqqqqnmmnqqqqqqqqqqpmpmpnqqqqqqqpmmmqqqpmmppqqpqihhhilllmmmmllllmmmmpqqq",
-"qqmpmpmmlmmqppnqqmlmqqpmqqqqqqqtqqqquuxwqqmpqqqqmmlilmmmhhimmlilhlilmlliljlilllilmliilmqmmmmmmmmqmmqqqqnimmmmnmlmmmmmqqmillihilmmpqppqpmlmlmmmllmmqqqqqpmtrpmntrmppmmmmmlmmmmllimmmmmmmiiiimmmmmmmnnmjliillmmmpmqnpnmlmpqqqqquurppnqpqqpuutqqqqqqqpmmmmmllmqqqqq",
-"mlllmmpmqqtqqqppqmlmquqmmlmpmpppllmpqqqqmmlmpqqqppmmtxIuutqppmqtqqqqtqqpqqnqqnmmqquuuuuuqutqmpqmmmmnnmjmmmqnquurqpmmpqqmmqqmmmqqmqqqnqmlqmqqqtqqqtqqqqrqtvxqqtuvtrqqqqqmnmmmmmqtmmiiiiiimliiiiheiimmmmmmppmpppmlmmmmmlmqmlilmqpmqqqqqnpmqpnppmliqmmmmmqqmmqqqpmm",
-"uqqqqmmmmmmmihimqmpqqtqqqqqqqqqrqutqmqqtqqqqqmllqqpmmmqqqqmmmpmmmmqqrqmlillmmmmmmmpqqqqmmljmqqmimmmmlimmmmnpnmnmmqqmmpqqmqnqmmmmlmmlmllmiiilmmmmqqqqmmiililqqqqqmqqqqqpqpmlilmpnmmmmlmmplmmlhilnlnqqqqqqpnpqppppqqqqqqqqqqqqqqqqqtqqqqpqmqqqqqmmuqmmmmqnmliiiiqu",
-"uuqquqqtqqqqpmpqmmmmmqmpqqtqqqqqqqqqqqtqqqnpmmmmqqqqtuuutqqqqqqpqpqqqqqmpqqqqqppqqqqqmmmmmliliihimmmmimmmmmmmmmmmqnmmmmmmmmmmmlmmlmmmmmmmmmmpmpmmmmmlmmmilimqpmpmmmlmmmqnpmmpqnppqqqqtqqmmmqqutqnqqqqqtqpqqqtqmlmmjmnqnnqqnmmnpqmmmmmmnpmmqquuuuruqqqqmmqmqnqqrx",
-"qpmqqqqqqtuuuqqquuqtuuuuvxuurtququtquuuqnppmqpqpqqpqqqqqqqqqqqqprrruuurqqqqtqqqquqqqmmmmqmliiliimmqqmmiiijijmmmmnqpmmqqqmqqqqmmmmnmmmmqqmqpnqnqqqqmmmqqqmmqqqqqqutqqqquutqqtrutqnpqruuqmqpqqurqmqqqqmqqpmmpppmllnnpnqqpmmmliliiimmppqqqqqqqqquuuqqqqqnpmmmmqqmqr",
-"lilmmpmmqqqqqqqtqqqqquuuqqqqqqqqqqnqtuutqqqqqqqqvurqqutqqqqqqqqqutqqqqqququuutttqqqmpmpmqqmlmmppnqurqqmmmmpmmmmmqqnnqtrqnqqqqqmmpmmmmpnqpmmpmpmqqqqmquqpmmpqqmqqmmmmmpmpnqmqqqqqmmmpqqmlmqqmihlqmqpmmmmmppllllmpqqqqqnmmutrtrquuqqqqqqqqqqqqqpmmmmqqmmqqpmmmmilm",
-"qqqqtrqqmmmqqmqrqqnqqqquqpqqqmqnqmmmqqqnuqqqqqqquuqmpmnpqqqqmqqqqqmmjmlmlmmmpmpmqqqqqqpqpmmppmqmmqnqqnqqnqmnmmmqnmmmmnnnmmnnmiifiliiimmmnqmnmmmmpmmmpqmlehiiiiilllmmlliiihiiimmmmlllmmihlmmihhquurqqqqtquqqpmpppnnmmmiihiiiiilmlnqpnpmmmqqqqqnqqqqqqqrruqqqqmmqq",
-"rurqqtqqqmmmmmqqquqqqqqqqqrqqqqpqmmmmmllmmmmlimlmihheiimmmmmmlmnqnmliliiillmmmmpmqqnpmmmmmmmmliiiiiimmmnmmmimljljifiiihimmnmjifemmimlimmqnmmliiihiilmmmhehhilhimmmpqqqmmllilmpqqqpmmpmmlmmmmpqquuuuqquuuttttqqpppmmmmmmjmmmmmnqqqqqqqqqqqqqqqpmmnnqrruqnqnmnqqru",
-"pqqmmnqmqmmmmmmmqqqmliiiimmqmmliqmqqqmimiliiiiiiilmmimpqmmmmmmmmqqnqnnmmqqqtttttqqqpmmmmmpqpmihhhehiiimliiiiiiimmjijjijmnqrqnnmmqqqqqqqqqqmmlilihlmmpqmmpmmmqqmqmqmqmpmmqqqqqqqqpnqqqqpmqqqpnqqpnqpmqqqpmqpqpollqqqmnqnqmmmmpqqqpnmqqqqqpnqqqmliljlmqqmmmliljmmq",
-"mmmmmqqqqmliihiimmmmmiiiimpqqqmmilmqqmlmmmmmpmmmiimmlmqqqqtqqqqqqnqqqqqmmmmqmpmmuqqqqqttqqqqqmliiiiiiiieliiiimmmnnqrqqrvurvurrrrqrrrrrrqqqqqnqqqqquuuuuqrqqqqqqqqqqqqqqqmmmqqqqmmmppnpmpimpmihlqlliiimlimlllllomqnmjmlmmiiiiiiimiilililmmmqqqmmimieimnqmmiiiiiii",
-"qnmmqqqnmmmmmmlitqmmmmmlmmmqqnqqqqqqmnqqqmqqqqqqqqqqqqquqtqqpppptqpllllhqqqlhehlmmmmmmmmmmmmmlmpjmmmilmqqnqqqqqqqqpmmmqqqqqqpmllmnmmqqpmqpnqrururtqqqqpqmiiilmmquqqmlillppmmlllliiiimmmmhihehiiljjmimiimmmnmmijmjiiiimnmnmiiijiimmmmmmqnqqmmmpmlmlhimqpmmmppmmmm",
-"qnpmnmmmqqqqqnqnrqqquuurqurrqqqnuurrqqqqxJuqnmmiqqqqqmqqmmppmlmlmmmlmmpmllmllmqqxuuuuuqqqqqpmlmmmnmmiijmiiiimmmmmmmmlmmmlmmpmmmmjmmmnqqpqnqqqqrrqquqqqmmpmllihiilliillilnqqqmmllillmqqqmmmmmmpqqmnnqnqqrqqurqqmqmiijmnnnnmiijmjimjmjmmmqmmmppqqtqpmpqqqquuuuqqtq",
-"npnqqqqnqrrqmmmmqqqqqqqqmmmqqqqqnqqqqmmmmqqmmtrqmijnqqqqmpmppmpmhlmlmpqpqtqppqtqqlimqqmlqnqmmillmmmliihiiiimmmmilmlmlllmmmmmmlmljmmmpqqpmmmljmmmmnqqqpmmqmmmmllmqqqpnqpmlmqqqmmllmmpqqqpuuuuuuuuvuvruruvqruurqqqmnnqqrqqqnnmnmmjmmmqmnpmqqtqnpqtqmmmmqqmpmmmmmmm",
-"mmmmmmnqmnqnieiiiiiiiiilnmmliiiiiimmmmmmmnmiimqmihipquuuqqtuttqtqtuuuwEHEuuqqqplihhimmmmilihhhhemmmmnqnmmmmiijiimmmmmlillmllliilmmmmmqmmmlmiiljjqqmmmqqrqqqqqnqqpmmmpmmllmpqqqqqnqqqqnpmnpqqqqmmuvvrrqqnqruurqqqnnmnnnnnnqnnqqnmmnmnmmmlmqnpmmlmiiehilihmlllmpml",
-"iiieeehemmpmiheihiiiilmqqqmmliilmmqqqqmmqpmmmlmmqmnruurqqtuuutqtquutquDEttqpqqqmpmmpmllmmpmlimmliimmqqmmmmiiiliippqmmlliliiiilmmmnmmmmpmmpqqnmmnurqqqqruqnqqnmmnmmmppqpmmpqqtqtuqtqqqpqqpqqqqmmlnqqqmmjlmmmmmmmmmliihhiimmmmmmmliilllihheeghllllihhhhilililmppml",
-"miiiilmmnqqqnmmqqqpqpqqqmmmmqqtqqtuqqqqpnmpqqmquqnpquqqqmqpqpppmmpmmmmqqqqmmpqqqqqqnmiimmmmiilliqqqrqqnmqnmmmnqqqqqqqmmmmmmmmpmqnqmmqqqpmqqqqnmmqqqnqnqmqmmnqmmqutqqquqqmmpmmpqqmmmmmmmqmqmqmqmmmmnqqqqqnmmmljmmmjiheeehiiiiiiiihiijmmiiliilqqtppmmmppqpmmmpmmli",
-"mqqqqruvqqrqqqqnuqqqqqmmpqpmmmmmqqqqmmmmquqqmllmiiimmmmmllllllllmmmmpqtqqqpmmpqmqqqqqmpquuuqtuvtvvxvuruuqqqqqqqqnnqqqqqqqqpmqmmmmmmmmnpplmqmmliiiilmmmjmmmmmmmmqpmmmqmlhhiiliiillmmmmlmliiiiilmmmnqqqruuuurururummmmiiiliiillilimmmpmmpmqqqtqttqqqppnqqqqttqqqqq",
-"qruuuqqqquqqmmmllimqqrqmlimmmmmpmjliiillimpieiieiiimliiliillllmpilllmqmmllliimmpmlillliiimlhiqqmmmqqmmmmmjmmmmihillljlmmliiilmlliiihhihhmpmlieeiiiiiimmqqqmmliiiihilpmmhehhhihiimmqqpmlilillmpqqqqnmmmnqnmpmmpmmmmqmmlmmmmmmmmmnqqpqqqpmlmpppmppmmmmllmmqqqqmpqq",
-"mqqqmqrwqqpmpmmmhhhimlllhmlilmlmqlhhhiiilpqpllllnqqqqqqptqqqqppqqpmmmmmpmmqqpmmmmmmmqqqqmlmmmmmmmqnqmmiimmqmjeeihiiiiiiimiiiiiiieihihhlmlmpmllmnqrqmmqqnmmmiiiihimmmmqmimmmqqmmpmppmmmqqqmququutnqqnpnqqmmqmmlmlpmllqqmihhililihliiiilihlllpmllplllllilmpqqpmpmp",
-"qqpnqpqqqnqqqpmmmmmlmmmlqqqmmpqqqqmmmlmlmqqqquuquruqquuvqqtttqtuuuuqtqqqqtqqqqtrxuuxvuuuxuqqqqqqruuruqrqqqrqmmmjieiiiiiiimlmmmmnqqqqqqqutuuuqqqqqqqqqrqqnqnmqqqqmquqtuuqqqquqqquqqqtqqpmqmmqmqqmmmmqqmmmmmmmlmmqllililihiliililihlllmmppplmqspllmmpqqpmpmpqppqqq",
-"qmllqqmmmpmqqqpmqtqppqpmqutmppmqqtuwuttupmllmqqquurqquvIqppqqpqtqqqqqqqqqnqmqqqqmqqqqqqmuqqmmqqqqqrrqqqrnqnmmmmmmmjlimmmmmmmmqqqnnqnmmqqqqqqqnmjmmmnrurmmmmmnqqnqqqqqqqqmmllmlmqqqmjlmmmqmpmmmmilimmqqmihihhhimmmmmpmmlmmliiiliihlmmlppqppoqtqplllmppmlmlmpmmpmp",
-"pmlmqqplpmpmppmppqtmmtqplqplpmlllmpqqtqqqplllppmmmiiimpqqqmlkilpiilmmmmmilmqqmmillmmqqpmqmihilmmmmmmmijmiihiiliimmmiilijljmmjmmmimjmllmplliiiiieiiimmqmiiiiilmmmlmmmiliillljllmmqmhehilmpmmqlilhiiimmmliliihihiliilmmpmmqmmlmmmmmqtqpqtqttttutspqqpmmmqtpqqppmpm",
-"qqppqqpmmmllmmmmmqpmlqpipqmllmlmlllmpqqphiihhhlimmmiimmmqqmlihhlilmmmmmlmmqqnpmlimmmqqnpqmliiihhjmmiiiiihiiiijiimiieffiiiiiiiiifhfhieilmqmmiiiiiihhilmiimmqqmmmmnpqpmmiheeehehiiilmqqqmlmmtqmilmiillmqmlqpppmppmmmmpqqqquuqqtuuutDEDtttuHDHDGCDCDDutqtDIDDuDutuu",
-"DDuDuDttutqpqqtqqttqqqplttmhlmlptqmpqqqpqttqpqppnqqqqqpmlmppplhhmmmmmmiimmmlmjmmlilmmmmlmliiilihiijljlmmmmmmmliiiieieiiiiijljmjmimmmlmmquutqnmnqqqmqnpqqqquuqqquuruvuqmmqqqqqrtqmpqquuuqpqvxqpqqqqnqtuqquqtuuuttuutruxuuuuutruuuquDtqtttCCDtptCtqtDDuDCqHDCDLDLH",
-"NDCCDDDCLDCtCDCCuDuuuuutuuqmpqqqqpmllpmmpmliilihmnqnpmmllmpqqpmpqqqqmmmlmmmmmpnqqqqqtqtqmlillmmmmmmnqnmqnqqqmmmmnnmmmmmnmmnnnqqnrqrrqquEuuuqqqnquqquqqqrqqquuqqqutquuqqqmqqqqqqqqqqqqquvqquuqruuqqqtruuuqqqqqqqqqqmpmqqtqquqqpqqpqqpppplpppopppplmqpmpqmzqqtDttq",
-"pmlmqCDCztqqCtCqHuuDHDDIqDuuIIutututtqttuuqqtIIuuvxvvxurutqtttuIuuuuuuqqruuvxvxvququvxvxurqmqqqqqquurqqqqrrqnqruuurqnnnnmmnnqqnnijmiillmmqqqnnqrmmqqmlmpuqmqqqmlqmnqqqmqqqqqmqqqqquqqqqqqmmqmqqpilmmpmmmtqmlmpppmmqmmmquqquuqmmqqtpppppllpolpsplmqqmmpqpqpmpqpmm",
-"llmppqpmqqqqqqqpruqqquupptttpppppmquuupmptuuuutqDDtqppppuuIurruquuuurqqquuuuqtqquuuuuuuEvqmmqqqmqqtqppnqqqqqqmmmqnieeimmmmmlmjiiiljmmmqtqplhllpluqpmmmpmmqqpmmmpmppqpppqhmtqqpmmpmlpqpmhpmpppppqpqqppppmtqllpuqpnrrunmmqrtqqtpplqtqpmmmlpquqpmppqpllmpqqtqpqqDtq",
-"qqtqqpqpppppqppqqtuqqqqqqqqpppqupmlppmllqmlllmpqpppmmmlmimqqppnqmmqmpmmmmqnmmmpmqnqnnnqqqmmilmmmlmppmlihjiimjiiimmmiilmqqnnqnqmiiimllmmqqqqppqtqqqqpmpnpmqqmlmpqlmllmpmpqqqtqppmmpmppppmlppmmlmpppliipqtqqplmqpljnnrqnqrmmlppppptutttuuttuutqtqqttDuDtqpqpmmqqqm",
-"qtqpmmmqtrtqqtqqquvuqqtuppmlmppqqppqqqpputpllpqqpmpmpmpmhlpqnqqpmmmmmmqqmmpmmmqmmmmmlmmmmmmmjlimhilmmmmlmlmmmmjmiiiiimmmmmnqqnmmlmjmmmmpmmlllpmllmmmmllmmmpmmmnppmllpppmppplmmllllmpmmmpmpqpplmmpmlhhlpqllllmppmrrrvvvuItututtuDuHEuuuHuuHuuIOIDOOHMDOEHDDttDDtq",
-"DDHDutDOqqqppmppmqqqmlmqppmpsqplllpqtqpmtpmpqpplqqqpppmpmqqqqqqqmmppmqqtmqqqqqqqnmnnmmmmmmmmmmmmllmpquqqmilmmiilmmmllmmljmpqnpnmnnqqqqqqqtqqpqqpqpmmpqnpqtqtqttqutpqqutqppmmppppmppqqqttttttqtqtwvwwuuuutttqtuuuEvvEEuuEuuDutuDHHEwututqtttuDIHuDDqqtqCtDutDIOOD",
-"qtutqDIOOOOODHOOPOPIPIIIuutuuHutppqtutppqqqtutmltqpmmmpqppqqpqqqpqqmqpqqqqqqmqqqqtqqqqqqmmmqqqmlmmjjmmlimmmqpmlmqtqpnqqqqqqqqnqqqqurtruuuvutqtutEuqtuvwuuuuvIvuqtquuututquuutqtuuutuuwuuutqtuuttuuDIIutquuqqpppqqnqqnmmqlmpmlpttpqtqtqqpqquuuqpppppqpmlhlllpqtuu",
-"lmmmlpqttttqqqDNIvtuEDutOuuuIOOOIHDuDuuDHDHEIIHutttqtuuDtutquuvuuuuuuuuuuuuuuuuxEEvurqqrqqpqqqqmvvuuruvvuuuuuutuqqqmpqqquuqqqqqqmnqqnpqqqtpmlmmmuqmmqtqqpmqtqqpmlppppmmmpqttqpmptqpppqqpqpmmpqpmlllmpmmpqmlllillmmnqnmqunqqpmqtpqtttqtqpqtDIHuDItquuHIDIutqqtqpp",
-"qtqqqquDDDDtqtDOEutuuutqutttuHIOHuttqpqtttttttutDDDHDHDDtuuuuIIIDEIEvuuDuIuuuEIIuuuutqtqqqqmqqqqmmnmmmqqqqqqtqpqllmllmppuqqqqpmmmmmmmmmmqtqpmpppmmmmmmmmllmmpmmpmmllmomllmpmmlllmmmlllmpmpppmlmmpppqtttttppqtqtqqqqruruIuIuttHuttuutuuuuuuHIOIOXOIHDIWY2WPOHuttq",
-"ttqttDDDuDtqpmqtuqqqtpmpqqqtttttqpqttpppmpptpqttqqtCtqpmpqqqquqqqtqtqqqqmmpmmqqqmmmmmmmqmmmmlimqnnrqnnmqillpmompillllmmlqqpqqqqpruqqpmqqqqtqtqqpqtuutqtqqqquuquIutqqtuttqqqqttutqttqpptutuxuqpqutquIIutuutquutqpuqqqqqqqqqtqtEItqtttuOWXHutqqqtDtqtuuDwtuutqtuuH",
-"qqtuuqtqDtuDDDDODDEHDttutttptDtptpptqptOQHuqtpmllpqlpV0QuqqtqpmpqqpmllmpmquutqpqqmmmmmmmllllmplhmmjiiiimillmpptttqqpmppqmpmquuqqqrrruuuuuwuuuuttqquuDuuuuuuuuuIEHuuuHEwuItptuutuIIuuuuuuIuutuwutqtqqtqqtquqpputqrqnqqmmqqtqmquupqqquORIuqpmpppppptuDIItppqqtqppp",
-"qtqtDtDutqDDDtppuuuDDuDIIOOHOWXHtttHIDOY0VONDCtqtLOODHDutqqqqppqlmpmppqtutpmmmpmmmmppqpmqqqqtqmlnnnnmmmnmmmlmpmptutqqqqqqqtqqpmmqmmmmmpqqqqtuutquqmmmpqtipqqtrqqlpqtppqutqqtqpmpllllpqttqtuqpmtutqtpppqqtIIupquwqqpqqpnquvtpptuuupmlptDumpqpqqqquuttuDtmmppqtuuq",
-"qqqquDHODqtqqquEttqqttqtDHHHNXODODNUUHHOHNHHNHDGLQYYXNCDODDHDuuItuuHIIOROIDHHIDuwDwEIIwutttuuuutvuurqqqqqqmpppqmlmmmlliimqqqmmmpmmmmmqqqqqqqpqqpqqpqquqmmmqqmplipqutqpqumqtqppqtutqqppmpqqppqtqqqtqqmptuptuqlmpmpmqqqqpqtwJIuuuwuwDxDuDHquIDuIIHuDuHOPHttqqtHIut",
-"qqttCDDDDtqtqtOYuqpqqqpppttttHHsONNOHtqsqtqpqCCCppCNCtqqtqtDutqututuuuDDtuuDIDtpqqqqpqpmqqtttttuvvrrqrrqrqpmmpmlllmmmmmplmmmmmmmnqmmpqqqtqpllmppiipuuuqlqqqmmmpputpmmplhlpplipuuililmqqqlllptqlhlmmmlmpquutqttqmqpppqqqqtuPQPuuumtIOIuuuuDIHutuupquIIHuqttpqutqp",
-"DIODuDtqtDEOHDqtDtqqtuCDptDDDNNCCtCCCCtCNHCppqtpCNONOYWDqtuDDqqqtqqpmpppqmpmmpmpqtpmmpqpqqqpmlmlpmmmqqqquqmlmiihjllllmmnmmliiiiiqmmiiliillillmpqhiiillmmhiihilmqupmllllipqmhhllltppllhhhlpuuqplmpqttqqqtuuutuwupqqqqqtuuqqpqqmmttttqpqHOIHuIuqtItuIOIutttttuuHuw",
-"uDODDODtODOOODDuDDuDDDDHtNNNNOOHDDDDDNLDUUHttCDtlpppCNDpCDOOODuDDDtqttutqttttqpmliihhlmlppmllllmmllilmmlmmiimmmiiiheeehimiiimmmimiilmmmmlmpqtqppqpmlmmpqquIxuxuuqttqpqqtqppmmpmlmmpquwwuuuuttqttutuuttqqqttqqpqquuttuxIJIxvIxuvvuuqqptIXutqtqptDutwuttuIuuuwuuuu",
-"mqtquDODODtDIOOODDDHDtDDDOOHNONNWUNNNNNGHONCLONNCCCCDNDCtCDODtDHDDuDDDDDuDDEODqmqttqtIIuqpppqttttqpmpmmimmmmmnnqmmmmmmmmmnmqnqqqnmmqqutqquuutqppqqtuuurtqqtqqqmmmpqtqpqtqppqttqqtttttqqptplmptqpqpmpppmltqqtqppqttuqtuIIuqtqqpmmpmommmpplpmllpqpmlllpmptpppmppll",
-"lpplmtqpDtqDOECtqtDENDOQNUWONWWOUNOUOUNDNWUNNWUCYUNNLtCODDOOOEOVOOOOOVOOWODDOOOItIDuuOIDIutttuutuuqtuuuuqqqnmmmmnqqqqqqruuvurqrruuuruuqmpmplllmpmmlmqqqqquqqpquutqqtIwqlpllmpmptpqqqqtqqqqutqquxuqqquuuttpllpqmllmplmqtqIvumimpqpmllllmlmEHmpIIpqplpqpppqpmptttq",
-"mmmmqqqmimmqmpmjlpqCDCqmDNDCLLNUUOUWUOOOOUVUOLOWONOMNLOUHDCtDHHtHuDHOIDtuuqtuuqqqqqppqppqmmpqqqquqqqpmpqtqqtqppqpmmlllmppqqttqqqutqtttttqqqttqqpmpqqpqtuqqtuutDDOEuqqmpqnqqqqqqqqqqtqqqqDtNOHtqoqlmqqtqmmpliplhtmlmptDDHtHtpsqttqptutmtutuuuqqqqtqppppqqpqqpmmmm",
-"mqmmnqrqmmmimmmqlllppmpllpmptCzHCCqCCzCCCDDCqtzCDDCtmpppqtttDHDtqqpmppmlqtuqmilmqmliillitqpmqquuqpmqmlmmllmqtqtuutqqqttuqtutttttuuutuuuDtppmppppqqqqpmmlqmmmpmmlqpmpmllmppqpqpqqmmpmpmqqplpqplplmilmmqqplmqtuqpqtqqtuDHDtDtppppttpqtqptuqttqqppqqqqqmmpmmqqppqpl",
-"pqpmppqqqppmlpqqlmpmqpqqlmpmzqCDDDCDDDDMLDDCCztqCLDCtqqtmppqtttpuuttpppqqqpmqqmiqmlhiilluqmlilmmmmpmmliimmpqqqqtqppmpqpppmppmppqmpqpllptqqplllllmppqqpmlppmpquqmqpmppmmpmmmmmmppmmmmlmppqmmpllppqmlmpquqttuHuuHDHIIOOOIOOQOtHHDHODuDuHOHIOOOHIHIOODDDuttqtuqqDtm",
-"uuutqqqpllmlmllhpmpmpmppqCpptqqCCqqtzqCCLDCzCDCzpppqpqtCmppqttpppppmlmpqmiimpmlitqpmmlmmqpmhhilhmmmmllilpmpmplmmqmmompmlmppmpmpplmppmlpqppmppmlillimpqpmmihiptqpmmmpqmpqllllmpmmmmmmllmmtplpllllqqqqquIuutDIuHPIPVWVQOWXQYXOXWW0WRWQOWYRYWWWXUXWUWUXOOMOHVUMHOEq",
-"DNINDttttDORQOutillmllilqqmlmpmtqpqqtppptqpqqqtqqqqqpppqtttttttqtuuuttuDuOXOuqqvttqtqpqpmpppqtqqpmmlmmmmmpmpppppqplmppllpmmlllmpppqqtqqpqpqtqpppqpmpqqqpqtpmpqqptqtttqqqpmmmppppqqqqmqpqtmqtqtuturuvuJOuutIWIDItHNONHNU0NWTNTWOWOUWUNOWOWONNHNGDOOPUOOODDXYQOOOH",
-"HDNOOODDtDHOONHDtCDCtppppqmlptzNDCDLLCqCCzqtCDCCLNLDDDDCHODDtuCtqtttqqqtuIOIqmnquuuuutququuruxIuquqqquutquuuuuuuqqppqqpmqqppmppqtqttuwutIHuuuHIDIuuuuDuDIIIuuIIDPIDEuuuHIDuuuDutEIMIDuDDPDHUODNqpquvDIOuuuIDtuDtDDDDCDQWCONGHNNWNHNOHDNHUNNHDDHCHLHODDDDtLPODDOO",
-"CttDNCCCNNNNNNONOUXUMODLqCttDLDODCCDDDCDLNDLLNLMCDCCLDDDDLHttuDtIOIDuuuuuuqquuuquuuuqqtutuqpqtuquuuqtuuuuxxuuuutwuwuuuIxHIIIuwvIIIuDIOIDIHDuwDIHuDDHDDHImtqqtDIuDttqpmpqOIDHEIDuEEDDDuDDODuDtqmlmmqtquupDHtmpqtDttGDDGDNNNHCGNNWUCGNNGNNWWNNNNNNLDLDDCCCCCCLDqCO",
-"NtpCHCtCDCCCCtppDDNDCzCDCLDzDCqCOLLLNLOONDLDDDDDDDLDLLHDttCqtttttqqpppppmmqqnmnqmqppmmqqqqmiiqutqqqqqqqmpqqqqtqqqqtttuuHuuuuuuutDttpqtttpqptqqppqqtqqppmlmppqDtpIuqpmmpqppmmtqqpqmmmmmpqDqqDqqplimqqmqqipuqlppmtpqttttspGNCsCCGN1CCNNGNHNCCtGCGCDNDCCCqqODDLDtqD",
-"DNUCppCUKspppCCpDpCDmtLpCqmlpqCDlpqptOOLDDCtzpplppCDNDtCqtpppllpmqpiilmmmmpmmmqqqmlmpqpqplllmmpqqqqiimqqpqplimtqmpqpmpqtutpmpppmpqpppqqqpmqqsppqpqttpmpqqplmlmpqqpqpppppmpppqttpmqqqmlmmqppppmllllmmqqtuqtuutqtuDOODsqLWDHNUWNNGCCGNNCCCsCCKCttCDOCzOMCCOzDOLqCz",
-"pCCCCCCCpCUNpCLCDpqCpqDqmtNODCDLOUOCqCDCqqqpqpppmppqmpmmtpmtOQHtmpqtqqplpqqqqqqrtqqquqqpmllmpmmmqqqqppqqmmmlllmplmppmppqpmpppqqtmmmpmpppppqqqppqlmpmmlmpmmmppmpppppqpqqqtqqpmpmlmmqnmmmqmpqqqtqqurquuuuuqppqtutqHNLCtDONCCGNHNN0NKNOUNNTXTNNNKNWLLDDLtmCLtztCNDp",
-"CCKNLNLNlCKLKNTpCqqCzpqCCDOLCqCNDOOzpqtzqpqqqpqqpqqppCDtqplpuOuppmlmppqqmmmmmmnmihillliimlllmmlmqmmqqqmppmpmppmmlllmpmmmlmmmppptppqpqtqqtqtttqttqqqqqqpppppqtqqqqqqqqqqtpqpmppplrurqqqqutrttqmlhmmllmmmmmllmpqqpqqqlmCCpqzCCppCWCCCKNNCNUNDGDNNUNCLUNqtLOUNzCNCm",
-"NUNKCCLTNqCCDUTCDDCDDqmqOLqpqppmpLUOOOUNDCCqppqqpqqlpDDCtttpppqtutmpppquDuuuurqqtttuuuuxuuquuuuwqmpuuqqqqllqqpmpppqtqttptqtqqqqqtuttttttqpqqtttuwuutttqpqpqtutqttqtqtqtquuuuwEIInmmmmmmmmmqqttqqurqqqtttqquttqttDDCqqLDqmtDLpppLCCtCqppCCppCCCCpCmCUCCNLCUUCqzDN",
-"ULCzqzCLZNLUKzCLUNDCLCtLNCqCDzmllpqqzCqmLDCDzpqCCLDqqNHqqHODqtHODDDIDqqqEDDDruqnmmqqqpqqmllmpmppmmquqpqupillpllmmmpqqqpmqplllppmtqqtqqppmlmpqqqqtqpqqpmlpmpqqqqtpppmmpmpqqpppmmpmqmmljmmpquuvHuuIvuuuqqqqtttqpqtAOMDrEDqCDLNDzDNOLLDDCDLCqCNOLCqllpCpzLpmsppqppZ",
-"CplqNUCpLpzUNCLCUODztDUXDDLOLDDUDLNDNUODODCLHDCDDONLOUODptCttDttqtDqppmmmmmmqmnmlmpqtnllmmqtuqpmhhilihimqmmmmmpplmppppmpplilmpqpqttttqqptpqttqptppmpqqppmpmpqtquqqppqttuuutuqpptrqrqqqqquqqtqppmmmmmmpmmplilqtplmqqqmmmmqqqqqqqDDCDLDCLONDDDLDCDpCLqpCClCCllCplD",
-"zqzLUULmmmpzLUMzCzCqpLULLCCDCCNVptCqqDLCOCqLOLCDpppqCDCtmpqpqtphqqpilqqmmqqtrqrupmmtqpmlpmmqqpmmhihhhehhpqqpppqqqqtutqtqttqttutqtqtuutqpttquutqqmmppqtqqpmpqtqtutqqtqtuupppmplmqmmmmnmmmililmpqtqqqqqtuutplpqtqmmmnqnmmmjlimllmqpmptqpqDCqqqqqCDCTUKLCzpTUCmKtlp",
-"mDSULzpqhDYLlzNzllDDmDNlCpmDLtmllqDCqCqpLpmCDtmpDqqCDqpmpttqpttppttqDXIlqrDEDruEIuttuuuuIutqqqqtqqqmmqmmimplilmlhlmmllllmpqpmlhhlmpqpppmlllpqppllllmmpmpmlpqtqtqppplmmpppmmmlhlmmmmnqqqqpmmmmpqtqqnpmmmilmlllhhhjijqnlimlmqqmmlmmmpqpmpqmmpqqqDOlCLCNpoKq0LoCCpN",
-"qmqqDOOOuMOIuqDICqpCOOCmDCqpCqplmqpmtqqMDqtuqpqHCCCDOOHuOMEDurDEqqqpqtqputqqqqquqrurqnqrqqqnqmmqmqnmuvtqpmqqqmimmmpnmlmqmmmppmllihimqqnmmmmmmmmmnmmnmnnqqqrtqmmqnmjmmmmnlmlllmpqqlmpmimlmlmmpmlmmquuqmmpqmmmpqmhjijimnnmnmmnnmmmlzmlmpDqllmqqlmmlllmmlmphlmmmpmm",
-"mmmmmqqnqturqtuDDDCDNODCOMNLOODCHODDDttOIDOOOqDOONCqtDOOqtuqqpnmqqpmmpmlrqqqmlmqmmmmmmqrimmmqqnqimlhmmmliihmmmmmmjmmmmimpqpppmmlunmmnmiimmnmmmmmnnmnmmmnnnqqqmmmjjlmmmmilililmqqmilnmlmmqmmqqmmpqqqqqpmmmlmmqqmlmnnmnruuuruuqnmnqLplllmlqqqmmiiqqmlllmqDIDtmlmmm",
-"mqpqpmmmmmqqtDMOmpmpmpmpztztCzqqqpqtqqqqpqCDDpptOODCtqCDqqmqqqpmmpqpqquqpmmqqquEqqqquqmmmnmmqqmmmqmiimmmmieimqqquqquqqqqmpqpmllpnpnqqqqqnqqqnnmqrqnnqnnquqqrqmilimjmmmmjlilmmpqppmptqqqqutuDutqqqqpmqqmmmmmpnpmimpmliiiijmnqmimqlCmpmptmqDDqmmpmllqDDtqqpqqttttq",
-"qqqqmmmpllilmqqqpmpppqqpppqqppqqpmqHqqtpmpqDDqqqtCDCtqtDDqpmqqqqhilmmpqtmmmlmimmqnmmnmiemqmimmihmqlehihiqliilmmimjmmpmmmtrtqtqttnqrrqmiiiljmmmmmmmnqqnqqqqqqqqmlmmljmmmpqqqtuuuuqpquqqtpillmmlllqmhehlmlihhhhiedaeeeeiimdeiiiiiihllmqqDqlqDqpqqqpqqqtqqtpquDDDqq",
-"qqqqpmpqqmmmmmmpqppqDLCqpqmpmmtCDptDqqqmqqqtDtqqpqqpmtMWODqmqqqmuuDtqpqqutqqqqqqIuqqquuuimpmqnmqimmimlimmlheiihedehjiilmhedhhhhhlmmmiheeddddddeeeeimmmliiheilmmpjiiiiimmimqqmlmplippmmpicdehhhhdlhddeehiiheiilllqqqiheedmlimmihehlhpplmhhqqpimmipmpqqpqqtqmpqqtD",
-"mmmmmmmmppmpqqqqpmmpCDqpppplmpzLDqqqppqtCtqtqqpmttCtppqtpmpquuqmllllhedhihiiiimmiljmmmliiqqmmqqqmmpmqqmmliiilmmiimmqmiimliklmpmmimlieiileeeeeddeeeinqmilmilillmpijmmmmmmhlmlihhihhllklmlhlllppmmiiimmllihiehhiildhiilmqqqmmmpmihdlhmplpimtqlilmihlpttqmmplhillmm",
-"hhhhhhhhihlillmmpmppqqppqqqpptDDDtmpqttEtDDtqpqqqqtqpliiilmqCDqmllilmlllrqmpmlilimquqmhehmlhiiheililmihhimmlmmqqmmmmlihiililllllurqiheieimmliiiiiimpqpmmqpqpmllmjmnnmmmmmqqtpmmqllllllplhllllpplpqqqrqmmhhhehehelmplillmmllpqpppmmlqDqDqtqqmmmmlmliiilpDDqmlkedc",
-"qmmmppmmqqqqmmlllllihhilhhhhlllllmliqlelhlmlhhilmlihhilpmllmmmmlmllmqppqqpmqqqqqnqqmihimqunmmqmlimiimleeelmieimqiiimnqqqlmmpmlllmmmlmmmmiliiiiimlimqqnppmmmpmllpmmmmmimnlmmpmmmmllplllphllplmpppuqqqtqqmqqquEDuuDOEtppppqpqqtquDOOqDCqqlmmmpqqpmllllpllmUtlkilpq",
-"qqppqqqmqDCpmqqpmmppppmmppmmllmtqppqpmmllillllllhilpqpqtqpptDDttquDIDuqqqquvuuqqpqqpmqqpuqppqqqmmlimmmilmmiimplhmimqqmmmqqpqppppnmmlmmmmpmmpmllilmqmqqpmmtqmlpplmmmnnmmilpqqmlmpllpppppqppqCCtqpmmmmpqmmlqqmqqqqmmlmmpqqDqtDDtqqODDqqqqqtCDDDDOODDDCqqtCCCLPODqt",
-"OMDDMNDDOODuqqqqppqqDDtqqqtDDqtCDqqqqppqqppmqqqqmmpnpmmpqqqDODOOODCqqqqquqqqqqqqqqqqmpmlpmmmqqqqIuqpmllmuuqqqqniqmimmliiiillppqpmlilmmmlrpmmmlmqmqqqmlillllhhllhiiimmmieiihhhilphlpqzCCCpppqzpppihllmmliimpmmmilmlllllmmppqDDqplmpquLDDCqqqCqqCDCLDCqCCDMNDNLCDL",
-"ONNLDLONLCCCDLDDDCDDLNLDNCCqqppqqutpqDDDOEDuqqqqqtqDutqqptDDqpqCuqmmppqtqqpmmqqqllllmpmlmpqqqqqtuqnqqnmqnqqmqqqqrqmmmmlmqppmmpmlmppqqqqqqqqqqqmpimqmiiiiquqpmpmhmmjmiiihliliilmmhhlmommmpmpppmmlhiimmllilqqmpmlmlmilmmmqmnquqqleilmqqqqmpmlmpmqCqCLCCDLLNLDCCCKO",
-"qzDCCCzDCmpLUOLNUOLDCDLOLtmppqppqCqmpDODDHDtqppmmmqqqnpptDHCqppqDttpmlliiiilmljlllllpqplhilllklihilmqqqmmpnqquuurqqqqmqqqqqtuHIwDuDuDDutqquDuqqmquurqqtqqqqppqpmrqqnmmiipnppqpmlpmllhllpmlmllllllmpmihiimmmmqqlmiiimmmmmmmpimmmiiihhililmllllllmpCCCCCLNCCCLDCDL",
-"ptDDCqCzDqCLULCztDDCmpqDppqNUOzpqDDpmqtmpqqqqpmpqnqqqpmlmmpppppqpqqqqpqqpqqqqqqnmllllmlhlllilihhiilmmmlilmmmlmmmmmmmmqqqqqquIIIDODDqqqqntqqppqqqqnnmmmmilmpnqquurqqnmmmmnppqqqlillihllmpmmlllilhnqqmihhlmmiimmhelilmiheeiiiiimqmmmpqqqtuLDDLCzqCmpzqpqCqzCLDCCCC",
-"mpzzqqqtztqDDCpmlmCtpmpqCqtDLDqptDtqpqpmmpqtmmlmpmmqqqmmllllmpqpmppqtDIOEuuqqquuuuutuuuqqpppqqqpmmmmmmmlimliiiiheimmmmmmmqpqppppDDqpmlmlmmmlilllqqmmqqqmlmppmpqqmnnnmmnqpmmmpnpmmmmpnqpmtqqqqpmpqqqmlimmqpilqmihmiimjeeelmjlmmmmdhiillilmllmplllpqCpmompCDCppppp",
-"pppqztzCqCCzCzCqpqzCCtzCODpppmmpqqqqqtqttqtqqppqjmlmqqqqtDDttHDtODtqqqqpqqmmmmmplmllllllllmmlllmqqqmmqqqmnqmqqqqmmnmmpnpehllmmquDuqqqqpmhlmmmmmhijjjmnmjmmiiihhhiimmmnqrqqqtuDuuEHvDIuuquuuturtqqqqpmmqquqqquqmqqmmnmjmnrnqnnmmjqrturqqtqqqCLLKLzCCCpqCCNLKzppzp",
-"LDDDCLOUNUODCLOLOLDCDLNOCqzqCqtqDttttqtDmpqtqtEPIDuEEDDDqtCqpqtztpmptDqmmnqqurqquutplpmpmppllhlpmqqqquqmmmmmmmmjqruqmmmmmmmlllptuzutuuqquuqppqtrqrurqqqnpmmmmmmmimmnmqqrqrDOOOIDurqqqqqqqqqqqqqqqmqmmpmmmqmpqqqEErnnnmmqrqnqrqnuqqqpmqtDODzCCCzCCNLLCTUUNUWUNUUN",
-"nDDmpDLDMMLDUOLUCNNLNUUCLKNUNLKNCNULUUULNCCCCppBOErqpqqqmuummqutOuqruuuuIuqqqtrtqrurrquvuEJuqnqqrrqrurqqnqnmmmmmppqpqqplpppppptDKCKKKKCCyyKCCByytqpppqttpppppppppppppmmpqqqqqmquvqqnnqqnnnmnqnmmmmmnqnmmmmnqqqqqmnqqqnmmlqtllllolqCqpliqpmpqzpllmmtqpqqCCDCpoqCC",
-"mmmmmmpqztppCzpqplpCCCCyppsCCpqCpypppKCsplopypppmmmmqqqquEIttuDvEuuurqqqqqqquqqmimmmjjmmqruqnmqqmjmnqrrqvuuqnqquqqqqtuqpllmmlmptKLLLLSTSNTTTKByBqpmlllmppqtuDtttKLLCCqtztqqqqmqqruqqqnnnqmmmmmmjmmmmqmmiiljmmjiimjmmmnpplqppoppCqCqqqppCLCzCDCqqOMDDzqqqlmqCqplk",
-"DrCDDqzDDCqzLDqCDCCLLpptCqCCCzCCzCCpCNLCCzqCCCzqDDDDDEDDDDutqqttqpqppllmlllmpplhmjmmmmmmmmmmljmiiiiimmmmqqrrqqnnqqqpqqqpuuutqqqqCKLLKCKKCKTKCyCKDCtqtttqqCDDHDDDMNLLDLDOqqmmqpmmnnqnqqqnrqnnnqnqmmmmmmmlmmmilllijijmmmqqpqppqspCLDCzDLDLVNDDLDLDDDCDDDCqDDNCCCCq",
-"nqqqzqtzDLLNUOLOUONOKqqCLCCLLCCCHLDDNUUNLNLLDCCCUIDtqttqtqqpmllmilllillmlililmlljiiijmjimmjiiiifliiiimmmiimmnmmjlmmimmpmqtqqpmppzzCCppmppyyyyoyCtqqpqqtqttDCtqtqKKCzCqDDqpmpmmlmimmnnmnqqqnqqruruuuuuuuqqqpqpnmqmnqnpnpmqpmpColBDCpmCDCDNLCCqCqCmpmqqCDCDCqpptCC",
-"immlmqmlmqqCDqpCpzzpmqCzqmpqqqnqqqqqzLDqqqCqmmpqpmlimmpqmmlmlillmliilmpmtqmllmmqiiiiliiililillihiiiilmmmqmiehjnqlmmmmpqqhmmmlmpmqqzpmllmCCpoooollllooolopppololpqqppmpqpmmpmliimilllilmmmiiimpmpllllhihlpmmmmpqqqqqqqnmlqplptmklqqmlpmpqCqqqpqppqqtqqppqllpqCqlk",
-"muqmmqqihllmpllpmqqilmqmliimmppqilmmpmmlqqqlihiilimppqmplllllmpppmlhlpmlppmlllihmmmmmmmmiiihilliiihiiiiiqmiiiimmimmmmnqqmqtqmppmmpppppplypllomolppomplolplolllppppmmppqqmmpmliimmmmliillmllllmmlqqpmpmppmlllmpppnqqrqpmilmppqpklpCplpppCqCzqpqpmpqzqmlmpllpCCtol",
-"nqqmmqmlmmllqplmmpqpmplimllmpmmqmmpqpmmmqzqpmpmlmmlmmllhlmmllpplmmlilmmlilllilhlimmmmiiliimliimlmljiiiiimjmlmiieijmlmmmqqqDpmmmhqpmmpqppplompppppolllllkppppppppqpmpqqppmpmpmlmmppmmomllqpmmpqpmpppplllmppppomlpmnnqqmmlippmppllqqpmpqqLpqCqpppmlmmpmmmpqmllllll",
-"qmlmqmmmqqlmCqmlpimqDqlmmlilmmllpqqqmmmqilmmDMDqDqpmlllipttmmpmlmpqpmmpmllllmpqtmmqqmmmmqqqqmqqmmmmnqqqnmmmmmmliiiljimqmmuDqqtqqDqqtqCqmpqtppopppppppspqppqqppompmpmpqqmpmmqqpmppmpqzqpmmmmpqqqppqppllppppppmpolqqqqqppmiqplolllppllpqqCqCzpmmpmillmpqpqDqopppop",
-"qnCEqllihlpCCplmqmlmqmmqtmmpqmmqimqqmmmmlnmlmpmmilmmppqqlmmppmptqquDttuqqpmplhmqqmmqmiiilmmqmmlllmmmpqqupqqqqqqqmqrqqqqrqqqqqmqqqpmqDOtmtHDplttplppppomoolloppmlqqqtrqqqqtDqqDDqppmomlmllptCCzppppllpplllpppplmpqpmqDDmllmqqqqqpmpqmpLLmDCqCqqqCuqmpqCqpqqpptDCp",
-"ODDDqqztDzqDDDCCDDDLDqtDqqpqqpqqOqmlmpmmmpmmqqmlqqqqqqpputDEDqppplpqqtqppmlmllmtmiileelmmmmmlhhimmpqmlihiheeddeeeeiiijmmqqqqqqpnqqqqtDqplqCqpqplopppptCCCCCCCCGCDqqpqpmllmmlmpmmppqzCCCDqyzzCCCCDDqpCtppDCCCqpppqqDDqlllmpmmlmppqmllipCCqppppppzOOMDDqpmCppCCppt",
-"AqqmlmCmDqppzqqqlqLCppmpzCCCCDCCOzqpmmDUqCqqLDqmpqqCqCqzqpllllmpmllpqzqlDCtDDtCDtqDODuDEuDHDuuuHruuuuqqqqqqmpmqqmnmmmmmnmmqqruqtquDuruDtDDutqtDDqtttqtDDqqtCtqtCEuqquDDqtDDtCDDCqCzCCzCzppllmppzlllhllilpmlpqCCtMDCDODDtqAttqDDDDpqtppzDCqqzDCDLqDDDqpmptmptCmpC",
-"DDDzqDDqDDDOOLCCzNUNzCCCpzzqpCzpDCDqlhhqmqpmqpmmlllmppmpDqmlptHIODLUNOODCqqDCqmpmhlnpmmlhimllimpmpnqqqquqqquuuuururqqqmmeehmpqmmillillmmqpmmompttqqqpmppppppppqqqpmpqDDDqzCqqzCqppqpppmllllompmlpppptCsthhghllppmhhlqqmillmmpmmlplpzqqCzDCCDLDCDpqDDqqCDMNDLNHKO",
-"DDMLDLMmzLUYUOLOKNTNLNNTNUYWTUYUUNLUUNDLCUUUNLNNVUOUULHDDCDHODDtllqqmmpmpllpplilqlillmpmlmpqmllmlmlihillhhllmmmmqnqqrqqqmpnqqqpmiiihimmlilmtqplmmpqpqppqmlilmmplmmpnmmlmmpmllmplppqCqqpppppqtCtClpmpqqqqtqpmlhihhmqqmlilimpmlihhihhehpDppmmpplllmpmmmmmpCDCtCLNC",
-"nnpmillimqqCqppDBpoospypsCGCCCCCppppppqClCLLDtmpCqpqCqpqlmpmppllppCDpqCCqqqDDppqqiilmqqipqqqqqppmpqqqmmlliiilllmmmnqqqnmqqqqqtqqurqqquuqpptuuqttqtutqqqpmllimpmlqqutqpmqDDtCqCzCqCtzCtpptqppmpCDqtqtDDqDttqqpmllllmqpmllDDCqqtDDpppllDLlmlllmlhhiihhhlhhlplllCtl",
-"qmqqiilmpqqCpmqCBolBBooBBBKCBoBKCUUzhghhpCCCCCppCpmqCqqClllllmppmmqCpqCqtpqCqppqqmqDtDtmqqtquuDulmpqqpqqppmllmmmpmmljliihihiiilmqqmmnqmimmlkilpqtqtqqpmptqqtqtqqqqqrtruDCqqqpppzpppplmplmpmlllpCilihlllpilmpqtqqqppCOODqztqpmqDLDCLDCLDptppqCqpmmmpqrCtqpqtqCNKt",
-"qqDDpimpqqCDCtqqCooKColyCCBCBosCpKColppkCKplpCppUzpzzppqlpCtqtqpDtCDtCDtzqtzplmpqpqqlmqqtqmmmpmmmpnpqquuqqqttqqprqmmmmmmmmmlhilliiiiimheeiihhilihiiiilmmillmliliiihhimllmmllllllhihllllpllppmlpqlmlilmmtmllmqqmhllmpmhlmqqqmlilimilllmDUzqqDLDzqqDDLODCqmppCCtCL",
-"LDLLDtqCLDUUCqLCLCqttqptDDCDDtCDqCLDCDOUDDDCDLLDuDEHuqqtDOEtqCuqtutqqqmltmlqtmllimmmimqmiilliiilnrnjiifbmnnjjjjijmmqqnieeeeeiiiijjmqqniiedeeehiihilhlilhhhiiliedheeehiiiiiimmmmimiiiheemllmqmeellhddhlliihimttqmpmppqqmllqpmplhpppllhhlmllmpqppqCpmlllqNqqqCLLDC",
-"tqpqqppqpmqClmNVqpppmpmpDCtCttDNLDCqpqpmpqCDLDCmDqqqtuqpmpqmpmmilmpqtqtqpmlppmmqpquqqqpmlliihiiinnmjjjnmfiiffiffmjmmmmjijiijnqnqqqqnqrqqmmliiilmqpmihlmmmmpmpmlleeeiiiiiqmimmmidaeiqqmqqmmpqqmpqLqmlmppmtplhheddddddhlhhhmhhihhipqqqqpqCilpqpmlplllmmlillllllmpq",
-"ppmplillllqDmlptmmlmmllmmlillllpCplilmlhllllpCqptplmpqqnhlmlmtpmppqtutqqtqpqpmpuquuqqqqqrqqmmlpmmmmiimmmifihijmmjmjjiijmiiiimmnnnnnqnqrrEurtuDEPqqplmmpqpmpqqqqmnqqqrDuujlimqqrrqqDEDmiihlmqppqqDqppquztqqmmmmpqmlllmpmlCDplpplhhhlllhhghlzDqllmpllllmpphlpqpmpq",
-"qqqpppmpllzDplhdkhhllllltpllllmpqmllmpqmmlhlmzDCmqqpmpquqqppqDDuqtuutqqquqqpmmpqqqnpmqqquutqqqnpnqrrrrqnnqqnqqrnmmmmiimniieeeeiieiljlijmheeeeillqqqqmlieihiimmmmqmmmqrDErurnjmmqjmmmiedeeilliiilehhlmmmlmpqqppmplmppppppmqqqCODpqqqqqqpmlmtDCpmpplhhlomlDqplhhpL",
-"ppqCCCDCCqpppmmqqqqqtpqqCqpqtqptDLCppqtpqCqCDCqlmqqqppqtDtqmpqpmpmmmmmqqqmlmmmllillmmmmmpmmmmliheiimnqnquuurqqnmmnrnmijmiifeeeeeeefieeiijliiheehehilmihhdeddhhhhihedehilqqmmleeeeeeihhiihhlihhhdddddddddddhhhededkmmlilmhlllipmhhhhhllmppmppqpmmCtzDOOCpqqqqqmmp",
-"mpqpmpmmppiimppCzqqCzqpqplmpqtqpqCqmlllipmpllmlhmlhlmpmliiilllheiilihilmliilpqpmiilqqmliihillihdeadddeeiijmmmmmiimqnmifiiifeeeeeiieeeehieeeedede#.#dhilmheddeehhhiehehedaddiqqldiiiiiliidhhhihhhlihedhhlehihedhhdipmhhhllllhdhlhlhhhhlmpqpillhhhhhhlpzqpllpCDpll",
-"ppplihlhdiklpidllhhhhedhlllqtqqpiilhhihhhihedhlmlihilmlhehlmpmllmmqpmlmmqpqqtuqqpmqruqpmmmmmqqmmqmmilhilhhiilmppmmnmmiiiiiiieeehjiieeijjhfhehiimllhihdddihhehhiieeheiheeeeimmmieadehiilmhehllhhlmmmlllqqDDqmihddhhhhdcddhdilhlCtilhhdhhlCplhhhhhhhdhlqDCmhdddhmC",
-"mpmlhppqlDLOUCtUqmlllhhlhhhmqplhlllllmliimpmllllppqpmlmpttuDuqtqtuEIvuuwuuEuuutqvuquuuuvutuuxIxuuttuutqtqqpllmmmqrqqmnqqqqqqmmmmmmjmmnmlnmljimmmmilmmiilihehhlmpihhiimmphlmlhhipqqmiimmmlhlpqmmpilpmmliliihihhhhdhdhhilpqhlmhhlehilllhlmCqmlhehlhllllllehhlpqmlp",
-"lllllllllpqqplmmzLLqqmpzqtCCCCDDDMOMEHDDtDLHDqDDEEDuuDEIOOEDDDtqqqtpmqurJIxvuuuutrtqquvIuuqqqqnpqtvIIIuuuuxutqtuxvxvxxvvrqqnqnlinqqqmmmnmqqmmqtmpmpmpmpmmmpmmlilpmimpqmimmqpmlmmnlilmppqqppqtqmpmpqqpmpqppmllmqqqmpqpllmhpqplpqqlllmlmmppmllllpmpppmpllhlllpqppm",
-"CDDDCCzCCCDLCCCDCLLKLLDUCDDCqCDLDtCqCqqmqtzqqqpqtqqqqppqqtqqtqmmlmmmmllilmmpqrtqmmqqqqqqqqqqmlllpmlllpqtutmpqtqmurtrqqmmqmmmqqnmnnqrnqqrmnqnqqruqqqqqqqtqqqqmpmqmpmmqqtqqqqqqqpqqnqqqqqqtqqtttqtqqqqpqqqpmpmpqqDqppqqqppqCDCqCCDDDDNDCDNMNDNDDDDCDDDDLDLCDDDCDCD",
-"zCCCDqCtztztqzCCqzmpzqmmmmpmmlptqmmpqqqqqqqqqqmmmppmpmmmpmmpmmpmqqtqqpmmiimnqqqmmmmqmmmlmpmmlmljllhimmpqpmllmpmlmmmmnqmmqmmlmmqmmnnnmnmnqmnqmlmqqppmpmpnpmmlmllmqqqqpqqttqmpqqqqpmnqqmmqmlmmmmpmpmmmmmpmqqmpmpqtqqppCDCqqtztzCDCtqtCzqpqtqCCCCzqCzCCDLLOCDLDzqCD",
-"ppqpmlmmlllllppmzLzqzpikhlllllmpmmlmpqqqqqmmqqqmpmpqqqqpmppmpppmqqqmlmmpllmmpmilmpmmlmmmmmqmmilmllillmmlhilllllmmmmmqqqnqmmjlmjlmmiimjlimmmmmmmmliiiiillmmliehiltqqppmmmmllllmmpnmiihhmqqqttqmllllilpqpmpmlilmlmlpmlmztmlllmpqqpqpqztpmplpqqqqqpqqpmpppmlmppplpq",
-"qqzqpllpllmlmpqmpKzzzpmpmpqqppqqpmlliliiqpmpqqpmqqqpmpqpmpmpmmmpqqnmmmqqiiiiiiiilmmmpqqtmqqqmiiiqmheehiiiimmmmmqqqpqmmlllmmmmmpmieeimmmmimmmnuqmillhiliiqqmliillqqmpmplhhhihhhlmqqiieimuDDDzpmlllilmqqpmllhhhhillmllllpllllmpqpqqpqCqpppmmppppqqCztqplihlllmppmm",
-"qCCqpmmpmqqpqCzpmzzzzmlmpqCCqqppmmmlllilpmlmpqqpqqmmlilmmmmllllinqtqqqqqmmiiililmmpqqmpnmmqmmlmmqmmmliihmlilqqqmqqnqqqmmmmpqqqmmmjmmmnnmmqnmpDqillimllllqpmlliimmllmqqmihllmillpnmmiiimmmmihhlpqmmmpqqmliiliililllmlllllpmlppmpmmllmpmmmlllliillDCDCqpllmmppqqpp",
-"pqCqplmppCCqpqCqLLLzLCmpmlmmpppmlmpnmmmqmmmmnqqqqpliliilllmllilmmqnqnqqmurqmpmnmpqqqpmmmmmmpmqqqmquuqqmmnmmmqqqmmmmpqqqqmpqqmmmimmmmmmmmqqqmmqmillmmmmmlilmllllllllmppplllpmmmpqmjiiihehhihhiqrCmlllilihlmqqmlllilllllllmlllmlllpllmppppmmpmlllmzqzqpmplmpqqpqpp",
-"qCDCqpqCqDDpmpzqKCzpLLpmlillptzqmpqqmllmqmpqqquummmlllpmmpppmmpqqqqnmqquqqpnqqqqqmmmmmqtutqnqqpmqqqqmmqumnqqmmmmmlmmmmmlmmmmmlliifiiimjmqmmmqqqummmppmmmlmmmmpmpmmmmllllmmmmpppmunmiiihiiiliimlhllhhhhhimqHDqlhhlgdlmlhhlhhllhllheghililllmlllllplmllllmlpppmmpq",
-"hlyyzKmhlyyzyKKKCLKKCCDLttqtDMONArADEDqDqDttDONCODuuDEuuuurruuqmrrrrqnnnnmnnnnmjiiliiimmmmqqqnnqqnmjmnnnmmmjmiifhiilmmiieiiliihhfeeflmmqquutpttpimqqqmmlqpmqqmmqlplllmllpolllopshlmlhlllmllllhlmpmlmptqlllihhhhlehhlpCqlhhhhilqzqttDtpmlhppmlilqpmllmllpppmpppll",
-"zKSLKSKKzKKSLKSSNTONLLNLLDDNDHDuAqzDzqqqCqtqCNDtqnqqqqnpmmqqmmlijiijjjjiiifiimmmmiiiehiiiiimmiimjjiiiiiiiiiieeeieeimqqqqilllihedeeeimmpqxupqwIwsHDDDEIOIDuHEHuDIqqtpqCCpppsspoopLqppqqplpmmppmlpmpmlmpmlmpppppmllmpmlmllmmmllllmlmmmmpqqmmllpmlmpmpppmppqqqqpmpm",
-"U0YYLDKCUSUTLLLLLLLLCCqplllmpmllmmmqqqqtmpmlppplllmmmlmmmmqpmliliifeiiiifeeeijmmmlieiiieliiiiheihiiihehinqqmiiimiimmnqqqqnqqpppmnmmnnmmmqtqqspttqpmpqtqpqtDtqqqpzCCCNLCpCLNLCCCCLCqDCpmqpptDCtqqqqtqpqpptqppqqppptCqqqDDCDDDDCqtCtqqtqDDCuqqDDqtDCDDNDCqCLOLDNU0",
-"hllppypzKDKzCzypCpppplihmpqttqpmmimmmmlmmmlmomllmlmmlmllmpmmlilimiiijmjiiiiiimnqmmiimmmmmmliieeheiiiiiimmqnmmimmmmnqqqqqrtuuuuutuqnqmmiilmlkhlllmllmqpmhimmmmqpipmmppCplppppolpCmpCqmllqpqCLDDCCDCLqzCDCCqpqpppqqpmpCLLDpqpqpmpppmpppmmmlqqmpmqDCqpqzqmlqqpmlihl",
-"hhhmpplhllllllmlppmlpllhmmliheddmmmmmhedhlllllhgllhkllllmllkilkhmiihiilimmmmmpmmmqqqmpqqmiiihehiimmmmmpqmmmqquqqqrqrqqqqtqqqqqpmnjljmllmmlhdlwsdhhlllihhdhhhptqlmlillmmlllllkloplmlhltphlmpppqqzqzppqCqqqpqqpmptmlillmllCCtqppqqhhhiiiliimpmpppDDCCzCCqplllkhhhh",
-"pmopCqlhllllllkhlklllpmlttqpmlllqqqDtnlmllmppllhqplmpppltpmmppppmpmmpqqqttuutqqqqquqqnqqmmlmnpnqtrtqqqqquqquuvuqurrqnmnnmmlmmpmlmmimmmmqpqpltIHplmmlihllmllmquplqmmmmomplpppmllllpmhlmphillillmpmpllmpplllpqplllllplkhlmllhhhhllmlihhllplmilqqmmhihhhhllmllmpqpp",
-"hhhlqqtqCtqpqppmlmpppppqIDDutqtuDDDMODDDIDHOOututqtCDDDCDDHCDDDDuDDuuuHIuvHIutttruqqqpnqqmmqtruuuuqqqqqqqpmmmlihqqnmmillllllmppmqnmnqnqqmqtuutqttuHuuuuIuuuwDuqqDtqtqpqulllmollhlqCpllmppqqpmlmlommmlmllpikmplhlpppmlhltomllllpqqmlihhililhipplhlmpmlpqpqpmhhhhh",
-"ODqtttDNDDDHOOOHLNODDCDDUWPODuqtVUMODCtDtqqtqppqptNOOOONtDNNNCDHDIOEttDOuwDututuqqqmqnmlmmlmnqmmqmllmmpmlillllmmiilmimmqqqpmppmlqpnqqqqqplitulhlhimppmlmpmmtqppqCDDDtnqCDttqCHDCDqqqCDCqDMNCqtqpmptpllliNmhlppppplhhhhllqtppllmpqqqqppmmmtDtDqmpmqCtqqCDzCCtpqDU",
-"OHCtCDtqtCDCqtqCtzCLDDDHEDDDqmmqDDDLOEqpmpqqqpmmllpDNCtNqtCttqsppqqpmpqIpquutllpqqqqmlmpmlmmmlililmmihiiilmpqqqpqqqmmqpqmpqtqtqpnmpqruqnqmmllmqtqplptqphlmqtqqppjmqAqilqLqmtqqCqqppqqqpmtpmpqCCtpqCDDDtqtCuqpqDOttuCtttIttttttttDCuDOVOOHMLMUMDMHLNMNNLOLLOMUULC",
-"CDCtqttCDtCtqqtqCqmlmmqDDuDtqmpqOOOUUODqtqqqqqttppqHDqpCNCqplppqtDHDtqtDttuDtpppqquEutqmqqqqtqpqpqqqqqpqmpqmqqqnqqqqqnqquutpmmpltqqquuuuqpqqtttqwttuutqquHIIutqqqqDDAqmtDmpqlmppDqmlpqqpDzppqqqqCqqqpqzClpqtqppqppptttqqpqqpqppmqmmpnppmqqqCODqCppqCDDCLDLNDCDCq",
-"qDILDqDEODqqppmptqqqplmpmlmmqmquOOVWXOODDIHDuuvIDtCDNtpmpmhhhhlppqDDtqtuHDIIuqqutttqtqqqtqqttqqtnpqqpnqqqrqqqqutrqqqqtqtuuuqpptqqqqqquuuqqpquvtqmppqqqtuuDHIIuutrqquunqquqqtmmmpODqpqCHNDDqqpptqDCpmppqClmptttqqpmpqCqppppqqqpppqqqqpqqpqtqDODpqDqzLLLDDCDLDCCDD",
-"tDDDqpqDDtpllilhhhlmllhhlilmmmquLNOUONDDDDDIHDDuNDDLNDqlmplllllmntDEIuDIIIOIHuuIOvttuuwutqtuuutuuurqruurqtrtruuuqtruuuuvtuHuIIutqqmpqqqtuqmmqqqntqqqtqtIqtqplhhdmmmqqqqqEDDEDttqCttqtqCDLHDCqtCDLCztqzDDqpqqCDDHCtqtCttqtttttqpmppqqqqCDqzCDMCqDLCCDNLCzDLNCzDLL",
-"qqpmllmpDqmiilhimlmpqqqEqmmmmlmntDNNDtttqqttrtqqtqtDEDqlpmpmmliilmqtqquuuuEIvuwIttquuHtpttuuDutuuuuuurqqqqqqqqnmnnpqqqtuDDEHOHtpuuqqqqquuqmlimmpupppppqqpmpmpmllnmnnrrruDqrODDqmqCNDttDHOODDCDDDDDDLNLNDLDttDDHHCDLLDzqqpmpmmllliilllmmpimqqqpqOLCzLOONNOODqqCqp",
-"qqqpmqpqqtqqpqqqlmpmmlllmlllmmmmptCDtqqqqqpmpmtumqqqtDqililiillllmpnmmmmqqqtuqqummlmppmlqmptqppmnnnmmmmijmmjimiiliiimmpquutqquqpuqmmmmpmqqqmliljlhdhilllllmpqttqjimmnnmmqlmqqqplpqDtmlqDCCtqqpppppCDDCztDCDCCtqpmpDULpllhhhhllmmlmmmmllilmmlmlmDCqtDLLDCLCzpCCCq",
-"CqqCAtAqCzDDDDDLttuDtmliliimmmqqppttttqpqqnpmqqummmmmqqmmmmmpnqqqqruutqqmmqqqqqqtppmpqtqpmllllllmqqqnmmmimmmimmjlllllmqqpqplppsqtmlhmmmiqqqmmimmlhhlppmpppllihegjmmnmmmmnmmqmmnmlllkhhllqqppppmlmmmpqppmqqtDtppmlmqCCmliehhilmptqqpqqqpmpqmllilqpmlpmllippqqqDCq",
-"mmqqqmmmnqDDzqzqqpmlmlpqqqqqqqpqpppqqppplmpmpmmpnqpimqtmpmqqnmliimqqqqnqmmmqqmmmllmpqpmltqppmlmpmnqrqmmmmmmjmqrrqmmmmqtumqqqlpptItmmquqmqqmmimmmqqpqqpmlppmpptqqnrururrnuqqqpqtupptqqpppqppqtutpqqpqppqpptqqqqpppmlmppmltqpmlllmmlmpqqpmlliippmtmpqztpqCmqqpllll",
-"hlmppmllhhlillqLmlmtqlimlqmmpmmqpCOUNCqtuHODttuItpqtCtttqtqtttppqqnrrruruqqruuqqqqqqqruuqqmmpnqqmqnmmmiimmiliiihhilllmmmqtqqmmlljimmiiilmqqmllilmllllllltqpmmmpmmliilliihihlqtqDDCDDCpmqtqqtqqtqDCppzCzzzLLCppzqzCDCpqCLtCDCtCDCturuDDuqtDqqDLCqCCCCCDCqCCqpppqq",
-"illllllllhhlllhghilqqliilmpqqqmptCCpmlpqpqtqpmqqDtpqqqqqppqqttDDEDuuqqqqqqrtqqqqqquuDIDuDuuuuuuDutuuqqqpmmmmmmmmppqqquuIuuuqtqqmqqnmmjiinqqmpqmlpmppqqtqtututttqqmqqnpmphihmtqpqmllppmplpmlllpppqpmpqqpppmllmDCplllmtDDCzCzqmpmmmmljlllimqpmppqDKppzCpmpqpmmlill",
-"pmppmllhhllmtqpmlmpqqpmmmpilpmiilpppolllllmmllllplllmlppqppmlmppqqnmmmmmmqqqmlilmqqqqqpmqqqqqqqpmqmpmmmippqqtutqqqnpmmmpuqqqqqqmnnmmmmmmmmimmqplmppmppmpmqtuuqppmqqqqqmmqttDOHqttqpmpqplllpppllllmpmpmlllpmlllmpqpllllhhqCCqppppliiiilmmhmlmpmpDpplppllmllllllmm",
-"llppqpmlpqqpmllmllmlimpmCqmlmllpppCCtppmppqqqqpmpmlpppqtttqplpmmmmmmmqqqquuuqpmqpqqplmmqmmpqpmlmmlmmmmllnmqqqqqqqqqmllllmlilmmmlmljmmmqqqqpquuqplmpmlllllpqtqpmhmmqqmmlmpqmptqmpqqpllmldlllihdhhlmmpmlllmpplihlmhhhhdhlphhhdehilmmihilmphlhlqqlikhllllpmmllllmmp",
-"illmqttqCDLCqppqpqqppqqtOOCqtqtOTNDCDCDDHDDDHuutDtDHDDCDDLHDDONHDIHDtDDIDIOOIuutimpmlmqtmpqqqpmmhiillljmmmmmmmlimmllilmqmlllmpmmqnpmqqqpqmqtutpmtuuHuuuImpqtqpllmqqqmmmmlmllqmlqlplllppmDtplhlpqqtqppppqtmhltDqlghhhllquppmllpttqpliiihillhmCphghophlpqltpmlllmm",
-"ODtqqDLNtztDUUOLDLOMOMOMOOMOLqmDNNLLNCqpqtqqqqqpqtDOODDDqDDCDDHDDLHqquNDuuDuDtttpquqqqppqpqqqqpqmpmqnqpqqpqpqmmmilililmmqpmqqqqqqqnqqqqnllppmlllillmlllhlpqqqpppqnqqpmpqmqpqDtqtpppmpqttDDDDDDDDtttqqttDDtmtOOCqutqtIHtltttmlpppuqqqpqqqqDDCDpmCpCLtzNLtDDtqtuDI",
-"0ULCDLDLCqppqtqpDCqCqpzNLLCCDplpCCNNOLplpmppmommllqDDDCCtDCqptqlmtqpmqDtppttpplpuDIHDuqpuututuDDuuuuuuuuqqqqqtqqqqqqqpqqqqqqqqqpmmpqtuttqmpqtqqttqqtqppmmpqtqqpqqqqqqqqmpqmpqmpqqplllmpmpppqCtppCqpptqtttDHONttttptDWVHqHOHutttttttuDILOLNLOUCCOCLNTOLOLLDMOOUXU",
-"qppqCDCqmmpmmqLVUCpppmtVLtqzNDzOUOLNUODtuCutttuupqDNNCtDDOODDLDCtDNtptDDtDHupmptlllilpqmpmmmmpqtmmmmllilmmmmpmqmpqqqpmpmtutqpmmmrtquuvuqqpmpqttxtqtuuuqtuHIIHuuuqquuEuqpuqplmmpDOqlptttqHqlllqttppllptqppmpDDtplklptqpppllppppmlmqmpqppmppmCUCmpplpONppNDDDDDuqq",
-"qCDqqCDDNDDNODCCqtDDCDLOCDLOLDDCNTXUOCCCttDDDDHDHDDDOOOLDHNOOOONDOODtqtCuHOHtpppmpmlmpppppppqqqqpqqqmmqqqqqmmmmlqqtqquutJurtrutqqqqqqtuutqptutqlmpqqtquuuDIDuqtquuurpqqqqutqqtqqDCqqtDDDLHCtqtCDDDtqtDHtDppqtqqDutttttpqHOItqtpptqqqtqqCqCDKDzpCCCCLUDCqLUOtqttq",
-"tDLCqzCCODLLLCDDCDLDDDNO0OztOUUOLTUWUNDOCuDDuIEHDDNOUVOOOOOONNDDOOONDCDODHIDtlllqqtqtDDDtDDDDtqtuuuuuuuuqqtqtuuqqququuvuEuuuuuuqtqqqqqttppmpptttHutqqtuDDIOOOOIOJIIEuuuuDDDDtqqptttqqtCNtqtqtqqqtttqtCCqtttqtDHCtttDHutDtHtttuHuODuDDDDLpCCCKtpKCCzCCCDLDNDqqtDq",
-"DLDDztCDLCqqqqqqCCtzCCCCNCpCNULpsCDCtCtCqppqpptqpqtDHDDCDCCDDNDDDDDqqqtDuDHuqpppptqpqtqpmqDDtqqtuqqqqqqppqqpmmpmmmmmmqqqlmmpqqqquqqpqtqqqplhhllmpmllmpqputuDDIIDEuuurqmqquDDIDtqDLOHCtHVONDNDDHDCNONODOOCONtCOHqDDHODDtDDDtqtCDDIDCttqtCCLNNUTLWLLNUUNLOONDDDDDE",
-"qCDCtzCDDqppppppppppqCqqpqCCqpppptCCCpqqqpqmpqquqpptCDtppmmptDDCppppllmmpqqtttqtttqptqpllppppmommmpmpmiilmlihihhilllllmmililmmpmqmlilmpltqpkhhllhehilmliqqpqtqqptmqqpiipilmpqmllppqqllptDCqqppqtpqDDtCttDNDDtCqpqtDHCtptttttqttCtqpmppmpltzKNCCLpBDNLqppCqpqpppq",
-"ppqtqpqqCCqpqqqppppqCtpspCCqllsDoppqppplppmpmptDCqpmtCqpqpppqqppqrrrqqqpilmqqquuDDHDIOODIDtqpplkmpqqmlllillllmmmmmmmmmmptpmmlmlluqllmqpmpmpllllplmppmlllqqqqqqpmrtuvqilqqmpqqmlihlllhllptqpppllpmmppzCqmCqCDzpmmkmtzqqqqpqpqqCztqpppqqpolppCNCopCzppmlpqqpmppmpq",
-"mpqqpmmpqqppqCqmllpppqpqqqstCtCCmpppqppppppppquIOtqqCDtpttqqttqpqtuDuqqqpqqnqqqqtDDHDNHHNDppppmlmqqqpllmilmlmppmpllmlllmmmmllmmmtqpmpqppmpppllklppmliilmqpqqqqpmqqrtmllqqppqtqppmpmpqqtDCqtDDtpqtqqqLOLqCqqLDppCmpCtztztqpqpqppqtqppqCtppCLNTCopCCCCCpqCpppqqtqq",
-"ppqDCppqCqqpqDCppsqsppsCCszCLLqoNNDDCCDDuDDuuuOUUOOHOOLDqqttCCtqqnqqrrqqrqtrtqqqpptppppqqpmppppppqqqpmmlmmmilmllmllmmlilllllmmpqmmiihhhhpppllkkhllihhlmpmpqqqqmmmmpmmiiliehmqplmlllompqqqppCtqptpplmqLCpqqzCCCzDqDDCCCCqCqmppmpqDtqpqCCqptpCKsloppqCCppmmmpmqtqm",
-"pqCOLDDONLDtLOOCLNNLCCNUNNCCspsqLCppomppppqpmptupptqqppqppqCtqqtnqqruuuuqqqqqrqqipppmpuDpqptqqqpuqttutqqpqppmpmmpmmqqqpqqqqqqqqqutqpmmllqqppomppqpmpqtqqqtDDuqppqqqqqqqlmlltDqpplmppllmptmlmpmtMpmllpCCqlpCmmqqplpmpqDCqqmlmmpCOOHqppCLCpszCNLCNUCCzCzqqCLIDDOEq",
-"qDDDDtCqzCCKDCzyHLCCCDCqDCDLtmllpllmqttqqppqtqppqDDppqDtqqpqppptplpzppzqlmpmmlpqDDDDNOODpmlllhklimmmmmmmimlilmpqmqqpuqlmIumliililllmpqqquuqqnqmmmqqpmlihlmqutmlmmmqqmpqqqquuuquuuuqquuuuIIvuuvuxqutuDOMDDEDHOUODDHHDDNODCCtttDNLuDEIEEIODDDDMLMMCqqpqtttptCqpqCC",
-"pqtqqqqtqqqzCzppztqqCCqlpmpqCCDNpplomqqptpptDCuCpqtmmppmttqqmlilllpzpCLDDDDtttquONDCDNDtCtttDtDHEIEuqppqqqqmmmqpqqqqqqqqtqpmppqqpmmllpqqmqmmmmnmimpmlllimmqtqmmppqqqmiilqpqquqqqqqqqmpqqvutqqmmlmmmmqqtqqqqqpqqmllmllpppHODDDNIDqqqmpmmmqqqqquDDmllppqqtqplpqDtm",
-"mqqppqCzCpppzCBpmpqqqqmlCqppzLOLOLDDDDNLDDCDLCqqLOUONLDCCDLNCpqtppCDzCDCUNDuCutqODqppqqpONDDtqpqtqqqmmmmmqplllmmllllhillmlmlmmmmpplllilmmmmlmnmmlmmmmmmllmpmpmmqmmpnpqqrqqqquqqqqqmpmmmmtqqqqqqmppmllmmlqtqpmmmpqqtttqtqDIDtuDutuqppnppmmmilmmqpttqpqpqptqppCDtl",
-"uDqqpqqqDzptCLCpCDLNLDCqDNDqtDDtDDLCCzCDLDCDDzpppqtpppmlmpqqDtzCCCLNCqzpDCqqqqquCqplmpppqqppqpqqqqqqqqtqppqpmppppmqtmptqpppppppmqppllllmppmpnqqmmpqpqpqpqttDutuDquutqqqquqquuqqqqqqnqqpqqqqtuuuuIODuuDDupqqqqttquttqqqtttttqqqpluuqqtuuqDuDDDILDDDDDDttqCDODDDDu",
-"UOODDDDHCtpzCLCpqDDCqCqtpDLCqCCqpqtqppqCqppqCtpmCCCqqqqqtpmpzqtqppCLtztpqttqpqDDtqpppqqtCqttDtqtDuDDDutqquuqtqtquqHIqtIuuuuqqqqpqqqtqpqqqnqqqqqqqqtqqtqqqqutqqtqqqqmmmmmqpmmpmmlmpnpqmqqqmqmqqqqlmmmmmqpmlmpqqqmqmmmmpqqqqqqqqpmmpqtqppqmpmqqppmpptqtCCuqHODttLU",
-"qqplhlllqpppCCpplpqmllmplpCCqqppqqqqpqtDtpmqqqppmpmlllmpCqptCCCCppCDypqmpqqqpmqDqqqqtpqqDttCtpllmpqtuqqpuDutqqqpmpqqpqqtqpmmppmmmptqqqpqmmmqrrqrmqpmpnpmmppmpqmmlillmppqpmllllilmmpmqqqmqpmmpqpnqqtqmpmmliimqpmimllmmmqqqqqppqmmllqqpmlmqqtqutqqlmpppqqtpqCtqCHO",
-"DDtqppqtmppqCCppqCDtppqCqqqqqpmpppppppqCLzptzqqppmppmpqCmmqzzqzDCCNNCpplmpppmppqttptqpptplmqDtpppqqDLHDDqttqqppmpqpqqttumlklmplklmppmlmmlllqqqqqllmllmmlqqqqqttqqqmmmmmmqmmmmmpqpmqqqpqqmqqqruuuqurqmlihmmmqqpmmlimpqpmqmqqqmmqqptttqpppplmmppppttqqpmppptqpqqtq",
-"qtqmlmllpqCCDCzppzDCmpqqDpmpqqqCzqpqqzCDDtqzDCDLqqCqCCDLCNUVNDDOLCUULCtpqpqqttuuCqqttqDDLDHOOLtmDqCDDMDDtDEDuuuttuqpwDuOutqtuHuqilmmlllmmimmqnmnmpmmpqqpmmpmmqqqmpmmpqqtnpqqqqquqqtqqqqqppqqutqqqquqqmmmmlmqqmmqqqtuuqpmqquqnpqqttqqtttqppppqqtuDDDqpppqqDNDplpp",
-"qtttuDuDuDDNUONCCqppqDOUUDCDNDDDCDDCqqCLzCCCLONCCCpqCDLNLOOCCDLLNCCNDCtpttqtDIIItDCqtDtqtCDNDtqtLMLDCDDODDHLDutuDDuuDDOOVqtDDDOqqtqtqqqqtqqqtqtuuqttuuuDpqqtDutqpquwuuuuHuuuutuDDuuuIHuDqquHIDuqnquqqqquqquruvvuuuuvuqruuuvxuuvuIwuHIIwDIDuDOPODDUOHOMHODOUICtCD",
-"IIDDDDCtDNNNOUUNOLDCDLOUDCDLLDCqmqLLOLNLHDzpmqzqqqqCLOOOCzLOLCCDCCLUHDNDOODDuttqDDDCDNONqDDDtzCDLDtqqqDDDHDDuCuDtqqqqtDDDtqqmtDtpqtDtutuqqquuruuquqtuDtuqtuDuDuquIODuDIIIDuDuuDIIDDIOIIIIIIIOODuvxuEuvEIurqqqqqquruuutquvutqtuvJuuwIIIHwutqtIOIDtOODNNDCNOONDttD",
-"IDDuDwDCDDOOUUOULCqqzCDDXLtqCCDOUULCzqqqCLLDztzCqpqzDLLCzpzONqmzppCHpppplllmpqqtllpmpqqqmptqmpptppqCCtmlDCqpppttttttqtDHtDHtltODmmmppqqqqqquuuuutqtrCuAtqqqqqtqtDHDutDHOOIHDutIUOIHOPOOOutqqqqtttqqtrtqmqqqqqqqntqquurtqqquuuuuutsqCIHDDHuttNOOHLOONVODNONOODDCD",
-"qpppqqqtptHUONGNqpllqDDCUCmlmpCLLCmlllmpmCLLtzCLMLLLNLDzODCLLqqCCtNUCqtqDtutqqqpmppqtttpltDDtpmppqLOLzppqqppmpqqqtqppppqpqtpmpttqmpmmmtuqpqtqqqqppmmpqqqqqqqqtDDqqqppquDtuDuqqtOutuDDuDDtqppppqqqqqqqmmmmmmmmnpqmmmqqpmmlmqquupmplpttttqtqppqqppqtpptCtDDqqDCplm",
-"ppmpppolppCHNCCDCqpqCONMNDDLNDDCCDLLNLCqNMLCpzOYYUOLUUNLUUMLCLCzCtDUHHNDOOIDttqqttqDDDDDDOUODtqtMUNLCqDUpttqpqttqCDqptDDtppqtpmCDDDqqtuDmmmqqmmmlihillmmlllmlmqqmppmpquDqqqtpmpqqqpqtqqtqtqpmpmpmmqnmmjmmlilmmiilhllllllmlllmpppppmpttqtDCppqCqqttqqDCqDDCDODqmp",
-"qtttuuttDttDDDNWDCqqDOUULDCDNDDCLMNMLLDLLLDzqpqLpmlmmqzCpzCqzzqllklpmlmlhhklmptuqmlllppDttqplllmCCzCpmqOpqCqtttqpqtpqDHDttqtLtqDqzCDCqmpmmpmpmmmmllllmpplmmmllmptqtqquDCDDHEDtqDDDDDDDHOuttqqmmleimmiilmnnqnqqqqppqqqpqttqpqtuDuutuHOOHDONDDNONLDOOOUHCDOOUUOHCt",
-"pqquuHDuutqHNDCNCqmppzDLtmillllmhhhilmzLllmppihelhehhillmmllmlihlkopkhklllllllmpqlkhhlmplhhgdhhkmllmpllpipqpmqpphhhhhomilqlhmplllmmpmmllqmpqqpqqtqqqqqqquuHDuuDEuDDtuDIDOOOODuDDIHDIHDMODLIDttqtnqqqqqqqutruuvvvqtttqptDtttDDHDtCtDOUOLDCqqqqqqppCCttqpDpCtqppqp",
-"mpmppmlklllCDpolmllhlmqCpmpqqpmlhlqzpmllzppzLCzqLDzpqqpmDlillhhlhkmpkhmppomlhhlmlkhilhghllhlllmmpihllllphmpllppmhlhdhmlghtpdhpmhmlmllmpqqqqquruuDuuuuqpmmqtqqqtDqtqqtDOOuqqppmmppmmpmmptmpqppmmpurqqqqqnurrqrqqqllmplhlpDqlhklmlllpCDCplqqpppmllpqpmmlqVlqtliptq",
-};
diff --git a/sandbox/texture-paper.xpm b/sandbox/texture-paper.xpm
deleted file mode 100644
index 35f805b..0000000
--- a/sandbox/texture-paper.xpm
+++ /dev/null
@@ -1,87 +0,0 @@
-/* XPM */
-static char *on[] = {
-/* width height num_colors chars_per_pixel */
-" 32 32 48 1",
-/* colors */
-". c #f8e0d8",
-"# c #f8e0d0",
-"a c #f8e0c0",
-"b c #f8e0b8",
-"c c #f8d4d0",
-"d c #f8d4c0",
-"e c #f8d4b8",
-"f c #f8e0e0",
-"g c #f8e0d8",
-"h c #f8e0d0",
-"i c #f8e0c0",
-"j c #f8e0b8",
-"k c #f8d4d0",
-"l c #f8d4c0",
-"m c #f8d4b8",
-"n c #f8d4b0",
-"o c #f8ccc0",
-"p c #f8ccb8",
-"q c #f8ccb0",
-"r c #f8c4b8",
-"s c #f8c4b0",
-"t c #f0e0d0",
-"u c #f0e0c0",
-"v c #f0e0b8",
-"w c #f0d4d0",
-"x c #f0d4c0",
-"y c #f0d4b8",
-"z c #f0d4b0",
-"A c #f0d4a8",
-"B c #f0ccc0",
-"C c #f0ccb8",
-"D c #f0ccb0",
-"E c #f0cca8",
-"F c #f0cca0",
-"G c #f0c4b8",
-"H c #f0c4b0",
-"I c #f0c4a8",
-"J c #f0c4a0",
-"K c #e8e0b8",
-"L c #e8d4b8",
-"M c #e8ccc0",
-"N c #e8ccb8",
-"O c #e8ccb0",
-"P c #e8cca8",
-"Q c #e8c4b8",
-"R c #e8c4b0",
-"S c #e8c4a8",
-"T c #e8c4a0",
-/* pixels */
-"h#kyGCmmmmvmvyjjyyCpjvjvuhhivjia",
-"LmymvvyllyyithLvLyvjvpihjjyli#kg",
-"CDCQyyCCGyikyCCCyLyNMxyyyLmulyRS",
-"NqmvjyCyvuimLLymmCpmmjmCvyyCOAGm",
-"jvliivvyymiyjCCpvmjmjvjjmyyCCvij",
-"uvyvCiiujixCGmyjymvmvljyCCCvvuuj",
-"yyyllBxmONyjyxukxBlxlBCrCjiljkwK",
-"pyCCyQSIDDmymCyyCGCRFIzCLmmyyOTT",
-"yyjvmvyjuuvxlijvjmmjjjjeijjyjDmj",
-"vyvjuiyjjhllliiixljjullylmLjaivv",
-"vihhivuuhiuhwxCGCvhkvvyyCyujvjuj",
-"CopCCxCCpmxCQCCmxBmLCCCyyyCpCCxy",
-"ypmmyyyyyvyyLCyCCRDmyyvymCyvyjpv",
-"vjvjvjlujiiiyyCyDjjKjjmymmvjvyvb",
-"jyliiiyyxiijymyCpmymNCBjuKimmliv",
-"mwhipyliavjjvyCCvmyyuuxmyijyjvmy",
-"yjlDNGvmKmmyNLyyCCCCHRSyylyyCCQG",
-"jmCsOyyGymyCyjyQyryDnmCjvmyjmmyy",
-"NHHyyCyjyjmyCymyyiiuvvuyxlikyyjy",
-"mmCymmyymyrCyvyyyimuyyxhhuCmjyQE",
-"GCmCyyjmpmmmmvxxliyylkllCmyDSCmy",
-"yyCNNNSPCyCCmyByCyyCMPDDOTTRJRTL",
-"yppmyCCmyyylijypjvmymCmmDyvmnmmj",
-"vymCymvvjlvjyymmvmmCmmvvjyppmiyy",
-"CCvmjpjyxlymyyCyyNmjmyvyCyivyyyv",
-"CpyyNNyyyyOOCmyvyvCpmCyyyOyLCCCC",
-"pypNmxilypDzppymyxdmCyvymDpyLyyy",
-"yydhlxyjmyyluvlltiumjyyymjvvjlku",
-"cgljjyvpiilyihxyyjvyyyliiiikjyml",
-"xymNpihiLChlyyymmyCylixvxiyCjl.t",
-"NPREmxyCGCyGryCCCCyCCCLmCypLyLmm",
-"mygfxyzHbypvjvvyjKjrHRbjvLjbtvbe",
-};
diff --git a/sandbox/trash.xbm b/sandbox/trash.xbm
deleted file mode 100644
index 0370f11..0000000
--- a/sandbox/trash.xbm
+++ /dev/null
@@ -1,6 +0,0 @@
-#define trash_width 16
-#define trash_height 16
-static char trash_bits[] = {
- 0x00, 0x01, 0xe0, 0x0f, 0x10, 0x10, 0xf8, 0x3f, 0x10, 0x10, 0x50, 0x15,
- 0x50, 0x15, 0x50, 0x15, 0x50, 0x15, 0x50, 0x15, 0x50, 0x15, 0x50, 0x15,
- 0x50, 0x15, 0x10, 0x10, 0xe0, 0x0f, 0x00, 0x00};
diff --git a/sandbox/triangles.pl b/sandbox/triangles.pl
deleted file mode 100644
index 23dc1f0..0000000
--- a/sandbox/triangles.pl
+++ /dev/null
@@ -1,69 +0,0 @@
-#!/usr/bin/perl -w
-
-use Tk;
-use Tk::Zinc;
-use Controls;
-use Tk::Photo;
-require Tk::PNG;
-
-$mw = MainWindow->new();
-$logo = $mw->Photo(-file => "logo.gif");
-$papier = $mw->Photo(-file => "texture-paper.xpm");
-$penguin = $mw->Photo(-format => 'png',
- -file => "xpenguin.png");
-
-$top = 1;
-$zinc = $mw->Zinc(-render => 1,
- -borderwidth => 0,
- -highlightthickness => 0,
- -relief => 'sunken',
- -takefocus => 1,
- -tile => $papier);
-$zinc->pack(-expand => 1, -fill => 'both');
-$zinc->configure(-width => 500, -height => 500);
-$gr1 = $zinc->add('group', $top);
-$clip = $zinc->add('arc', $gr1, [50, 50, 399, 399],
- -filled => 1,
- -fillcolor => 'Pink:40',
-# -fillpattern => 'AlphaStipple4',
- -linewidth => 0);
-#$zinc->itemconfigure($gr1, -clip => $clip);
-$gr2 = $zinc->add('group', $gr1);
-$clip2 = $zinc->add('rectangle', $gr2, [200, 200, 450, 300],
- -filled => 1,
-# -fillcolor => 'white:100|white:0',
- -fillcolor => 'white:100 0|black:100 100/90',
-# -fillcolor => 'white 0 |blue 20|blue 80|black:0 100/270',
- -linewidth => 0);
-#$zinc->itemconfigure($gr2, -clip => $clip2);
-$view = $zinc->add('group', $gr2, -tags => "controls");
-$zinc->lower($clip);
-$zinc->lower($clip2);
-
-new Controls($zinc);
-
-$cv2 = $zinc->add('curve', $view, [],
- -linewidth => 2);
-$cv3 = $zinc->add('curve', $view, [],
- -linewidth => 2);
-
-$tri2 = $zinc->add('triangles', $view, [50, 50, 300, 50, 150, 150, 300, 150],
- -colors => ['tan:50', '', '', 'red']);
-$zinc->contour($cv2, 'union', $tri2);
-
-$tri3 = $zinc->add('triangles', $view, [150, 150, 50, 50, 150, 50, 300, 50],
- -colors => ['grey50', 'blue', 'red', 'yellow'],
- -fan => 1);
-$tri4 = $zinc->clone($tri3, -colors => ['grey', 'red']);
-$zinc->translate($tri4, 100, 300);
-
-$zinc->contour($cv3, 'union', $tri3);
-$zinc->translate($tri3, 0, 300);
-$zinc->translate($cv3, 0, 300);
-
-$zinc->monitor(1);
-$mw->Tk::bind('<p>', sub { print "perfs: ", join(',', $zinc->monitor()), "\n" });
-$mw->Tk::bind('<t>', sub { $zinc->remove($arc); });
-$mw->Tk::bind('<q>', sub { exit(0); });
-$zinc->focusFollowsMouse();
-MainLoop();
diff --git a/sandbox/xpenguin.png b/sandbox/xpenguin.png
deleted file mode 100644
index 1b1d352..0000000
--- a/sandbox/xpenguin.png
+++ /dev/null
Binary files differ
diff --git a/sandbox/zinc.tcl b/sandbox/zinc.tcl
deleted file mode 100644
index a798e3b..0000000
--- a/sandbox/zinc.tcl
+++ /dev/null
@@ -1,284 +0,0 @@
-lappend auto_path .
-
-package require Tkzinc
-package require Img
-
-set top 1
-
-#memory info
-#memory trace on
-#memory validate on
-
-image create photo logo -file logo.gif
-image create photo logosmall -file logo.gif
-#image create photo bois -file texture-bois1.xpm
-
-#set r [zinc .r -backcolor gray -relief sunken -tile bois]
-set r [zinc .r -backcolor gray -relief sunken]
-pack .r -expand t -fill both
-set scale 1.0
-set centerX 0.0
-set centerY 0.0
-set zincWidth 800
-set zincHeight 500
-#.r configure -width $zincWidth -height $zincHeight
-#.r configure -drawbboxes t
-set view [.r add group $top -tags "controls"]
-
-frame .rc
-button .rc.up -text "Up" \
- -command {set centerY [expr $centerY+30.0]; updateTransform .r}
-button .rc.down -text "Down" \
- -command {set centerY [expr $centerY-30.0]; updateTransform .r}
-button .rc.left -text "Left" \
- -command {set centerX [expr $centerX+30.0]; updateTransform .r}
-button .rc.right -text "Right" \
- -command {set centerX [expr $centerX-30.0]; updateTransform .r}
-button .rc.expand -text "Expand" \
- -command {set scale [expr $scale*1.1]; updateTransform .r}
-button .rc.shrink -text "Shrink" \
- -command {set scale [expr $scale*0.9]; updateTransform .r}
-button .rc.reset -text "Reset" \
- -command {set scale 1.0; set centerX 0.0; set centerY 0.0; \
- updateTransform .r}
-button .rc.quit -text "Quit" -command "exit"
-grid .rc.up -row 0 -column 2 -sticky ew
-grid .rc.down -row 2 -column 2 -sticky ew
-grid .rc.left -row 1 -column 1
-grid .rc.right -row 1 -column 3
-grid .rc.expand -row 1 -column 4
-grid .rc.shrink -row 1 -column 0
-grid .rc.reset -row 1 -column 2 -sticky ew
-grid .rc.quit -row 3 -column 2
-pack .rc
-
-bind .r <Configure> "ZincStyleConfig %W %w %h"
-
-proc ZincStyleConfig {zinc w h} {
- global zincWidth zincHeight
-
- set bw [$zinc cget -borderwidth]
- set zincWidth [expr $w - 2*$bw]
- set zincHeight [expr $h - 2*$bw]
- updateTransform $zinc
-}
-
-proc updateTransform {zinc} {
- global zincWidth zincHeight
- global scale centerX centerY
- global top
-
- $zinc treset $top
- $zinc translate $top [expr -$centerX] [expr -$centerY]
- $zinc scale $top $scale $scale
- $zinc scale $top 1 -1
- $zinc translate $top [expr $zincWidth/2] [expr $zincHeight/2]
-}
-
-#
-# TRACKS
-#
-set track [.r add track $view 6 -tags track -leaderanchors "|0|0"]
-.r itemconfigure $track -position "1 1"
-.r itemconfigure $track -position "10 10"
-.r itemconfigure $track -position "20 20"
-.r itemconfigure $track -position "30 30"
-.r itemconfigure $track -position "40 40"
-.r itemconfigure $track -position "50 50"
-.r itemconfigure $track -position "55 60"
-.r itemconfigure $track -position "60 70"
-.r itemconfigure $track -speedvector "20 0"
-.r itemconfigure $track -symbolcolor salmon -speedvectorcolor salmon -leadercolor salmon \
- -labeldistance 20
-.r itemconfigure $track -markersize 20 \
- -filledmarker 1 \
- -markerfillpattern AlphaStipple4 \
- -markercolor salmon
-.r itemconfigure $track -labelformat "120x40 l0l0+0+0 x80x20+0+0 x40x20+80+0 x40x20+0+20 x20x20>3>2 x60x20>1>1"
-.r itemconfigure $track 0 -filled 1 -backcolor gray -bordercolor gray -relief groove
-.r itemconfigure $track 1 -filled 1 -backcolor tan -bordercolor tan -relief groove \
- -font "cenapii-etiquette-m17" -text "AFR451"
-.r itemconfigure $track 2 -text "WPY" \
- -font "cenapii-etiquette-m17"
-.r itemconfigure $track 3 -text "400" -filled 1 -backcolor wheat \
- -font "cenapii-etiquette-m17"
-.r itemconfigure $track 4 -text "-" -filled 1 -backcolor wheat \
- -font "cenapii-etiquette-m17"
-.r itemconfigure $track 5 -text "450" -font "cenapii-etiquette-m17"
-
-.r bind $track:speedvector <Enter> ".r itemconfigure $track -speedvectorcolor red"
-.r bind $track:speedvector <Leave> ".r itemconfigure $track -speedvectorcolor salmon"
-
-set track2 [.r add track $view 4 -speedvector "-20 0" \
- -symbolcolor salmon -speedvectorcolor salmon -leadercolor salmon \
- -labeldx -20 -labeldy 20 -leaderanchors "%30x30" \
- -historycolor MistyRose -lastasfirst t ]
-.r itemconfigure $track2 -labelformat "a3f110+0+0 a3f110>0^0 a3f110^0>0 a3f110>2>0"
-.r itemconfigure $track2 0 -filled 1 -backcolor tan -text "BAW452"
-.r itemconfigure $track2 1 -filled 1 -backcolor wheat -text "450"
-.r itemconfigure $track2 2 -filled 1 -backcolor wheat -text "KMC"
-#.r itemconfigure $track2 3 -filled 1 -backcolor wheat -text ""
-.r itemconfigure $track2 -connecteditem $track -connectioncolor green
-.r itemconfigure $track2 -position "10 0"
-.r itemconfigure $track2 -position "-20 10"
-.r itemconfigure $track2 -position "-30 20"
-.r itemconfigure $track2 -position "-40 30"
-.r itemconfigure $track2 -position "-50 40"
-.r itemconfigure $track2 -position "-60 50"
-.r itemconfigure $track2 -position "-70 50"
-.r itemconfigure $track2 -position "-80 50"
-.r itemconfigure $track2 -position "-90 50"
-
-#
-# WAY POINTS
-#
-puts "creating way points"
-set wp [.r add waypoint $view 1 -tags borders]
-.r itemconfigure $wp -symbolcolor bisque -leadercolor bisque -position "-100 120" \
- -labelformat "40x20"
-.r itemconfigure $wp 0 -bordercolor bisque -text "NCY" -tile logo -filled t
-set wp2 [.r add waypoint $view 1 -tags borders]
-.r itemconfigure $wp2 -symbolcolor bisque \
- -leadercolor bisque \
- -position "50 160" \
- -labelformat "40x20" \
- -connectioncolor bisque \
- -connecteditem $wp
-.r itemconfigure $wp2 0 -bordercolor bisque -text "MPW"
-set wp3 [.r add waypoint $view 1 -tags borders]
-.r itemconfigure $wp3 -symbolcolor bisque \
- -leadercolor bisque \
- -position "200 140" \
- -labelformat "40x20" \
- -connectioncolor bisque \
- -connecteditem $wp2
-.r itemconfigure $wp3 0 -bordercolor bisque -text "ART"
-
-#
-# MACROS
-#
-puts "creating macros"
-set macro [.r add tabular $view 10 -labelformat "x40x20+0+0 x40x20+40+0" \
- -tags f0borders -connecteditem $track]
-.r itemconfigure $macro 0 -text une
-.r itemconfigure $macro 1 -text macro
-
-#
-# MINISTRIPS
-#
-puts "creating ministrips"
-set ministrip [.r add tabular $view 1 \
- -labelformat "60x20" -position "10 10"]
-.r itemconfigure $ministrip 0 -text "ministrip" -sensitive f
-set ministrip2 [.r add tabular $view 1 \
- -labelformat "60x20" -connecteditem $ministrip]
-.r itemconfigure $ministrip2 0 -text "ministrip2" -sensitive f
-set ministrip3 [.r add tabular $view 1 \
- -labelformat "60x20" -connecteditem $ministrip2]
-.r itemconfigure $ministrip3 0 -text "ministrip3" -sensitive f
-
-#
-# MAPS
-#
-puts "creating maps"
-videomap load "/usr/share/toccata/maps/videomap_paris-w_90_2" 0 paris-w
-videomap load "/usr/share/toccata/maps/videomap_orly" 17 orly
-videomap load "/usr/share/toccata/maps/hegias_parouest_TE.vid" 0 paris-ouest
-
-set map [.r add map $view -color darkblue]
-.r itemconfigure $map -mapinfo orly
-
-set map2 [.r add map $view -color darkblue -filled 1 -priority 0 -fillpattern AlphaStipple1]
-.r itemconfigure $map2 -mapinfo paris-ouest
-
-set map3 [.r add map $view -color orange]
-
-mapinfo mpessai create
-mapinfo mpessai add text normal simple 0 200 "Et voilà"
-mapinfo mpessai add line simple 5 0 0 100 100
-mapinfo mpessai add line simple 0 100 100 0 200
-mapinfo mpessai add line simple 2 -100 100 0 0
-.r itemconfigure $map3 -mapinfo mpessai
-
-#
-# Clip
-#
-puts "crée les clips"
-set clip [.r add rectangle $view "-100 -100 300 200" -filled t \
- -linewidth 0 -fillcolor darkgray -visible f]
-#.r rotate $clip [expr 3.14159 / 4]
-.r lower $clip
-#.r itemconfigure $view -clip $clip
-
-.r add rectangle $top "-5 -5 5 5" -filled t -fillcolor red
-set topclip [.r add rectangle $top "-400 -400 400 400" \
- -filled t -fillcolor lightgray -linewidth 0 -visible t]
-.r lower $topclip
-#.r rotate $topclip [expr 3.14159 / 4]
-#.r itemconfigure $top -clip $topclip
-
-#
-# CONTROLS
-#
-proc borders {onoff} {
- set part [.r currentpart]
- puts "part $part $onoff"
- set contour noborder
- if { $onoff == "on" } {
- set contour "contour oblique"
- }
- if { [regexp {^[0-9]+$} $part] } {
- .r itemconfigure current $part -border $contour
- }
-}
-
-.r bind borders <Enter> "borders on"
-.r bind borders <Leave> "borders off"
-.r bind f0borders:0 <Enter> "borders on"
-.r bind f0borders:0 <Leave> "borders off"
-.r bind track <Enter> {puts "Entre dans item"}
-.r bind track <Leave> {puts "Sort d'item"}
-.r bind track:0 <Enter> {puts "Entre dans champ 0"}
-.r bind track:0 <Leave> {puts "Sort de champ 0"}
-.r bind track:1 <Enter> {puts "Entre dans champ 1"}
-.r bind track:1 <Leave> {puts "Sort de champ 1"}
-.r bind track:2 <Enter> {puts "Entre dans champ 2"}
-.r bind track:2 <Leave> {puts "Sort de champ 2"}
-.r bind track:3 <Enter> {puts "Entre dans champ 3"}
-.r bind track:3 <Leave> {puts "Sort de champ 3"}
-
-bind .r <2> {puts "%x@%y, item: [.r find atpoint %x %y]"}
-
-proc finditems {cornerx cornery} {
- global origx origy
-
- puts "--- enclosed ---"
- puts "++ [.r find enclosed $origx $origy $cornerx $cornery] ++"
- puts "--- overlapping ---"
- puts "++ [.r find overlapping $origx $origy $cornerx $cornery] ++"
- puts ""
-}
-
-bind .r <ButtonPress-1> "set origx %x; set origy %y"
-bind .r <ButtonRelease-1> "finditems %x %y"
-
-.r bind all <1> { if {! [catch {.r find withtag current} item] } { \
- puts "<1> in $item" } else { puts "None" } }
-
-#
-#for {set j 0} {$j < 20} {incr j} {
-# memory info
-# for {set i 0} {$i < 10} {incr i} {
-# set a($i) [.r add icon 1 -image logo]
-# set b($i) [.r add rectangle 1 "10 10 1000 1000" -filled t -tile logosmall]
-# set c($i) [.r add curve 1 "10 10 10 100 100 100" -filled t -tile logosmall]
-# }
-# for {set i 0} {$i < 10} {incr i} {
-# .r remove $a($i)
-# .r remove $b($i)
-# .r remove $c($i)
-# }
-#}
-
-source "controls.tcl"
-
diff --git a/sandbox/zinc.test b/sandbox/zinc.test
deleted file mode 100644
index d5ce7fe..0000000
--- a/sandbox/zinc.test
+++ /dev/null
@@ -1,154 +0,0 @@
-#-*- mode:tcl -*-
-
-if {[lsearch [namespace children] ::tcltest] == -1} {
-# package require tcltest
-# namespace import ::tcltest::*
- source [file join [pwd] [file dirname [info script]] defs.tcl]
-}
-
-proc setupHier {} {
- set view [.r add group 1]
- .r add rectangle $view "50 -150 100 -50" -tags "poly rectangle"
- set model [.r add group $view]
- .r add curve $model "50 -150 100 -50" -tags "poly foo"
- .r add rectangle $model "50 -150 100 -50" -tags "rectangle"
- .r add text $model -text "UnTexte" -tags "title"
- .r clone $model
- .r clone $model
- .r clone $model
- .r remove $model
-}
-
-load tkzinc3.1.so
-zinc .r
-pack .r
-update
-setupHier
-
-test FindItems-1.0 {Test subcommand 'all' with no args} {} {
- .r find all
-} {2 3 16 19 18 17 12 15 14 13 8 11 10 9}
-
-test FindItems-1.1 {Test subcommand 'all' with top group} {} {
- .r find all 1
-} {2 3 16 19 18 17 12 15 14 13 8 11 10 9}
-
-test FindItems-1.2 {Test subcommand 'all' with top group, non-recursive} {} {
- .r find all 1 f
-} {2}
-
-test FindItems-1.3 {Test subcommand 'all' with inner group} {} {
- .r find all 2
-} {3 16 19 18 17 12 15 14 13 8 11 10 9}
-
-test FindItems-1.4 {Test subcommand 'all' with inner group, non-recursive} {} {
- .r find all 2 f
-} {3 16 12 8}
-
-test FindItems-1.5 {Test subcommand 'all' with inner most group} {} {
- .r find all 8
-} {11 10 9}
-
-test FindItems-1.6 {Test subcommand 'all' with inner most group, non-recursive} {} {
- .r find all 8 f
-} {11 10 9}
-
-test FindItems-2.0 {Test subcommand 'above' with id} {} {
- .r find above 9
-} {10}
-
-test FindItems-2.1 {Test subcommand 'above' with tag} {} {
- .r find above foo
-} {18}
-
-test FindItems-2.2 {Test subcommand 'above' with tag in group} {} {
- .r find above foo 8
-} {10}
-
-test FindItems-2.3 {Test subcommand 'above' with tag in group} {} {
- .r find above foo 2 f
-} {}
-
-test FindItems-3.0 {Test subcommand 'below' with id} {} {
- .r find below 10
-} {9}
-
-test FindItems-3.1 {Test subcommand 'below' with tag} {} {
- .r find below title
-} {10}
-
-test FindItems-3.2 {Test subcommand 'below' with tag in group} {} {
- .r find below title 12
-} {14}
-
-test FindItems-3.3 {Test subcommand 'below' with tag in group, non-recursive} {} {
- .r find below title 2 f
-} {}
-
-test FindItems-4.0 {Test subcommand 'atpriority'} {} {
- .r find atpriority 2
-} {3 19 18 17 15 14 13 11 10 9}
-
-test FindItems-4.1 {Test subcommand 'atpriority' in group} {} {
- .r find atpriority 2 2
-} {3 19 18 17 15 14 13 11 10 9}
-
-test FindItems-4.2 {Test subcommand 'atpriority' in group, non-recursive} {} {
- .r find atpriority 2 2 f
-} {3}
-
-test FindItems-5.0 {Test subcommand 'withtag'} {} {
- .r find withtag poly
-} {3 17 13 9}
-
-test FindItems-5.1 {Test subcommand 'withtag' in group} {} {
- .r find withtag poly 2
-} {3 17 13 9}
-
-test FindItems-5.2 {Test subcommand 'withtag' in group, non-recursive} {} {
- .r find withtag poly 2 f
-} {3}
-
-test FindItems-6.0 {Test subcommand 'withtype'} {} {
- .r find withtype rectangle
-} {3 18 14 10}
-
-test FindItems-6.1 {Test subcommand 'withtype' in group} {} {
- .r find withtype rectangle 2
-} {3 18 14 10}
-
-test FindItems-6.2 {Test subcommand 'withtype' in group, non-recursive} {} {
- .r find withtype rectangle 2 f
-} {3}
-
-test FindItems-7.0 {Test tag operator '&&'} {} {
- .r find withtag {poly && rectangle}
-} {3}
-
-test FindItems-7.1 {Test tag operator '||'} {} {
- .r find withtag {poly || rectangle}
-} {3 18 17 14 13 10 9}
-
-test FindItems-7.2 {Test tag operator '!'} {} {
- .r find withtag {!rectangle&&!poly}
-} {2 16 19 12 15 8 11}
-
-test FindItems-7.3 {Test tag operator '^'} {} {
- .r find withtag {rectangle^poly}
-} {18 17 14 13 10 9}
-
-test FindItems-7.4 {Test tag grouping operator '()'} {} {
- .r find withtag {!(rectangle&&poly)}
-} {2 16 19 18 17 12 15 14 13 8 11 10 9}
-
-test FindItems-7.5 {Test not using tag grouping operator '()'} {} {
- .r find withtag {!rectangle&&poly}
-} {17 13 9}
-
-catch {destroy .r}
-#zinc .r
-#pack .r
-#update
-
-::tcltest::cleanupTests
-return
diff --git a/starkit.tcl.in b/starkit.tcl.in
deleted file mode 100644
index 8ce35bb..0000000
--- a/starkit.tcl.in
+++ /dev/null
@@ -1,203 +0,0 @@
-#
-# This script is intended to be run in the top directory
-# with: tclsh starkit.tcl.
-# It needs a tclkit and the sdx command as a starkit in the path.
-#
-
-set MAJOR_VERSION @MAJOR_VERSION@
-set MINOR_VERSION @MINOR_VERSION@
-set PATCHLEVEL @PATCHLEVEL@
-
-
-#
-# Starkit structure
-#
-# demo.tcl
-# lib
-# tkimg1.3
-# files from the Tkimg starkit
-# TkzincX.Y
-# Copyright
-# demos
-# demos files and sub-directories
-# Linux-x86
-# Tkzinc.so
-# pkgIndex.tcl
-# Windows-x86
-# Tkzinc.dll
-# zincGraphics.tcl
-# zincLogo.tcl
-# zincText.tcl
-# main.tcl
-#
-
-proc crossCompile {} {
- global MAJOR_VERSION MINOR_VERSION PATCHLEVEL
- global env
-
- #
- # Try to find the Tcl/Tk headers and stubs cache
- set kit [file normalize [file join [pwd] .. .kittmp]]
- if { ! [file exists $kit] } {
- puts "Unable to find the Tcl/Tk headers and stubs in $kit, exiting."
- exit
- }
- puts "Using Tcl/Tk headers and stubs in: $kit"
-
- set sources {
- libtess/dict.c libtess/geom.c libtess/memalloc.c libtess/mesh.c
- libtess/normal.c libtess/priorityq.c libtess/render.c
- libtess/sweep.c libtess/tess.c libtess/tessmono.c
- generic/Track.c generic/Tabular.c generic/Reticle.c generic/Map.c
- generic/Rectangle.c generic/Arc.c generic/Curve.c generic/Item.c
- generic/PostScript.c generic/MapInfo.c generic/Attrs.c
- generic/Draw.c generic/Geo.c generic/List.c generic/perfos.c
- generic/Transfo.c generic/Group.c generic/Icon.c generic/Text.c
- generic/Image.c generic/Color.c generic/Field.c generic/Triangles.c
- generic/Window.c generic/tkZinc.c generic/OverlapMan.c
- win/WinPort.c
- }
- set cFlags [list -I$kit -I$kit/generic -I$kit/xlib -Igeneric -Ilibtess \
- -DUSE_TCL_STUBS=1 -DUSE_TK_STUBS=1 \
- -DVERSION=\"$MAJOR_VERSION.$MINOR_VERSION.$PATCHLEVEL\" \
- -DGL=1 -DGL_DAMAGE=1 -DOM=1 -O2 -DBUILD_Tkzinc=1 ]
- set lFlags [list -shared -s -L$kit/Windows-x86 -ltclstub -ltkstub \
- -lopengl32 -lgdi32 -lwsock32 -luser32 ]
- set objs [list]
-
- set envSave $env(PATH)
- set env(PATH) $env(HOME)/cross-tools/bin:$env(PATH)
- set logFile [open starkit.log w]
-
- foreach f $sources {
- lappend objs [file rootname [file tail $f]].o
- set cmdLine "gcc $cFlags -c $f >&@ $logFile"
- puts $logFile $cmdLine
- catch {eval exec $cmdLine} result
- puts $logFile $result
- }
- set cmdLine "gcc $objs $lFlags -o Tkzinc$MAJOR_VERSION$MINOR_VERSION$PATCHLEVEL.dll >&@ $logFile"
- puts $logFile $cmdLine
- catch {eval exec $cmdLine} result
- puts $logFile $result
-
- close $logFile
- set env(PATH) $envSave
-}
-
-proc updateKit {} {
- global MAJOR_VERSION MINOR_VERSION PATCHLEVEL
-
- set zincPath [file join Tkzinc.vfs lib Tkzinc$MAJOR_VERSION.$MINOR_VERSION]
- set version $MAJOR_VERSION.$MINOR_VERSION.$PATCHLEVEL
- set winVersion $MAJOR_VERSION$MINOR_VERSION$PATCHLEVEL
-
- file copy -force [file join starkit demo.tcl] [file join starkit main.tcl] Tkzinc.vfs
-
- set zincPath [file join Tkzinc.vfs lib Tkzinc$MAJOR_VERSION.$MINOR_VERSION]
- file mkdir $zincPath
- file copy -force Copyright \
- [file join library zincGraphics.tcl] \
- [file join library zincLogo.tcl] \
- [file join library zincText.tcl] \
- $zincPath
-
- set demosPath [file join $zincPath demos]
- file mkdir $demosPath
- foreach f [glob -directory demos *.tcl] {
- file copy -force $f $demosPath
- }
- file delete -force [file join $demosPath data] [file join $demosPath images]
- file copy -force [file join demos zinc-widget] [file join demos data] [file join demos images] $demosPath
-
- #
- # Emit a merged pkgIndex.tcl
- #
- set fOut [open [file join $zincPath pkgIndex.tcl] w]
- puts $fOut "proc Platform {} {"
- puts -nonewline $fOut [info body Platform]
- puts $fOut "}"
- set fIn [open [file join library pkgIndex.tcl]]
- foreach line [split [read $fIn] \n] {
- if {![regexp {^\s*$|^#} $line]} {
- puts $fOut $line
- }
- }
- close $fIn
- puts -nonewline $fOut "package ifneeded Tkzinc $version "
- puts $fOut {[list load [file join $dir [Platform] Tkzinc[info sharedlibext]]]}
- close $fOut
-
- #
- # Copy the platform dependent libraries
- #
- if { [file exists libTkzinc$version.so] } {
- set platformPath [file join $zincPath Linux-x86]
- file mkdir $platformPath
- file copy -force libTkzinc$version.so [file join $platformPath Tkzinc.so]
- }
- if { [file exists Tkzinc$winVersion.dll] } {
- set platformPath [file join $zincPath Windows-x86]
- file mkdir $platformPath
- file copy -force Tkzinc330.dll [file join $platformPath Tkzinc.dll]
- }
-
- exec sdx wrap Tkzinc.kit
-}
-
-
-proc Platform {} {
- global tcl_platform
- set plat [lindex $tcl_platform(os) 0]
- set mach $tcl_platform(machine)
- switch -glob -- $mach {
- sun4* { set mach sparc }
- intel -
- i*86* { set mach x86 }
- "Power Macintosh" { set mach ppc }
- }
- switch -- $plat {
- AIX { set mach ppc }
- HP-UX { set mach hppa }
- }
- return "$plat-$mach"
-}
-
-#
-# Build the Windows variant
-crossCompile
-
-#
-# Build the linux variant
-catch {exec make clean}
-catch {exec make}
-
-#
-# If the starkit Tkzinc.kit already exist in the top directory
-# simply update it else build a new one according to the layout
-# above. In this later case one need to make sure there is a
-# valid Tkimg.kit in the top directory's parent.
-#
-if { [file exists Tkzinc.kit] } {
- if { [file exists Tkzinc.vfs] } {
- file delete -force Tkzinc.vfs
- }
- exec sdx unwrap Tkzinc.kit
- updateKit
-} {
- if { [file exists Tkzinc.vfs] } {
- file delete -force Tkzinc.vfs
- }
- file mkdir Tkzinc.vfs
-
- if { [file exists Tkimg.vfs] } {
- file delete -force Tkimg.vfs
- }
- exec sdx unwrap [file join .. Tkimg.kit]
- file copy [file join Tkimg.vfs lib] Tkzinc.vfs
-
- updateKit
-}
-
-file delete -force Tkimg.vfs
-file delete -force Tkzinc.vfs
diff --git a/starkit/demo.tcl b/starkit/demo.tcl
deleted file mode 100644
index ed1c373..0000000
--- a/starkit/demo.tcl
+++ /dev/null
@@ -1,4 +0,0 @@
-
-set path [file dirname [info script]]
-
-source [file join [lindex [glob -directory [file join $path lib] Tkzinc*] 0] demos zinc-widget]
diff --git a/starkit/main.tcl b/starkit/main.tcl
deleted file mode 100644
index 724f807..0000000
--- a/starkit/main.tcl
+++ /dev/null
@@ -1,35 +0,0 @@
-
-package require starkit
-
-set method [starkit::startup]
-if { $method eq "sourced"} return
-
-array set help {
- demo { Launch a package demo
-
- Usage: demo package
- }
-}
-
-set action [lindex $argv 0]
-set path [file dirname [info script]]
-
-set validActions [array names help]
-if { $action eq "" ||
- ($action eq "help" && [llength $argv] == 1 &&
- [lsearch $validActions $action] < 0) } {
- puts "Specify one of the following commands:\n"
- foreach c [array names help] {
- puts -nonewline " $c"
- }
- puts "\n\nFor more information, type: $argv0 help ?command?"
- exit
-} elseif { $action eq "help" } {
- set cmd [lindex $argv 1]
- puts $help($cmd)
- exit
-}
-
-set argv [lrange $argv 1 end]
-
-source [file join $path $action.tcl]
diff --git a/tclconfig/README.txt b/tclconfig/README.txt
deleted file mode 100644
index 9055a58..0000000
--- a/tclconfig/README.txt
+++ /dev/null
@@ -1,26 +0,0 @@
-These files comprise the basic building blocks for a Tcl Extension
-Architecture (TEA) extension. For more information on TEA see:
-
- http://www.tcl.tk/doc/tea/
-
-This package is part of the Tcl project at SourceForge, and latest
-sources should be available there:
-
- http://tcl.sourceforge.net/
-
-This package is a freely available open source package. You can do
-virtually anything you like with it, such as modifying it, redistributing
-it, and selling it either in whole or in part.
-
-CONTENTS
-========
-The following is a short description of the files you will find in
-the sample extension.
-
-README.txt This file
-
-install-sh Program used for copying binaries and script files
- to their install locations.
-
-tcl.m4 Collection of Tcl autoconf macros. Included by a package's
- aclocal.m4 to define SC_* macros.
diff --git a/tclconfig/install-sh b/tclconfig/install-sh
deleted file mode 100644
index 0ff4b6a..0000000
--- a/tclconfig/install-sh
+++ /dev/null
@@ -1,119 +0,0 @@
-#!/bin/sh
-
-#
-# install - install a program, script, or datafile
-# This comes from X11R5; it is not part of GNU.
-#
-# $XConsortium: install.sh,v 1.2 89/12/18 14:47:22 jim Exp $
-#
-# This script is compatible with the BSD install script, but was written
-# from scratch.
-#
-
-
-# set DOITPROG to echo to test this script
-
-# Don't use :- since 4.3BSD and earlier shells don't like it.
-doit="${DOITPROG-}"
-
-
-# put in absolute paths if you don't have them in your path; or use env. vars.
-
-mvprog="${MVPROG-mv}"
-cpprog="${CPPROG-cp}"
-chmodprog="${CHMODPROG-chmod}"
-chownprog="${CHOWNPROG-chown}"
-chgrpprog="${CHGRPPROG-chgrp}"
-stripprog="${STRIPPROG-strip}"
-rmprog="${RMPROG-rm}"
-
-instcmd="$mvprog"
-chmodcmd=""
-chowncmd=""
-chgrpcmd=""
-stripcmd=""
-rmcmd="$rmprog -f"
-mvcmd="$mvprog"
-src=""
-dst=""
-
-while [ x"$1" != x ]; do
- case $1 in
- -c) instcmd="$cpprog"
- shift
- continue;;
-
- -m) chmodcmd="$chmodprog $2"
- shift
- shift
- continue;;
-
- -o) chowncmd="$chownprog $2"
- shift
- shift
- continue;;
-
- -g) chgrpcmd="$chgrpprog $2"
- shift
- shift
- continue;;
-
- -s) stripcmd="$stripprog"
- shift
- continue;;
-
- *) if [ x"$src" = x ]
- then
- src=$1
- else
- dst=$1
- fi
- shift
- continue;;
- esac
-done
-
-if [ x"$src" = x ]
-then
- echo "install: no input file specified"
- exit 1
-fi
-
-if [ x"$dst" = x ]
-then
- echo "install: no destination specified"
- exit 1
-fi
-
-
-# If destination is a directory, append the input filename; if your system
-# does not like double slashes in filenames, you may need to add some logic
-
-if [ -d $dst ]
-then
- dst="$dst"/`basename $src`
-fi
-
-# Make a temp file name in the proper directory.
-
-dstdir=`dirname $dst`
-dsttmp=$dstdir/#inst.$$#
-
-# Move or copy the file name to the temp name
-
-$doit $instcmd $src $dsttmp
-
-# and set any options; do chmod last to preserve setuid bits
-
-if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; fi
-if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; fi
-if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; fi
-if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; fi
-
-# Now rename the file to the real destination.
-
-$doit $rmcmd $dst
-$doit $mvcmd $dsttmp $dst
-
-
-exit 0
diff --git a/tclconfig/tcl.m4 b/tclconfig/tcl.m4
deleted file mode 100644
index 9a7e253..0000000
--- a/tclconfig/tcl.m4
+++ /dev/null
@@ -1,3179 +0,0 @@
-# tcl.m4 --
-#
-# This file provides a set of autoconf macros to help TEA-enable
-# a Tcl extension.
-#
-# Copyright (c) 1999-2000 Ajuba Solutions.
-# Copyright (c) 2002 ActiveState Corporation.
-#
-# See the file "license.terms" for information on usage and redistribution
-# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
-
-#------------------------------------------------------------------------
-# TEA_PATH_TCLCONFIG --
-#
-# Locate the tclConfig.sh file and perform a sanity check on
-# the Tcl compile flags
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --with-tcl=...
-#
-# Defines the following vars:
-# TCL_BIN_DIR Full path to the directory containing
-# the tclConfig.sh file
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_PATH_TCLCONFIG, [
- if test x"${TEA_INITED}" = x ; then
- # Can't refer to exact macro name or it will be substituted
- AC_MSG_ERROR([Must call TEA INIT before PATH_TCLCONFIG])
- fi
- #
- # Ok, lets find the tcl configuration
- # First, look for one uninstalled.
- # the alternative search directory is invoked by --with-tcl
- #
-
- if test x"${no_tcl}" = x ; then
- # we reset no_tcl in case something fails here
- no_tcl=true
- AC_ARG_WITH(tcl, [ --with-tcl directory containing tcl configuration (tclConfig.sh)], with_tclconfig=${withval})
- AC_MSG_CHECKING([for Tcl configuration])
- AC_CACHE_VAL(ac_cv_c_tclconfig,[
-
- # First check to see if --with-tcl was specified.
- if test x"${with_tclconfig}" != x ; then
- if test -f "${with_tclconfig}/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd ${with_tclconfig}; pwd)`
- else
- AC_MSG_ERROR([${with_tclconfig} directory doesn't contain tclConfig.sh])
- fi
- fi
-
- # then check for a private Tcl installation
- if test x"${ac_cv_c_tclconfig}" = x ; then
- for i in \
- ../tcl \
- `ls -dr ../tcl[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../tcl \
- `ls -dr ../../tcl[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../../tcl \
- `ls -dr ../../../tcl[[8-9]].[[0-9]]* 2>/dev/null` ; do
- if test -f "$i/unix/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
-
- # check in a few common install locations
- if test x"${ac_cv_c_tclconfig}" = x ; then
- for i in `ls -d ${exec_prefix}/lib 2>/dev/null` \
- `ls -d /usr/local/lib 2>/dev/null` \
- `ls -d /usr/contrib/lib 2>/dev/null` \
- `ls -d /usr/lib 2>/dev/null` \
- ; do
- if test -f "$i/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd $i; pwd)`
- break
- fi
- done
- fi
-
- # check in a few other private locations
- if test x"${ac_cv_c_tclconfig}" = x ; then
- for i in \
- ${srcdir}/../tcl \
- `ls -dr ${srcdir}/../tcl[[8-9]].[[0-9]]* 2>/dev/null` ; do
- if test -f "$i/unix/tclConfig.sh" ; then
- ac_cv_c_tclconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
- ])
-
- if test x"${ac_cv_c_tclconfig}" = x ; then
- TCL_BIN_DIR="# no Tcl configs found"
- AC_MSG_WARN("Cannot find Tcl configuration definitions")
- exit 0
- else
- no_tcl=
- TCL_BIN_DIR=${ac_cv_c_tclconfig}
- AC_MSG_RESULT([found $TCL_BIN_DIR/tclConfig.sh])
- fi
- fi
-])
-
-#------------------------------------------------------------------------
-# TEA_PATH_TKCONFIG --
-#
-# Locate the tkConfig.sh file
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --with-tk=...
-#
-# Defines the following vars:
-# TK_BIN_DIR Full path to the directory containing
-# the tkConfig.sh file
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_PATH_TKCONFIG, [
- #
- # Ok, lets find the tk configuration
- # First, look for one uninstalled.
- # the alternative search directory is invoked by --with-tk
- #
-
- if test x"${no_tk}" = x ; then
- # we reset no_tk in case something fails here
- no_tk=true
- AC_ARG_WITH(tk, [ --with-tk directory containing tk configuration (tkConfig.sh)], with_tkconfig=${withval})
- AC_MSG_CHECKING([for Tk configuration])
- AC_CACHE_VAL(ac_cv_c_tkconfig,[
-
- # First check to see if --with-tkconfig was specified.
- if test x"${with_tkconfig}" != x ; then
- if test -f "${with_tkconfig}/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd ${with_tkconfig}; pwd)`
- else
- AC_MSG_ERROR([${with_tkconfig} directory doesn't contain tkConfig.sh])
- fi
- fi
-
- # then check for a private Tk library
- if test x"${ac_cv_c_tkconfig}" = x ; then
- for i in \
- ../tk \
- `ls -dr ../tk[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../tk \
- `ls -dr ../../tk[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../../tk \
- `ls -dr ../../../tk[[8-9]].[[0-9]]* 2>/dev/null` ; do
- if test -f "$i/unix/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
- # check in a few common install locations
- if test x"${ac_cv_c_tkconfig}" = x ; then
- for i in `ls -d ${exec_prefix}/lib 2>/dev/null` \
- `ls -d /usr/local/lib 2>/dev/null` \
- `ls -d /usr/contrib/lib 2>/dev/null` \
- `ls -d /usr/lib 2>/dev/null` \
- ; do
- if test -f "$i/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd $i; pwd)`
- break
- fi
- done
- fi
- # check in a few other private locations
- if test x"${ac_cv_c_tkconfig}" = x ; then
- for i in \
- ${srcdir}/../tk \
- `ls -dr ${srcdir}/../tk[[8-9]].[[0-9]]* 2>/dev/null` ; do
- if test -f "$i/unix/tkConfig.sh" ; then
- ac_cv_c_tkconfig=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
- ])
- if test x"${ac_cv_c_tkconfig}" = x ; then
- TK_BIN_DIR="# no Tk configs found"
- AC_MSG_WARN("Cannot find Tk configuration definitions")
- exit 0
- else
- no_tk=
- TK_BIN_DIR=${ac_cv_c_tkconfig}
- AC_MSG_RESULT([found $TK_BIN_DIR/tkConfig.sh])
- fi
- fi
-
-])
-
-#------------------------------------------------------------------------
-# TEA_LOAD_TCLCONFIG --
-#
-# Load the tclConfig.sh file
-#
-# Arguments:
-#
-# Requires the following vars to be set:
-# TCL_BIN_DIR
-#
-# Results:
-#
-# Subst the following vars:
-# TCL_BIN_DIR
-# TCL_SRC_DIR
-# TCL_LIB_FILE
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_LOAD_TCLCONFIG, [
- AC_MSG_CHECKING([for existence of $TCL_BIN_DIR/tclConfig.sh])
-
- if test -f "$TCL_BIN_DIR/tclConfig.sh" ; then
- AC_MSG_RESULT([loading])
- . $TCL_BIN_DIR/tclConfig.sh
- else
- AC_MSG_RESULT([file not found])
- fi
-
- #
- # If the TCL_BIN_DIR is the build directory (not the install directory),
- # then set the common variable name to the value of the build variables.
- # For example, the variable TCL_LIB_SPEC will be set to the value
- # of TCL_BUILD_LIB_SPEC. An extension should make use of TCL_LIB_SPEC
- # instead of TCL_BUILD_LIB_SPEC since it will work with both an
- # installed and uninstalled version of Tcl.
- #
-
- if test -f $TCL_BIN_DIR/Makefile ; then
- TCL_LIB_SPEC=${TCL_BUILD_LIB_SPEC}
- TCL_STUB_LIB_SPEC=${TCL_BUILD_STUB_LIB_SPEC}
- TCL_STUB_LIB_PATH=${TCL_BUILD_STUB_LIB_PATH}
- fi
-
- #
- # eval is required to do the TCL_DBGX substitution
- #
-
- eval "TCL_LIB_FILE=\"${TCL_LIB_FILE}\""
- eval "TCL_LIB_FLAG=\"${TCL_LIB_FLAG}\""
- eval "TCL_LIB_SPEC=\"${TCL_LIB_SPEC}\""
-
- eval "TCL_STUB_LIB_FILE=\"${TCL_STUB_LIB_FILE}\""
- eval "TCL_STUB_LIB_FLAG=\"${TCL_STUB_LIB_FLAG}\""
- eval "TCL_STUB_LIB_SPEC=\"${TCL_STUB_LIB_SPEC}\""
-
- AC_SUBST(TCL_VERSION)
- AC_SUBST(TCL_BIN_DIR)
- AC_SUBST(TCL_SRC_DIR)
-
- AC_SUBST(TCL_LIB_FILE)
- AC_SUBST(TCL_LIB_FLAG)
- AC_SUBST(TCL_LIB_SPEC)
-
- AC_SUBST(TCL_STUB_LIB_FILE)
- AC_SUBST(TCL_STUB_LIB_FLAG)
- AC_SUBST(TCL_STUB_LIB_SPEC)
-
- #AC_SUBST(TCL_DBGX)
- AC_SUBST(TCL_LIBS)
- AC_SUBST(TCL_DEFS)
- AC_SUBST(TCL_EXTRA_CFLAGS)
- AC_SUBST(TCL_LD_FLAGS)
- AC_SUBST(TCL_SHLIB_LD_LIBS)
- #AC_SUBST(TCL_BUILD_LIB_SPEC)
- #AC_SUBST(TCL_BUILD_STUB_LIB_SPEC)
-])
-
-#------------------------------------------------------------------------
-# TEA_LOAD_TKCONFIG --
-#
-# Load the tkConfig.sh file
-#
-# Arguments:
-#
-# Requires the following vars to be set:
-# TK_BIN_DIR
-#
-# Results:
-#
-# Sets the following vars that should be in tkConfig.sh:
-# TK_BIN_DIR
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_LOAD_TKCONFIG, [
- AC_MSG_CHECKING([for existence of ${TK_BIN_DIR}/tkConfig.sh])
-
- if test -f "${TK_BIN_DIR}/tkConfig.sh" ; then
- AC_MSG_RESULT([loading])
- . $TK_BIN_DIR/tkConfig.sh
- else
- AC_MSG_RESULT([could not find ${TK_BIN_DIR}/tkConfig.sh])
- fi
-
- #
- # If the TK_BIN_DIR is the build directory (not the install directory),
- # then set the common variable name to the value of the build variables.
- # For example, the variable TK_LIB_SPEC will be set to the value
- # of TK_BUILD_LIB_SPEC. An extension should make use of TK_LIB_SPEC
- # instead of TK_BUILD_LIB_SPEC since it will work with both an
- # installed and uninstalled version of Tcl.
- #
-
- if test -f $TK_BIN_DIR/Makefile ; then
- TK_LIB_SPEC=${TK_BUILD_LIB_SPEC}
- TK_STUB_LIB_SPEC=${TK_BUILD_STUB_LIB_SPEC}
- TK_STUB_LIB_PATH=${TK_BUILD_STUB_LIB_PATH}
- fi
-
- #
- # eval is required to do the TK_DBGX substitution
- #
-
- eval "TK_LIB_FILE=\"${TK_LIB_FILE}\""
- eval "TK_LIB_FLAG=\"${TK_LIB_FLAG}\""
- eval "TK_LIB_SPEC=\"${TK_LIB_SPEC}\""
-
- eval "TK_STUB_LIB_FILE=\"${TK_STUB_LIB_FILE}\""
- eval "TK_STUB_LIB_FLAG=\"${TK_STUB_LIB_FLAG}\""
- eval "TK_STUB_LIB_SPEC=\"${TK_STUB_LIB_SPEC}\""
-
- AC_SUBST(TK_VERSION)
- AC_SUBST(TK_BIN_DIR)
- AC_SUBST(TK_SRC_DIR)
-
- AC_SUBST(TK_LIB_FILE)
- AC_SUBST(TK_LIB_FLAG)
- AC_SUBST(TK_LIB_SPEC)
-
- AC_SUBST(TK_STUB_LIB_FILE)
- AC_SUBST(TK_STUB_LIB_FLAG)
- AC_SUBST(TK_STUB_LIB_SPEC)
-
- AC_SUBST(TK_LIBS)
- AC_SUBST(TK_XINCLUDES)
-])
-
-#------------------------------------------------------------------------
-# TEA_ENABLE_SHARED --
-#
-# Allows the building of shared libraries
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-shared=yes|no
-#
-# Defines the following vars:
-# STATIC_BUILD Used for building import/export libraries
-# on Windows.
-#
-# Sets the following vars:
-# SHARED_BUILD Value of 1 or 0
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_ENABLE_SHARED, [
- AC_MSG_CHECKING([how to build libraries])
- AC_ARG_ENABLE(shared,
- [ --enable-shared build and link with shared libraries [[yes]]],
- [tcl_ok=$enableval], [tcl_ok=yes])
-
- if test "${enable_shared+set}" = set; then
- enableval="$enable_shared"
- tcl_ok=$enableval
- else
- tcl_ok=yes
- fi
-
- if test "$tcl_ok" = "yes" ; then
- AC_MSG_RESULT([shared])
- SHARED_BUILD=1
- else
- AC_MSG_RESULT([static])
- SHARED_BUILD=0
- AC_DEFINE(STATIC_BUILD)
- fi
- AC_SUBST(SHARED_BUILD)
-])
-
-#------------------------------------------------------------------------
-# TEA_ENABLE_THREADS --
-#
-# Specify if thread support should be enabled. If "yes" is
-# specified as an arg (optional), threads are enabled by default.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-threads
-#
-# Sets the following vars:
-# THREADS_LIBS Thread library(s)
-#
-# Defines the following vars:
-# TCL_THREADS
-# _REENTRANT
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_ENABLE_THREADS, [
- AC_ARG_ENABLE(threads, [ --enable-threads build with threads [[$1]]],
- [tcl_ok=$enableval], [tcl_ok=$1])
-
- if test "$tcl_ok" = "yes"; then
- TCL_THREADS=1
-
- if test "${TEA_PLATFORM}" != "windows" ; then
- # We are always OK on Windows, so check what this platform wants.
- AC_DEFINE(USE_THREAD_ALLOC)
- AC_DEFINE(_REENTRANT)
- AC_DEFINE(_THREAD_SAFE)
- AC_CHECK_LIB(pthread,pthread_mutex_init,tcl_ok=yes,tcl_ok=no)
- if test "$tcl_ok" = "no"; then
- # Check a little harder for __pthread_mutex_init in the
- # same library, as some systems hide it there until
- # pthread.h is defined. We could alternatively do an
- # AC_TRY_COMPILE with pthread.h, but that will work with
- # libpthread really doesn't exist, like AIX 4.2.
- # [Bug: 4359]
- AC_CHECK_LIB(pthread, __pthread_mutex_init,
- tcl_ok=yes, tcl_ok=no)
- fi
-
- if test "$tcl_ok" = "yes"; then
- # The space is needed
- THREADS_LIBS=" -lpthread"
- else
- AC_CHECK_LIB(pthreads, pthread_mutex_init,
- tcl_ok=yes, tcl_ok=no)
- if test "$tcl_ok" = "yes"; then
- # The space is needed
- THREADS_LIBS=" -lpthreads"
- else
- AC_CHECK_LIB(c, pthread_mutex_init,
- tcl_ok=yes, tcl_ok=no)
- if test "$tcl_ok" = "no"; then
- AC_CHECK_LIB(c_r, pthread_mutex_init,
- tcl_ok=yes, tcl_ok=no)
- if test "$tcl_ok" = "yes"; then
- # The space is needed
- THREADS_LIBS=" -pthread"
- else
- TCL_THREADS=0
- AC_MSG_WARN("Don t know how to find pthread lib on your system - thread support disabled")
- fi
- fi
- fi
- fi
-
- # Does the pthread-implementation provide
- # 'pthread_attr_setstacksize' ?
- AC_CHECK_FUNCS(pthread_attr_setstacksize)
- fi
- else
- TCL_THREADS=0
- fi
- # Do checking message here to not mess up interleaved configure output
- AC_MSG_CHECKING([for building with threads])
- if test "${TCL_THREADS}" = "1"; then
- AC_DEFINE(TCL_THREADS)
- AC_MSG_RESULT([yes])
- else
- AC_MSG_RESULT([no (default)])
- fi
- # TCL_THREADS sanity checking. See if our request for building with
- # threads is the same as the way Tcl was built. If not, warn the user.
- case ${TCL_DEFS} in
- *THREADS=1*)
- if test "${TCL_THREADS}" = "0"; then
- AC_MSG_WARN([
- Building ${PACKAGE} without threads enabled, but building against a Tcl
- that IS thread-enabled.])
- fi
- ;;
- *)
- if test "${TCL_THREADS}" = "1"; then
- AC_MSG_WARN([
- --enable-threads requested, but attempting building against a Tcl
- that is NOT thread-enabled.])
- fi
- ;;
- esac
- AC_SUBST(TCL_THREADS)
-])
-
-#------------------------------------------------------------------------
-# TEA_ENABLE_SYMBOLS --
-#
-# Specify if debugging symbols should be used
-# Memory (TCL_MEM_DEBUG) debugging can also be enabled.
-#
-# Arguments:
-# none
-#
-# Requires the following vars to be set:
-# CFLAGS_DEBUG
-# CFLAGS_OPTIMIZE
-# LDFLAGS_DEBUG
-# LDFLAGS_OPTIMIZE
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-symbols
-#
-# Defines the following vars:
-# CFLAGS_DEFAULT Sets to CFLAGS_DEBUG if true
-# Sets to CFLAGS_OPTIMIZE if false
-# LDFLAGS_DEFAULT Sets to LDFLAGS_DEBUG if true
-# Sets to LDFLAGS_OPTIMIZE if false
-# DBGX Debug library extension
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_ENABLE_SYMBOLS, [
- if test x"${TEA_INITED}" = x ; then
- # Can't refer to exact macro name or it will be substituted
- AC_MSG_ERROR([Must call TEA INIT before ENABLE_SYMBOLS])
- fi
-
- if test "${TEA_PLATFORM}" = "windows" ; then
- tcl_dbgx=d
- else
- tcl_dbgx=g
- fi
-
- AC_MSG_CHECKING([for build with symbols])
- AC_ARG_ENABLE(symbols, [ --enable-symbols build with debugging symbols (yes,no,mem,all) [[no]]], [tcl_ok=$enableval], [tcl_ok=no])
- if test "$tcl_ok" = "no"; then
- CFLAGS_DEFAULT='$(CFLAGS_OPTIMIZE)'
- LDFLAGS_DEFAULT='$(LDFLAGS_OPTIMIZE)'
- DBGX=""
- TCL_DBGX=""
- AC_MSG_RESULT([no])
- else
- CFLAGS_DEFAULT='$(CFLAGS_DEBUG)'
- LDFLAGS_DEFAULT='$(LDFLAGS_DEBUG)'
- DBGX=${tcl_dbgx}
- TCL_DBGX=${tcl_dbgx}
- if test "$tcl_ok" = "yes"; then
- AC_MSG_RESULT([yes (standard debugging)])
- fi
- fi
-
- AC_SUBST(TCL_DBGX)
- AC_SUBST(CFLAGS_DEFAULT)
- AC_SUBST(LDFLAGS_DEFAULT)
-
- if test "$tcl_ok" = "mem" -o "$tcl_ok" = "all"; then
- AC_DEFINE(TCL_MEM_DEBUG)
- fi
-
- if test "$tcl_ok" != "yes" -a "$tcl_ok" != "no"; then
- if test "$tcl_ok" = "all"; then
- AC_MSG_RESULT([enabled symbols mem debugging])
- else
- AC_MSG_RESULT([enabled $tcl_ok debugging])
- fi
- fi
-])
-
-#------------------------------------------------------------------------
-# TEA_ENABLE_LANGINFO --
-#
-# Allows use of modern nl_langinfo check for better l10n.
-# This is only relevant for Unix.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-langinfo=yes|no (default is yes)
-#
-# Defines the following vars:
-# HAVE_LANGINFO Triggers use of nl_langinfo if defined.
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_ENABLE_LANGINFO, [
- AC_ARG_ENABLE(langinfo,
- [ --enable-langinfo use nl_langinfo if possible to determine
- encoding at startup, otherwise use old heuristic [[yes]]],
- [langinfo_ok=$enableval], [langinfo_ok=yes])
-
- HAVE_LANGINFO=0
- if test "$langinfo_ok" = "yes"; then
- if test "$langinfo_ok" = "yes"; then
- AC_CHECK_HEADER(langinfo.h,[langinfo_ok=yes],[langinfo_ok=no])
- fi
- fi
- AC_MSG_CHECKING([whether to use nl_langinfo])
- if test "$langinfo_ok" = "yes"; then
- AC_TRY_COMPILE([#include <langinfo.h>],
- [nl_langinfo(CODESET);],[langinfo_ok=yes],[langinfo_ok=no])
- if test "$langinfo_ok" = "no"; then
- langinfo_ok="no (could not compile with nl_langinfo)";
- fi
- if test "$langinfo_ok" = "yes"; then
- AC_DEFINE(HAVE_LANGINFO)
- fi
- fi
- AC_MSG_RESULT([$langinfo_ok])
-])
-
-#--------------------------------------------------------------------
-# TEA_CONFIG_CFLAGS
-#
-# Try to determine the proper flags to pass to the compiler
-# for building shared libraries and other such nonsense.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines the following vars:
-#
-# DL_OBJS - Name of the object file that implements dynamic
-# loading for Tcl on this system.
-# DL_LIBS - Library file(s) to include in tclsh and other base
-# applications in order for the "load" command to work.
-# LDFLAGS - Flags to pass to the compiler when linking object
-# files into an executable application binary such
-# as tclsh.
-# LD_SEARCH_FLAGS-Flags to pass to ld, such as "-R /usr/local/tcl/lib",
-# that tell the run-time dynamic linker where to look
-# for shared libraries such as libtcl.so. Depends on
-# the variable LIB_RUNTIME_DIR in the Makefile.
-# SHLIB_CFLAGS - Flags to pass to cc when compiling the components
-# of a shared library (may request position-independent
-# code, among other things).
-# SHLIB_LD - Base command to use for combining object files
-# into a shared library.
-# SHLIB_LD_LIBS - Dependent libraries for the linker to scan when
-# creating shared libraries. This symbol typically
-# goes at the end of the "ld" commands that build
-# shared libraries. The value of the symbol is
-# "${LIBS}" if all of the dependent libraries should
-# be specified when creating a shared library. If
-# dependent libraries should not be specified (as on
-# SunOS 4.x, where they cause the link to fail, or in
-# general if Tcl and Tk aren't themselves shared
-# libraries), then this symbol has an empty string
-# as its value.
-# SHLIB_SUFFIX - Suffix to use for the names of dynamically loadable
-# extensions. An empty string means we don't know how
-# to use shared libraries on this platform.
-# TCL_LIB_FILE - Name of the file that contains the Tcl library, such
-# as libtcl7.8.so or libtcl7.8.a.
-# TCL_LIB_SUFFIX -Specifies everything that comes after the "libtcl"
-# in the shared library name, using the $VERSION variable
-# to put the version in the right place. This is used
-# by platforms that need non-standard library names.
-# Examples: ${VERSION}.so.1.1 on NetBSD, since it needs
-# to have a version after the .so, and ${VERSION}.a
-# on AIX, since the Tcl shared library needs to have
-# a .a extension whereas shared objects for loadable
-# extensions have a .so extension. Defaults to
-# ${VERSION}${SHLIB_SUFFIX}.
-# TCL_NEEDS_EXP_FILE -
-# 1 means that an export file is needed to link to a
-# shared library.
-# TCL_EXP_FILE - The name of the installed export / import file which
-# should be used to link to the Tcl shared library.
-# Empty if Tcl is unshared.
-# TCL_BUILD_EXP_FILE -
-# The name of the built export / import file which
-# should be used to link to the Tcl shared library.
-# Empty if Tcl is unshared.
-# CFLAGS_DEBUG -
-# Flags used when running the compiler in debug mode
-# CFLAGS_OPTIMIZE -
-# Flags used when running the compiler in optimize mode
-# EXTRA_CFLAGS -
-# Extra CFLAGS to pass to the compiler
-#
-# Subst's the following vars:
-# DL_LIBS
-# CFLAGS_DEBUG
-# CFLAGS_OPTIMIZE
-# CFLAGS_WARNING
-#
-# STLIB_LD
-# SHLIB_LD
-# SHLIB_CFLAGS
-# SHLIB_LDFLAGS
-# LDFLAGS_DEBUG
-# LDFLAGS_OPTIMIZE
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_CONFIG_CFLAGS, [
- if test x"${TEA_INITED}" = x ; then
- # Can't refer to exact macro name or it will be substituted
- AC_MSG_ERROR([Must call TEA INIT before CONFIG_CFLAGS])
- fi
-
- # Step 0: Enable 64 bit support?
-
- AC_MSG_CHECKING([if 64bit support is enabled])
- AC_ARG_ENABLE(64bit,[ --enable-64bit enable 64bit support (where applicable) [[no]]], [do64bit=$enableval], [do64bit=no])
- AC_MSG_RESULT([$do64bit])
-
- # Step 0.b: Enable Solaris 64 bit VIS support?
-
- AC_MSG_CHECKING([if 64bit Sparc VIS support is requested])
- AC_ARG_ENABLE(64bit-vis,[ --enable-64bit-vis enable 64bit Sparc VIS support [[no]]], [do64bitVIS=$enableval], [do64bitVIS=no])
- AC_MSG_RESULT([$do64bitVIS])
-
- if test "$do64bitVIS" = "yes"; then
- # Force 64bit on with VIS
- do64bit=yes
- fi
-
- # Step 1: set the variable "system" to hold the name and version number
- # for the system. This can usually be done via the "uname" command, but
- # there are a few systems, like Next, where this doesn't work.
-
- AC_MSG_CHECKING([system version (for dynamic loading)])
- if test -f /usr/lib/NextStep/software_version; then
- system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
- else
- system=`uname -s`-`uname -r`
- if test "$?" -ne 0 ; then
- AC_MSG_RESULT([unknown (can't find uname command)])
- system=unknown
- else
- # Special check for weird MP-RAS system (uname returns weird
- # results, and the version is kept in special file).
-
- if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
- system=MP-RAS-`awk '{print $3}' /etc/.relid'`
- fi
- if test "`uname -s`" = "AIX" ; then
- system=AIX-`uname -v`.`uname -r`
- fi
- if test "${TEA_PLATFORM}" = "windows" ; then
- system=windows
- fi
- AC_MSG_RESULT([$system])
- fi
- fi
-
- # Step 2: check for existence of -ldl library. This is needed because
- # Linux can use either -ldl or -ldld for dynamic loading.
-
- AC_CHECK_LIB(dl, dlopen, have_dl=yes, have_dl=no)
-
- # Step 3: set configuration options based on system name and version.
-
- do64bit_ok=no
- EXTRA_CFLAGS=""
- TCL_EXPORT_FILE_SUFFIX=""
- UNSHARED_LIB_SUFFIX=""
- TCL_TRIM_DOTS='`echo ${VERSION} | tr -d .`'
- ECHO_VERSION='`echo ${VERSION}`'
- TCL_LIB_VERSIONS_OK=ok
- CFLAGS_DEBUG=-g
- CFLAGS_OPTIMIZE=-O
- if test "$GCC" = "yes" ; then
-#
-# no-implicit-int is already included in all.
-# -Wconversion generate some pretty useless warnings
-# among more useful ones. To be used once in a while.
-# Added -W which _is_ useful, it detects comparisons
-# between unsigned and signed, empty blocks, unused
-# parameters/vars....
-# CFLAGS_WARNING="-Wall -Wconversion -Wno-implicit-int"
- CFLAGS_WARNING="-Wall -W"
- else
- CFLAGS_WARNING=""
- fi
- TCL_NEEDS_EXP_FILE=0
- TCL_BUILD_EXP_FILE=""
- TCL_EXP_FILE=""
-dnl FIXME: Replace AC_CHECK_PROG with AC_CHECK_TOOL once cross compiling is fixed.
-dnl AC_CHECK_TOOL(AR, ar, :)
- AC_CHECK_PROG(AR, ar, ar)
- STLIB_LD='${AR} cr'
- case $system in
- windows)
- # This is a 2-stage check to make sure we have the 64-bit SDK
- # We have to know where the SDK is installed.
- if test "$do64bit" = "yes" ; then
- if test "x${MSSDK}x" = "xx" ; then
- MSSDK="C:/Progra~1/Microsoft SDK"
- fi
- # In order to work in the tortured autoconf environment,
- # we need to ensure that this path has no spaces
- MSSDK=`cygpath -w -s "$MSSDK" | sed -e 's!\\\!/!g'`
- if test ! -d "${MSSDK}/bin/win64" ; then
- AC_MSG_WARN("could not find 64-bit SDK to enable 64bit mode")
- do64bit="no"
- else
- do64bit_ok="yes"
- fi
- fi
-
- if test "${SHARED_BUILD}" = "0" ; then
- runtime=-MT
- else
- runtime=-MD
- fi
-
- if test "$do64bit" = "yes" ; then
- # All this magic is necessary for the Win64 SDK RC1 - hobbs
- export CC="${MSSDK}/Bin/Win64/cl.exe \
- -I${MSSDK}/Include/prerelease -I${MSSDK}/Include/Win64/crt \
- -I${MSSDK}/Include"
- export RC="${MSSDK}/bin/rc.exe"
- export lflags="-MACHINE:IA64 -LIBPATH:${MSSDK}/Lib/IA64 \
- -LIBPATH:${MSSDK}/Lib/Prerelease/IA64"
- export STLIB_LD="${MSSDK}/bin/win64/lib.exe -nologo ${lflags}"
- export LINKBIN="${MSSDK}/bin/win64/link.exe ${lflags}"
- CFLAGS_DEBUG="-nologo -Zi -Od -W3 ${runtime}d"
- CFLAGS_OPTIMIZE="-nologo -O2 -Gs -W2 ${runtime}"
- else
- RC="rc"
- STLIB_LD="lib -nologo"
- LINKBIN="link -link50compat"
- CFLAGS_DEBUG="-nologo -Z7 -Od -W3 -WX ${runtime}d"
- CFLAGS_OPTIMIZE="-nologo -O2 -Gs -GD -W2 ${runtime}"
- fi
-
- if test "$MINGW32" = "yes"; then
- # mingw gcc mode
- CFLAGS_DEBUG="-g"
- CFLAGS_OPTIMIZE="-O2"
- SHLIB_LD="gcc -shared"
- STLIB_LD='${AR} cr'
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- LDFLAGS_CONSOLE="-wl,--subsystem,console ${lflags}"
- LDFLAGS_WINDOW="-wl,--subsystem,windows ${lflags}"
- else
- SHLIB_LD="${LINKBIN} -dll -nologo"
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.lib'
- EXTRA_CFLAGS="-YX"
- # For information on what debugtype is most useful, see:
- # http://msdn.microsoft.com/library/en-us/dnvc60/html/gendepdebug.asp
- # This essentially turns it all on.
- LDFLAGS_DEBUG="-debug:full -debugtype:both -warn:2"
- LDFLAGS_OPTIMIZE="-release"
- LDFLAGS_CONSOLE="-link -subsystem:console ${lflags}"
- LDFLAGS_WINDOW="-link -subsystem:windows ${lflags}"
- PATHTYPE=-w
- fi
-
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".dll"
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.dll'
-
- TCL_LIB_VERSIONS_OK=nodots
- # Bogus to avoid getting this turned off
- DL_OBJS="tclLoadNone.obj"
- ;;
- AIX-*)
- if test "${TCL_THREADS}" = "1" -a "$GCC" != "yes" ; then
- # AIX requires the _r compiler when gcc isn't being used
- if test "${CC}" != "cc_r" ; then
- CC=${CC}_r
- fi
- AC_MSG_RESULT([Using $CC for compiling with threads])
- fi
- LIBS="$LIBS -lc"
- SHLIB_CFLAGS=""
- SHLIB_SUFFIX=".so"
- SHLIB_LD_LIBS='${LIBS}'
- if test "`uname -m`" = "ia64" ; then
- # AIX-5 uses ELF style dynamic libraries on IA-64, but not PPC
- SHLIB_LD="/usr/ccs/bin/ld -G -z text"
- # AIX-5 has dl* in libc.so
- DL_LIBS=""
- if test "$GCC" = "yes" ; then
- LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
- else
- LD_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
- fi
- else
- SHLIB_LD="${TCL_SRC_DIR}/unix/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry"
- DL_LIBS="-ldl"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- TCL_NEEDS_EXP_FILE=1
- TCL_EXPORT_FILE_SUFFIX='${VERSION}\$\{DBGX\}.exp'
- fi
- DL_OBJS="tclLoadDl.o"
- LDFLAGS=""
-
- # AIX v<=4.1 has some different flags than 4.2+
- if test "$system" = "AIX-4.1" -o "`uname -v`" -lt "4" ; then
- LIBOBJS="$LIBOBJS tclLoadAix.o"
- DL_LIBS="-lld"
- fi
-
- # On AIX <=v4 systems, libbsd.a has to be linked in to support
- # non-blocking file IO. This library has to be linked in after
- # the MATH_LIBS or it breaks the pow() function. The way to
- # insure proper sequencing, is to add it to the tail of MATH_LIBS.
- # This library also supplies gettimeofday.
- #
- # AIX does not have a timezone field in struct tm. When the AIX
- # bsd library is used, the timezone global and the gettimeofday
- # methods are to be avoided for timezone deduction instead, we
- # deduce the timezone by comparing the localtime result on a
- # known GMT value.
-
- AC_CHECK_LIB(bsd, gettimeofday, libbsd=yes, libbsd=no)
- if test $libbsd = yes; then
- MATH_LIBS="$MATH_LIBS -lbsd"
- AC_DEFINE(USE_DELTA_FOR_TZ)
- fi
-
- # Check to enable 64-bit flags for compiler/linker on AIX 4+
- if test "$do64bit" = "yes" -a "`uname -v`" -gt "3" ; then
- if test "$GCC" = "yes" ; then
- AC_MSG_WARN("64bit mode not supported with GCC on $system")
- else
- do64bit_ok=yes
- EXTRA_CFLAGS="-q64"
- LDFLAGS="-q64"
- RANLIB="${RANLIB} -X64"
- AR="${AR} -X64"
- SHLIB_LDFLAGS="-b64"
- fi
- fi
- ;;
- BSD/OS-2.1*|BSD/OS-3*)
- SHLIB_CFLAGS=""
- SHLIB_LD="shlicc -r"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- BSD/OS-4.*)
- SHLIB_CFLAGS="-export-dynamic -fPIC"
- SHLIB_LD="cc -shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS="-export-dynamic"
- LD_SEARCH_FLAGS=""
- ;;
- dgux*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- HP-UX-*.11.*)
- # Use updated header definitions where possible
- AC_DEFINE(_XOPEN_SOURCE_EXTENDED)
-
- SHLIB_SUFFIX=".sl"
- AC_CHECK_LIB(dld, shl_load, tcl_ok=yes, tcl_ok=no)
- if test "$tcl_ok" = yes; then
- SHLIB_CFLAGS="+z"
- SHLIB_LD="ld -b"
- SHLIB_LD_LIBS='${LIBS}'
- DL_OBJS="tclLoadShl.o"
- DL_LIBS="-ldld"
- LDFLAGS="-Wl,-E"
- LD_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
- fi
-
- # Users may want PA-RISC 1.1/2.0 portable code - needs HP cc
- #EXTRA_CFLAGS="+DAportable"
-
- # Check to enable 64-bit flags for compiler/linker
- if test "$do64bit" = "yes" ; then
- if test "$GCC" = "yes" ; then
- hpux_arch=`gcc -dumpmachine`
- case $hpux_arch in
- hppa64*)
- # 64-bit gcc in use. Fix flags for GNU ld.
- do64bit_ok=yes
- SHLIB_LD="gcc -shared"
- SHLIB_LD_LIBS=""
- LD_SEARCH_FLAGS=''
- ;;
- *)
- AC_MSG_WARN("64bit mode not supported with GCC on $system")
- ;;
- esac
- else
- do64bit_ok=yes
- EXTRA_CFLAGS="+DA2.0W"
- LDFLAGS="+DA2.0W $LDFLAGS"
- fi
- fi
- ;;
- HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*)
- SHLIB_SUFFIX=".sl"
- AC_CHECK_LIB(dld, shl_load, tcl_ok=yes, tcl_ok=no)
- if test "$tcl_ok" = yes; then
- SHLIB_CFLAGS="+z"
- SHLIB_LD="ld -b"
- SHLIB_LD_LIBS=""
- DL_OBJS="tclLoadShl.o"
- DL_LIBS="-ldld"
- LDFLAGS="-Wl,-E"
- LD_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
- fi
- ;;
- IRIX-4.*)
- SHLIB_CFLAGS="-G 0"
- SHLIB_SUFFIX=".a"
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
- SHLIB_LD_LIBS='${LIBS}'
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS="-Wl,-D,08000000"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a'
- ;;
- IRIX-5.*)
- SHLIB_CFLAGS=""
- SHLIB_LD="ld -shared -rdata_shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- EXTRA_CFLAGS=""
- LDFLAGS=""
- ;;
- IRIX-6.*|IRIX64-6.5*)
- SHLIB_CFLAGS=""
- SHLIB_LD="ld -n32 -shared -rdata_shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- if test "$GCC" = "yes" ; then
- EXTRA_CFLAGS="-mabi=n32"
- LDFLAGS="-mabi=n32"
- else
- case $system in
- IRIX-6.3)
- # Use to build 6.2 compatible binaries on 6.3.
- EXTRA_CFLAGS="-n32 -D_OLD_TERMIOS"
- ;;
- *)
- EXTRA_CFLAGS="-n32"
- ;;
- esac
- LDFLAGS="-n32"
- fi
- ;;
- IRIX64-6.*)
- SHLIB_CFLAGS=""
- SHLIB_LD="ld -n32 -shared -rdata_shared"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
-
- # Check to enable 64-bit flags for compiler/linker
-
- if test "$do64bit" = "yes" ; then
- if test "$GCC" = "yes" ; then
- AC_MSG_WARN([64bit mode not supported by gcc])
- else
- do64bit_ok=yes
- SHLIB_LD="ld -64 -shared -rdata_shared"
- EXTRA_CFLAGS="-64"
- LDFLAGS="-64"
- fi
- fi
- ;;
- Linux*)
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
-
- # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings
- # when you inline the string and math operations. Turn this off to
- # get rid of the warnings.
-
- CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
-
- if test "$have_dl" = yes; then
- SHLIB_LD="${CC} -shared"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS="-rdynamic"
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- else
- AC_CHECK_HEADER(dld.h, [
- SHLIB_LD="ld -shared"
- DL_OBJS="tclLoadDld.o"
- DL_LIBS="-ldld"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""])
- fi
- if test "`uname -m`" = "alpha" ; then
- EXTRA_CFLAGS="-mieee"
- fi
-
- # The combo of gcc + glibc has a bug related
- # to inlining of functions like strtod(). The
- # -fno-builtin flag should address this problem
- # but it does not work. The -fno-inline flag
- # is kind of overkill but it works.
- # Disable inlining only when one of the
- # files in compat/*.c is being linked in.
- if test x"${LIBOBJS}" != x ; then
- EXTRA_CFLAGS="${EXTRA_CFLAGS} -fno-inline"
- fi
-
- ;;
- GNU*)
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
-
- if test "$have_dl" = yes; then
- SHLIB_LD="${CC} -shared"
- DL_OBJS=""
- DL_LIBS="-ldl"
- LDFLAGS="-rdynamic"
- LD_SEARCH_FLAGS=""
- else
- AC_CHECK_HEADER(dld.h, [
- SHLIB_LD="ld -shared"
- DL_OBJS=""
- DL_LIBS="-ldld"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""])
- fi
- if test "`uname -m`" = "alpha" ; then
- EXTRA_CFLAGS="-mieee"
- fi
- ;;
- MP-RAS-02*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- MP-RAS-*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS="-Wl,-Bexport"
- LD_SEARCH_FLAGS=""
- ;;
- NetBSD-*|FreeBSD-[[1-2]].*|OpenBSD-*)
- # Not available on all versions: check for include file.
- AC_CHECK_HEADER(dlfcn.h, [
- # NetBSD/SPARC needs -fPIC, -fpic will not do.
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD="ld -Bshareable -x"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- AC_MSG_CHECKING([for ELF])
- AC_EGREP_CPP(yes, [
-#ifdef __ELF__
- yes
-#endif
- ],
- AC_MSG_RESULT([yes])
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so',
- AC_MSG_RESULT([no])
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
- )
- ], [
- SHLIB_CFLAGS=""
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".a"
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- ])
-
- # FreeBSD doesn't handle version numbers with dots.
-
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- TCL_LIB_VERSIONS_OK=nodots
- ;;
- FreeBSD-*)
- # FreeBSD 3.* and greater have ELF.
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD="ld -Bshareable -x"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS="-export-dynamic"
- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
- if test "${TCL_THREADS}" = "1" ; then
- # The -pthread needs to go in the CFLAGS, not LIBS
- LIBS=`echo $LIBS | sed s/-pthread//`
- EXTRA_CFLAGS="-pthread"
- LDFLAGS="$LDFLAGS -pthread"
- fi
- case $system in
- FreeBSD-3.*)
- # FreeBSD-3 doesn't handle version numbers with dots.
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
- TCL_LIB_VERSIONS_OK=nodots
- ;;
- esac
- ;;
- Rhapsody-*|Darwin-*)
- SHLIB_CFLAGS="-fno-common"
- SHLIB_LD="cc -dynamiclib \${LDFLAGS}"
- TCL_SHLIB_LD_EXTRAS="-compatibility_version ${TCL_MAJOR_VERSION} -current_version \${VERSION} -install_name \${LIB_RUNTIME_DIR}/\${TCL_LIB_FILE} -prebind -seg1addr 0xa000000"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".dylib"
- DL_OBJS="tclLoadDyld.o"
- DL_LIBS=""
- LDFLAGS="-prebind"
- LD_SEARCH_FLAGS=""
- CFLAGS_OPTIMIZE="-O3"
- EXTRA_CFLAGS="-arch ppc -pipe"
- ;;
- NEXTSTEP-*)
- SHLIB_CFLAGS=""
- SHLIB_LD="cc -nostdlib -r"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadNext.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- OS/390-*)
- CFLAGS_OPTIMIZE="" # Optimizer is buggy
- AC_DEFINE(_OE_SOCKETS) # needed in sys/socket.h
- ;;
- OSF1-1.0|OSF1-1.1|OSF1-1.2)
- # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1
- SHLIB_CFLAGS=""
- # Hack: make package name same as library name
- SHLIB_LD='ld -R -export $@:'
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadOSF.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- OSF1-1.*)
- # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2
- SHLIB_CFLAGS="-fPIC"
- if test "$SHARED_BUILD" = "1" ; then
- SHLIB_LD="ld -shared"
- else
- SHLIB_LD="ld -non_shared"
- fi
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- OSF1-V*)
- # Digital OSF/1
- SHLIB_CFLAGS=""
- if test "$SHARED_BUILD" = "1" ; then
- SHLIB_LD='ld -shared -expect_unresolved "*"'
- else
- SHLIB_LD='ld -non_shared -expect_unresolved "*"'
- fi
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
- if test "$GCC" != "yes" ; then
- EXTRA_CFLAGS="-DHAVE_TZSET -std1"
- fi
- # see pthread_intro(3) for pthread support on osf1, k.furukawa
- if test "${TCL_THREADS}" = "1" ; then
- EXTRA_CFLAGS="${EXTRA_CFLAGS} -DHAVE_PTHREAD_ATTR_SETSTACKSIZE"
- EXTRA_CFLAGS="${EXTRA_CFLAGS} -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
- LIBS=`echo $LIBS | sed s/-lpthreads//`
- if test "$GCC" = "yes" ; then
- LIBS="$LIBS -lpthread -lmach -lexc"
- else
- EXTRA_CFLAGS="${EXTRA_CFLAGS} -pthread"
- LDFLAGS="-pthread"
- fi
- fi
-
- ;;
- QNX-6*)
- # QNX RTP
- # This may work for all QNX, but it was only reported for v6.
- SHLIB_CFLAGS="-fPIC"
- SHLIB_LD="ld -Bshareable -x"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- # dlopen is in -lc on QNX
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- RISCos-*)
- SHLIB_CFLAGS="-G 0"
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".a"
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS="-Wl,-D,08000000"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- ;;
- SCO_SV-3.2*)
- # Note, dlopen is available only on SCO 3.2.5 and greater. However,
- # this test works, since "uname -s" was non-standard in 3.2.4 and
- # below.
- if test "$GCC" = "yes" ; then
- SHLIB_CFLAGS="-fPIC -melf"
- LDFLAGS="-melf -Wl,-Bexport"
- else
- SHLIB_CFLAGS="-Kpic -belf"
- LDFLAGS="-belf -Wl,-Bexport"
- fi
- SHLIB_LD="ld -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LD_SEARCH_FLAGS=""
- ;;
- SINIX*5.4*)
- SHLIB_CFLAGS="-K PIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- ;;
- SunOS-4*)
- SHLIB_CFLAGS="-PIC"
- SHLIB_LD="ld"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
-
- # SunOS can't handle version numbers with dots in them in library
- # specs, like -ltcl7.5, so use -ltcl75 instead. Also, it
- # requires an extra version number at the end of .so file names.
- # So, the library has to have a name like libtcl75.so.1.0
-
- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
- UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
- TCL_LIB_VERSIONS_OK=nodots
- ;;
- SunOS-5.[[0-6]]*)
-
- # Note: If _REENTRANT isn't defined, then Solaris
- # won't define thread-safe library routines.
-
- AC_DEFINE(_REENTRANT)
- AC_DEFINE(_POSIX_PTHREAD_SEMANTICS)
-
- SHLIB_CFLAGS="-KPIC"
-
- # Note: need the LIBS below, otherwise Tk won't find Tcl's
- # symbols when dynamically loaded into tclsh.
-
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- LDFLAGS=""
- if test "$GCC" = "yes" ; then
- SHLIB_LD="$CC -shared"
- LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
- else
- SHLIB_LD="/usr/ccs/bin/ld -G -z text"
- LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
- fi
- ;;
- SunOS-5*)
-
- # Note: If _REENTRANT isn't defined, then Solaris
- # won't define thread-safe library routines.
-
- AC_DEFINE(_REENTRANT)
- AC_DEFINE(_POSIX_PTHREAD_SEMANTICS)
-
- SHLIB_CFLAGS="-KPIC"
- LDFLAGS=""
-
- # Check to enable 64-bit flags for compiler/linker
- if test "$do64bit" = "yes" ; then
- arch=`isainfo`
- if test "$arch" = "sparcv9 sparc" ; then
- if test "$GCC" = "yes" ; then
- AC_MSG_WARN("64bit mode not supported with GCC on $system")
- else
- do64bit_ok=yes
- if test "$do64bitVIS" = "yes" ; then
- EXTRA_CFLAGS="-xarch=v9a"
- LDFLAGS="-xarch=v9a"
- else
- EXTRA_CFLAGS="-xarch=v9"
- LDFLAGS="-xarch=v9"
- fi
- fi
- else
- AC_MSG_WARN("64bit mode only supported sparcv9 system")
- fi
- fi
-
- # Note: need the LIBS below, otherwise Tk won't find Tcl's
- # symbols when dynamically loaded into tclsh.
-
- SHLIB_LD_LIBS='${LIBS}'
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- if test "$GCC" = "yes" ; then
- SHLIB_LD="$CC -shared"
- LD_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
- else
- SHLIB_LD="/usr/ccs/bin/ld -G -z text"
- LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
- fi
- ;;
- ULTRIX-4.*)
- SHLIB_CFLAGS="-G 0"
- SHLIB_SUFFIX=".a"
- SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
- SHLIB_LD_LIBS='${LIBS}'
- DL_OBJS="tclLoadAout.o"
- DL_LIBS=""
- LDFLAGS="-Wl,-D,08000000"
- LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
- if test "$GCC" != "yes" ; then
- EXTRA_CFLAGS="-DHAVE_TZSET -std1"
- fi
- ;;
- UNIX_SV* | UnixWare-5*)
- SHLIB_CFLAGS="-KPIC"
- SHLIB_LD="cc -G"
- SHLIB_LD_LIBS=""
- SHLIB_SUFFIX=".so"
- DL_OBJS="tclLoadDl.o"
- DL_LIBS="-ldl"
- # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
- # that don't grok the -Bexport option. Test that it does.
- hold_ldflags=$LDFLAGS
- AC_MSG_CHECKING([for ld accepts -Bexport flag])
- LDFLAGS="${LDFLAGS} -Wl,-Bexport"
- AC_TRY_LINK(, [int i;], found=yes, found=no)
- LDFLAGS=$hold_ldflags
- AC_MSG_RESULT([$found])
- if test $found = yes; then
- LDFLAGS="-Wl,-Bexport"
- else
- LDFLAGS=""
- fi
- LD_SEARCH_FLAGS=""
- ;;
- esac
-
- if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then
- AC_MSG_WARN("64bit support being disabled -- don\'t know magic for this platform")
- fi
-
- # Step 4: If pseudo-static linking is in use (see K. B. Kenny, "Dynamic
- # Loading for Tcl -- What Became of It?". Proc. 2nd Tcl/Tk Workshop,
- # New Orleans, LA, Computerized Processes Unlimited, 1994), then we need
- # to determine which of several header files defines the a.out file
- # format (a.out.h, sys/exec.h, or sys/exec_aout.h). At present, we
- # support only a file format that is more or less version-7-compatible.
- # In particular,
- # - a.out files must begin with `struct exec'.
- # - the N_TXTOFF on the `struct exec' must compute the seek address
- # of the text segment
- # - The `struct exec' must contain a_magic, a_text, a_data, a_bss
- # and a_entry fields.
- # The following compilation should succeed if and only if either sys/exec.h
- # or a.out.h is usable for the purpose.
- #
- # Note that the modified COFF format used on MIPS Ultrix 4.x is usable; the
- # `struct exec' includes a second header that contains information that
- # duplicates the v7 fields that are needed.
-
- if test "x$DL_OBJS" = "xtclLoadAout.o" ; then
- AC_MSG_CHECKING([sys/exec.h])
- AC_TRY_COMPILE([#include <sys/exec.h>],[
- struct exec foo;
- unsigned long seek;
- int flag;
-#if defined(__mips) || defined(mips)
- seek = N_TXTOFF (foo.ex_f, foo.ex_o);
-#else
- seek = N_TXTOFF (foo);
-#endif
- flag = (foo.a_magic == OMAGIC);
- return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
- ], tcl_ok=usable, tcl_ok=unusable)
- AC_MSG_RESULT([$tcl_ok])
- if test $tcl_ok = usable; then
- AC_DEFINE(USE_SYS_EXEC_H)
- else
- AC_MSG_CHECKING([a.out.h])
- AC_TRY_COMPILE([#include <a.out.h>],[
- struct exec foo;
- unsigned long seek;
- int flag;
-#if defined(__mips) || defined(mips)
- seek = N_TXTOFF (foo.ex_f, foo.ex_o);
-#else
- seek = N_TXTOFF (foo);
-#endif
- flag = (foo.a_magic == OMAGIC);
- return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
- ], tcl_ok=usable, tcl_ok=unusable)
- AC_MSG_RESULT([$tcl_ok])
- if test $tcl_ok = usable; then
- AC_DEFINE(USE_A_OUT_H)
- else
- AC_MSG_CHECKING([sys/exec_aout.h])
- AC_TRY_COMPILE([#include <sys/exec_aout.h>],[
- struct exec foo;
- unsigned long seek;
- int flag;
-#if defined(__mips) || defined(mips)
- seek = N_TXTOFF (foo.ex_f, foo.ex_o);
-#else
- seek = N_TXTOFF (foo);
-#endif
- flag = (foo.a_midmag == OMAGIC);
- return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry;
- ], tcl_ok=usable, tcl_ok=unusable)
- AC_MSG_RESULT([$tcl_ok])
- if test $tcl_ok = usable; then
- AC_DEFINE(USE_SYS_EXEC_AOUT_H)
- else
- DL_OBJS=""
- fi
- fi
- fi
- fi
-
- # Step 5: disable dynamic loading if requested via a command-line switch.
-
- AC_ARG_ENABLE(load, [ --disable-load disallow dynamic loading and "load" command],
- [tcl_ok=$enableval], [tcl_ok=yes])
- if test "$tcl_ok" = "no"; then
- DL_OBJS=""
- fi
-
- if test "x$DL_OBJS" != "x" ; then
- BUILD_DLTEST="\$(DLTEST_TARGETS)"
- else
- echo "Can't figure out how to do dynamic loading or shared libraries"
- echo "on this system."
- SHLIB_CFLAGS=""
- SHLIB_LD=""
- SHLIB_SUFFIX=""
- DL_OBJS="tclLoadNone.o"
- DL_LIBS=""
- LDFLAGS=""
- LD_SEARCH_FLAGS=""
- BUILD_DLTEST=""
- fi
-
- # If we're running gcc, then change the C flags for compiling shared
- # libraries to the right flags for gcc, instead of those for the
- # standard manufacturer compiler.
-
- if test "$DL_OBJS" != "tclLoadNone.o" ; then
- if test "$GCC" = "yes" ; then
- case $system in
- AIX-*)
- ;;
- BSD/OS*)
- ;;
- IRIX*)
- ;;
- NetBSD-*|FreeBSD-*|OpenBSD-*)
- ;;
- Rhapsody-*|Darwin-*)
- ;;
- RISCos-*)
- ;;
- SCO_SV-3.2*)
- ;;
- ULTRIX-4.*)
- ;;
- windows)
- if test "$MINGW32" != "yes"; then
- SHLIB_CFLAGS="-fPIC"
- fi
- ;;
- *)
- SHLIB_CFLAGS="-fPIC"
- ;;
- esac
- fi
- fi
-
- if test "$SHARED_LIB_SUFFIX" = "" ; then
- SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}${SHLIB_SUFFIX}'
- fi
- if test "$UNSHARED_LIB_SUFFIX" = "" ; then
- UNSHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a'
- fi
-
- AC_SUBST(DL_LIBS)
- AC_SUBST(CFLAGS_DEBUG)
- AC_SUBST(CFLAGS_OPTIMIZE)
- AC_SUBST(CFLAGS_WARNING)
- AC_SUBST(EXTRA_CFLAGS)
-
- SHLIB_LDFLAGS='$(LDFLAGS_DEFAULT)'
- AC_SUBST(STLIB_LD)
- AC_SUBST(SHLIB_LD)
- AC_SUBST(SHLIB_CFLAGS)
- AC_SUBST(SHLIB_LDFLAGS)
- AC_SUBST(SHLIB_LD_LIBS)
- AC_SUBST(LDFLAGS_DEBUG)
- AC_SUBST(LDFLAGS_OPTIMIZE)
-])
-
-#--------------------------------------------------------------------
-# TEA_SERIAL_PORT
-#
-# Determine which interface to use to talk to the serial port.
-# Note that #include lines must begin in leftmost column for
-# some compilers to recognize them as preprocessor directives,
-# and some build environments have stdin not pointing at a
-# pseudo-terminal (usually /dev/null instead.)
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines only one of the following vars:
-# HAVE_SYS_MODEM_H
-# USE_TERMIOS
-# USE_TERMIO
-# USE_SGTTY
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_SERIAL_PORT, [
- AC_CHECK_HEADERS(sys/modem.h)
- AC_MSG_CHECKING([termios vs. termio vs. sgtty])
- AC_CACHE_VAL(tcl_cv_api_serial, [
- AC_TRY_RUN([
-#include <termios.h>
-
-int main() {
- struct termios t;
- if (tcgetattr(0, &t) == 0) {
- cfsetospeed(&t, 0);
- t.c_cflag |= PARENB | PARODD | CSIZE | CSTOPB;
- return 0;
- }
- return 1;
-}], tcl_cv_api_serial=termios, tcl_cv_api_serial=no, tcl_cv_api_serial=no)
- if test $tcl_cv_api_serial = no ; then
- AC_TRY_RUN([
-#include <termio.h>
-
-int main() {
- struct termio t;
- if (ioctl(0, TCGETA, &t) == 0) {
- t.c_cflag |= CBAUD | PARENB | PARODD | CSIZE | CSTOPB;
- return 0;
- }
- return 1;
-}], tcl_cv_api_serial=termio, tcl_cv_api_serial=no, tcl_cv_api_serial=no)
- fi
- if test $tcl_cv_api_serial = no ; then
- AC_TRY_RUN([
-#include <sgtty.h>
-
-int main() {
- struct sgttyb t;
- if (ioctl(0, TIOCGETP, &t) == 0) {
- t.sg_ospeed = 0;
- t.sg_flags |= ODDP | EVENP | RAW;
- return 0;
- }
- return 1;
-}], tcl_cv_api_serial=sgtty, tcl_cv_api_serial=none, tcl_cv_api_serial=none)
- fi
- if test $tcl_cv_api_serial = no ; then
- AC_TRY_RUN([
-#include <termios.h>
-#include <errno.h>
-
-int main() {
- struct termios t;
- if (tcgetattr(0, &t) == 0
- || errno == ENOTTY || errno == ENXIO || errno == EINVAL) {
- cfsetospeed(&t, 0);
- t.c_cflag |= PARENB | PARODD | CSIZE | CSTOPB;
- return 0;
- }
- return 1;
-}], tcl_cv_api_serial=termios, tcl_cv_api_serial=no, tcl_cv_api_serial=no)
- fi
- if test $tcl_cv_api_serial = no; then
- AC_TRY_RUN([
-#include <termio.h>
-#include <errno.h>
-
-int main() {
- struct termio t;
- if (ioctl(0, TCGETA, &t) == 0
- || errno == ENOTTY || errno == ENXIO || errno == EINVAL) {
- t.c_cflag |= CBAUD | PARENB | PARODD | CSIZE | CSTOPB;
- return 0;
- }
- return 1;
- }], tcl_cv_api_serial=termio, tcl_cv_api_serial=no, tcl_cv_api_serial=no)
- fi
- if test $tcl_cv_api_serial = no; then
- AC_TRY_RUN([
-#include <sgtty.h>
-#include <errno.h>
-
-int main() {
- struct sgttyb t;
- if (ioctl(0, TIOCGETP, &t) == 0
- || errno == ENOTTY || errno == ENXIO || errno == EINVAL) {
- t.sg_ospeed = 0;
- t.sg_flags |= ODDP | EVENP | RAW;
- return 0;
- }
- return 1;
-}], tcl_cv_api_serial=sgtty, tcl_cv_api_serial=none, tcl_cv_api_serial=none)
- fi])
- case $tcl_cv_api_serial in
- termios) AC_DEFINE(USE_TERMIOS);;
- termio) AC_DEFINE(USE_TERMIO);;
- sgtty) AC_DEFINE(USE_SGTTY);;
- esac
- AC_MSG_RESULT([$tcl_cv_api_serial])
-])
-
-#--------------------------------------------------------------------
-# TEA_MISSING_POSIX_HEADERS
-#
-# Supply substitutes for missing POSIX header files. Special
-# notes:
-# - stdlib.h doesn't define strtol, strtoul, or
-# strtod insome versions of SunOS
-# - some versions of string.h don't declare procedures such
-# as strstr
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines some of the following vars:
-# NO_DIRENT_H
-# NO_ERRNO_H
-# NO_VALUES_H
-# NO_LIMITS_H
-# NO_STDLIB_H
-# NO_STRING_H
-# NO_SYS_WAIT_H
-# NO_DLFCN_H
-# HAVE_UNISTD_H
-# HAVE_SYS_PARAM_H
-#
-# HAVE_STRING_H ?
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_MISSING_POSIX_HEADERS, [
- AC_MSG_CHECKING([dirent.h])
- AC_TRY_LINK([#include <sys/types.h>
-#include <dirent.h>], [
-#ifndef _POSIX_SOURCE
-# ifdef __Lynx__
- /*
- * Generate compilation error to make the test fail: Lynx headers
- * are only valid if really in the POSIX environment.
- */
-
- missing_procedure();
-# endif
-#endif
-DIR *d;
-struct dirent *entryPtr;
-char *p;
-d = opendir("foobar");
-entryPtr = readdir(d);
-p = entryPtr->d_name;
-closedir(d);
-], tcl_ok=yes, tcl_ok=no)
-
- if test $tcl_ok = no; then
- AC_DEFINE(NO_DIRENT_H)
- fi
-
- AC_MSG_RESULT([$tcl_ok])
- AC_CHECK_HEADER(errno.h, , [AC_DEFINE(NO_ERRNO_H)])
- AC_CHECK_HEADER(float.h, , [AC_DEFINE(NO_FLOAT_H)])
- AC_CHECK_HEADER(values.h, , [AC_DEFINE(NO_VALUES_H)])
- AC_CHECK_HEADER(limits.h, , [AC_DEFINE(NO_LIMITS_H)])
- AC_CHECK_HEADER(stdlib.h, tcl_ok=1, tcl_ok=0)
- AC_EGREP_HEADER(strtol, stdlib.h, , tcl_ok=0)
- AC_EGREP_HEADER(strtoul, stdlib.h, , tcl_ok=0)
- AC_EGREP_HEADER(strtod, stdlib.h, , tcl_ok=0)
- if test $tcl_ok = 0; then
- AC_DEFINE(NO_STDLIB_H)
- fi
- AC_CHECK_HEADER(string.h, tcl_ok=1, tcl_ok=0)
- AC_EGREP_HEADER(strstr, string.h, , tcl_ok=0)
- AC_EGREP_HEADER(strerror, string.h, , tcl_ok=0)
-
- # See also memmove check below for a place where NO_STRING_H can be
- # set and why.
-
- if test $tcl_ok = 0; then
- AC_DEFINE(NO_STRING_H)
- fi
-
- AC_CHECK_HEADER(sys/wait.h, , [AC_DEFINE(NO_SYS_WAIT_H)])
- AC_CHECK_HEADER(dlfcn.h, , [AC_DEFINE(NO_DLFCN_H)])
-
- # OS/390 lacks sys/param.h (and doesn't need it, by chance).
-
- AC_HAVE_HEADERS(unistd.h sys/param.h)
-
-])
-
-#--------------------------------------------------------------------
-# TEA_PATH_X
-#
-# Locate the X11 header files and the X11 library archive. Try
-# the ac_path_x macro first, but if it doesn't find the X stuff
-# (e.g. because there's no xmkmf program) then check through
-# a list of possible directories. Under some conditions the
-# autoconf macro will return an include directory that contains
-# no include files, so double-check its result just to be safe.
-#
-# This should be called after TEA_CONFIG_CFLAGS as setting the
-# LIBS line can confuse some configure macro magic.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Sets the following vars:
-# XINCLUDES
-# XLIBSW
-# LIBS (appends to)
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_PATH_X, [
- if test "${TEA_PLATFORM}" = "unix" ; then
- TEA_PATH_UNIX_X
- fi
-])
-
-AC_DEFUN(TEA_PATH_UNIX_X, [
- AC_PATH_X
- not_really_there=""
- if test "$no_x" = ""; then
- if test "$x_includes" = ""; then
- AC_TRY_CPP([#include <X11/XIntrinsic.h>], , not_really_there="yes")
- else
- if test ! -r $x_includes/X11/Intrinsic.h; then
- not_really_there="yes"
- fi
- fi
- fi
- if test "$no_x" = "yes" -o "$not_really_there" = "yes"; then
- AC_MSG_CHECKING([for X11 header files])
- XINCLUDES="# no special path needed"
- AC_TRY_CPP([#include <X11/Intrinsic.h>], , XINCLUDES="nope")
- if test "$XINCLUDES" = nope; then
- dirs="/usr/unsupported/include /usr/local/include /usr/X386/include /usr/X11R6/include /usr/X11R5/include /usr/include/X11R5 /usr/include/X11R4 /usr/openwin/include /usr/X11/include /usr/sww/include"
- for i in $dirs ; do
- if test -r $i/X11/Intrinsic.h; then
- AC_MSG_RESULT([$i])
- XINCLUDES=" -I$i"
- break
- fi
- done
- fi
- else
- if test "$x_includes" != ""; then
- XINCLUDES=-I$x_includes
- else
- XINCLUDES="# no special path needed"
- fi
- fi
- if test "$XINCLUDES" = nope; then
- AC_MSG_RESULT([could not find any!])
- XINCLUDES="# no include files found"
- fi
-
- if test "$no_x" = yes; then
- AC_MSG_CHECKING([for X11 libraries])
- XLIBSW=nope
- dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib"
- for i in $dirs ; do
- if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then
- AC_MSG_RESULT([$i])
- XLIBSW="-L$i -lX11"
- x_libraries="$i"
- break
- fi
- done
- else
- if test "$x_libraries" = ""; then
- XLIBSW=-lX11
- else
- XLIBSW="-L$x_libraries -lX11"
- fi
- fi
- if test "$XLIBSW" = nope ; then
- AC_CHECK_LIB(Xwindow, XCreateWindow, XLIBSW=-lXwindow)
- fi
- if test "$XLIBSW" = nope ; then
- AC_MSG_RESULT([could not find any! Using -lX11.])
- XLIBSW=-lX11
- fi
- if test x"${XLIBSW}" != x ; then
- LIBS="${LIBS} ${XLIBSW}"
- fi
-])
-
-#--------------------------------------------------------------------
-# TEA_BLOCKING_STYLE
-#
-# The statements below check for systems where POSIX-style
-# non-blocking I/O (O_NONBLOCK) doesn't work or is unimplemented.
-# On these systems (mostly older ones), use the old BSD-style
-# FIONBIO approach instead.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines some of the following vars:
-# HAVE_SYS_IOCTL_H
-# HAVE_SYS_FILIO_H
-# USE_FIONBIO
-# O_NONBLOCK
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_BLOCKING_STYLE, [
- AC_CHECK_HEADERS(sys/ioctl.h)
- AC_CHECK_HEADERS(sys/filio.h)
- AC_MSG_CHECKING([FIONBIO vs. O_NONBLOCK for nonblocking I/O])
- if test -f /usr/lib/NextStep/software_version; then
- system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
- else
- system=`uname -s`-`uname -r`
- if test "$?" -ne 0 ; then
- system=unknown
- else
- # Special check for weird MP-RAS system (uname returns weird
- # results, and the version is kept in special file).
-
- if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
- system=MP-RAS-`awk '{print $3}' /etc/.relid'`
- fi
- if test "`uname -s`" = "AIX" ; then
- system=AIX-`uname -v`.`uname -r`
- fi
- fi
- fi
- case $system in
- # There used to be code here to use FIONBIO under AIX. However, it
- # was reported that FIONBIO doesn't work under AIX 3.2.5. Since
- # using O_NONBLOCK seems fine under AIX 4.*, I removed the FIONBIO
- # code (JO, 5/31/97).
-
- OSF*)
- AC_DEFINE(USE_FIONBIO)
- AC_MSG_RESULT([FIONBIO])
- ;;
- SunOS-4*)
- AC_DEFINE(USE_FIONBIO)
- AC_MSG_RESULT([FIONBIO])
- ;;
- ULTRIX-4.*)
- AC_DEFINE(USE_FIONBIO)
- AC_MSG_RESULT([FIONBIO])
- ;;
- *)
- AC_MSG_RESULT([O_NONBLOCK])
- ;;
- esac
-])
-
-#--------------------------------------------------------------------
-# TEA_TIME_HANLDER
-#
-# Checks how the system deals with time.h, what time structures
-# are used on the system, and what fields the structures have.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines some of the following vars:
-# USE_DELTA_FOR_TZ
-# HAVE_TM_GMTOFF
-# HAVE_TM_TZADJ
-# HAVE_TIMEZONE_VAR
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_TIME_HANDLER, [
- AC_CHECK_HEADERS(sys/time.h)
- AC_HEADER_TIME
- AC_STRUCT_TIMEZONE
-
- AC_CHECK_FUNCS(gmtime_r localtime_r)
-
- AC_MSG_CHECKING([tm_tzadj in struct tm])
- AC_CACHE_VAL(tcl_cv_member_tm_tzadj,
- AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_tzadj;],
- tcl_cv_member_tm_tzadj=yes, tcl_cv_member_tm_tzadj=no))
- AC_MSG_RESULT([$tcl_cv_member_tm_tzadj])
- if test $tcl_cv_member_tm_tzadj = yes ; then
- AC_DEFINE(HAVE_TM_TZADJ)
- fi
-
- AC_MSG_CHECKING([tm_gmtoff in struct tm])
- AC_CACHE_VAL(tcl_cv_member_tm_gmtoff,
- AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_gmtoff;],
- tcl_cv_member_tm_gmtoff=yes, tcl_cv_member_tm_gmtoff=no))
- AC_MSG_RESULT([$tcl_cv_member_tm_gmtoff])
- if test $tcl_cv_member_tm_gmtoff = yes ; then
- AC_DEFINE(HAVE_TM_GMTOFF)
- fi
-
- #
- # Its important to include time.h in this check, as some systems
- # (like convex) have timezone functions, etc.
- #
- AC_MSG_CHECKING([long timezone variable])
- AC_CACHE_VAL(tcl_cv_var_timezone,
- AC_TRY_COMPILE([#include <time.h>],
- [extern long timezone;
- timezone += 1;
- exit (0);],
- tcl_cv_timezone_long=yes, tcl_cv_timezone_long=no))
- AC_MSG_RESULT([$tcl_cv_timezone_long])
- if test $tcl_cv_timezone_long = yes ; then
- AC_DEFINE(HAVE_TIMEZONE_VAR)
- else
- #
- # On some systems (eg IRIX 6.2), timezone is a time_t and not a long.
- #
- AC_MSG_CHECKING([time_t timezone variable])
- AC_CACHE_VAL(tcl_cv_timezone_time,
- AC_TRY_COMPILE([#include <time.h>],
- [extern time_t timezone;
- timezone += 1;
- exit (0);],
- tcl_cv_timezone_time=yes, tcl_cv_timezone_time=no))
- AC_MSG_RESULT([$tcl_cv_timezone_time])
- if test $tcl_cv_timezone_time = yes ; then
- AC_DEFINE(HAVE_TIMEZONE_VAR)
- fi
- fi
-])
-
-#--------------------------------------------------------------------
-# TEA_BUGGY_STRTOD
-#
-# Under Solaris 2.4, strtod returns the wrong value for the
-# terminating character under some conditions. Check for this
-# and if the problem exists use a substitute procedure
-# "fixstrtod" (provided by Tcl) that corrects the error.
-# Also, on Compaq's Tru64 Unix 5.0,
-# strtod(" ") returns 0.0 instead of a failure to convert.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Might defines some of the following vars:
-# strtod (=fixstrtod)
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_BUGGY_STRTOD, [
- AC_CHECK_FUNC(strtod, tcl_strtod=1, tcl_strtod=0)
- if test "$tcl_strtod" = 1; then
- AC_MSG_CHECKING([for Solaris2.4/Tru64 strtod bugs])
- AC_TRY_RUN([
- extern double strtod();
- int main()
- {
- char *string = "NaN", *spaceString = " ";
- char *term;
- double value;
- value = strtod(string, &term);
- if ((term != string) && (term[-1] == 0)) {
- exit(1);
- }
- value = strtod(spaceString, &term);
- if (term == (spaceString+1)) {
- exit(1);
- }
- exit(0);
- }], tcl_ok=1, tcl_ok=0, tcl_ok=0)
- if test "$tcl_ok" = 1; then
- AC_MSG_RESULT([ok])
- else
- AC_MSG_RESULT([buggy])
- LIBOBJS="$LIBOBJS fixstrtod.o"
- AC_DEFINE(strtod, fixstrtod)
- fi
- fi
-])
-
-#--------------------------------------------------------------------
-# TEA_TCL_LINK_LIBS
-#
-# Search for the libraries needed to link the Tcl shell.
-# Things like the math library (-lm) and socket stuff (-lsocket vs.
-# -lnsl) are dealt with here.
-#
-# Arguments:
-# Requires the following vars to be set in the Makefile:
-# DL_LIBS
-# LIBS
-# MATH_LIBS
-#
-# Results:
-#
-# Subst's the following var:
-# TCL_LIBS
-# MATH_LIBS
-#
-# Might append to the following vars:
-# LIBS
-#
-# Might define the following vars:
-# HAVE_NET_ERRNO_H
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_TCL_LINK_LIBS, [
- #--------------------------------------------------------------------
- # On a few very rare systems, all of the libm.a stuff is
- # already in libc.a. Set compiler flags accordingly.
- # Also, Linux requires the "ieee" library for math to work
- # right (and it must appear before "-lm").
- #--------------------------------------------------------------------
-
- AC_CHECK_FUNC(sin, MATH_LIBS="", MATH_LIBS="-lm")
- AC_CHECK_LIB(ieee, main, [MATH_LIBS="-lieee $MATH_LIBS"])
-
- #--------------------------------------------------------------------
- # Interactive UNIX requires -linet instead of -lsocket, plus it
- # needs net/errno.h to define the socket-related error codes.
- #--------------------------------------------------------------------
-
- AC_CHECK_LIB(inet, main, [LIBS="$LIBS -linet"])
- AC_CHECK_HEADER(net/errno.h, AC_DEFINE(HAVE_NET_ERRNO_H))
-
- #--------------------------------------------------------------------
- # Check for the existence of the -lsocket and -lnsl libraries.
- # The order here is important, so that they end up in the right
- # order in the command line generated by make. Here are some
- # special considerations:
- # 1. Use "connect" and "accept" to check for -lsocket, and
- # "gethostbyname" to check for -lnsl.
- # 2. Use each function name only once: can't redo a check because
- # autoconf caches the results of the last check and won't redo it.
- # 3. Use -lnsl and -lsocket only if they supply procedures that
- # aren't already present in the normal libraries. This is because
- # IRIX 5.2 has libraries, but they aren't needed and they're
- # bogus: they goof up name resolution if used.
- # 4. On some SVR4 systems, can't use -lsocket without -lnsl too.
- # To get around this problem, check for both libraries together
- # if -lsocket doesn't work by itself.
- #--------------------------------------------------------------------
-
- tcl_checkBoth=0
- AC_CHECK_FUNC(connect, tcl_checkSocket=0, tcl_checkSocket=1)
- if test "$tcl_checkSocket" = 1; then
- AC_CHECK_FUNC(setsockopt, , [AC_CHECK_LIB(socket, setsockopt,
- LIBS="$LIBS -lsocket", tcl_checkBoth=1)])
- fi
- if test "$tcl_checkBoth" = 1; then
- tk_oldLibs=$LIBS
- LIBS="$LIBS -lsocket -lnsl"
- AC_CHECK_FUNC(accept, tcl_checkNsl=0, [LIBS=$tk_oldLibs])
- fi
- AC_CHECK_FUNC(gethostbyname, , [AC_CHECK_LIB(nsl, gethostbyname,
- [LIBS="$LIBS -lnsl"])])
-
- # Don't perform the eval of the libraries here because DL_LIBS
- # won't be set until we call TEA_CONFIG_CFLAGS
-
- TCL_LIBS='${DL_LIBS} ${LIBS} ${MATH_LIBS}'
- AC_SUBST(TCL_LIBS)
- AC_SUBST(MATH_LIBS)
-])
-
-#--------------------------------------------------------------------
-# TEA_TCL_EARLY_FLAGS
-#
-# Check for what flags are needed to be passed so the correct OS
-# features are available.
-#
-# Arguments:
-# None
-#
-# Results:
-#
-# Might define the following vars:
-# _ISOC99_SOURCE
-# _LARGEFILE64_SOURCE
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_TCL_EARLY_FLAG,[
- AC_CACHE_VAL([tcl_cv_flag_]translit($1,[A-Z],[a-z]),
- AC_TRY_COMPILE([$2], $3, [tcl_cv_flag_]translit($1,[A-Z],[a-z])=no,
- AC_TRY_COMPILE([[#define ]$1[ 1
-]$2], $3,
- [tcl_cv_flag_]translit($1,[A-Z],[a-z])=yes,
- [tcl_cv_flag_]translit($1,[A-Z],[a-z])=no)))
- if test ["x${tcl_cv_flag_]translit($1,[A-Z],[a-z])[}" = "xyes"] ; then
- AC_DEFINE($1)
- tcl_flags="$tcl_flags $1"
- fi
-])
-
-AC_DEFUN(TEA_TCL_EARLY_FLAGS,[
- AC_MSG_CHECKING([for required early compiler flags])
- tcl_flags=""
- TEA_TCL_EARLY_FLAG(_ISOC99_SOURCE,[#include <stdlib.h>],
- [char *p = (char *)strtoll; char *q = (char *)strtoull;])
- TEA_TCL_EARLY_FLAG(_LARGEFILE64_SOURCE,[#include <sys/stat.h>],
- [struct stat64 buf; int i = stat64("/", &buf);])
- if test "x${tcl_flags}" = "x" ; then
- AC_MSG_RESULT([none])
- else
- AC_MSG_RESULT([${tcl_flags}])
- fi
-])
-
-#--------------------------------------------------------------------
-# TEA_TCL_64BIT_FLAGS
-#
-# Check for what is defined in the way of 64-bit features.
-#
-# Arguments:
-# None
-#
-# Results:
-#
-# Might define the following vars:
-# TCL_WIDE_INT_IS_LONG
-# TCL_WIDE_INT_TYPE
-# HAVE_STRUCT_DIRENT64
-# HAVE_STRUCT_STAT64
-# HAVE_TYPE_OFF64_T
-#
-#--------------------------------------------------------------------
-
-AC_DEFUN(TEA_TCL_64BIT_FLAGS, [
- AC_MSG_CHECKING([for 64-bit integer type])
- AC_CACHE_VAL(tcl_cv_type_64bit,[
- AC_TRY_COMPILE(,[__int64 value = (__int64) 0;],
- tcl_cv_type_64bit=__int64,tcl_cv_type_64bit=none
- AC_TRY_RUN([#include <unistd.h>
- int main() {exit(!(sizeof(long long) > sizeof(long)));}
- ], tcl_cv_type_64bit="long long"))])
- if test "${tcl_cv_type_64bit}" = none ; then
- AC_MSG_RESULT([using long])
- else
- AC_DEFINE_UNQUOTED(TCL_WIDE_INT_TYPE,${tcl_cv_type_64bit})
- AC_MSG_RESULT([${tcl_cv_type_64bit}])
-
- # Now check for auxiliary declarations
- AC_MSG_CHECKING([for struct dirent64])
- AC_CACHE_VAL(tcl_cv_struct_dirent64,[
- AC_TRY_COMPILE([#include <sys/types.h>
-#include <sys/dirent.h>],[struct dirent64 p;],
- tcl_cv_struct_dirent64=yes,tcl_cv_struct_dirent64=no)])
- if test "x${tcl_cv_struct_dirent64}" = "xyes" ; then
- AC_DEFINE(HAVE_STRUCT_DIRENT64)
- fi
- AC_MSG_RESULT([${tcl_cv_struct_dirent64}])
-
- AC_MSG_CHECKING([for struct stat64])
- AC_CACHE_VAL(tcl_cv_struct_stat64,[
- AC_TRY_COMPILE([#include <sys/stat.h>],[struct stat64 p;
-],
- tcl_cv_struct_stat64=yes,tcl_cv_struct_stat64=no)])
- if test "x${tcl_cv_struct_stat64}" = "xyes" ; then
- AC_DEFINE(HAVE_STRUCT_STAT64)
- fi
- AC_MSG_RESULT([${tcl_cv_struct_stat64}])
-
- AC_MSG_CHECKING([for off64_t])
- AC_CACHE_VAL(tcl_cv_type_off64_t,[
- AC_TRY_COMPILE([#include <sys/types.h>],[off64_t offset;
-],
- tcl_cv_type_off64_t=yes,tcl_cv_type_off64_t=no)])
- if test "x${tcl_cv_type_off64_t}" = "xyes" ; then
- AC_DEFINE(HAVE_TYPE_OFF64_T)
- fi
- AC_MSG_RESULT([${tcl_cv_type_off64_t}])
- fi
-])
-
-##
-## Here ends the standard Tcl configuration bits and starts the
-## TEA specific functions
-##
-
-#------------------------------------------------------------------------
-# TEA_INIT --
-#
-# Init various Tcl Extension Architecture (TEA) variables.
-# This should be the first called TEA_* macro.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Defines and substs the following vars:
-# CYGPATH
-# EXEEXT
-# Defines only:
-# TEA_INITED
-# TEA_PLATFORM (windows or unix)
-#
-# "cygpath" is used on windows to generate native path names for include
-# files. These variables should only be used with the compiler and linker
-# since they generate native path names.
-#
-# EXEEXT
-# Select the executable extension based on the host type. This
-# is a lightweight replacement for AC_EXEEXT that doesn't require
-# a compiler.
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_INIT, [
- AC_MSG_CHECKING([for correct TEA configuration])
- if test x"${PACKAGE}" = x ; then
- AC_MSG_ERROR([
-The PACKAGE variable must be defined by your TEA configure.in])
- fi
- AC_MSG_RESULT([ok])
- TEA_INITED=ok
- case "`uname -s`" in
- *win32*|*WIN32*|*CYGWIN_NT*|*CYGWIN_9*|*CYGWIN_ME*|*MINGW32_*)
- AC_CHECK_PROG(CYGPATH, cygpath, cygpath -w, echo)
- EXEEXT=".exe"
- TEA_PLATFORM="windows"
- ;;
- *)
- CYGPATH=echo
- EXEEXT=""
- TEA_PLATFORM="unix"
- ;;
- esac
-
- AC_SUBST(EXEEXT)
- AC_SUBST(CYGPATH)
-])
-
-#------------------------------------------------------------------------
-# TEA_PREFIX --
-#
-# Handle the --prefix=... option by defaulting to what Tcl gave
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# If --prefix or --exec-prefix was not specified, $prefix and
-# $exec_prefix will be set to the values given to Tcl when it was
-# configured.
-#------------------------------------------------------------------------
-AC_DEFUN(TEA_PREFIX, [
- # Should be AC_MSG_NOTICE, but that requires autoconf 2.50
- if test "${prefix}" = "NONE"; then
- prefix_default=yes
- if test x"${TCL_PREFIX}" != x; then
- AC_MSG_WARN([--prefix defaulting to TCL_PREFIX ${TCL_PREFIX}])
- prefix=${TCL_PREFIX}
- else
- prefix=/usr/local
- fi
- fi
- if test "${exec_prefix}" = "NONE" -a x"${prefix_default}" = x"yes" ; then
- if test x"${TCL_EXEC_PREFIX}" != x; then
- AC_MSG_WARN([--exec-prefix defaulting to TCL_EXEC_PREFIX ${TCL_EXEC_PREFIX}])
- exec_prefix=${TCL_EXEC_PREFIX}
- else
- exec_prefix=$prefix
- fi
- fi
-])
-
-#------------------------------------------------------------------------
-# TEA_PROG_CC --
-#
-# Do compiler checks the way we want. This is just a replacement
-# for AC_PROG_CC in TEA configure.in files to make them cleaner.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Sets up CC var and other standard bits we need to make executables.
-#------------------------------------------------------------------------
-AC_DEFUN(TEA_SETUP_COMPILER, [
- # If the user did not set CFLAGS, set it now to keep
- # the AC_PROG_CC macro from adding "-g -O2".
- if test "${CFLAGS+set}" != "set" ; then
- CFLAGS=""
- fi
-
- AC_PROG_CC
-
- #------------------------------------------------------------------------
- # If we're using GCC, see if the compiler understands -pipe. If so, use it.
- # It makes compiling go faster. (This is only a performance feature.)
- #------------------------------------------------------------------------
-
- if test -z "$no_pipe" -a -n "$GCC"; then
- AC_MSG_CHECKING([if the compiler understands -pipe])
- OLDCC="$CC"
- CC="$CC -pipe"
- AC_TRY_COMPILE(,, AC_MSG_RESULT([yes]), CC="$OLDCC"
- AC_MSG_RESULT([no]))
- fi
-
- AC_PROG_INSTALL
-
- #--------------------------------------------------------------------
- # Checks to see if the make program sets the $MAKE variable.
- #--------------------------------------------------------------------
-
- AC_PROG_MAKE_SET
-
- #--------------------------------------------------------------------
- # Find ranlib
- #--------------------------------------------------------------------
-
- AC_PROG_RANLIB
-
- #--------------------------------------------------------------------
- # Determines the correct binary file extension (.o, .obj, .exe etc.)
- #--------------------------------------------------------------------
-
- AC_OBJEXT
- AC_EXEEXT
-])
-
-#------------------------------------------------------------------------
-# TEA_MAKE_LIB --
-#
-# Generate a line that can be used to build a shared/unshared library
-# in a platform independent manner.
-#
-# Arguments:
-# none
-#
-# Requires:
-#
-# Results:
-#
-# Defines the following vars:
-# CFLAGS - Done late here to note disturb other AC macros
-# MAKE_LIB - Command to execute to build the Tcl library;
-# differs depending on whether or not Tcl is being
-# compiled as a shared library.
-# MAKE_SHARED_LIB Makefile rule for building a shared library
-# MAKE_STATIC_LIB Makefile rule for building a static library
-# MAKE_STUB_LIB Makefile rule for building a stub library
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_MAKE_LIB, [
- if test "${TEA_PLATFORM}" = "windows" -a "$GCC" != "yes"; then
- MAKE_STATIC_LIB="\${STLIB_LD} -out:\[$]@ \$(\[$](PACKAGE)_OBJECTS)"
- MAKE_SHARED_LIB="\${SHLIB_LD} \${SHLIB_LDFLAGS} \${SHLIB_LD_LIBS} \$(LDFLAGS) -out:\[$]@ \$(\[$](PACKAGE)_OBJECTS)"
- MAKE_STUB_LIB="\${STLIB_LD} -out:\[$]@ \$(\[$](PACKAGE)stub_OBJECTS)"
- else
- MAKE_STATIC_LIB="\${STLIB_LD} \[$]@ \$(\[$](PACKAGE)_OBJECTS)"
- MAKE_SHARED_LIB="\${SHLIB_LD} -o \[$]@ \$(\[$](PACKAGE)_OBJECTS) \${SHLIB_LDFLAGS} \${SHLIB_LD_LIBS}"
- MAKE_STUB_LIB="\${STLIB_LD} \[$]@ \$(\[$](PACKAGE)stub_OBJECTS)"
- fi
-
- if test "${SHARED_BUILD}" = "1" ; then
- MAKE_LIB="${MAKE_SHARED_LIB} "
- else
- MAKE_LIB="${MAKE_STATIC_LIB} "
- fi
-
- #--------------------------------------------------------------------
- # Shared libraries and static libraries have different names.
- # Use the double eval to make sure the ${DBGX} in the suffix is
- # substituted.
- #--------------------------------------------------------------------
-
- if test "${TEA_PLATFORM}" = "windows" ; then
- if test "${SHARED_BUILD}" = "1" ; then
- # We force the unresolved linking of symbols that are really in
- # the private libraries of Tcl and Tk.
- SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TCL_BIN_DIR}/${TCL_STUB_LIB_FILE}`\""
- if test x"${TK_BIN_DIR}" != x ; then
- SHLIB_LD_LIBS="${SHLIB_LD_LIBS} \"`${CYGPATH} ${TK_BIN_DIR}/${TK_STUB_LIB_FILE}`\""
- fi
- eval eval "${PACKAGE}_LIB_FILE=${PACKAGE}${SHARED_LIB_SUFFIX}"
- RANLIB=:
- else
- eval eval "${PACKAGE}_LIB_FILE=${PACKAGE}${UNSHARED_LIB_SUFFIX}"
- fi
- # Some packages build there own stubs libraries
- eval eval "${PACKAGE}stub_LIB_FILE=${PACKAGE}stub${UNSHARED_LIB_SUFFIX}"
- else
- if test "${SHARED_BUILD}" = "1" ; then
- SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TCL_STUB_LIB_SPEC}"
- if test x"${TK_BIN_DIR}" != x ; then
- SHLIB_LD_LIBS="${SHLIB_LD_LIBS} ${TK_STUB_LIB_SPEC}"
- fi
- eval eval "${PACKAGE}_LIB_FILE=lib${PACKAGE}${SHARED_LIB_SUFFIX}"
- #RANLIB=:
- else
- eval eval "${PACKAGE}_LIB_FILE=lib${PACKAGE}${UNSHARED_LIB_SUFFIX}"
- fi
- # Some packages build there own stubs libraries
- eval eval "${PACKAGE}stub_LIB_FILE=lib${PACKAGE}stub${UNSHARED_LIB_SUFFIX}"
- fi
-
- # These are escaped so that only CFLAGS is picked up at configure time.
- # The other values will be substituted at make time.
- CFLAGS="${CFLAGS} \${CFLAGS_DEFAULT} \${CFLAGS_WARNING}"
- if test "${SHARED_BUILD}" = "1" ; then
- CFLAGS="${CFLAGS} \${SHLIB_CFLAGS}"
- fi
-
- AC_SUBST(MAKE_LIB)
- AC_SUBST(MAKE_SHARED_LIB)
- AC_SUBST(MAKE_STATIC_LIB)
- AC_SUBST(MAKE_STUB_LIB)
-])
-
-#------------------------------------------------------------------------
-# TEA_LIB_SPEC --
-#
-# Compute the name of an existing object library located in libdir
-# from the given base name and produce the appropriate linker flags.
-#
-# Arguments:
-# basename The base name of the library without version
-# numbers, extensions, or "lib" prefixes.
-# extra_dir Extra directory in which to search for the
-# library. This location is used first, then
-# $prefix/$exec-prefix, then some defaults.
-#
-# Requires:
-# TEA_INIT and TEA_PREFIX must be called first.
-#
-# Results:
-#
-# Defines the following vars:
-# ${basename}_LIB_NAME The computed library name.
-# ${basename}_LIB_SPEC The computed linker flags.
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_LIB_SPEC, [
- AC_MSG_CHECKING([for $1 library])
-
- # Look in exec-prefix for the library (defined by TEA_PREFIX).
-
- tea_lib_name_dir="${exec_prefix}/lib"
-
- # Or in a user-specified location.
-
- if test x"$2" != x ; then
- tea_extra_lib_dir=$2
- else
- tea_extra_lib_dir=NONE
- fi
-
- for i in \
- `ls -dr ${tea_extra_lib_dir}/$1[[0-9]]*.lib 2>/dev/null ` \
- `ls -dr ${tea_extra_lib_dir}/lib$1[[0-9]]* 2>/dev/null ` \
- `ls -dr ${tea_lib_name_dir}/$1[[0-9]]*.lib 2>/dev/null ` \
- `ls -dr ${tea_lib_name_dir}/lib$1[[0-9]]* 2>/dev/null ` \
- `ls -dr /usr/lib/$1[[0-9]]*.lib 2>/dev/null ` \
- `ls -dr /usr/lib/lib$1[[0-9]]* 2>/dev/null ` \
- `ls -dr /usr/local/lib/$1[[0-9]]*.lib 2>/dev/null ` \
- `ls -dr /usr/local/lib/lib$1[[0-9]]* 2>/dev/null ` ; do
- if test -f "$i" ; then
- tea_lib_name_dir=`dirname $i`
- $1_LIB_NAME=`basename $i`
- $1_LIB_PATH_NAME=$i
- break
- fi
- done
-
- if test "${TEA_PLATFORM}" = "windows"; then
- $1_LIB_SPEC=\"`${CYGPATH} ${$1_LIB_PATH_NAME} 2>/dev/null`\"
- else
- # Strip off the leading "lib" and trailing ".a" or ".so"
-
- tea_lib_name_lib=`echo ${$1_LIB_NAME}|sed -e 's/^lib//' -e 's/\.[[^.]]*$//' -e 's/\.so.*//'`
- $1_LIB_SPEC="-L${tea_lib_name_dir} -l${tea_lib_name_lib}"
- fi
-
- if test "x${$1_LIB_NAME}" = x ; then
- AC_MSG_ERROR([not found])
- else
- AC_MSG_RESULT([${$1_LIB_SPEC}])
- fi
-])
-
-#------------------------------------------------------------------------
-# TEA_PRIVATE_TCL_HEADERS --
-#
-# Locate the private Tcl include files
-#
-# Arguments:
-#
-# Requires:
-# TCL_SRC_DIR Assumes that TEA_LOAD_TCLCONFIG has
-# already been called.
-#
-# Results:
-#
-# Substs the following vars:
-# TCL_TOP_DIR_NATIVE
-# TCL_GENERIC_DIR_NATIVE
-# TCL_UNIX_DIR_NATIVE
-# TCL_WIN_DIR_NATIVE
-# TCL_BMAP_DIR_NATIVE
-# TCL_TOOL_DIR_NATIVE
-# TCL_PLATFORM_DIR_NATIVE
-# TCL_BIN_DIR_NATIVE
-# TCL_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_PRIVATE_TCL_HEADERS, [
- AC_MSG_CHECKING([for Tcl private include files])
-
- if test "${TEA_PLATFORM}" = "windows"; then
- TCL_TOP_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}`\"
- TCL_GENERIC_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/generic`\"
- TCL_UNIX_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/unix`\"
- TCL_WIN_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/win`\"
- TCL_BMAP_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/bitmaps`\"
- TCL_TOOL_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/tools`\"
- TCL_COMPAT_DIR_NATIVE=\"`${CYGPATH} ${TCL_SRC_DIR}/compat`\"
- TCL_PLATFORM_DIR_NATIVE=${TCL_WIN_DIR_NATIVE}
- else
- TCL_TOP_DIR_NATIVE='$(TCL_SRC_DIR)'
- TCL_GENERIC_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/generic'
- TCL_UNIX_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/unix'
- TCL_WIN_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/win'
- TCL_BMAP_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/bitmaps'
- TCL_TOOL_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/tools'
- TCL_COMPAT_DIR_NATIVE='$(TCL_TOP_DIR_NATIVE)/compat'
- TCL_PLATFORM_DIR_NATIVE=${TCL_UNIX_DIR_NATIVE}
- fi
-
- AC_SUBST(TCL_TOP_DIR_NATIVE)
- AC_SUBST(TCL_GENERIC_DIR_NATIVE)
- AC_SUBST(TCL_UNIX_DIR_NATIVE)
- AC_SUBST(TCL_WIN_DIR_NATIVE)
- AC_SUBST(TCL_BMAP_DIR_NATIVE)
- AC_SUBST(TCL_TOOL_DIR_NATIVE)
- AC_SUBST(TCL_PLATFORM_DIR_NATIVE)
-
- TCL_INCLUDES="-I${TCL_GENERIC_DIR_NATIVE} -I${TCL_PLATFORM_DIR_NATIVE}"
- AC_SUBST(TCL_INCLUDES)
- AC_MSG_RESULT([Using srcdir found in tclConfig.sh: ${TCL_SRC_DIR}])
-])
-
-#------------------------------------------------------------------------
-# TEA_PUBLIC_TCL_HEADERS --
-#
-# Locate the installed public Tcl header files
-#
-# Arguments:
-# None.
-#
-# Requires:
-# CYGPATH must be set
-#
-# Results:
-#
-# Adds a --with-tclinclude switch to configure.
-# Result is cached.
-#
-# Substs the following vars:
-# TCL_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_PUBLIC_TCL_HEADERS, [
- AC_MSG_CHECKING([for Tcl public headers])
-
- AC_ARG_WITH(tclinclude, [ --with-tclinclude directory containing the public Tcl header files], with_tclinclude=${withval})
-
- AC_CACHE_VAL(ac_cv_c_tclh, [
- # Use the value from --with-tclinclude, if it was given
-
- if test x"${with_tclinclude}" != x ; then
- if test -f "${with_tclinclude}/tcl.h" ; then
- ac_cv_c_tclh=${with_tclinclude}
- else
- AC_MSG_ERROR([${with_tclinclude} directory does not contain tcl.h])
- fi
- else
- # Check order: pkg --prefix location, Tcl's --prefix location,
- # directory of tclConfig.sh, and Tcl source directory.
- # Looking in the source dir is not ideal, but OK.
-
- eval "temp_includedir=${includedir}"
- list="`ls -d ${temp_includedir} 2>/dev/null` \
- `ls -d ${TCL_PREFIX}/include 2>/dev/null` \
- `ls -d ${TCL_BIN_DIR}/../include 2>/dev/null` \
- `ls -d ${TCL_SRC_DIR}/generic 2>/dev/null`"
- if test "${TEA_PLATFORM}" != "windows" -o "$GCC" = "yes"; then
- list="$list /usr/local/include /usr/include"
- fi
- for i in $list ; do
- if test -f "$i/tcl.h" ; then
- ac_cv_c_tclh=$i
- break
- fi
- done
- fi
- ])
-
- # Print a message based on how we determined the include path
-
- if test x"${ac_cv_c_tclh}" = x ; then
- AC_MSG_ERROR([tcl.h not found. Please specify its location with --with-tclinclude])
- else
- AC_MSG_RESULT([${ac_cv_c_tclh}])
- fi
-
- # Convert to a native path and substitute into the output files.
-
- INCLUDE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tclh}`
-
- TCL_INCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
-
- AC_SUBST(TCL_INCLUDES)
-])
-
-#------------------------------------------------------------------------
-# TEA_PRIVATE_TK_HEADERS --
-#
-# Locate the private Tk include files
-#
-# Arguments:
-#
-# Requires:
-# TK_SRC_DIR Assumes that TEA_LOAD_TKCONFIG has
-# already been called.
-#
-# Results:
-#
-# Substs the following vars:
-# TK_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_PRIVATE_TK_HEADERS, [
- AC_MSG_CHECKING([for Tk private include files])
-
- if test "${TEA_PLATFORM}" = "windows"; then
- TK_TOP_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}`\"
- TK_UNIX_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/unix`\"
- TK_WIN_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/win`\"
- TK_GENERIC_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/generic`\"
- TK_XLIB_DIR_NATIVE=\"`${CYGPATH} ${TK_SRC_DIR}/xlib`\"
- TK_PLATFORM_DIR_NATIVE=${TK_WIN_DIR_NATIVE}
-
- TK_INCLUDES="-I${TK_GENERIC_DIR_NATIVE} -I${TK_PLATFORM_DIR_NATIVE} -I${TK_XLIB_DIR_NATIVE}"
- else
- TK_TOP_DIR_NATIVE='$(TK_SRC_DIR)'
- TK_GENERIC_DIR_NATIVE='$(TK_TOP_DIR_NATIVE)/generic'
- TK_UNIX_DIR_NATIVE='$(TK_TOP_DIR_NATIVE)/unix'
- TK_WIN_DIR_NATIVE='$(TK_TOP_DIR_NATIVE)/win'
- TK_PLATFORM_DIR_NATIVE=${TK_UNIX_DIR_NATIVE}
-
- TK_INCLUDES="-I${TK_GENERIC_DIR_NATIVE} -I${TK_PLATFORM_DIR_NATIVE}"
- fi
-
- AC_SUBST(TK_TOP_DIR_NATIVE)
- AC_SUBST(TK_UNIX_DIR_NATIVE)
- AC_SUBST(TK_WIN_DIR_NATIVE)
- AC_SUBST(TK_GENERIC_DIR_NATIVE)
- AC_SUBST(TK_XLIB_DIR_NATIVE)
- AC_SUBST(TK_PLATFORM_DIR_NATIVE)
-
- AC_SUBST(TK_INCLUDES)
- AC_MSG_RESULT([Using srcdir found in tkConfig.sh: ${TK_SRC_DIR}])
-])
-
-#------------------------------------------------------------------------
-# TEA_PUBLIC_TK_HEADERS --
-#
-# Locate the installed public Tk header files
-#
-# Arguments:
-# None.
-#
-# Requires:
-# CYGPATH must be set
-#
-# Results:
-#
-# Adds a --with-tkinclude switch to configure.
-# Result is cached.
-#
-# Substs the following vars:
-# TK_INCLUDES
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_PUBLIC_TK_HEADERS, [
- AC_MSG_CHECKING([for Tk public headers])
-
- AC_ARG_WITH(tkinclude, [ --with-tkinclude directory containing the public Tk header files.], with_tkinclude=${withval})
-
- AC_CACHE_VAL(ac_cv_c_tkh, [
- # Use the value from --with-tkinclude, if it was given
-
- if test x"${with_tkinclude}" != x ; then
- if test -f "${with_tkinclude}/tk.h" ; then
- ac_cv_c_tkh=${with_tkinclude}
- else
- AC_MSG_ERROR([${with_tkinclude} directory does not contain tk.h])
- fi
- else
- # Check order: pkg --prefix location, Tcl's --prefix location,
- # directory of tclConfig.sh, and Tcl source directory.
- # Looking in the source dir is not ideal, but OK.
-
- eval "temp_includedir=${includedir}"
- list="`ls -d ${temp_includedir} 2>/dev/null` \
- `ls -d ${TK_PREFIX}/include 2>/dev/null` \
- `ls -d ${TCL_PREFIX}/include 2>/dev/null` \
- `ls -d ${TCL_BIN_DIR}/../include 2>/dev/null` \
- `ls -d ${TK_SRC_DIR}/generic 2>/dev/null`"
- if test "${TEA_PLATFORM}" != "windows" -o "$GCC" = "yes"; then
- list="$list /usr/local/include /usr/include"
- fi
- for i in $list ; do
- if test -f "$i/tk.h" ; then
- ac_cv_c_tkh=$i
- break
- fi
- done
- fi
- ])
-
- # Print a message based on how we determined the include path
-
- if test x"${ac_cv_c_tkh}" = x ; then
- AC_MSG_ERROR([tk.h not found. Please specify its location with --with-tkinclude])
- else
- AC_MSG_RESULT([${ac_cv_c_tkh}])
- fi
-
- # Convert to a native path and substitute into the output files.
-
- INCLUDE_DIR_NATIVE=`${CYGPATH} ${ac_cv_c_tkh}`
-
- TK_INCLUDES=-I\"${INCLUDE_DIR_NATIVE}\"
-
- AC_SUBST(TK_INCLUDES)
-])
-
-#------------------------------------------------------------------------
-# TEA_PROG_TCLSH
-# Locate a tclsh shell in the following directories:
-# ${TCL_BIN_DIR} ${TCL_BIN_DIR}/../bin
-# ${exec_prefix}/bin ${prefix}/bin
-# ${PATH}
-#
-# Arguments
-# none
-#
-# Results
-# Subst's the following values:
-# TCLSH_PROG
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_PROG_TCLSH, [
- AC_MSG_CHECKING([for tclsh])
-
- AC_CACHE_VAL(ac_cv_path_tclsh, [
- search_path=`echo ${TCL_BIN_DIR}:${TCL_BIN_DIR}/../bin:${exec_prefix}/bin:${prefix}/bin:${PATH} | sed -e 's/:/ /g'`
- for dir in $search_path ; do
- for j in `ls -r $dir/tclsh[[8-9]]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/tclsh*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_tclsh" = x ; then
- if test -f "$j" ; then
- ac_cv_path_tclsh=$j
- break
- fi
- fi
- done
- done
- ])
-
- if test -f "$ac_cv_path_tclsh" ; then
- TCLSH_PROG=$ac_cv_path_tclsh
- AC_MSG_RESULT([$TCLSH_PROG])
- else
- AC_MSG_ERROR([No tclsh found in PATH: $search_path])
- fi
- AC_SUBST(TCLSH_PROG)
-])
-
-#------------------------------------------------------------------------
-# TEA_PROG_WISH
-# Locate a wish shell in the following directories:
-# ${TK_BIN_DIR} ${TK_BIN_DIR}/../bin
-# ${TCL_BIN_DIR} ${TCL_BIN_DIR}/../bin
-# ${exec_prefix}/bin ${prefix}/bin
-# ${PATH}
-#
-# Arguments
-# none
-#
-# Results
-# Subst's the following values:
-# WISH_PROG
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_PROG_WISH, [
- AC_MSG_CHECKING([for wish])
-
- AC_CACHE_VAL(ac_cv_path_wish, [
- search_path=`echo ${TK_BIN_DIR}:${TK_BIN_DIR}/../bin:${TCL_BIN_DIR}:${TCL_BIN_DIR}/../bin:${exec_prefix}/bin:${prefix}/bin:${PATH} | sed -e 's/:/ /g'`
- for dir in $search_path ; do
- for j in `ls -r $dir/wish[[8-9]]*${EXEEXT} 2> /dev/null` \
- `ls -r $dir/wish*${EXEEXT} 2> /dev/null` ; do
- if test x"$ac_cv_path_wish" = x ; then
- if test -f "$j" ; then
- ac_cv_path_wish=$j
- break
- fi
- fi
- done
- done
- ])
-
- if test -f "$ac_cv_path_wish" ; then
- WISH_PROG=$ac_cv_path_wish
- AC_MSG_RESULT([$WISH_PROG])
- else
- AC_MSG_ERROR([No wish found in PATH: $search_path])
- fi
- AC_SUBST(WISH_PROG)
-])
-
-#------------------------------------------------------------------------
-# TEA_PATH_CONFIG --
-#
-# Locate the ${1}Config.sh file and perform a sanity check on
-# the ${1} compile flags. These are used by packages like
-# [incr Tk] that load *Config.sh files from more than Tcl and Tk.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --with-$1=...
-#
-# Defines the following vars:
-# $1_BIN_DIR Full path to the directory containing
-# the $1Config.sh file
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_PATH_CONFIG, [
- #
- # Ok, lets find the $1 configuration
- # First, look for one uninstalled.
- # the alternative search directory is invoked by --with-$1
- #
-
- if test x"${no_$1}" = x ; then
- # we reset no_$1 in case something fails here
- no_$1=true
- AC_ARG_WITH($1, [ --with-$1 directory containing $1 configuration ($1Config.sh)], with_$1config=${withval})
- AC_MSG_CHECKING([for $1 configuration])
- AC_CACHE_VAL(ac_cv_c_$1config,[
-
- # First check to see if --with-$1 was specified.
- if test x"${with_$1config}" != x ; then
- if test -f "${with_$1config}/$1Config.sh" ; then
- ac_cv_c_$1config=`(cd ${with_$1config}; pwd)`
- else
- AC_MSG_ERROR([${with_$1config} directory doesn't contain $1Config.sh])
- fi
- fi
-
- # then check for a private $1 installation
- if test x"${ac_cv_c_$1config}" = x ; then
- for i in \
- ../$1 \
- `ls -dr ../$1[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../$1 \
- `ls -dr ../../$1[[8-9]].[[0-9]]* 2>/dev/null` \
- ../../../$1 \
- `ls -dr ../../../$1[[8-9]].[[0-9]]* 2>/dev/null` \
- ${srcdir}/../$1 \
- `ls -dr ${srcdir}/../$1[[8-9]].[[0-9]]* 2>/dev/null` \
- ; do
- if test -f "$i/$1Config.sh" ; then
- ac_cv_c_$1config=`(cd $i; pwd)`
- break
- fi
- if test -f "$i/unix/$1Config.sh" ; then
- ac_cv_c_$1config=`(cd $i/unix; pwd)`
- break
- fi
- done
- fi
-
- # check in a few common install locations
- if test x"${ac_cv_c_$1config}" = x ; then
- for i in `ls -d ${exec_prefix}/lib 2>/dev/null` \
- `ls -d /usr/local/lib 2>/dev/null` \
- `ls -d /usr/contrib/lib 2>/dev/null` \
- `ls -d /usr/lib 2>/dev/null` \
- ; do
- if test -f "$i/$1Config.sh" ; then
- ac_cv_c_$1config=`(cd $i; pwd)`
- break
- fi
- done
- fi
- ])
-
- if test x"${ac_cv_c_$1config}" = x ; then
- $1_BIN_DIR="# no $1 configs found"
- AC_MSG_WARN("Cannot find $1 configuration definitions")
- exit 0
- else
- no_$1=
- $1_BIN_DIR=${ac_cv_c_$1config}
- AC_MSG_RESULT([found $$1_BIN_DIR/$1Config.sh])
- fi
- fi
-])
-
-#------------------------------------------------------------------------
-# TEA_LOAD_CONFIG --
-#
-# Load the $1Config.sh file
-#
-# Arguments:
-#
-# Requires the following vars to be set:
-# $1_BIN_DIR
-#
-# Results:
-#
-# Subst the following vars:
-# $1_SRC_DIR
-# $1_LIB_FILE
-# $1_LIB_SPEC
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(TEA_LOAD_CONFIG, [
- AC_MSG_CHECKING([for existence of ${$1_BIN_DIR}/$1Config.sh])
-
- if test -f "${$1_BIN_DIR}/$1Config.sh" ; then
- AC_MSG_RESULT([loading])
- . ${$1_BIN_DIR}/$1Config.sh
- else
- AC_MSG_RESULT([file not found])
- fi
-
- #
- # If the $1_BIN_DIR is the build directory (not the install directory),
- # then set the common variable name to the value of the build variables.
- # For example, the variable $1_LIB_SPEC will be set to the value
- # of $1_BUILD_LIB_SPEC. An extension should make use of $1_LIB_SPEC
- # instead of $1_BUILD_LIB_SPEC since it will work with both an
- # installed and uninstalled version of Tcl.
- #
-
- if test -f ${$1_BIN_DIR}/Makefile ; then
- AC_MSG_WARN([Found Makefile - using build library specs for $1])
- $1_LIB_SPEC=${$1_BUILD_LIB_SPEC}
- $1_STUB_LIB_SPEC=${$1_BUILD_STUB_LIB_SPEC}
- $1_STUB_LIB_PATH=${$1_BUILD_STUB_LIB_PATH}
- fi
-
- AC_SUBST($1_VERSION)
- AC_SUBST($1_SRC_DIR)
-
- AC_SUBST($1_LIB_FILE)
- AC_SUBST($1_LIB_SPEC)
-
- AC_SUBST($1_STUB_LIB_FILE)
- AC_SUBST($1_STUB_LIB_SPEC)
- AC_SUBST($1_STUB_LIB_PATH)
-])
diff --git a/tests/all.tcl b/tests/all.tcl
deleted file mode 100644
index cb36d08..0000000
--- a/tests/all.tcl
+++ /dev/null
@@ -1,8 +0,0 @@
-
-package require Tcl 8.4
-package require tcltest 2.2
-
-tcltest::configure -testdir [file dir [file normalize [info script]]]
-eval tcltest::configure $argv
-
-tcltest::runAllTests
diff --git a/tests/rectangle.test b/tests/rectangle.test
deleted file mode 100644
index 35aa1c5..0000000
--- a/tests/rectangle.test
+++ /dev/null
@@ -1,48 +0,0 @@
-# -*- tcl -*-
-# This file is part of the Tkzinc test suite.
-# It tests the code in Rectangle.c which implements
-# the rectangle item.
-#
-
-package require tcltest 2.2
-eval tcltest::configure $argv
-
-lappend auto_path [file join [file dirname [info script]] ..]
-package require Tkzinc
-
-zinc .z -width 400 -height 300 -borderwidth 2 -relief sunken
-pack .z
-bind .z <1> {
- puts "button down at (%x,%y)"
-}
-update
-
-namespace eval ::rectangle::test {
- namespace import ::tcltest::*
-
-# testConstraint X [expr {...}]
-
- variable SETUP {
- #common setup code
- }
- variable CLEANUP {
- #common cleanup code
- }
-
- test example-1 {} -setup $SETUP {
- set i 1
- } -cleanup $CLEANUP
-
-# test example-2 {} -constraints emptyTest -setup $SETUP {
-# # Second test; constrained
-# } -cleanup $CLEANUP -result {...}
-
-# test example-3 {} {
-# # Third test; no context required
-# } {...}
-
- cleanupTests
-}
-
-namespace delete ::rectangle::test
- \ No newline at end of file
diff --git a/tkzinc.m4 b/tkzinc.m4
deleted file mode 100644
index b18f25f..0000000
--- a/tkzinc.m4
+++ /dev/null
@@ -1,170 +0,0 @@
-#
-# Include the TEA standard macro set
-#
-
-builtin(include,tclconfig/tcl.m4)
-
-#
-# Zinc specific macros below.
-#
-#
-# ALL the new macros here need to be modified to
-# detect the various packages needed and to get their paths.
-# Right now all this is statically defined in the macros.
-#
-#------------------------------------------------------------------------
-# ZINC_ENABLE_GL --
-#
-# Specify if openGL support should be used.
-# Code for managing a damage area can also be enabled.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-gl=[yes,no,damage]
-#
-# Defines the following vars:
-# GL_INCLUDES OpenGL include files path
-# GL_LIBS additional libraries needed for GL
-# LIBS Modified to reflect the need of new
-# libraries
-# GL Defined if GL support is enabled
-# GL_DAMAGE Defined if damage support has been
-# requested
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(ZINC_ENABLE_GL, [
- if test x"${TEA_INITED}" = x ; then
- AC_MSG_ERROR([Must call TEA INIT before ENABLE_GL])
- fi
-
- AC_MSG_CHECKING([for build with GL])
- AC_ARG_ENABLE(gl,
- [ --enable-gl build with openGL support (yes,no,damage) [[no]]],
- [tcl_ok=$enableval], [tcl_ok=no])
-
- if test "$tcl_ok" = "no"; then
- GL_LIBS=
- GL_INCLUDES=
- AC_MSG_RESULT([no])
- else
- if test "${TEA_PLATFORM}" = "windows" ; then
- GL_LIBS=-lopengl32
- else
- GL_LIBS="-lGL"
- GL_INCLUDES='-I/usr/include'
- fi
-
- AC_DEFINE(GL)
- if test "$tcl_ok" = "damage"; then
- AC_DEFINE(GL_DAMAGE)
- fi
-
- LIBS="$LIBS $GL_LIBS"
-
- if test "$tcl_ok" = "yes"; then
- AC_MSG_RESULT([yes (standard)])
- else
- AC_MSG_RESULT([yes (with damage support)])
- fi
- fi
-
- AC_SUBST(GL_LIBS)
- AC_SUBST(GL_INCLUDES)
-])
-
-#------------------------------------------------------------------------
-# ZINC_ENABLE_OM --
-#
-# Specify if the anti overlapping code should be included.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-om=[yes,no]
-#
-# Defines the following vars:
-# Om_LIB_FILE Contains the platform depent library
-# name for the pluggable overlap manager
-# OM Defined if overlap manager support
-# is enabled
-#
-# Adjust LIBS to include the overlap manager default library.
-# May Modify LD_SEARCH_FLAGS to include the zinc install directory
-#
-#------------------------------------------------------------------------
-
- AC_DEFUN(ZINC_ENABLE_OM, [
- if test x"${TEA_INITED}" = x ; then
- AC_MSG_ERROR([Must call TEA INIT before ENABLE_OM])
- fi
-
- AC_MSG_CHECKING([for build with the overlap manager])
- AC_ARG_ENABLE(om,
- [ --enable-om build with overlap manager support [[yes]]],
- [tcl_ok=$enableval], [tcl_ok=yes])
- if test "$tcl_ok" = "no"; then
- Om_LIB_FILE=
- AC_MSG_RESULT([no])
- else
- if test "${TEA_PLATFORM}" = "windows" ; then
- Om_LIB_FILE=om.dll
- bin_BINARIES="\$(Om_LIB_FILE) ${bin_BINARIES}"
- else
- Om_LIB_FILE=libom${TCL_SHLIB_SUFFIX}
- aux_BINARIES="\$(Om_LIB_FILE) ${bin_BINARIES}"
- fi
- AC_DEFINE(OM)
- AC_MSG_RESULT([yes])
-# LIBS="${LIBS} -L. -lom"
- fi
- AC_SUBST(Om_LIB_FILE)
-])
-
-#------------------------------------------------------------------------
-# ZINC_ENABLE_SHAPE --
-#
-# Specify if the X shape extension support should be included.
-#
-# Arguments:
-# none
-#
-# Results:
-#
-# Adds the following arguments to configure:
-# --enable-shape=[yes,no]
-#
-# Defines the following vars:
-# SHAPE Defined if shape support is enabled
-#
-# Adjust LIBS to include the X extension library
-#
-#------------------------------------------------------------------------
-
-AC_DEFUN(ZINC_ENABLE_SHAPE, [
- if test x"${TEA_INITED}" = x ; then
- AC_MSG_ERROR([Must call TEA INIT before ENABLE_SHAPE])
- fi
- AC_MSG_CHECKING([for build with X shape support])
- AC_ARG_ENABLE(shape,
- [ --enable-shape build with X shape support (if applicable) [[yes]]],
- [tcl_ok=$enableval], [tcl_ok=yes])
- if test "$tcl_ok" = "no"; then
- AC_MSG_RESULT([no])
- else
- if test "${TEA_PLATFORM}" = "windows" ; then
- AC_MSG_RESULT([no (not available on windows)])
- else
- AC_DEFINE(SHAPE)
- AC_MSG_RESULT([yes])
- LIBS="${LIBS} -lXext"
- fi
- fi
-])
diff --git a/win/Tkzinc.aip.in b/win/Tkzinc.aip.in
deleted file mode 100644
index d7fc904..0000000
--- a/win/Tkzinc.aip.in
+++ /dev/null
@@ -1,118 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<DOCUMENT type="Advanced Installer" version="1.4" modules="freeware" RootPath=".">
- <COMPONENT cid="caphyon.advinst.msicomp.MsiPropsComponent">
- <ROW Property="ProductCode" Value="{D5355F48-24D0-4B15-A267-DC02AA7C93C2}"/>
- <ROW Property="ALLUSERS" Value="2"/>
- <ROW Property="ARPCONTACT" Value="zinc@cena.fr"/>
- <ROW Property="ARPURLINFOABOUT" Value="www.tkzinc.org"/>
- <ROW Property="BannerBitmap" Value="default_banner.bmp"/>
- <ROW Property="DialogBitmap" Value="default_dialog.bmp"/>
- <ROW Property="Manufacturer" Value="C.E.N.A"/>
- <ROW Property="ProductLanguage" Value="1033"/>
- <ROW Property="ProductVersion" Value="@VERSION@"/>
- <ROW Property="SecureCustomProperties" Value="OLDPRODUCTS"/>
- <ROW Property="UpgradeCode" Value="{E1562383-D767-4BF5-AED0-B8CCF6581AC9}"/>
- <ROW Property="ProductName" Value="TkZinc"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiDirsComponent">
- <ROW Directory="TARGETDIR" Directory_Parent="" DefaultDir="SourceDir"/>
- <ROW Directory="data" Directory_Parent="Tkzinc" DefaultDir="data"/>
- <ROW Directory="demos" Directory_Parent="TARGETDIR" DefaultDir="demos"/>
- <ROW Directory="images" Directory_Parent="Tkzinc" DefaultDir="images"/>
- <ROW Directory="Tkzinc" Directory_Parent="demos" DefaultDir="Tkzinc"/>
- <ROW Directory="Tkzinc_1" Directory_Parent="lib" DefaultDir="Tkzinc"/>
- <ROW Directory="bin" Directory_Parent="TARGETDIR" DefaultDir="bin"/>
- <ROW Directory="lib" Directory_Parent="TARGETDIR" DefaultDir="lib"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiCompsComponent">
- <ROW Component="Tkzinc@MAJOR_VERSION@@MINOR_VERSION@@PATCHLEVEL@.dll" ComponentId="{BD006EA0-030C-4C37-853A-74802C13198A}" Directory_="Tkzinc_1" Attributes="0" Condition="" KeyPath="Tkzinc@MAJOR_VERSION@@MINOR_VERSION@@PATCHLEVEL@.dll" FullKeyPath="TARGETDIR\lib\Tkzinc\Tkzinc@MAJOR_VERSION@@MINOR_VERSION@@PATCHLEVEL@.dll"/>
- <ROW Component="demos" ComponentId="{1971090C-E55B-49F0-BF82-2F4E1F7CFD36}" Directory_="demos" Attributes="0" Condition="" KeyPath="" FullKeyPath=""/>
- <ROW Component="videomap_paris_w_90_2" ComponentId="{2568BCC4-ED6E-4C50-AF00-BD8B53AD2D22}" Directory_="data" Attributes="0" Condition="" KeyPath="videomap_paris_w_90_2" FullKeyPath="TARGETDIR\demos\Tkzinc\data"/>
- <ROW Component="zinc.gif" ComponentId="{EAA08733-85D2-48B8-BCB0-41FED94ECE88}" Directory_="images" Attributes="0" Condition="" KeyPath="zinc.gif" FullKeyPath="TARGETDIR\demos\Tkzinc\images"/>
- <ROW Component="zinc_widget.tcl" ComponentId="{75BEE58C-9D63-4C77-B0EE-F84010D0666A}" Directory_="bin" Attributes="0" Condition="" KeyPath="zinc_widget.tcl" FullKeyPath="TARGETDIR\bin"/>
- <ROW Component="lib" ComponentId="{B8FDD86E-7E03-4764-89F3-225B746368F4}" Directory_="lib" Attributes="0" Condition="" KeyPath="" FullKeyPath=""/>
- <ROW Component="pkgIndex.tcl" ComponentId="{F0E7B97E-2B21-4CB3-A3AE-D915174972D7}" Directory_="Tkzinc_1" Attributes="0" Condition="" KeyPath="pkgIndex.tcl" FullKeyPath="TARGETDIR\lib\Tkzinc"/>
- <ROW Component="reliefs.tcl" ComponentId="{F1C0F127-1924-4C59-8565-883A18CD536D}" Directory_="Tkzinc" Attributes="0" Condition="" KeyPath="reliefs.tcl" FullKeyPath="TARGETDIR\demos\Tkzinc"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiFeatsComponent">
- <ROW Feature="MainFeature" Feature_Parent="" Title="Main Feature" Description="Main Feature" Display="2" Level="1" Directory_="TARGETDIR" Attributes="0" Components="lib pkgIndex.tcl demos reliefs.tcl zinc.gif videomap_paris_w_90_2 Tkzinc@MAJOR_VERSION@@MINOR_VERSION@@PATCHLEVEL@.dll zinc_widget.tcl"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiFilesComponent">
- <ROW File="fillRule.tcl" Component_="reliefs.tcl" FileName="fillRule.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\fillRule.tcl" SelfReg="false"/>
- <ROW File="simpleInteractionTrack.tcl" Component_="reliefs.tcl" FileName="simple~1.tcl|simpleInteractionTrack.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\simpleInteractionTrack.tcl" SelfReg="false"/>
- <ROW File="transforms.tcl" Component_="reliefs.tcl" FileName="transf~1.tcl|transforms.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\transforms.tcl" SelfReg="false"/>
- <ROW File="photoAlpha.tcl" Component_="reliefs.tcl" FileName="photoA~1.tcl|photoAlpha.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\photoAlpha.tcl" SelfReg="false"/>
- <ROW File="paper_grey.gif" Component_="zinc.gif" FileName="paper-~1.gif|paper-grey.gif" Version="" Language="" Attributes="" SourcePath="..\demos\images\paper-grey.gif" SelfReg="false"/>
- <ROW File="testGraphics.tcl" Component_="reliefs.tcl" FileName="testGr~1.tcl|testGraphics.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\testGraphics.tcl" SelfReg="false"/>
- <ROW File="videomap_paris_w_90_2" Component_="videomap_paris_w_90_2" FileName="videom~1|videomap_paris-w_90_2" Version="" Language="" Attributes="" SourcePath="..\demos\data\videomap_paris-w_90_2" SelfReg="false"/>
- <ROW File="groupsPriority.tcl" Component_="reliefs.tcl" FileName="groups~2.tcl|groupsPriority.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\groupsPriority.tcl" SelfReg="false"/>
- <ROW File="items.tcl" Component_="reliefs.tcl" FileName="items.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\items.tcl" SelfReg="false"/>
- <ROW File="paper_grey1.gif" Component_="zinc.gif" FileName="paper-~2.gif|paper-grey1.gif" Version="" Language="" Attributes="" SourcePath="..\demos\images\paper-grey1.gif" SelfReg="false"/>
- <ROW File="photoAlpha.png" Component_="zinc.gif" FileName="photoA~1.png|photoAlpha.png" Version="" Language="" Attributes="" SourcePath="..\demos\images\photoAlpha.png" SelfReg="false"/>
- <ROW File="Tkzinc@MAJOR_VERSION@@MINOR_VERSION@@PATCHLEVEL@.dll" Component_="Tkzinc@MAJOR_VERSION@@MINOR_VERSION@@PATCHLEVEL@.dll" FileName="Tkzinc~1.dll|Tkzinc@MAJOR_VERSION@@MINOR_VERSION@@PATCHLEVEL@.dll" Version="" Language="" Attributes="" SourcePath="..\Tkzinc@MAJOR_VERSION@@MINOR_VERSION@@PATCHLEVEL@.dll" SelfReg="false"/>
- <ROW File="background_texture.gif" Component_="zinc.gif" FileName="backgr~1.gif|background_texture.gif" Version="" Language="" Attributes="" SourcePath="..\demos\images\background_texture.gif" SelfReg="false"/>
- <ROW File="hegias_parouest_TE.vid" Component_="videomap_paris_w_90_2" FileName="hegias~1.vid|hegias_parouest_TE.vid" Version="" Language="" Attributes="" SourcePath="..\demos\data\hegias_parouest_TE.vid" SelfReg="false"/>
- <ROW File="lines.tcl" Component_="reliefs.tcl" FileName="lines.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\lines.tcl" SelfReg="false"/>
- <ROW File="magicLens.tcl" Component_="reliefs.tcl" FileName="magicL~1.tcl|magicLens.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\magicLens.tcl" SelfReg="false"/>
- <ROW File="paper.gif" Component_="zinc.gif" FileName="paper.gif" Version="" Language="" Attributes="" SourcePath="..\demos\images\paper.gif" SelfReg="false"/>
- <ROW File="tiger.tcl" Component_="reliefs.tcl" FileName="tiger.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\tiger.tcl" SelfReg="false"/>
- <ROW File="colorCircular.tcl" Component_="reliefs.tcl" FileName="colorC~1.tcl|colorCircular.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\colorCircular.tcl" SelfReg="false"/>
- <ROW File="groupsInAtcStrips.tcl" Component_="reliefs.tcl" FileName="groups~1.tcl|groupsInAtcStrips.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\groupsInAtcStrips.tcl" SelfReg="false"/>
- <ROW File="pathTags.tcl" Component_="reliefs.tcl" FileName="pathTags.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\pathTags.tcl" SelfReg="false"/>
- <ROW File="simpleRadar.tcl" Component_="reliefs.tcl" FileName="simple~2.tcl|simpleRadar.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\simpleRadar.tcl" SelfReg="false"/>
- <ROW File="tkZincLogo.tcl" Component_="reliefs.tcl" FileName="tkZinc~1.tcl|tkZincLogo.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\tkZincLogo.tcl" SelfReg="false"/>
- <ROW File="allOptions.tcl" Component_="reliefs.tcl" FileName="allOpt~1.tcl|allOptions.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\allOptions.tcl" SelfReg="false"/>
- <ROW File="atomicGroups.tcl" Component_="reliefs.tcl" FileName="atomic~1.tcl|atomicGroups.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\atomicGroups.tcl" SelfReg="false"/>
- <ROW File="contours.tcl" Component_="reliefs.tcl" FileName="contours.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\contours.tcl" SelfReg="false"/>
- <ROW File="iconTransform.tcl" Component_="reliefs.tcl" FileName="iconTr~1.tcl|iconTransform.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\iconTransform.tcl" SelfReg="false"/>
- <ROW File="textInput.tcl" Component_="reliefs.tcl" FileName="textIn~1.tcl|textInput.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\textInput.tcl" SelfReg="false"/>
- <ROW File="windowContours.tcl" Component_="reliefs.tcl" FileName="window~1.tcl|windowContours.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\windowContours.tcl" SelfReg="false"/>
- <ROW File="zincGraphics.tcl" Component_="pkgIndex.tcl" FileName="zincGr~1.tcl|zincGraphics.tcl" Version="" Language="" Attributes="" SourcePath="..\library\zincGraphics.tcl" SelfReg="false"/>
- <ROW File="zincLogo.tcl" Component_="pkgIndex.tcl" FileName="zincLogo.tcl" Version="" Language="" Attributes="" SourcePath="..\library\zincLogo.tcl" SelfReg="false"/>
- <ROW File="clipping.tcl" Component_="reliefs.tcl" FileName="clipping.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\clipping.tcl" SelfReg="false"/>
- <ROW File="curveBezier.tcl" Component_="reliefs.tcl" FileName="curveB~1.tcl|curveBezier.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\curveBezier.tcl" SelfReg="false"/>
- <ROW File="stripped_texture.gif" Component_="zinc.gif" FileName="stripp~1.gif|stripped_texture.gif" Version="" Language="" Attributes="" SourcePath="..\demos\images\stripped_texture.gif" SelfReg="false"/>
- <ROW File="colorX.tcl" Component_="reliefs.tcl" FileName="colorX.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\colorX.tcl" SelfReg="false"/>
- <ROW File="zinc.gif" Component_="zinc.gif" FileName="zinc.gif" Version="" Language="" Attributes="" SourcePath="..\demos\images\zinc.gif" SelfReg="false"/>
- <ROW File="zinc_widget.tcl" Component_="zinc_widget.tcl" FileName="zinc-w~1.tcl|zinc-widget.tcl" Version="" Language="" Attributes="" SourcePath="zinc-widget.tcl" SelfReg="false"/>
- <ROW File="colorY.tcl" Component_="reliefs.tcl" FileName="colorY.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\colorY.tcl" SelfReg="false"/>
- <ROW File="labelformat.tcl" Component_="reliefs.tcl" FileName="labelf~1.tcl|labelformat.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\labelformat.tcl" SelfReg="false"/>
- <ROW File="triangles.tcl" Component_="reliefs.tcl" FileName="triang~1.tcl|triangles.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\triangles.tcl" SelfReg="false"/>
- <ROW File="videomap_orly" Component_="videomap_paris_w_90_2" FileName="videom~2|videomap_orly" Version="" Language="" Attributes="" SourcePath="..\demos\data\videomap_orly" SelfReg="false"/>
- <ROW File="zincText.tcl" Component_="pkgIndex.tcl" FileName="zincText.tcl" Version="" Language="" Attributes="" SourcePath="..\library\zincText.tcl" SelfReg="false"/>
- <ROW File="pkgIndex.tcl" Component_="pkgIndex.tcl" FileName="pkgIndex.tcl" Version="" Language="" Attributes="" SourcePath="pkgIndex.tcl" SelfReg="false"/>
- <ROW File="reliefs.tcl" Component_="reliefs.tcl" FileName="reliefs.tcl" Version="" Language="" Attributes="" SourcePath="..\demos\reliefs.tcl" SelfReg="false"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiCustActComponent">
- <ROW Action="SET_SHORTCUTDIR" Type="307" Source="SHORTCUTDIR" Target="[WindowsVolume]\Tcl\demos\Tkzinc"/>
- <ROW Action="SET_TARGETDIR" Type="307" Source="TARGETDIR" Target="[WindowsVolume]\Tcl"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiCreateFolderComponent">
- <ROW Directory_="demos" Component_="demos"/>
- <ROW Directory_="lib" Component_="lib"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiMediaComponent">
- <ATTRIBUTE name="InstallationType" value="0"/>
- <ATTRIBUTE name="MediaSize" value="0"/>
- <ATTRIBUTE name="Compress" value="1"/>
- <ATTRIBUTE name="Package" value="1"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiUpgradeComponent">
- <ROW UpgradeCode="UpgradeCode" VersionMin="" VersionMax="ProductVersion" Language="" Attributes="1025" Remove=""/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiBinaryComponent">
- <ROW Name="default_banner.bmp" SourcePath="&lt;default-banner.bmp&gt;"/>
- <ROW Name="default_dialog.bmp" SourcePath="&lt;default-dialog.bmp&gt;"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiLaunchConditionsComponent">
- <ROW Condition="Version9X&lt;&gt;400" Description="[ProductName] cannot be installed on Windows 95."/>
- <ROW Condition="Version9X&lt;&gt;410" Description="[ProductName] cannot be installed on Windows 98."/>
- <ROW Condition="Version9X&lt;&gt;490" Description="[ProductName] cannot be installed on Windows Milennium Edition."/>
- <ROW Condition="VersionNT&lt;&gt;400" Description="[ProductName] cannot be installed on Windows NT 4.0."/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiInstallUISequenceComponent">
- <ATTRIBUTE name="Start" value="WelcomeDlg FolderDlg VerifyReadyDlg"/>
- <ATTRIBUTE name="Progress" value="ProgressDlg"/>
- <ATTRIBUTE name="End" value="ExitDialog"/>
- </COMPONENT>
-</DOCUMENT>
diff --git a/win/Tkzincperl.aip.in b/win/Tkzincperl.aip.in
deleted file mode 100644
index b6e5e02..0000000
--- a/win/Tkzincperl.aip.in
+++ /dev/null
@@ -1,151 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<DOCUMENT type="Advanced Installer" version="1.4" modules="freeware" RootPath=".">
- <COMPONENT cid="caphyon.advinst.msicomp.MsiPropsComponent">
- <ROW Property="ARPURLINFOABOUT" Value="www.tkzinc.org"/>
- <ROW Property="DialogBitmap" Value="default_dialog.bmp"/>
- <ROW Property="Manufacturer" Value="C.E.N.A"/>
- <ROW Property="ProductLanguage" Value="1033"/>
- <ROW Property="ProductName" Value="Tkzinc-perl"/>
- <ROW Property="ALLUSERS" Value="2"/>
- <ROW Property="ARPCONTACT" Value="zinc@cena.fr"/>
- <ROW Property="BannerBitmap" Value="default_banner.bmp"/>
- <ROW Property="ProductVersion" Value="@VERSION@"/>
- <ROW Property="SecureCustomProperties" Value="OLDPRODUCTS"/>
- <ROW Property="UpgradeCode" Value="{FF2B87A1-C290-433D-8B75-11C51DEFBF4B}"/>
- <ROW Property="ProductCode" Value="{76AB4D37-3059-4ED1-AA67-57BB8B1C2FB3}"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiDirsComponent">
- <ROW Directory="Zinc" Directory_Parent="Tk" DefaultDir="Zinc"/>
- <ROW Directory="Zinc_1" Directory_Parent="Tk_1" DefaultDir="Zinc"/>
- <ROW Directory="demos" Directory_Parent="Tk_1" DefaultDir="demos"/>
- <ROW Directory="zinc_pm" Directory_Parent="demos" DefaultDir="zinc_pm"/>
- <ROW Directory="auto" Directory_Parent="lib" DefaultDir="auto"/>
- <ROW Directory="bin" Directory_Parent="TARGETDIR" DefaultDir="bin"/>
- <ROW Directory="site" Directory_Parent="TARGETDIR" DefaultDir="site"/>
- <ROW Directory="zinc_data" Directory_Parent="demos" DefaultDir="zinc_d~1|zinc_data"/>
- <ROW Directory="TARGETDIR" Directory_Parent="" DefaultDir="SourceDir"/>
- <ROW Directory="zinc_contrib_lib" Directory_Parent="demos" DefaultDir="zinc_c~1|zinc_contrib_lib"/>
- <ROW Directory="zinc_lib" Directory_Parent="demos" DefaultDir="zinc_lib"/>
- <ROW Directory="Tk" Directory_Parent="auto" DefaultDir="Tk"/>
- <ROW Directory="Tk_1" Directory_Parent="lib" DefaultDir="Tk"/>
- <ROW Directory="lib" Directory_Parent="site" DefaultDir="lib"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiCompsComponent">
- <ROW Component="Zinc.pdb" ComponentId="{F7C10F4C-49E2-4A87-9CE4-6FDF9F2C9190}" Directory_="Zinc" Attributes="0" Condition="" KeyPath="Zinc.pdb" FullKeyPath="TARGETDIR\site\lib\auto\Tk\Zinc"/>
- <ROW Component="demos" ComponentId="{667472C4-DA67-4414-AF5C-66DEB5CE0D19}" Directory_="demos" Attributes="0" Condition="" KeyPath="" FullKeyPath=""/>
- <ROW Component="auto" ComponentId="{8056E60B-3CCC-4934-B7FE-7A78711FF1EF}" Directory_="auto" Attributes="0" Condition="" KeyPath="" FullKeyPath=""/>
- <ROW Component="site" ComponentId="{C6397E22-6B68-4223-82D0-D5F6B23ABCA8}" Directory_="site" Attributes="0" Condition="" KeyPath="" FullKeyPath=""/>
- <ROW Component="Zinc.dll" ComponentId="{D96C4370-BE7B-43E7-A5E6-7D4D16FE06A2}" Directory_="Zinc" Attributes="0" Condition="" KeyPath="Zinc.dll" FullKeyPath="TARGETDIR\site\lib\auto\Tk\Zinc\Zinc.dll"/>
- <ROW Component="SimpleRadarControls.pm" ComponentId="{0AA127CF-56CA-4F8A-9480-3BAFB467BE0B}" Directory_="zinc_pm" Attributes="0" Condition="" KeyPath="SimpleRadarControls.pm" FullKeyPath="TARGETDIR\site\lib\Tk\demos\zinc_pm"/>
- <ROW Component="Tk" ComponentId="{5876071E-15AD-4A01-B0E4-4DBFCBCA3002}" Directory_="Tk" Attributes="0" Condition="" KeyPath="" FullKeyPath=""/>
- <ROW Component="TraceUtils.pm" ComponentId="{01F3478B-E89C-431C-9E93-92EE1FC3831A}" Directory_="Zinc_1" Attributes="0" Condition="" KeyPath="TraceUtils.pm" FullKeyPath="TARGETDIR\site\lib\Tk\Zinc"/>
- <ROW Component="TripleRotatingWheel.pl" ComponentId="{6880F916-90D4-41F6-B15E-6046AC4E5F84}" Directory_="zinc_contrib_lib" Attributes="0" Condition="" KeyPath="TripleRotatingWheel.pl" FullKeyPath="TARGETDIR\site\lib\Tk\demos\zinc_contrib_lib"/>
- <ROW Component="Zinc.pm" ComponentId="{09BA61D1-CEF5-4A84-9EB1-CA3A11FD58C6}" Directory_="Tk_1" Attributes="0" Condition="" KeyPath="Zinc.pm" FullKeyPath="TARGETDIR\site\lib\Tk"/>
- <ROW Component="lib" ComponentId="{F85FD376-379E-400A-BAF6-5A87BB455864}" Directory_="lib" Attributes="0" Condition="" KeyPath="" FullKeyPath=""/>
- <ROW Component="zinc_anti.gif" ComponentId="{A1AE55D1-7A80-4357-9003-F410383B4A2A}" Directory_="zinc_data" Attributes="0" Condition="" KeyPath="zinc_anti.gif" FullKeyPath="TARGETDIR\site\lib\Tk\demos\zinc_data"/>
- <ROW Component="zinc_demos.bat" ComponentId="{D547BFCA-5674-491D-8E03-183D90F51365}" Directory_="bin" Attributes="0" Condition="" KeyPath="zinc_demos.bat" FullKeyPath="TARGETDIR\bin"/>
- <ROW Component="zoom.pl" ComponentId="{153D1046-6E03-424B-B715-A88C24285360}" Directory_="zinc_lib" Attributes="0" Condition="" KeyPath="zoom.pl" FullKeyPath="TARGETDIR\site\lib\Tk\demos\zinc_lib"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiFeatsComponent">
- <ROW Feature="MainFeature" Feature_Parent="" Title="Main Feature" Description="Main Feature" Display="2" Level="1" Directory_="TARGETDIR" Attributes="0" Components="zinc_demos.bat site lib auto Tk Zinc.pdb Zinc.dll TraceUtils.pm Zinc.pm demos TripleRotatingWheel.pl zoom.pl zinc_anti.gif SimpleRadarControls.pm"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiFilesComponent">
- <ROW File="Text.pm" Component_="TraceUtils.pm" FileName="Text.pm" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\Zinc\Text.pm" SelfReg="false"/>
- <ROW File="clipping.pl" Component_="zoom.pl" FileName="clipping.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\clipping.pl" SelfReg="false"/>
- <ROW File="color_x.pl" Component_="zoom.pl" FileName="color-x.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\color-x.pl" SelfReg="false"/>
- <ROW File="color_y.pl" Component_="zoom.pl" FileName="color-y.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\color-y.pl" SelfReg="false"/>
- <ROW File="Debug.pm" Component_="TraceUtils.pm" FileName="Debug.pm" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\Zinc\Debug.pm" SelfReg="false"/>
- <ROW File="Graphics.pod" Component_="TraceUtils.pm" FileName="Graphics.pod" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\Zinc\Graphics.pod" SelfReg="false"/>
- <ROW File="color_path_and_conic.pl" Component_="zoom.pl" FileName="color-~2.pl|color-path-and-conic.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\color-path-and-conic.pl" SelfReg="false"/>
- <ROW File="paper_grey.gif" Component_="zinc_anti.gif" FileName="paper-~1.gif|paper-grey.gif" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\paper-grey.gif" SelfReg="false"/>
- <ROW File="videomap_paris_w_90_2" Component_="zinc_anti.gif" FileName="videom~2|videomap_paris-w_90_2" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\videomap_paris-w_90_2" SelfReg="false"/>
- <ROW File="SimpleRadarControls.pm" Component_="SimpleRadarControls.pm" FileName="Simple~1.pm|SimpleRadarControls.pm" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_pm\SimpleRadarControls.pm" SelfReg="false"/>
- <ROW File="labelformat.pl" Component_="zoom.pl" FileName="labelf~1.pl|labelformat.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\labelformat.pl" SelfReg="false"/>
- <ROW File="paper_grey1.gif" Component_="zinc_anti.gif" FileName="paper-~2.gif|paper-grey1.gif" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\paper-grey1.gif" SelfReg="false"/>
- <ROW File="triangles.pl" Component_="zoom.pl" FileName="triang~1.pl|triangles.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\triangles.pl" SelfReg="false"/>
- <ROW File="zinc_anti.gif" Component_="zinc_anti.gif" FileName="zinc_a~1.gif|zinc_anti.gif" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\zinc_anti.gif" SelfReg="false"/>
- <ROW File="background_texture.gif" Component_="zinc_anti.gif" FileName="backgr~1.gif|background_texture.gif" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\background_texture.gif" SelfReg="false"/>
- <ROW File="mapinfo.pl" Component_="zoom.pl" FileName="mapinfo.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\mapinfo.pl" SelfReg="false"/>
- <ROW File="lines.pl" Component_="zoom.pl" FileName="lines.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\lines.pl" SelfReg="false"/>
- <ROW File="path_tags.pl" Component_="zoom.pl" FileName="path_t~1.pl|path_tags.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\path_tags.pl" SelfReg="false"/>
- <ROW File="tiger.pl" Component_="zoom.pl" FileName="tiger.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\tiger.pl" SelfReg="false"/>
- <ROW File="atomic_groups.pl" Component_="zoom.pl" FileName="atomic~1.pl|atomic-groups.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\atomic-groups.pl" SelfReg="false"/>
- <ROW File="TraceErrors.pm" Component_="TraceUtils.pm" FileName="TraceE~1.pm|TraceErrors.pm" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\Zinc\TraceErrors.pm" SelfReg="false"/>
- <ROW File="TripleRotatingWheel.pl" Component_="TripleRotatingWheel.pl" FileName="Triple~1.pl|TripleRotatingWheel.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_contrib_lib\TripleRotatingWheel.pl" SelfReg="false"/>
- <ROW File="Zinc.bs" Component_="Zinc.pdb" FileName="Zinc.bs" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\arch\auto\Tk\Zinc\Zinc.bs" SelfReg="false"/>
- <ROW File="contours.pl" Component_="zoom.pl" FileName="contours.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\contours.pl" SelfReg="false"/>
- <ROW File="simple_interaction_track.pl" Component_="zoom.pl" FileName="simple~1.pl|simple_interaction_track.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\simple_interaction_track.pl" SelfReg="false"/>
- <ROW File="wheelOfFortune.pl" Component_="zoom.pl" FileName="wheelO~1.pl|wheelOfFortune.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\wheelOfFortune.pl" SelfReg="false"/>
- <ROW File="Zinc.pdb" Component_="Zinc.pdb" FileName="Zinc.pdb" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\arch\auto\Tk\Zinc\Zinc.pdb" SelfReg="false"/>
- <ROW File="icon_zoom_resize.pl" Component_="zoom.pl" FileName="icon_z~1.pl|icon_zoom_resize.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\icon_zoom_resize.pl" SelfReg="false"/>
- <ROW File="zinc.gif" Component_="zinc_anti.gif" FileName="zinc.gif" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\zinc.gif" SelfReg="false"/>
- <ROW File="Zinc.lib" Component_="Zinc.pdb" FileName="Zinc.lib" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\arch\auto\Tk\Zinc\Zinc.lib" SelfReg="false"/>
- <ROW File="fillrule.pl" Component_="zoom.pl" FileName="fillrule.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\fillrule.pl" SelfReg="false"/>
- <ROW File="transforms.pl" Component_="zoom.pl" FileName="transf~1.pl|transforms.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\transforms.pl" SelfReg="false"/>
- <ROW File="translation.pl" Component_="zoom.pl" FileName="transl~1.pl|translation.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\translation.pl" SelfReg="false"/>
- <ROW File="Trace.pm" Component_="TraceUtils.pm" FileName="Trace.pm" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\Zinc\Trace.pm" SelfReg="false"/>
- <ROW File="counter.pl" Component_="zoom.pl" FileName="counter.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\counter.pl" SelfReg="false"/>
- <ROW File="rotation.pl" Component_="zoom.pl" FileName="rotation.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\rotation.pl" SelfReg="false"/>
- <ROW File="videomap_orly" Component_="zinc_anti.gif" FileName="videom~1|videomap_orly" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\videomap_orly" SelfReg="false"/>
- <ROW File="TraceUtils.pm" Component_="TraceUtils.pm" FileName="TraceU~1.pm|TraceUtils.pm" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\Zinc\TraceUtils.pm" SelfReg="false"/>
- <ROW File="Zetris.pl" Component_="zoom.pl" FileName="Zetris.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\Zetris.pl" SelfReg="false"/>
- <ROW File="groups_in_ATC_strips.pl" Component_="zoom.pl" FileName="groups~1.pl|groups_in_ATC_strips.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\groups_in_ATC_strips.pl" SelfReg="false"/>
- <ROW File="groups_priority.pl" Component_="zoom.pl" FileName="groups~2.pl|groups_priority.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\groups_priority.pl" SelfReg="false"/>
- <ROW File="testGraphics.pl" Component_="zoom.pl" FileName="testGr~1.pl|testGraphics.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\testGraphics.pl" SelfReg="false"/>
- <ROW File="zinc_demos.bat" Component_="zinc_demos.bat" FileName="zinc-d~1|zinc-demos.bat" Version="" Language="" Attributes="" SourcePath="zinc-demos.bat" SelfReg="false"/>
- <ROW File="Graphics.pm" Component_="TraceUtils.pm" FileName="Graphics.pm" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\Zinc\Graphics.pm" SelfReg="false"/>
- <ROW File="Logo.pm" Component_="TraceUtils.pm" FileName="Logo.pm" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\Zinc\Logo.pm" SelfReg="false"/>
- <ROW File="hegias_parouest_TE.vid" Component_="zinc_anti.gif" FileName="hegias~1.vid|hegias_parouest_TE.vid" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\hegias_parouest_TE.vid" SelfReg="false"/>
- <ROW File="items.pl" Component_="zoom.pl" FileName="items.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\items.pl" SelfReg="false"/>
- <ROW File="paper.gif" Component_="zinc_anti.gif" FileName="paper.gif" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\paper.gif" SelfReg="false"/>
- <ROW File="MagicLens.pl" Component_="zoom.pl" FileName="MagicL~1.pl|MagicLens.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\MagicLens.pl" SelfReg="false"/>
- <ROW File="color_circular.pl" Component_="zoom.pl" FileName="color-~1.pl|color-circular.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\color-circular.pl" SelfReg="false"/>
- <ROW File="README" Component_="TripleRotatingWheel.pl" FileName="README" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_contrib_lib\README" SelfReg="false"/>
- <ROW File="Zinc.dll" Component_="Zinc.dll" FileName="Zinc.dll" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\arch\auto\Tk\Zinc\Zinc.dll" SelfReg="false"/>
- <ROW File="all_options.pl" Component_="zoom.pl" FileName="all_op~1.pl|all_options.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\all_options.pl" SelfReg="false"/>
- <ROW File="simpleradar.pl" Component_="zoom.pl" FileName="simple~2.pl|simpleradar.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\simpleradar.pl" SelfReg="false"/>
- <ROW File="tkZincLogo.pl" Component_="zoom.pl" FileName="tkZinc~1.pl|tkZincLogo.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\tkZincLogo.pl" SelfReg="false"/>
- <ROW File="window_contours.pl" Component_="zoom.pl" FileName="window~1.pl|window-contours.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\window-contours.pl" SelfReg="false"/>
- <ROW File="Zinc.exp" Component_="Zinc.pdb" FileName="Zinc.exp" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\arch\auto\Tk\Zinc\Zinc.exp" SelfReg="false"/>
- <ROW File="Zinc.pm" Component_="Zinc.pm" FileName="Zinc.pm" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\Zinc.pm" SelfReg="false"/>
- <ROW File="curve_bezier.pl" Component_="zoom.pl" FileName="curve_~1.pl|curve_bezier.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\curve_bezier.pl" SelfReg="false"/>
- <ROW File="stripped_texture.gif" Component_="zinc_anti.gif" FileName="stripp~1.gif|stripped_texture.gif" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_data\stripped_texture.gif" SelfReg="false"/>
- <ROW File="textInput.pl" Component_="zoom.pl" FileName="textIn~1.pl|textInput.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\textInput.pl" SelfReg="false"/>
- <ROW File="zoom.pl" Component_="zoom.pl" FileName="zoom.pl" Version="" Language="" Attributes="" SourcePath="..\buildperl\blib\lib\Tk\demos\zinc_lib\zoom.pl" SelfReg="false"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiCustActComponent">
- <ROW Action="SET_SHORTCUTDIR" Type="307" Source="SHORTCUTDIR" Target="[WindowsVolume]\Perl"/>
- <ROW Action="SET_TARGETDIR" Type="307" Source="TARGETDIR" Target="[WindowsVolume]\Perl"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiCreateFolderComponent">
- <ROW Directory_="Tk" Component_="Tk"/>
- <ROW Directory_="site" Component_="site"/>
- <ROW Directory_="auto" Component_="auto"/>
- <ROW Directory_="lib" Component_="lib"/>
- <ROW Directory_="demos" Component_="demos"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiMediaComponent">
- <ATTRIBUTE name="InstallationType" value="0"/>
- <ATTRIBUTE name="MediaSize" value="0"/>
- <ATTRIBUTE name="Compress" value="1"/>
- <ATTRIBUTE name="Package" value="1"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiUpgradeComponent">
- <ROW UpgradeCode="UpgradeCode" VersionMin="" VersionMax="ProductVersion" Language="" Attributes="1025" Remove=""/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiBinaryComponent">
- <ROW Name="default_banner.bmp" SourcePath="&lt;default-banner.bmp&gt;"/>
- <ROW Name="default_dialog.bmp" SourcePath="&lt;default-dialog.bmp&gt;"/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiLaunchConditionsComponent">
- <ROW Condition="Version9X&lt;&gt;400" Description="[ProductName] cannot be installed on Windows 95."/>
- <ROW Condition="Version9X&lt;&gt;410" Description="[ProductName] cannot be installed on Windows 98."/>
- <ROW Condition="Version9X&lt;&gt;490" Description="[ProductName] cannot be installed on Windows Milennium Edition."/>
- <ROW Condition="VersionNT&lt;&gt;400" Description="[ProductName] cannot be installed on Windows NT 4.0."/>
- </COMPONENT>
- <COMPONENT cid="caphyon.advinst.msicomp.MsiInstallUISequenceComponent">
- <ATTRIBUTE name="Start" value="WelcomeDlg FolderDlg VerifyReadyDlg"/>
- <ATTRIBUTE name="Progress" value="ProgressDlg"/>
- <ATTRIBUTE name="End" value="ExitDialog"/>
- </COMPONENT>
-</DOCUMENT>
diff --git a/win/WinPort.c b/win/WinPort.c
deleted file mode 100644
index 8e6b8d8..0000000
--- a/win/WinPort.c
+++ /dev/null
@@ -1,1042 +0,0 @@
-/*
- * WinPort.c -- Compatibility layer for Windows 2k
- *
- * Authors : Patrick Lecoanet.
- * Creation date :
- *
- * $Id$
- */
-
-/*
- * Copyright (c) 2003 - CENA, Patrick Lecoanet --
- *
- * This code is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This code is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public
- * License along with this code; if not, write to the Free
- * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
- *
- */
-
-#ifdef _WIN32
-
-#include "Types.h"
-
-#include <tkInt.h>
-#include <tkWinInt.h>
-#ifdef PTK
-#include <tkIntPlatDecls.m>
-#endif
-
-static const char rcsid[] = "$Id";
-static const char compile_id[]="$Compile$";
-
-#ifndef MIN
-#define MIN(a, b) ((a) <= (b) ? (a) : (b))
-#endif
-#ifndef MAX
-#define MAX(a, b) ((a) >= (b) ? (a) : (b))
-#endif
-
-
-/*
- *----------------------------------------------------------------------
- *
- * ZnPointInRegion --
- *
- * Test whether the specified point is inside a region.
- *
- * Results:
- * Returns the boolean result of the test.
- *
- * Side effects:
- * None.
- *
- *----------------------------------------------------------------------
- */
-int
-ZnPointInRegion(TkRegion reg,
- int x,
- int y)
-{
- return PtInRegion((HRGN) reg, x, y);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * ZnUnionRegion --
- *
- * Compute the union of two regions.
- *
- * Results:
- * Returns the result in the dr_return region.
- *
- * Side effects:
- * None.
- *
- *----------------------------------------------------------------------
- */
-void
-ZnUnionRegion(TkRegion sra,
- TkRegion srb,
- TkRegion dr_return)
-{
- CombineRgn((HRGN) dr_return, (HRGN) sra, (HRGN) srb, RGN_OR);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * ZnOffsetRegion --
- *
- * Offset a region by the specified pixel offsets.
- *
- * Results:
- * Returns the result in the dr_return region.
- *
- * Side effects:
- * None.
- *
- *----------------------------------------------------------------------
- */
-void
-ZnOffsetRegion(TkRegion reg,
- int dx,
- int dy)
-{
- OffsetRgn((HRGN) reg, dx, dy);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * ZnPolygonRegion --
- *
- * Compute a region from a polygon.
- *
- * Results:
- * Returns the result in the dr_return region.
- *
- * Side effects:
- * None.
- *
- *----------------------------------------------------------------------
- */
-TkRegion
-ZnPolygonRegion(XPoint *points,
- int n,
- int fill_rule)
-{
- POINT *pts;
- HRGN reg;
- int i;
-
- pts = (POINT *) ckalloc(n*sizeof(POINT));
- for (i = 0; i < n; i++, points++) {
- pts[i].x = points->x;
- pts[i].y = points->y;
- }
-
- reg = CreatePolygonRgn(pts, n,
- fill_rule==EvenOddRule?ALTERNATE:WINDING);
- if (!reg) {
- fprintf(stderr, "Polygon region failed: %ld, n: %d\n", GetLastError(), n);
- }
- ckfree((char *) pts);
- return (TkRegion) reg;
-}
-
-#define PI 3.14159265358979
-#define XAngleToRadians(a) ((double)(a) / 64 * PI / 180);
-
-/*
- * Translation table between X gc functions and Win32 raster op modes.
- */
-
-int tkpWinRopModes[] = {
- R2_BLACK, /* GXclear */
- R2_MASKPEN, /* GXand */
- R2_MASKPENNOT, /* GXandReverse */
- R2_COPYPEN, /* GXcopy */
- R2_MASKNOTPEN, /* GXandInverted */
- R2_NOT, /* GXnoop */
- R2_XORPEN, /* GXxor */
- R2_MERGEPEN, /* GXor */
- R2_NOTMERGEPEN, /* GXnor */
- R2_NOTXORPEN, /* GXequiv */
- R2_NOT, /* GXinvert */
- R2_MERGEPENNOT, /* GXorReverse */
- R2_NOTCOPYPEN, /* GXcopyInverted */
- R2_MERGENOTPEN, /* GXorInverted */
- R2_NOTMASKPEN, /* GXnand */
- R2_WHITE /* GXset */
-};
-
-/*
- * The following two raster ops are used to copy the foreground and background
- * bits of a source pattern as defined by a stipple used as the pattern.
- */
-
-#define COPYFG 0x00CA0749 /* dest = (pat & src) | (!pat & dst) */
-#define COPYBG 0x00AC0744 /* dest = (!pat & src) | (pat & dst) */
-
-/*
- * The followng typedef is used to pass Windows GDI drawing functions.
- */
-
-typedef BOOL (CALLBACK *WinDrawFunc) _ANSI_ARGS_((HDC dc,
- CONST POINT* points, int npoints));
-
-typedef struct ThreadSpecificData {
- POINT *winPoints; /* Array of points that is reused. */
- int nWinPoints; /* Current size of point array. */
-} ThreadSpecificData;
-static Tcl_ThreadDataKey dataKey;
-
-/*
- *----------------------------------------------------------------------
- *
- * SetUpGraphicsPort --
- *
- * Set up the graphics port from the given GC.
- *
- * Results:
- * None.
- *
- * Side effects:
- * The current port is adjusted.
- *
- *----------------------------------------------------------------------
- */
-
-static HPEN
-SetUpGraphicsPort(gc)
- GC gc;
-{
- DWORD style;
-
- if (gc->line_style == LineOnOffDash) {
- unsigned char *p = (unsigned char *) &(gc->dashes);
- /* pointer to the dash-list */
-
- /*
- * Below is a simple translation of serveral dash patterns
- * to valid windows pen types. Far from complete,
- * but I don't know how to do it better.
- * Any ideas: <mailto:j.nijtmans@chello.nl>
- */
-
- if (p[1] && p[2]) {
- if (!p[3] || p[4]) {
- style = PS_DASHDOTDOT; /* -.. */
- } else {
- style = PS_DASHDOT; /* -. */
- }
- } else {
- if (p[0] > (4 * gc->line_width)) {
- style = PS_DASH; /* - */
- } else {
- style = PS_DOT; /* . */
- }
- }
- } else {
- style = PS_SOLID;
- }
- if (gc->line_width < 2) {
- return CreatePen(style, gc->line_width, gc->foreground);
- } else {
- LOGBRUSH lb;
-
- lb.lbStyle = BS_SOLID;
- lb.lbColor = gc->foreground;
- lb.lbHatch = 0;
-
- style |= PS_GEOMETRIC;
- switch (gc->cap_style) {
- case CapNotLast:
- case CapButt:
- style |= PS_ENDCAP_FLAT;
- break;
- case CapRound:
- style |= PS_ENDCAP_ROUND;
- break;
- default:
- style |= PS_ENDCAP_SQUARE;
- break;
- }
- switch (gc->join_style) {
- case JoinMiter:
- style |= PS_JOIN_MITER;
- break;
- case JoinRound:
- style |= PS_JOIN_ROUND;
- break;
- default:
- style |= PS_JOIN_BEVEL;
- break;
- }
- return ExtCreatePen(style, gc->line_width, &lb, 0, NULL);
- }
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * ConvertPoints --
- *
- * Convert an array of X points to an array of Win32 points.
- *
- * Results:
- * Returns the converted array of POINTs.
- *
- * Side effects:
- * Allocates a block of memory in thread local storage that
- * should not be freed.
- *
- *----------------------------------------------------------------------
- */
-
-static POINT *
-ConvertPoints(points, npoints, mode, bbox)
- XPoint *points;
- int npoints;
- int mode; /* CoordModeOrigin or CoordModePrevious. */
- RECT *bbox; /* Bounding box of points. */
-{
- ThreadSpecificData *tsdPtr = (ThreadSpecificData *)
- Tcl_GetThreadData(&dataKey, sizeof(ThreadSpecificData));
- int i;
-
- /*
- * To avoid paying the cost of a malloc on every drawing routine,
- * we reuse the last array if it is large enough.
- */
-
- if (npoints > tsdPtr->nWinPoints) {
- if (tsdPtr->winPoints != NULL) {
- ckfree((char *) tsdPtr->winPoints);
- }
- tsdPtr->winPoints = (POINT *) ckalloc(sizeof(POINT) * npoints);
- if (tsdPtr->winPoints == NULL) {
- tsdPtr->nWinPoints = -1;
- return NULL;
- }
- tsdPtr->nWinPoints = npoints;
- }
-
- bbox->left = bbox->right = points[0].x;
- bbox->top = bbox->bottom = points[0].y;
-
- if (mode == CoordModeOrigin) {
- for (i = 0; i < npoints; i++) {
- tsdPtr->winPoints[i].x = points[i].x;
- tsdPtr->winPoints[i].y = points[i].y;
- bbox->left = MIN(bbox->left, tsdPtr->winPoints[i].x);
- bbox->right = MAX(bbox->right, tsdPtr->winPoints[i].x);
- bbox->top = MIN(bbox->top, tsdPtr->winPoints[i].y);
- bbox->bottom = MAX(bbox->bottom, tsdPtr->winPoints[i].y);
- }
- } else {
- tsdPtr->winPoints[0].x = points[0].x;
- tsdPtr->winPoints[0].y = points[0].y;
- for (i = 1; i < npoints; i++) {
- tsdPtr->winPoints[i].x = tsdPtr->winPoints[i-1].x + points[i].x;
- tsdPtr->winPoints[i].y = tsdPtr->winPoints[i-1].y + points[i].y;
- bbox->left = MIN(bbox->left, tsdPtr->winPoints[i].x);
- bbox->right = MAX(bbox->right, tsdPtr->winPoints[i].x);
- bbox->top = MIN(bbox->top, tsdPtr->winPoints[i].y);
- bbox->bottom = MAX(bbox->bottom, tsdPtr->winPoints[i].y);
- }
- }
- return tsdPtr->winPoints;
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * XFillRectangles --
- *
- * Fill multiple rectangular areas in the given drawable.
- *
- * Results:
- * None.
- *
- * Side effects:
- * Draws onto the specified drawable.
- *
- *----------------------------------------------------------------------
- */
-void
-XFillRectangles(display, d, gc, rectangles, nrectangles)
- Display* display;
- Drawable d;
- GC gc;
- XRectangle* rectangles;
- int nrectangles;
-{
- HDC dc;
- int i;
- RECT rect;
- TkWinDCState state;
- HBRUSH brush;
- TkpClipMask *clipPtr = (TkpClipMask*)gc->clip_mask;
-
- if (d == None) {
- return;
- }
-
- dc = TkWinGetDrawableDC(display, d, &state);
- SetROP2(dc, tkpWinRopModes[gc->function]);
- brush = CreateSolidBrush(gc->foreground);
-
- if (clipPtr && clipPtr->type == TKP_CLIP_REGION) {
- SelectClipRgn(dc, (HRGN) clipPtr->value.region);
- OffsetClipRgn(dc, gc->clip_x_origin, gc->clip_y_origin);
- }
- if ((gc->fill_style == FillStippled
- || gc->fill_style == FillOpaqueStippled)
- && gc->stipple != None) {
- TkWinDrawable *twdPtr = (TkWinDrawable *)gc->stipple;
- HBRUSH oldBrush, stipple;
- HBITMAP oldBitmap, bitmap;
- HDC dcMem;
- HBRUSH bgBrush = CreateSolidBrush(gc->background);
-
- if (twdPtr->type != TWD_BITMAP) {
- Tcl_Panic("unexpected drawable type in stipple");
- }
-
- /*
- * Select stipple pattern into destination dc.
- */
-
- stipple = CreatePatternBrush(twdPtr->bitmap.handle);
- SetBrushOrgEx(dc, gc->ts_x_origin, gc->ts_y_origin, NULL);
- oldBrush = SelectObject(dc, stipple);
- dcMem = CreateCompatibleDC(dc);
-
- /*
- * For each rectangle, create a drawing surface which is the size of
- * the rectangle and fill it with the background color. Then merge the
- * result with the stipple pattern.
- */
- for (i = 0; i < nrectangles; i++) {
- bitmap = CreateCompatibleBitmap(dc, rectangles[i].width,
- rectangles[i].height);
- oldBitmap = SelectObject(dcMem, bitmap);
- rect.left = 0;
- rect.top = 0;
- rect.right = rectangles[i].width;
- rect.bottom = rectangles[i].height;
- FillRect(dcMem, &rect, brush);
- BitBlt(dc, rectangles[i].x, rectangles[i].y, rectangles[i].width,
- rectangles[i].height, dcMem, 0, 0, COPYFG);
- if (gc->fill_style == FillOpaqueStippled) {
- FillRect(dcMem, &rect, bgBrush);
- BitBlt(dc, rectangles[i].x, rectangles[i].y,
- rectangles[i].width, rectangles[i].height, dcMem,
- 0, 0, COPYBG);
- }
- SelectObject(dcMem, oldBitmap);
- DeleteObject(bitmap);
- }
-
- DeleteDC(dcMem);
- SelectObject(dc, oldBrush);
- DeleteObject(stipple);
- DeleteObject(bgBrush);
- } else {
- for (i = 0; i < nrectangles; i++) {
- TkWinFillRect(dc, rectangles[i].x, rectangles[i].y,
- rectangles[i].width, rectangles[i].height, gc->foreground);
- }
- }
- DeleteObject(brush);
- TkWinReleaseDrawableDC(d, dc, &state);
-}
-
-
-/*
- *----------------------------------------------------------------------
- *
- * XFillRectangle --
- *
- * Fills a rectangular area in the given drawable. This procedure
- * is implemented as a call to XFillRectangles.
- *
- * Results:
- * None
- *
- * Side effects:
- * Fills the specified rectangle.
- *
- *----------------------------------------------------------------------
- */
-
-void
-XFillRectangle(display, d, gc, x, y, width, height)
- Display* display;
- Drawable d;
- GC gc;
- int x;
- int y;
- unsigned int width;
- unsigned int height;
-{
- XRectangle rectangle;
- rectangle.x = x;
- rectangle.y = y;
- rectangle.width = width;
- rectangle.height = height;
- XFillRectangles(display, d, gc, &rectangle, 1);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * RenderObject --
- *
- * This function draws a shape using a list of points, a
- * stipple pattern, and the specified drawing function.
- *
- * Results:
- * None.
- *
- * Side effects:
- * None.
- *
- *----------------------------------------------------------------------
- */
-
-static void
-RenderObject(dc, gc, points, npoints, mode, pen, func)
- HDC dc;
- GC gc;
- XPoint* points;
- int npoints;
- int mode;
- HPEN pen;
- WinDrawFunc func;
-{
- RECT rect;
- HPEN oldPen;
- HBRUSH oldBrush;
- POINT *winPoints = ConvertPoints(points, npoints, mode, &rect);
- TkpClipMask *clipPtr = (TkpClipMask*)gc->clip_mask;
-
- if (clipPtr && clipPtr->type == TKP_CLIP_REGION) {
- SelectClipRgn(dc, (HRGN) clipPtr->value.region);
- OffsetClipRgn(dc, gc->clip_x_origin, gc->clip_y_origin);
- }
- if ((gc->fill_style == FillStippled
- || gc->fill_style == FillOpaqueStippled)
- && gc->stipple != None) {
-
- TkWinDrawable *twdPtr = (TkWinDrawable *)gc->stipple;
- HDC dcMem;
- LONG width, height;
- HBITMAP oldBitmap;
- int i;
- HBRUSH oldMemBrush;
-
- if (twdPtr->type != TWD_BITMAP) {
- Tcl_Panic("unexpected drawable type in stipple");
- }
-
- /*
- * Grow the bounding box enough to account for line width.
- */
-
- rect.left -= gc->line_width;
- rect.top -= gc->line_width;
- rect.right += gc->line_width;
- rect.bottom += gc->line_width;
-
- width = rect.right - rect.left;
- height = rect.bottom - rect.top;
-
- /*
- * Select stipple pattern into destination dc.
- */
-
- SetBrushOrgEx(dc, gc->ts_x_origin, gc->ts_y_origin, NULL);
- oldBrush = SelectObject(dc, CreatePatternBrush(twdPtr->bitmap.handle));
-
- /*
- * Create temporary drawing surface containing a copy of the
- * destination equal in size to the bounding box of the object.
- */
-
- dcMem = CreateCompatibleDC(dc);
- oldBitmap = SelectObject(dcMem, CreateCompatibleBitmap(dc, width,
- height));
- oldPen = SelectObject(dcMem, pen);
- BitBlt(dcMem, 0, 0, width, height, dc, rect.left, rect.top, SRCCOPY);
-
- /*
- * Translate the object for rendering in the temporary drawing
- * surface.
- */
-
- for (i = 0; i < npoints; i++) {
- winPoints[i].x -= rect.left;
- winPoints[i].y -= rect.top;
- }
-
- /*
- * Draw the object in the foreground color and copy it to the
- * destination wherever the pattern is set.
- */
-
- SetPolyFillMode(dcMem, (gc->fill_rule == EvenOddRule) ? ALTERNATE
- : WINDING);
- oldMemBrush = SelectObject(dcMem, CreateSolidBrush(gc->foreground));
- (*func)(dcMem, winPoints, npoints);
- BitBlt(dc, rect.left, rect.top, width, height, dcMem, 0, 0, COPYFG);
-
- /*
- * If we are rendering an opaque stipple, then draw the polygon in the
- * background color and copy it to the destination wherever the pattern
- * is clear.
- */
-
- if (gc->fill_style == FillOpaqueStippled) {
- DeleteObject(SelectObject(dcMem,
- CreateSolidBrush(gc->background)));
- (*func)(dcMem, winPoints, npoints);
- BitBlt(dc, rect.left, rect.top, width, height, dcMem, 0, 0,
- COPYBG);
- }
-
- SelectObject(dcMem, oldPen);
- DeleteObject(SelectObject(dcMem, oldMemBrush));
- DeleteObject(SelectObject(dcMem, oldBitmap));
- DeleteDC(dcMem);
- } else {
- oldPen = SelectObject(dc, pen);
- oldBrush = SelectObject(dc, CreateSolidBrush(gc->foreground));
- SetROP2(dc, tkpWinRopModes[gc->function]);
-
- SetPolyFillMode(dc, (gc->fill_rule == EvenOddRule) ? ALTERNATE
- : WINDING);
-
- (*func)(dc, winPoints, npoints);
-
- SelectObject(dc, oldPen);
- }
- DeleteObject(SelectObject(dc, oldBrush));
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * XDrawLines --
- *
- * Draw connected lines.
- *
- * Results:
- * None.
- *
- * Side effects:
- * Renders a series of connected lines.
- *
- *----------------------------------------------------------------------
- */
-
-void
-XDrawLines(display, d, gc, points, npoints, mode)
- Display* display;
- Drawable d;
- GC gc;
- XPoint* points;
- int npoints;
- int mode;
-{
- HPEN pen;
- TkWinDCState state;
- HDC dc;
- TkpClipMask *clipPtr = (TkpClipMask*)gc->clip_mask;
-
- if (d == None) {
- return;
- }
-
- dc = TkWinGetDrawableDC(display, d, &state);
-
- if (clipPtr && clipPtr->type == TKP_CLIP_REGION) {
- SelectClipRgn(dc, (HRGN) clipPtr->value.region);
- OffsetClipRgn(dc, gc->clip_x_origin, gc->clip_y_origin);
- }
- pen = SetUpGraphicsPort(gc);
- SetBkMode(dc, TRANSPARENT);
- RenderObject(dc, gc, points, npoints, mode, pen, Polyline);
- DeleteObject(pen);
-
- TkWinReleaseDrawableDC(d, dc, &state);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * XDrawLine --
- *
- * Draw a single line between two points in a given drawable.
- *
- * Results:
- * None.
- *
- * Side effects:
- * Draws a single line segment.
- *
- *----------------------------------------------------------------------
- */
-
-void
-XDrawLine(display, d, gc, x1, y1, x2, y2)
- Display* display;
- Drawable d;
- GC gc;
- int x1, y1, x2, y2; /* Coordinates of line segment. */
-{
- XPoint points[2];
-
- points[0].x = x1;
- points[0].y = y1;
- points[1].x = x2;
- points[1].y = y2;
- XDrawLines(display, d, gc, points, 2, CoordModeOrigin);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * XFillPolygon --
- *
- * Draws a filled polygon.
- *
- * Results:
- * None.
- *
- * Side effects:
- * Draws a filled polygon on the specified drawable.
- *
- *----------------------------------------------------------------------
- */
-
-void
-XFillPolygon(display, d, gc, points, npoints, shape, mode)
- Display* display;
- Drawable d;
- GC gc;
- XPoint* points;
- int npoints;
- int shape;
- int mode;
-{
- HPEN pen;
- TkWinDCState state;
- HDC dc;
-
- if (d == None) {
- return;
- }
-
- dc = TkWinGetDrawableDC(display, d, &state);
-
- pen = GetStockObject(NULL_PEN);
- RenderObject(dc, gc, points, npoints, mode, pen, Polygon);
-
- TkWinReleaseDrawableDC(d, dc, &state);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * XDrawRectangle --
- *
- * Draws a rectangle.
- *
- * Results:
- * None.
- *
- * Side effects:
- * Draws a rectangle on the specified drawable.
- *
- *----------------------------------------------------------------------
- */
-
-void
-XDrawRectangle(display, d, gc, x, y, width, height)
- Display* display;
- Drawable d;
- GC gc;
- int x;
- int y;
- unsigned int width;
- unsigned int height;
-{
- HPEN pen, oldPen;
- TkWinDCState state;
- HBRUSH oldBrush;
- HDC dc;
- TkpClipMask *clipPtr = (TkpClipMask*)gc->clip_mask;
-
- if (d == None) {
- return;
- }
-
- dc = TkWinGetDrawableDC(display, d, &state);
-
- if (clipPtr && clipPtr->type == TKP_CLIP_REGION) {
- SelectClipRgn(dc, (HRGN) clipPtr->value.region);
- OffsetClipRgn(dc, gc->clip_x_origin, gc->clip_y_origin);
- }
- pen = SetUpGraphicsPort(gc);
- SetBkMode(dc, TRANSPARENT);
- oldPen = SelectObject(dc, pen);
- oldBrush = SelectObject(dc, GetStockObject(NULL_BRUSH));
- SetROP2(dc, tkpWinRopModes[gc->function]);
-
- Rectangle(dc, x, y, x+width+1, y+height+1);
-
- DeleteObject(SelectObject(dc, oldPen));
- SelectObject(dc, oldBrush);
- TkWinReleaseDrawableDC(d, dc, &state);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * DrawOrFillArc --
- *
- * This procedure handles the rendering of drawn or filled
- * arcs and chords.
- *
- * Results:
- * None.
- *
- * Side effects:
- * Renders the requested arc.
- *
- *----------------------------------------------------------------------
- */
-
-static void
-DrawOrFillArc(display, d, gc, x, y, width, height, start, extent, fill)
- Display *display;
- Drawable d;
- GC gc;
- int x, y; /* left top */
- unsigned int width, height;
- int start; /* start: three-o'clock (deg*64) */
- int extent; /* extent: relative (deg*64) */
- int fill; /* ==0 draw, !=0 fill */
-{
- HDC dc;
- HBRUSH brush, oldBrush;
- HPEN pen, oldPen;
- TkWinDCState state;
- int clockwise = (extent < 0); /* non-zero if clockwise */
- int xstart, ystart, xend, yend;
- double radian_start, radian_end, xr, yr;
- TkpClipMask *clipPtr = (TkpClipMask*)gc->clip_mask;
-
- if (d == None) {
- return;
- }
-
- dc = TkWinGetDrawableDC(display, d, &state);
-
- if (clipPtr && clipPtr->type == TKP_CLIP_REGION) {
- SelectClipRgn(dc, (HRGN) clipPtr->value.region);
- OffsetClipRgn(dc, gc->clip_x_origin, gc->clip_y_origin);
- }
- SetROP2(dc, tkpWinRopModes[gc->function]);
-
- /*
- * Compute the absolute starting and ending angles in normalized radians.
- * Swap the start and end if drawing clockwise.
- */
-
- start = start % (64*360);
- if (start < 0) {
- start += (64*360);
- }
- extent = (start+extent) % (64*360);
- if (extent < 0) {
- extent += (64*360);
- }
- if (clockwise) {
- int tmp = start;
- start = extent;
- extent = tmp;
- }
- radian_start = XAngleToRadians(start);
- radian_end = XAngleToRadians(extent);
-
- /*
- * Now compute points on the radial lines that define the starting and
- * ending angles. Be sure to take into account that the y-coordinate
- * system is inverted.
- */
-
- if (gc->fill_style == FillStippled && gc->stipple != None) {
- xr = width / 2.0;
- yr = height / 2.0;
- }
- else {
- xr = x + width / 2.0;
- yr = y + height / 2.0;
- }
- xstart = (int)((xr + cos(radian_start)*width/2.0) + 0.5);
- ystart = (int)((yr + sin(-radian_start)*height/2.0) + 0.5);
- xend = (int)((xr + cos(radian_end)*width/2.0) + 0.5);
- yend = (int)((yr + sin(-radian_end)*height/2.0) + 0.5);
-
- /*
- * Now draw a filled or open figure. Note that we have to
- * increase the size of the bounding box by one to account for the
- * difference in pixel definitions between X and Windows.
- */
-
- pen = SetUpGraphicsPort(gc);
- oldPen = SelectObject(dc, pen);
- if (!fill) {
- /*
- * Note that this call will leave a gap of one pixel at the
- * end of the arc for thin arcs. We can't use ArcTo because
- * it's only supported under Windows NT.
- */
-
- SetBkMode(dc, TRANSPARENT);
- Arc(dc, x, y, x+width+1, y+height+1, xstart, ystart, xend, yend);
- } else {
- brush = CreateSolidBrush(gc->foreground);
-
- if (gc->fill_style == FillStippled && gc->stipple != None) {
- TkWinDrawable *twdPtr = (TkWinDrawable *)gc->stipple;
- HBITMAP oldBitmap;
- HDC dcMem;
- HBRUSH oldMemBrush;
-
- if (twdPtr->type != TWD_BITMAP) {
- Tcl_Panic("unexpected drawable type in stipple");
- }
-
- /*
- * Select stipple pattern into destination dc.
- */
- SetBrushOrgEx(dc, gc->ts_x_origin, gc->ts_y_origin, NULL);
- oldBrush = SelectObject(dc,
- CreatePatternBrush(twdPtr->bitmap.handle));
-
- /*
- * Create temporary drawing surface containing a copy of the
- * destination equal in size to the bounding box of the object.
- */
- dcMem = CreateCompatibleDC(dc);
- oldBitmap = SelectObject(dcMem,
- CreateCompatibleBitmap(dc, width, height));
- BitBlt(dcMem, 0, 0, width, height, dc, x, y, SRCCOPY);
- oldMemBrush = SelectObject(dcMem, brush);
- if (gc->arc_mode == ArcChord) {
- Chord(dcMem, 0, 0, width+1, height+1, xstart, ystart, xend, yend);
- } else if ( gc->arc_mode == ArcPieSlice ) {
- Pie(dcMem, 0, 0, width+1, height+1, xstart, ystart, xend, yend);
- }
-
- BitBlt(dc, x, y, width, height, dcMem, 0, 0, COPYFG);
- DeleteObject(SelectObject(dcMem, oldBitmap));
- DeleteObject(SelectObject(dcMem, oldMemBrush));
- DeleteObject(SelectObject(dc, oldBrush));
- DeleteDC(dcMem);
- } else {
- oldBrush = SelectObject(dc, brush);
- if (gc->arc_mode == ArcChord) {
- Chord(dc, x, y, x+width+1, y+height+1, xstart, ystart, xend, yend);
- } else if ( gc->arc_mode == ArcPieSlice ) {
- Pie(dc, x, y, x+width+1, y+height+1, xstart, ystart, xend, yend);
- }
- DeleteObject(SelectObject(dc, oldBrush));
- }
- }
- DeleteObject(SelectObject(dc, oldPen));
- TkWinReleaseDrawableDC(d, dc, &state);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * XDrawArc --
- *
- * Draw an arc.
- *
- * Results:
- * None.
- *
- * Side effects:
- * Draws an arc on the specified drawable.
- *
- *----------------------------------------------------------------------
- */
-
-void
-XDrawArc(display, d, gc, x, y, width, height, start, extent)
- Display* display;
- Drawable d;
- GC gc;
- int x;
- int y;
- unsigned int width;
- unsigned int height;
- int start;
- int extent;
-{
- display->request++;
-
- DrawOrFillArc(display, d, gc, x, y, width, height, start, extent, 0);
-}
-
-/*
- *----------------------------------------------------------------------
- *
- * XFillArc --
- *
- * Draw a filled arc.
- *
- * Results:
- * None.
- *
- * Side effects:
- * Draws a filled arc on the specified drawable.
- *
- *----------------------------------------------------------------------
- */
-
-void
-XFillArc(display, d, gc, x, y, width, height, start, extent)
- Display* display;
- Drawable d;
- GC gc;
- int x;
- int y;
- unsigned int width;
- unsigned int height;
- int start;
- int extent;
-{
- display->request++;
-
- DrawOrFillArc(display, d, gc, x, y, width, height, start, extent, 1);
-}
-
-#endif /* _WIN32 */
diff --git a/win/makefile.vc.in b/win/makefile.vc.in
deleted file mode 100644
index 62fccd4..0000000
--- a/win/makefile.vc.in
+++ /dev/null
@@ -1,130 +0,0 @@
-# Generated automatically from Makefile.in by configure.
-# Copyright (c) 1993 - 2002 CENA, Patrick Lecoanet --
-#
-# This code is free software; you can redistribute it and/or
-# modify it under the terms of the GNU Library General Public
-# License as published by the Free Software Foundation; either
-# version 2 of the License, or (at your option) any later version.
-#
-# This code is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Library General Public License for more details.
-#
-# You should have received a copy of the GNU Library General Public
-# License along with this code; if not, write to the Free
-# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-#
-# $Revision$
-#
-srcdir = ..
-TCLTK_FULL_VER = 8.4.6
-TCLTK_LIB_VER = 84
-TKZINC_MAJOR = @MAJOR_VERSION@
-TKZINC_MINOR = @MINOR_VERSION@
-TKZINC_PATCHLVL = @PATCHLEVEL@
-
-# Visual Studio 6 default
-TOOLS32 = C:\Progra~1\Microsoft Visual Studio\VC98
-CC = "$(TOOLS32)\bin\cl.exe"
-LD = "$(TOOLS32)\bin\link.exe" -link50compat
-libpath32 = /LIBPATH:"$(TOOLS32)\lib"
-include32 = /I"$(TOOLS32)\include"
-CP = copy
-RM = del
-
-prefix = c:\Tcl
-exec_prefix = $(prefix)
-
-bindir = $(exec_prefix)\bin
-libdir = $(exec_prefix)\lib
-incdir = $(prefix)\include
-mandir = $(prefix)\man\man3
-
-windir = $(srcdir)\win
-genericdir = $(srcdir)\generic
-tessdir = $(srcdir)\libtess
-tmpdir = $(srcdir)
-
-tcl_inc_dir = $(srcdir)\..\tcl$(TCLTK_FULL_VER)
-tk_inc_dir = $(srcdir)\..\tk$(TCLTK_FULL_VER)
-INCLUDES = /I$(srcdir)/generic /I$(srcdir)/libtess $(include32)
-
-# Assume that WISH is already INSTALLED
-TCLSH = $(bindir)\tclsh$(TCLTK_LIB_VER)
-WISH = $(bindir)\wish$(TCLTK_LIB_VER)
-WIN_LIBS = user32.lib gdi32.lib ws2_32.lib
-GL_LIBS = opengl32.lib
-TKLIBS = $(libdir)\tcl$(TCLTK_LIB_VER).lib \
- $(libdir)\tk$(TCLTK_LIB_VER).lib \
- $(GL_LIBS) $(WIN_LIBS)
-
-VERSION = \"$(TKZINC_MAJOR).$(TKZINC_MINOR).$(TKZINC_PATCHLVL)\"
-
-#
-# Recognized compilation time flags are :
-#
-# PROFILE ask for profile support
-# OM include code for internal overlap manager
-# GL include code that need GL support.
-# GL_PRINT_CONFIG display the detected hardware capabilities
-# GL_DAMAGE redraw only modified areas
-# SHAPE include code for reshaping windows.
-#
-DFLAGS= /DOM /DGL /DGL_DAMAGE /DGL_PRINT_CONFIG
-#DFLAGS= /DOM
-#DFLAGS = /DTCL_MEM_DEBUG
-
-# Max speed
-#CDEBUG = -O2 -Gs
-# Debug
-CDEBUG = -Z7 -Od
-CFLAGS = /c /W3 /nologo /YX $(CDEBUG) /D__STDC__ /DVERSION=$(VERSION) /DDLL_BUILD /DBUILD_Tkzinc $(DFLAGS)
-TKCPPFLAGS = /Fp$(tmpdir)\ $(INCLUDES) /I"$(incdir)" /I$(tk_inc_dir)\generic /I$(tk_inc_dir)\win /I$(tcl_inc_dir)\generic /I$(tcl_inc_dir)\win /I$(tk_inc_dir)\xlib /D__STDC__
-
-LFLAGS = /nologo /machine:IX86 /warn:3 $(libpath32) /FORCE:MULTIPLE /NODEFAULTLIB:uuid.lib /NODEFAULTLIB:OLDNAMES.lib
-
-DLLENTRY = @12
-DLLLFLAGS = $(LFLAGS) /entry:_DllMainCRTStartup$(DLLENTRY) /dll
-
-TKDLLOBJS = $(tmpdir)\Track.obj $(tmpdir)\Tabular.obj \
- $(tmpdir)\Reticle.obj $(tmpdir)\Map.obj \
- $(tmpdir)\Rectangle.obj $(tmpdir)\Arc.obj \
- $(tmpdir)\Curve.obj $(tmpdir)\Item.obj \
-# $(tmpdir)\PostScript.obj $(tmpdir)\perfos.obj \
- $(tmpdir)\MapInfo.obj $(tmpdir)\Attrs.obj \
- $(tmpdir)\Draw.obj $(tmpdir)\Geo.obj \
- $(tmpdir)\List.obj $(tmpdir)\Transfo.obj \
- $(tmpdir)\Group.obj $(tmpdir)\Icon.obj \
- $(tmpdir)\Text.obj $(tmpdir)\Color.obj \
- $(tmpdir)\Field.obj $(tmpdir)\Triangles.obj \
- $(tmpdir)\Window.obj $(tmpdir)\tkZinc.obj \
- $(tmpdir)\OverlapMan.obj $(tmpdir)\WinPort.obj \
- $(tmpdir)\Image.obj $(tmpdir)\dict.obj $(tmpdir)\geom.obj \
- $(tmpdir)\memalloc.obj $(tmpdir)\mesh.obj $(tmpdir)\normal.obj \
- $(tmpdir)\priorityq.obj $(tmpdir)\render.obj \
- $(tmpdir)\sweep.obj $(tmpdir)\tess.obj $(tmpdir)\tessmono.obj
-
-DLL=Tkzinc$(TKZINC_MAJOR)$(TKZINC_MINOR)$(TKZINC_PATCHLVL).dll
-
-$(srcdir)/$(DLL): $(TKDLLOBJS)
- $(LD) $(DLLLFLAGS) $(TKLIBS) /OUT:$@ $(TKDLLOBJS)
- @"$(WISH)" <<
- package require Tk
- pkg_mkIndex -load Tk $(srcdir) $(DLL)
- exit
-<<
-
-{$(windir)}.c{$(tmpdir)}.obj:
- $(CC) $(TKCPPFLAGS) $(CFLAGS) -Fo$(tmpdir)\ $<
-
-{$(genericdir)}.c{$(tmpdir)}.obj:
- $(CC) $(TKCPPFLAGS) $(CFLAGS) -Fo$(tmpdir)\ $<
-
-{$(tessdir)}.c{$(tmpdir)}.obj:
- $(CC) $(TKCPPFLAGS) $(CFLAGS) -Fo$(tmpdir)\ $<
-
-mostlyclean:
- $(RM) *.bak *~ $(tmpdir)\*.obj
-clean:
- $(RM) $(tmpdir)\*.obj $(tmpdir)\*.dll $(tmpdir)\*.lib $(tmpdir)\*.exp $(tmpdir)\pkgIndex.tcl $(tmpdir)\*.pch
diff --git a/win/package.tcl b/win/package.tcl
deleted file mode 100644
index 2351f0b..0000000
--- a/win/package.tcl
+++ /dev/null
@@ -1,76 +0,0 @@
-#
-# This script is intended to be run in the win sub-directory
-# with: tclsh84 package.tcl
-#
-set packager {C:\Program Files\Caphyon\Advanced Installer\AdvancedInstaller.exe}
-
-#
-# Make the Tcl library
-#
-catch {exec nmake -f makefile.vc} result
-puts $result
-
-#
-# Make the Perl library, use for this the
-# buildperl script.
-#
-set wd [pwd]
-cd ..
-catch {exec tclsh buildperl.tcl} result
-puts $result
-cd $wd
-
-#
-# Build a merged pkgIndex.tcl
-#
-set fout [open pkgIndex.tcl w]
-set fin [open [file join .. pkgIndex.tcl]]
-puts -nonewline $fout [read $fin]
-close $fin
-set fin [open [file join .. library pkgIndex.tcl]]
-foreach line [split [read $fin] \n] {
- if {![regexp {^\s*$|^#} $line]} {
- puts $fout $line
- }
-}
-close $fin
-close $fout
-
-#
-# Build a .bat script for the Perl demos.
-#
-set fout [open zinc-demos.bat w]
-set fin [open [file join .. Perl demos zinc-demos]]
-puts $fout {@rem = '--*-Perl-*--
-@echo off
-if "%OS%" == "Windows_NT" goto WinNT
-perl -x -S "%0" %1 %2 %3 %4 %5 %6 %7 %8 %9
-goto endofperl
-:WinNT
-perl -x -S %0 %*
-if NOT "%COMSPEC%" == "%SystemRoot%\system32\cmd.exe" goto endofperl
-if %errorlevel% == 9009 echo You do not have Perl in your PATH.
-if errorlevel 1 goto script_failed_so_exit_with_non_zero_val 2>nul
-goto endofperl
-@rem ';}
-puts $fout [read $fin]
-puts $fout {__END__
-:endofperl}
-close $fin
-close $fout
-
-#
-# Create a demo script ending in .tcl
-#
-file copy -force [file join .. demos zinc-widget] zinc-widget.tcl
-
-#
-# Wrap up the msi packages
-#
-exec $packager /build Tkzinc.aip
-exec $packager /build Tkzincperl.aip
-
-#
-# Clean up after messing around
-#
-#file delete -force pkgIndex.tcl zinc-widget.tcl zinc-demos.bat