diff --git a/pd/tkpath/ChangeLog b/pd/tkpath/ChangeLog index bacbbebfa7cf65ca15dc7b1c000c92b2017e977a..ad4cc27e9f8fe4d5f076629bd6787419c395f8d8 100755 --- a/pd/tkpath/ChangeLog +++ b/pd/tkpath/ChangeLog @@ -1,3 +1,15 @@ +2013-09-12 Ivica Ico Bukvic <ico@vt.edu> + + * moved bbox and totalBbox to Tk_PathItem to make it visible + to Translate calls that previously failed to take into + account transforms via matrices (e.g. scale). This resulted + in artifacts left behind when translating objects with + scaling matrices applied to them (the same solves scale + calls and potentially ensuing artifacts as well) + * adapted all objects to reflect aforesaid change + * merged patch by Sean McKnight found at: + https://sourceforge.net/p/tclbitprint/patches/3/ + 2012-07-04 George Petasis <petasis@iit.demokritos.gr> * generic/tkpUtil.c: Fix in the tkStateKeyObjType definistion, in diff --git a/pd/tkpath/configure b/pd/tkpath/configure index 77d4c6199d962bc7e4bec7dcec0bcf6dd4cab8f1..7fcd79fa1e3612a8c2556ebc71959c76f8b2545d 100755 --- a/pd/tkpath/configure +++ b/pd/tkpath/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.68 for tkpath 0.3.2. +# Generated by GNU Autoconf 2.68 for tkpath 0.3.3. # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -557,8 +557,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='tkpath' PACKAGE_TARNAME='tkpath' -PACKAGE_VERSION='0.3.2' -PACKAGE_STRING='tkpath 0.3.2' +PACKAGE_VERSION='0.3.3' +PACKAGE_STRING='tkpath 0.3.3' PACKAGE_BUGREPORT='' PACKAGE_URL='' @@ -1292,7 +1292,7 @@ if test "$ac_init_help" = "long"; then # 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 <<_ACEOF -\`configure' configures tkpath 0.3.2 to adapt to many kinds of systems. +\`configure' configures tkpath 0.3.3 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1353,7 +1353,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of tkpath 0.3.2:";; + short | recursive ) echo "Configuration of tkpath 0.3.3:";; esac cat <<\_ACEOF @@ -1457,7 +1457,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -tkpath configure 0.3.2 +tkpath configure 0.3.3 generated by GNU Autoconf 2.68 Copyright (C) 2010 Free Software Foundation, Inc. @@ -1914,7 +1914,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by tkpath $as_me 0.3.2, which was +It was created by tkpath $as_me 0.3.3, which was generated by GNU Autoconf 2.68. Invocation command line was $ $0 $@ @@ -10260,7 +10260,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by tkpath $as_me 0.3.2, which was +This file was extended by tkpath $as_me 0.3.3, which was generated by GNU Autoconf 2.68. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -10313,7 +10313,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -tkpath config.status 0.3.2 +tkpath config.status 0.3.3 configured by $0, generated by GNU Autoconf 2.68, with options \\"\$ac_cs_config\\" diff --git a/pd/tkpath/configure.in b/pd/tkpath/configure.in index ca62abab0ca014507a2e244ec13d22f8774fc79e..d1dbd1badc960ce806c7bdab908d6626ef0f5ce5 100644 --- a/pd/tkpath/configure.in +++ b/pd/tkpath/configure.in @@ -18,7 +18,7 @@ dnl to configure the system for the local environment. # so you can encode the package version directly into the source files. #----------------------------------------------------------------------- -AC_INIT([tkpath], [0.3.2]) +AC_INIT([tkpath], [0.3.3]) #-------------------------------------------------------------------- # Call TEA_INIT as the first TEA_ macro to set up initial vars. diff --git a/pd/tkpath/generic/path.c b/pd/tkpath/generic/path.c index b4f1514eae96bfee3d789f782a5679b5442a0561..9a4e5060cc382c9fe120eea169c2698c0815852b 100644 --- a/pd/tkpath/generic/path.c +++ b/pd/tkpath/generic/path.c @@ -6,7 +6,7 @@ * * Copyright (c) 2005-2008 Mats Bengtsson * - * $Id$ + * $Id: path.c,v 1.39 2012/07/05 06:41:15 petasis Exp $ */ #include "tkp.h" diff --git a/pd/tkpath/generic/tkCanvEllipse.c b/pd/tkpath/generic/tkCanvEllipse.c index 520f13be3938889251bdd9f27847d6af913e6903..25f973149fc314a8683c068383bae94bb2a18de5 100644 --- a/pd/tkpath/generic/tkCanvEllipse.c +++ b/pd/tkpath/generic/tkCanvEllipse.c @@ -6,7 +6,7 @@ * * Copyright (c) 2007-2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvEllipse.c,v 1.30 2010/04/30 10:16:00 ebrunel Exp $ */ #include "tkIntPath.h" diff --git a/pd/tkpath/generic/tkCanvGradient.c b/pd/tkpath/generic/tkCanvGradient.c index 8f50c818e72e2479a1e67af6ff203d5960f8d996..429e57914789f30029951e9bb4bdaa1363a16088 100644 --- a/pd/tkpath/generic/tkCanvGradient.c +++ b/pd/tkpath/generic/tkCanvGradient.c @@ -7,7 +7,7 @@ * * TODO: o Add tkwin option here and there so we can free stop colors! * - * $Id$ + * $Id: tkCanvGradient.c,v 1.3 2012/07/04 19:43:18 petasis Exp $ */ #include "tkIntPath.h" diff --git a/pd/tkpath/generic/tkCanvGroup.c b/pd/tkpath/generic/tkCanvGroup.c index f6d62ed1d11782230e8ca60508555338d67244ac..653fabdb49e8c8521faed83e271857bdc9ee1cef 100644 --- a/pd/tkpath/generic/tkCanvGroup.c +++ b/pd/tkpath/generic/tkCanvGroup.c @@ -6,7 +6,7 @@ * * Copyright (c) 2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvGroup.c,v 1.9 2008/07/23 07:08:37 matben Exp $ */ #include <float.h> diff --git a/pd/tkpath/generic/tkCanvPath.c b/pd/tkpath/generic/tkCanvPath.c index 27e2712c0a9da66c50e86f2a6c6a08dfc77e7f30..d44642694aaae6c7213a2098b42112a1f8df4eb3 100644 --- a/pd/tkpath/generic/tkCanvPath.c +++ b/pd/tkpath/generic/tkCanvPath.c @@ -6,7 +6,7 @@ * * Copyright (c) 2005-2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvPath.c,v 1.55 2012/07/04 19:43:18 petasis Exp $ */ #include "tkIntPath.h" @@ -35,10 +35,6 @@ typedef struct PathItem { int pathLen; Tcl_Obj *normPathObjPtr;/* The object containing the normalized path. */ PathAtom *atomPtr; - PathRect bbox; /* Bounding box with zero width outline. - * Untransformed coordinates. */ - PathRect totalBbox; /* Bounding box including stroke. - * Untransformed coordinates. */ int maxNumSegments; /* Max number of straight segments (for subpath) * needed for Area and Point functions. */ long flags; /* Various flags, see enum. */ @@ -215,8 +211,8 @@ CreatePath( pathPtr->pathLen = 0; pathPtr->normPathObjPtr = NULL; pathPtr->atomPtr = NULL; - pathPtr->bbox = NewEmptyPathRect(); - pathPtr->totalBbox = NewEmptyPathRect(); + itemPtr->bbox = NewEmptyPathRect(); + itemPtr->totalBbox = NewEmptyPathRect(); pathPtr->maxNumSegments = 0; pathPtr->flags = 0L; @@ -404,10 +400,10 @@ ComputePathBbox( * Get an approximation of the path's bounding box * assuming zero stroke width. */ - pathPtr->bbox = GetGenericBarePathBbox(pathPtr->atomPtr); - pathPtr->totalBbox = GetGenericPathTotalBboxFromBare(pathPtr->atomPtr, - &style, &pathPtr->bbox); - SetGenericPathHeaderBbox(&itemExPtr->header, style.matrixPtr, &pathPtr->totalBbox); + itemPtr->bbox = GetGenericBarePathBbox(pathPtr->atomPtr); + itemPtr->totalBbox = GetGenericPathTotalBboxFromBare(pathPtr->atomPtr, + &style, &itemPtr->bbox); + SetGenericPathHeaderBbox(&itemExPtr->header, style.matrixPtr, &itemPtr->totalBbox); TkPathCanvasFreeInheritedStyle(&style); } @@ -586,7 +582,7 @@ DisplayPath( if (pathPtr->pathLen > 2) { style = TkPathCanvasInheritStyle(itemPtr, 0); TkPathDrawPath(Tk_PathCanvasTkwin(canvas), drawable, pathPtr->atomPtr, - &style, &m, &pathPtr->bbox); + &style, &m, &itemPtr->bbox); TkPathCanvasFreeInheritedStyle(&style); } } @@ -903,10 +899,10 @@ ScalePath( pathPtr->flags |= kPathItemNeedNewNormalizedPath; /* Just scale the bbox'es as well. */ - ScalePathRect(&pathPtr->bbox, originX, originY, scaleX, scaleY); - NormalizePathRect(&pathPtr->bbox); + ScalePathRect(&itemPtr->bbox, originX, originY, scaleX, scaleY); + NormalizePathRect(&itemPtr->bbox); - ScalePathRect(&pathPtr->totalBbox, originX, originY, scaleX, scaleY); + ScalePathRect(&itemPtr->totalBbox, originX, originY, scaleX, scaleY); NormalizePathRect(&r); ScaleItemHeader(itemPtr, originX, originY, scaleX, scaleY); } @@ -948,8 +944,8 @@ TranslatePath( pathPtr->flags |= kPathItemNeedNewNormalizedPath; /* Just translate the bbox'es as well. */ - TranslatePathRect(&pathPtr->bbox, deltaX, deltaY); - TranslatePathRect(&pathPtr->totalBbox, deltaX, deltaY); + TranslatePathRect(&itemPtr->bbox, deltaX, deltaY); + TranslatePathRect(&itemPtr->totalBbox, deltaX, deltaY); TranslateItemHeader(itemPtr, deltaX, deltaY); } diff --git a/pd/tkpath/generic/tkCanvPathUtil.c b/pd/tkpath/generic/tkCanvPathUtil.c index 14bfe2f5f95f8950841e7f2ee57adddbaab157a4..56b3d09d78e073bdc58fbc1bb159159c027839c0 100644 --- a/pd/tkpath/generic/tkCanvPathUtil.c +++ b/pd/tkpath/generic/tkCanvPathUtil.c @@ -6,7 +6,7 @@ * * Copyright (c) 2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvPathUtil.c,v 1.34 2008/08/10 08:02:17 matben Exp $ */ #include "tkPathStyle.h" @@ -1963,10 +1963,14 @@ TranslateItemHeader(Tk_PathItem *itemPtr, double deltaX, double deltaY) /* If all coords == -1 the item is hidden. */ if ((itemPtr->x1 != -1) || (itemPtr->x2 != -1) || (itemPtr->y1 != -1) || (itemPtr->y2 != -1)) { - itemPtr->x1 += (int) deltaX; - itemPtr->x2 += (int) deltaX; - itemPtr->y1 += (int) deltaY; - itemPtr->y2 += (int) deltaY; + Tk_PathStyle style; + style = TkPathCanvasInheritStyle(itemPtr, kPathMergeStyleNotFill); + SetGenericPathHeaderBbox(itemPtr, style.matrixPtr, &itemPtr->totalBbox); + TkPathCanvasFreeInheritedStyle(&style); + /*itemPtr->x1 += (int) deltaX; + itemPtr->x2 += (int) deltaX; + itemPtr->y1 += (int) deltaY; + itemPtr->y2 += (int) deltaY;*/ } } diff --git a/pd/tkpath/generic/tkCanvPathUtil.h b/pd/tkpath/generic/tkCanvPathUtil.h index 8a055949c9e8e4c301d17ae9fafda9c697d4709d..03d271001424d77c99a6308777c295aedfd7ee2f 100644 --- a/pd/tkpath/generic/tkCanvPathUtil.h +++ b/pd/tkpath/generic/tkCanvPathUtil.h @@ -5,7 +5,7 @@ * * Copyright (c) 2007-2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvPathUtil.h,v 1.24 2008/07/16 13:17:28 matben Exp $ */ #ifndef INCLUDED_TKCANVPATHUTIL_H diff --git a/pd/tkpath/generic/tkCanvPimage.c b/pd/tkpath/generic/tkCanvPimage.c index 86e2de74af2c61a78b4842bfd42e7b418e3dd300..f9404c5a44f475d137e283f3e38a36c22e9875c1 100644 --- a/pd/tkpath/generic/tkCanvPimage.c +++ b/pd/tkpath/generic/tkCanvPimage.c @@ -6,7 +6,7 @@ * * Copyright (c) 2007-2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvPimage.c,v 1.27 2010/04/30 10:16:00 ebrunel Exp $ */ #include "tkIntPath.h" @@ -42,8 +42,6 @@ typedef struct PimageItem { Tk_PhotoHandle photo; double width; /* If 0 use natural width or height. */ double height; - PathRect bbox; /* Bounding box with zero width outline. - * Untransformed coordinates. */ } PimageItem; @@ -192,7 +190,7 @@ CreatePimage(Tcl_Interp *interp, Tk_PathCanvas canvas, struct Tk_PathItem *itemP pimagePtr->photo = NULL; pimagePtr->height = 0; pimagePtr->width = 0; - pimagePtr->bbox = NewEmptyPathRect(); + itemPtr->bbox = NewEmptyPathRect(); if (optionTable == NULL) { optionTable = Tk_CreateOptionTable(interp, optionSpecs); @@ -267,6 +265,7 @@ GetTMatrix(PimageItem *pimagePtr) void ComputePimageBbox(Tk_PathCanvas canvas, PimageItem *pimagePtr) { + Tk_PathItem *itemPtr = (Tk_PathItem *)pimagePtr; Tk_PathState state = pimagePtr->header.state; TMatrix matrix; int width = 0, height = 0; @@ -291,7 +290,7 @@ ComputePimageBbox(Tk_PathCanvas canvas, PimageItem *pimagePtr) bbox.y1 = pimagePtr->coord[1]; bbox.x2 = bbox.x1 + width; bbox.y2 = bbox.y1 + height; - pimagePtr->bbox = bbox; + itemPtr->bbox = bbox; matrix = GetTMatrix(pimagePtr); SetGenericPathHeaderBbox(&pimagePtr->header, &matrix, &bbox); } @@ -472,7 +471,7 @@ PimageToPoint(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double *pointPtr) { PimageItem *pimagePtr = (PimageItem *) itemPtr; TMatrix m = GetTMatrix(pimagePtr); - return PathRectToPointWithMatrix(pimagePtr->bbox, &m, pointPtr); + return PathRectToPointWithMatrix(itemPtr->bbox, &m, pointPtr); } static int @@ -480,7 +479,7 @@ PimageToArea(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double *areaPtr) { PimageItem *pimagePtr = (PimageItem *) itemPtr; TMatrix m = GetTMatrix(pimagePtr); - return PathRectToAreaWithMatrix(pimagePtr->bbox, &m, areaPtr); + return PathRectToAreaWithMatrix(itemPtr->bbox, &m, areaPtr); } static int @@ -502,7 +501,7 @@ TranslatePimage(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double deltaX, doubl PimageItem *pimagePtr = (PimageItem *) itemPtr; /* Just translate the bbox'es as well. */ - TranslatePathRect(&(pimagePtr->bbox), deltaX, deltaY); + TranslatePathRect(&(itemPtr->bbox), deltaX, deltaY); pimagePtr->coord[0] += deltaX; pimagePtr->coord[1] += deltaY; TranslateItemHeader(itemPtr, deltaX, deltaY); diff --git a/pd/tkpath/generic/tkCanvPline.c b/pd/tkpath/generic/tkCanvPline.c index 4fd94a4c4aff8a9447a4480598ef58669b560f38..60320b9d2db56692f62e692e42cc8ddbae29cf76 100644 --- a/pd/tkpath/generic/tkCanvPline.c +++ b/pd/tkpath/generic/tkCanvPline.c @@ -6,7 +6,7 @@ * * Copyright (c) 2007-2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvPline.c,v 1.25 2010/04/30 10:16:00 ebrunel Exp $ */ #include "tkIntPath.h" @@ -25,8 +25,6 @@ typedef struct PlineItem { Tk_PathItemEx headerEx; /* Generic stuff that's the same for all * path types. MUST BE FIRST IN STRUCTURE. */ PathRect coords; /* Coordinates (unorders bare bbox). */ - PathRect totalBbox; /* Bounding box including stroke. - * Untransformed coordinates. */ } PlineItem; @@ -131,7 +129,7 @@ CreatePline(Tcl_Interp *interp, Tk_PathCanvas canvas, struct Tk_PathItem *itemPt itemExPtr->canvas = canvas; itemExPtr->styleObj = NULL; itemExPtr->styleInst = NULL; - plinePtr->totalBbox = NewEmptyPathRect(); + itemPtr->totalBbox = NewEmptyPathRect(); if (optionTable == NULL) { optionTable = Tk_CreateOptionTable(interp, optionSpecs); @@ -214,7 +212,7 @@ PlineCoords(Tcl_Interp *interp, Tk_PathCanvas canvas, Tk_PathItem *itemPtr, int result; result = ProcessCoords(interp, canvas, itemPtr, objc, objv); - if ((result == TCL_OK) && (objc == 1)) { + if ((result == TCL_OK) && ((objc == 1) || (objc == 4))) { ComputePlineBbox(canvas, plinePtr); } return result; @@ -242,8 +240,8 @@ ComputePlineBbox(Tk_PathCanvas canvas, PlineItem *plinePtr) r.x2 = MAX(plinePtr->coords.x1, plinePtr->coords.x2); r.y1 = MIN(plinePtr->coords.y1, plinePtr->coords.y2); r.y2 = MAX(plinePtr->coords.y1, plinePtr->coords.y2); - plinePtr->totalBbox = GetGenericPathTotalBboxFromBare(NULL, &style, &r); - SetGenericPathHeaderBbox(&itemExPtr->header, style.matrixPtr, &plinePtr->totalBbox); + itemPtr->totalBbox = GetGenericPathTotalBboxFromBare(NULL, &style, &r); + SetGenericPathHeaderBbox(&itemExPtr->header, style.matrixPtr, &itemPtr->totalBbox); TkPathCanvasFreeInheritedStyle(&style); } @@ -410,7 +408,7 @@ ScalePline(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double originX, double or { PlineItem *plinePtr = (PlineItem *) itemPtr; - ScalePathRect(&plinePtr->totalBbox, originX, originY, scaleX, scaleY); + ScalePathRect(&itemPtr->totalBbox, originX, originY, scaleX, scaleY); ScalePathRect(&plinePtr->coords, originX, originY, scaleX, scaleY); ScaleItemHeader(itemPtr, originX, originY, scaleX, scaleY); } @@ -421,7 +419,7 @@ TranslatePline(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double deltaX, double PlineItem *plinePtr = (PlineItem *) itemPtr; /* Just translate the bbox as well. */ - TranslatePathRect(&plinePtr->totalBbox, deltaX, deltaY); + TranslatePathRect(&itemPtr->totalBbox, deltaX, deltaY); TranslatePathRect(&plinePtr->coords, deltaX, deltaY); TranslateItemHeader(itemPtr, deltaX, deltaY); } diff --git a/pd/tkpath/generic/tkCanvPpoly.c b/pd/tkpath/generic/tkCanvPpoly.c index cca26b65722ae30a40f64cde461656f4af7e7fad..4fe0f6ccef19cb9aee94a66ab0db959cc0946482 100644 --- a/pd/tkpath/generic/tkCanvPpoly.c +++ b/pd/tkpath/generic/tkCanvPpoly.c @@ -6,7 +6,7 @@ * * Copyright (c) 2007-2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvPpoly.c,v 1.25 2010/04/30 10:16:00 ebrunel Exp $ */ #include "tkIntPath.h" @@ -26,10 +26,6 @@ typedef struct PpolyItem { * path types. MUST BE FIRST IN STRUCTURE. */ char type; /* Polyline or polygon. */ PathAtom *atomPtr; - PathRect bbox; /* Bounding box with zero width outline. - * Untransformed coordinates. */ - PathRect totalBbox; /* Bounding box including stroke. - * Untransformed coordinates. */ int maxNumSegments; /* Max number of straight segments (for subpath) * needed for Area and Point functions. */ } PpolyItem; @@ -198,8 +194,8 @@ CreateAny(Tcl_Interp *interp, Tk_PathCanvas canvas, struct Tk_PathItem *itemPtr, itemExPtr->styleInst = NULL; ppolyPtr->atomPtr = NULL; ppolyPtr->type = type; - ppolyPtr->bbox = NewEmptyPathRect(); - ppolyPtr->totalBbox = NewEmptyPathRect(); + itemPtr->bbox = NewEmptyPathRect(); + itemPtr->totalBbox = NewEmptyPathRect(); ppolyPtr->maxNumSegments = 0; if (ppolyPtr->type == kPpolyTypePolyline) { @@ -280,10 +276,10 @@ ComputePpolyBbox(Tk_PathCanvas canvas, PpolyItem *ppolyPtr) return; } style = TkPathCanvasInheritStyle(itemPtr, kPathMergeStyleNotFill); - ppolyPtr->bbox = GetGenericBarePathBbox(ppolyPtr->atomPtr); - ppolyPtr->totalBbox = GetGenericPathTotalBboxFromBare(ppolyPtr->atomPtr, - &style, &ppolyPtr->bbox); - SetGenericPathHeaderBbox(&itemExPtr->header, style.matrixPtr, &ppolyPtr->totalBbox); + itemPtr->bbox = GetGenericBarePathBbox(ppolyPtr->atomPtr); + itemPtr->totalBbox = GetGenericPathTotalBboxFromBare(ppolyPtr->atomPtr, + &style, &itemPtr->bbox); + SetGenericPathHeaderBbox(&itemExPtr->header, style.matrixPtr, &itemPtr->totalBbox); TkPathCanvasFreeInheritedStyle(&style); } @@ -384,7 +380,7 @@ DisplayPpoly(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, Display *display, Drawa style = TkPathCanvasInheritStyle(itemPtr, 0); TkPathDrawPath(Tk_PathCanvasTkwin(canvas), drawable, ppolyPtr->atomPtr, &style, - &m, &ppolyPtr->bbox); + &m, &itemPtr->bbox); TkPathCanvasFreeInheritedStyle(&style); } @@ -440,8 +436,8 @@ ScalePpoly(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double originX, double or PpolyItem *ppolyPtr = (PpolyItem *) itemPtr; ScalePathAtoms(ppolyPtr->atomPtr, originX, originY, scaleX, scaleY); - ScalePathRect(&ppolyPtr->bbox, originX, originY, scaleX, scaleY); - ScalePathRect(&ppolyPtr->totalBbox, originX, originY, scaleX, scaleY); + ScalePathRect(&itemPtr->bbox, originX, originY, scaleX, scaleY); + ScalePathRect(&itemPtr->totalBbox, originX, originY, scaleX, scaleY); ScaleItemHeader(itemPtr, originX, originY, scaleX, scaleY); } @@ -451,9 +447,9 @@ TranslatePpoly(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double deltaX, double PpolyItem *ppolyPtr = (PpolyItem *) itemPtr; TranslatePathAtoms(ppolyPtr->atomPtr, deltaX, deltaY); - TranslatePathRect(&ppolyPtr->bbox, deltaX, deltaY); - TranslatePathRect(&ppolyPtr->totalBbox, deltaX, deltaY); - TranslateItemHeader(itemPtr, deltaX, deltaY); + TranslatePathRect(&itemPtr->bbox, deltaX, deltaY); + TranslatePathRect(&itemPtr->totalBbox, deltaX, deltaY); + TranslateItemHeader(itemPtr, deltaX, deltaY); } /* diff --git a/pd/tkpath/generic/tkCanvPrect.c b/pd/tkpath/generic/tkCanvPrect.c index 1e157208a507f14ca3ec16a33b48ce4466248483..6ad83bdbfc83f7a82bba28212ecb6088e7d5500f 100644 --- a/pd/tkpath/generic/tkCanvPrect.c +++ b/pd/tkpath/generic/tkCanvPrect.c @@ -6,7 +6,7 @@ * * Copyright (c) 2007-2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvPrect.c,v 1.28 2010/04/30 10:16:00 ebrunel Exp $ */ #include "tkIntPath.h" @@ -26,10 +26,6 @@ typedef struct PrectItem { * path types. MUST BE FIRST IN STRUCTURE. */ double rx; /* Radius of corners. */ double ry; - PathRect rect; /* Bounding box with zero width outline. - * Untransformed coordinates. */ - PathRect totalBbox; /* Bounding box including stroke. - * Untransformed coordinates. */ int maxNumSegments; /* Max number of straight segments (for subpath) * needed for Area and Point functions. */ } PrectItem; @@ -153,8 +149,8 @@ CreatePrect(Tcl_Interp *interp, Tk_PathCanvas canvas, Tk_PathItem *itemPtr, itemExPtr->canvas = canvas; itemExPtr->styleObj = NULL; itemExPtr->styleInst = NULL; - prectPtr->rect = NewEmptyPathRect(); - prectPtr->totalBbox = NewEmptyPathRect(); + itemPtr->bbox = NewEmptyPathRect(); + itemPtr->totalBbox = NewEmptyPathRect(); prectPtr->maxNumSegments = 100; /* Crude overestimate. */ if (optionTable == NULL) { @@ -172,7 +168,7 @@ CreatePrect(Tcl_Interp *interp, Tk_PathCanvas canvas, Tk_PathItem *itemPtr, break; } } - if (CoordsForRectangularItems(interp, canvas, &prectPtr->rect, i, objv) != TCL_OK) { + if (CoordsForRectangularItems(interp, canvas, &itemPtr->bbox, i, objv) != TCL_OK) { goto error; } if (ConfigurePrect(interp, canvas, itemPtr, objc-i, objv+i, 0) == TCL_OK) { @@ -196,7 +192,7 @@ PrectCoords(Tcl_Interp *interp, Tk_PathCanvas canvas, Tk_PathItem *itemPtr, PrectItem *prectPtr = (PrectItem *) itemPtr; int result; - result = CoordsForRectangularItems(interp, canvas, &prectPtr->rect, objc, objv); + result = CoordsForRectangularItems(interp, canvas, &itemPtr->bbox, objc, objv); if ((result == TCL_OK) && ((objc == 1) || (objc == 4))) { ComputePrectBbox(canvas, prectPtr); } @@ -220,8 +216,8 @@ ComputePrectBbox(Tk_PathCanvas canvas, PrectItem *prectPtr) return; } style = TkPathCanvasInheritStyle(itemPtr, kPathMergeStyleNotFill); - prectPtr->totalBbox = GetGenericPathTotalBboxFromBare(NULL, &style, &prectPtr->rect); - SetGenericPathHeaderBbox(&itemExPtr->header, style.matrixPtr, &prectPtr->totalBbox); + itemPtr->totalBbox = GetGenericPathTotalBboxFromBare(NULL, &style, &itemPtr->bbox); + SetGenericPathHeaderBbox(&itemExPtr->header, style.matrixPtr, &itemPtr->totalBbox); TkPathCanvasFreeInheritedStyle(&style); } @@ -293,13 +289,14 @@ ConfigurePrect(Tcl_Interp *interp, Tk_PathCanvas canvas, Tk_PathItem *itemPtr, static PathAtom * MakePathAtoms(PrectItem *prectPtr) { + Tk_PathItem *itemPtr = (Tk_PathItem *) prectPtr; PathAtom *atomPtr; double points[4]; - points[0] = prectPtr->rect.x1; - points[1] = prectPtr->rect.y1; - points[2] = prectPtr->rect.x2; - points[3] = prectPtr->rect.y2; + points[0] = itemPtr->bbox.x1; + points[1] = itemPtr->bbox.y1; + points[2] = itemPtr->bbox.x2; + points[3] = itemPtr->bbox.y2; TkPathMakePrectAtoms(points, prectPtr->rx, prectPtr->ry, &atomPtr); return atomPtr; } @@ -336,7 +333,7 @@ DisplayPrect(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, Display *display, Drawa style = TkPathCanvasInheritStyle(itemPtr, 0); atomPtr = MakePathAtoms(prectPtr); TkPathDrawPath(Tk_PathCanvasTkwin(canvas), drawable, atomPtr, - &style, &m, &prectPtr->rect); + &style, &m, &itemPtr->bbox); TkPathFreeAtoms(atomPtr); TkPathCanvasFreeInheritedStyle(&style); } @@ -354,7 +351,7 @@ PrectToPoint(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double *pointPtr) PrectItem *prectPtr = (PrectItem *) itemPtr; Tk_PathStyle style; TMatrix *mPtr; - PathRect *rectPtr = &prectPtr->rect; + PathRect *rectPtr = &itemPtr->bbox; double bareRect[4]; double width, dist; int rectiLinear = 0; @@ -405,7 +402,7 @@ PrectToArea(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double *areaPtr) Tk_PathItemEx *itemExPtr = &prectPtr->headerEx; Tk_PathStyle style = itemExPtr->style; /* NB: We *copy* the style for temp usage. */ TMatrix *mPtr; - PathRect *rectPtr = &(prectPtr->rect); + PathRect *rectPtr = &(itemPtr->bbox); double bareRect[4]; double width; int rectiLinear = 0; @@ -459,20 +456,20 @@ static void ScalePrect(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double originX, double originY, double scaleX, double scaleY) { - PrectItem *prectPtr = (PrectItem *) itemPtr; + //PrectItem *prectPtr = (PrectItem *) itemPtr; - ScalePathRect(&prectPtr->rect, originX, originY, scaleX, scaleY); + ScalePathRect(&itemPtr->bbox, originX, originY, scaleX, scaleY); ScaleItemHeader(itemPtr, originX, originY, scaleX, scaleY); } static void TranslatePrect(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double deltaX, double deltaY) { - PrectItem *prectPtr = (PrectItem *) itemPtr; + //PrectItem *prectPtr = (PrectItem *) itemPtr; /* Just translate the bbox'es as well. */ - TranslatePathRect(&prectPtr->rect, deltaX, deltaY); - TranslatePathRect(&prectPtr->totalBbox, deltaX, deltaY); + TranslatePathRect(&itemPtr->bbox, deltaX, deltaY); + TranslatePathRect(&itemPtr->totalBbox, deltaX, deltaY); TranslateItemHeader(itemPtr, deltaX, deltaY); } diff --git a/pd/tkpath/generic/tkCanvPtext.c b/pd/tkpath/generic/tkCanvPtext.c index fd4fde7cc2cff142ee51fc1ecba2427517166176..0a3d30788b8831ae24e3008cb3a7240f5d26d4c7 100644 --- a/pd/tkpath/generic/tkCanvPtext.c +++ b/pd/tkpath/generic/tkCanvPtext.c @@ -1,12 +1,12 @@ /* * tkCanvPtext.c -- * - * This file implements a text canvas item modelled after its +486 * This file implements a text canvas item modelled after its * SVG counterpart. See http://www.w3.org/TR/SVG11/. * * Copyright (c) 2007-2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvPtext.c,v 1.26 2010/04/30 10:16:00 ebrunel Exp $ */ #include "tkIntPath.h" @@ -28,8 +28,6 @@ typedef struct PtextItem { int textAnchor; double x; double y; - PathRect bbox; /* Bounding box with zero width outline. - * Untransformed coordinates. */ Tcl_Obj *utf8Obj; /* The actual text to display; UTF-8 */ int numChars; /* Length of text in characters. */ int numBytes; /* Length of text in bytes. */ @@ -201,7 +199,7 @@ CreatePtext(Tcl_Interp *interp, Tk_PathCanvas canvas, itemExPtr->canvas = canvas; itemExPtr->styleObj = NULL; itemExPtr->styleInst = NULL; - ptextPtr->bbox = NewEmptyPathRect(); + itemPtr->bbox = NewEmptyPathRect(); ptextPtr->utf8Obj = NULL; ptextPtr->numChars = 0; ptextPtr->numBytes = 0; @@ -344,7 +342,7 @@ ComputePtextBbox(Tk_PathCanvas canvas, PtextItem *ptextPtr) bbox.x2 += halfWidth; bbox.x2 += halfWidth; } - ptextPtr->bbox = bbox; + itemPtr->bbox = bbox; SetGenericPathHeaderBbox(&itemExPtr->header, style.matrixPtr, &bbox); TkPathCanvasFreeInheritedStyle(&style); } @@ -485,7 +483,7 @@ DisplayPtext(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, Display *display, Drawa /* @@@ We need to handle gradients as well here! Wait to see what the other APIs have to say. */ - TkPathTextDraw(ctx, &style, &ptextPtr->textStyle, ptextPtr->bbox.x1, ptextPtr->y, + TkPathTextDraw(ctx, &style, &ptextPtr->textStyle, itemPtr->bbox.x1, ptextPtr->y, Tcl_GetString(ptextPtr->utf8Obj), ptextPtr->custom); TkPathEndPath(ctx); TkPathFree(ctx); @@ -508,7 +506,7 @@ PtextToPoint(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double *pointPtr) style = TkPathCanvasInheritStyle(itemPtr, kPathMergeStyleNotFill | kPathMergeStyleNotStroke); - dist = PathRectToPointWithMatrix(ptextPtr->bbox, style.matrixPtr, pointPtr); + dist = PathRectToPointWithMatrix(itemPtr->bbox, style.matrixPtr, pointPtr); TkPathCanvasFreeInheritedStyle(&style); return dist; } @@ -522,7 +520,7 @@ PtextToArea(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double *areaPtr) style = TkPathCanvasInheritStyle(itemPtr, kPathMergeStyleNotFill | kPathMergeStyleNotStroke); - area = PathRectToAreaWithMatrix(ptextPtr->bbox, style.matrixPtr, areaPtr); + area = PathRectToAreaWithMatrix(itemPtr->bbox, style.matrixPtr, areaPtr); TkPathCanvasFreeInheritedStyle(&style); return area; } @@ -541,7 +539,7 @@ ScalePtext(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double originX, double or ptextPtr->x = originX + scaleX*(ptextPtr->x - originX); ptextPtr->y = originY + scaleY*(ptextPtr->y - originY); - ScalePathRect(&ptextPtr->bbox, originX, originY, scaleX, scaleY); + ScalePathRect(&itemPtr->bbox, originX, originY, scaleX, scaleY); ScaleItemHeader(itemPtr, originX, originY, scaleX, scaleY); } @@ -552,7 +550,7 @@ TranslatePtext(Tk_PathCanvas canvas, Tk_PathItem *itemPtr, double deltaX, double ptextPtr->x += deltaX; ptextPtr->y += deltaY; - TranslatePathRect(&ptextPtr->bbox, deltaX, deltaY); + TranslatePathRect(&itemPtr->bbox, deltaX, deltaY); TranslateItemHeader(itemPtr, deltaX, deltaY); } diff --git a/pd/tkpath/generic/tkCanvStyle.c b/pd/tkpath/generic/tkCanvStyle.c index cc5fff7677905e71b96aa8d3ee2516d0ed02fac3..824ff7dda0db126721d38b615739120dd1c0c2cc 100644 --- a/pd/tkpath/generic/tkCanvStyle.c +++ b/pd/tkpath/generic/tkCanvStyle.c @@ -5,7 +5,7 @@ * * Copyright (c) 2008 Mats Bengtsson * - * $Id$ + * $Id: tkCanvStyle.c,v 1.2 2008/06/05 12:51:58 matben Exp $ */ #include "tkIntPath.h" diff --git a/pd/tkpath/generic/tkIntPath.h b/pd/tkpath/generic/tkIntPath.h index 2c5901d6c4360dca22decd8eb691c33cb9abda7d..790942b3e6e7b6fdcde439b81f73b3021b3fde29 100644 --- a/pd/tkpath/generic/tkIntPath.h +++ b/pd/tkpath/generic/tkIntPath.h @@ -5,7 +5,7 @@ * * Copyright (c) 2005-2008 Mats Bengtsson * - * $Id$ + * $Id: tkIntPath.h,v 1.52 2010/04/30 10:16:00 ebrunel Exp $ */ #ifndef INCLUDED_TKINTPATH_H diff --git a/pd/tkpath/generic/tkPath.c b/pd/tkpath/generic/tkPath.c index 64fdfbe5b3c53196b485ac8212c1abb9e94f540e..f84853162234ffe1887a8e496a3b6ead6305bf6c 100644 --- a/pd/tkpath/generic/tkPath.c +++ b/pd/tkpath/generic/tkPath.c @@ -7,7 +7,7 @@ * * Copyright (c) 2005-2008 Mats Bengtsson * - * $Id$ + * $Id: tkPath.c,v 1.18 2012/07/04 19:43:18 petasis Exp $ */ #include "tkIntPath.h" diff --git a/pd/tkpath/generic/tkPath.h b/pd/tkpath/generic/tkPath.h index a8c27946fb318813ba30f710af28f2886776edca..216e3c22a1d04f088e28458ef44f750631207913 100644 --- a/pd/tkpath/generic/tkPath.h +++ b/pd/tkpath/generic/tkPath.h @@ -6,7 +6,7 @@ * * Copyright (c) 2005-2008 Mats Bengtsson * - * $Id$ + * $Id: tkPath.h,v 1.32 2008/06/14 14:23:25 matben Exp $ */ #ifndef INCLUDED_TKPATH_H @@ -52,13 +52,6 @@ typedef struct PathPoint { double y; } PathPoint; -typedef struct PathRect { - double x1; - double y1; - double x2; - double y2; -} PathRect; - /* * The transformation matrix: * | a b 0 | diff --git a/pd/tkpath/generic/tkPathGradient.c b/pd/tkpath/generic/tkPathGradient.c index 88057adf4889f94610400980f9ef2fca491d92fe..0102d2432d0087af9b2099844bebacb2b12fbdbc 100644 --- a/pd/tkpath/generic/tkPathGradient.c +++ b/pd/tkpath/generic/tkPathGradient.c @@ -8,7 +8,7 @@ * * TODO: o Add tkwin option here and there so we can free stop colors! * - * $Id$ + * $Id: tkPathGradient.c,v 1.4 2012/07/04 19:43:18 petasis Exp $ */ #include "tkIntPath.h" diff --git a/pd/tkpath/generic/tkPathStyle.c b/pd/tkpath/generic/tkPathStyle.c index 37e7ff1c9eefbba5d67bb483c4108cd9e29c16e9..ef89e7bee4c9705d5ad4fb33d857074e2b9b4e1c 100644 --- a/pd/tkpath/generic/tkPathStyle.c +++ b/pd/tkpath/generic/tkPathStyle.c @@ -14,7 +14,7 @@ * items are not notified. They will only notice any change when * they need to redisplay. * - * $Id$ + * $Id: tkPathStyle.c,v 1.32 2012/07/04 19:43:18 petasis Exp $ */ #include "tkIntPath.h" diff --git a/pd/tkpath/generic/tkPathStyle.h b/pd/tkpath/generic/tkPathStyle.h index 1721ab3e2330768ad5bc74b2cffa2ca03cf4251e..4a122c3a09c0f36c19796fa154e5c2b279f3995e 100644 --- a/pd/tkpath/generic/tkPathStyle.h +++ b/pd/tkpath/generic/tkPathStyle.h @@ -6,7 +6,7 @@ * * Copyright (c) 2007-2008 Mats Bengtsson * - * $Id$ + * $Id: tkPathStyle.h,v 1.5 2008/06/03 08:08:17 matben Exp $ */ #include "tkIntPath.h" diff --git a/pd/tkpath/generic/tkPathSurface.c b/pd/tkpath/generic/tkPathSurface.c index 45131eee9a5177d0dc3cf76b06ce1d151f2cdba1..2e86d0f43cefc1c999eee3d77beac85243639f5a 100644 --- a/pd/tkpath/generic/tkPathSurface.c +++ b/pd/tkpath/generic/tkPathSurface.c @@ -6,7 +6,7 @@ * * Copyright (c) 2007-2008 Mats Bengtsson * - * $Id$ + * $Id: tkPathSurface.c,v 1.28 2012/07/04 19:43:18 petasis Exp $ */ #include "tkIntPath.h" diff --git a/pd/tkpath/generic/tkPathTkDraw.c b/pd/tkpath/generic/tkPathTkDraw.c index d4f0136f9efbb6be6b1a893ea32b74fee60e96a3..dc554d5a3b14f4821bec3310c7300311b440e2b2 100644 --- a/pd/tkpath/generic/tkPathTkDraw.c +++ b/pd/tkpath/generic/tkPathTkDraw.c @@ -11,7 +11,7 @@ * * Copyright (c) 2005-2008 Mats Bengtsson * - * $Id$ + * $Id: tkPathTkDraw.c,v 1.25 2008/05/22 06:18:21 matben Exp $ */ #include "tkIntPath.h" diff --git a/pd/tkpath/generic/tkPathUtil.c b/pd/tkpath/generic/tkPathUtil.c index d3dedbe03adbf0c401a49ba1c5f1119bbb0e52aa..4f60eb738c192255904070afa084fc9be6128a8e 100644 --- a/pd/tkpath/generic/tkPathUtil.c +++ b/pd/tkpath/generic/tkPathUtil.c @@ -5,7 +5,7 @@ * * Copyright (c) 2005-2008 Mats Bengtsson * - * $Id$ + * $Id: tkPathUtil.c,v 1.30 2012/07/04 19:43:18 petasis Exp $ */ #include <float.h> @@ -190,6 +190,7 @@ TkPathGetTotalBbox(PathAtom *atomPtr, Tk_PathStyle *stylePtr) { PathRect bare, total; + fprintf(stderr,"TKPathGetTotalBbox\n"); bare = GetGenericBarePathBbox(atomPtr); total = GetGenericPathTotalBboxFromBare(atomPtr, stylePtr, &bare); return total; diff --git a/pd/tkpath/generic/tkp.h b/pd/tkpath/generic/tkp.h index 90571c2591df1fb3d272ff641f335beb407d2779..285fafcae36659f4ad24ba8b55c58c70383480b3 100644 --- a/pd/tkpath/generic/tkp.h +++ b/pd/tkpath/generic/tkp.h @@ -4,7 +4,7 @@ * This file includes stuff from tk.h which we need * in a modified form and to make the tkp::canvas self contained. * - * $Id$ + * $Id: tkp.h,v 1.6 2008/07/16 13:17:33 matben Exp $ */ #ifndef INCLUDED_TKP_H @@ -68,6 +68,13 @@ typedef struct Tk_PathTags { * *tagPtr. */ } Tk_PathTags; +typedef struct PathRect { + double x1; + double y1; + double x2; + double y2; +} PathRect; + typedef struct Tk_PathItem { int id; /* Unique identifier for this item (also * serves as first tag for item). */ @@ -106,6 +113,10 @@ typedef struct Tk_PathItem { * item. Item area includes x1 and y1 but not * x2 and y2. */ Tk_PathState state; /* State of item. */ + PathRect bbox; /* Bounding box with zero width outline. + * Untransformed coordinates. */ + PathRect totalBbox; /* Bounding box including stroke. + * Untransformed coordinates. */ char *reserved1; /* reserved for future use */ int redraw_flags; /* Some flags used in the canvas */ diff --git a/pd/tkpath/generic/tkpCanvArc.c b/pd/tkpath/generic/tkpCanvArc.c index bb70a5c1f72be2626e67cefc7a6f0c41376316b2..1596540dfbb876f95c92ff20a31141e7a8c30e8a 100644 --- a/pd/tkpath/generic/tkpCanvArc.c +++ b/pd/tkpath/generic/tkpCanvArc.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvArc.c,v 1.5 2008/07/22 09:41:35 matben Exp $ */ #include <stdio.h> diff --git a/pd/tkpath/generic/tkpCanvBmap.c b/pd/tkpath/generic/tkpCanvBmap.c index 230ae905be9875453950208dadd00f991276e5c0..24477f61e53e380198289209251ca1e548f8d635 100644 --- a/pd/tkpath/generic/tkpCanvBmap.c +++ b/pd/tkpath/generic/tkpCanvBmap.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvBmap.c,v 1.2 2008/06/21 14:58:42 matben Exp $ */ #include <stdio.h> diff --git a/pd/tkpath/generic/tkpCanvImg.c b/pd/tkpath/generic/tkpCanvImg.c index f18bc950571f7badfae5a51d65645c402c633cc1..65485c63c3eaf69c1ee3a9d20107ed752b99ce07 100644 --- a/pd/tkpath/generic/tkpCanvImg.c +++ b/pd/tkpath/generic/tkpCanvImg.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvImg.c,v 1.2 2008/06/21 14:58:42 matben Exp $ */ #include <stdio.h> diff --git a/pd/tkpath/generic/tkpCanvLine.c b/pd/tkpath/generic/tkpCanvLine.c index c0d12cf7f6152aa675ccddf514deac805557c826..799170b9859dcef87d009283affa0a6a90734ac5 100644 --- a/pd/tkpath/generic/tkpCanvLine.c +++ b/pd/tkpath/generic/tkpCanvLine.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvLine.c,v 1.5 2008/07/22 09:41:35 matben Exp $ */ #include <stdio.h> diff --git a/pd/tkpath/generic/tkpCanvPoly.c b/pd/tkpath/generic/tkpCanvPoly.c index bfbc8312de064ce7b51c9f76908b05eb5a1f95de..1d88f3a85e1e16eb4ad61705b7713273291b5c8f 100644 --- a/pd/tkpath/generic/tkpCanvPoly.c +++ b/pd/tkpath/generic/tkpCanvPoly.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvPoly.c,v 1.6 2010/03/10 22:47:37 petasis Exp $ */ #include <stdio.h> diff --git a/pd/tkpath/generic/tkpCanvPs.c b/pd/tkpath/generic/tkpCanvPs.c index 8499c4ba80645e78be1436a8b7be43c33074b1f1..8023b83cd8572c78b032b2dde19337cf241906fa 100644 --- a/pd/tkpath/generic/tkpCanvPs.c +++ b/pd/tkpath/generic/tkpCanvPs.c @@ -13,7 +13,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvPs.c,v 1.3 2012/07/04 19:43:18 petasis Exp $ */ #include "tkInt.h" diff --git a/pd/tkpath/generic/tkpCanvText.c b/pd/tkpath/generic/tkpCanvText.c index eb3e94c328ca093d45031c98c3b91bf94b16be08..56cd99b4868f9d18aa2987d39edc43ff8103b518 100644 --- a/pd/tkpath/generic/tkpCanvText.c +++ b/pd/tkpath/generic/tkpCanvText.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvText.c,v 1.8 2008/07/16 13:17:33 matben Exp $ */ #include <stdio.h> diff --git a/pd/tkpath/generic/tkpCanvUtil.c b/pd/tkpath/generic/tkpCanvUtil.c index 0e928d6ce9d566b679f2e814933446471de8fecb..5f5f1557425e1cb0176155cab6c4f755e22f6d95 100644 --- a/pd/tkpath/generic/tkpCanvUtil.c +++ b/pd/tkpath/generic/tkpCanvUtil.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvUtil.c,v 1.13 2010/03/10 22:47:37 petasis Exp $ */ #include "tkInt.h" diff --git a/pd/tkpath/generic/tkpCanvWind.c b/pd/tkpath/generic/tkpCanvWind.c index 12cda11504e70cb910fccee7298818c0debc41de..84be095106f99b9536275ce10987eb06f3f406f6 100644 --- a/pd/tkpath/generic/tkpCanvWind.c +++ b/pd/tkpath/generic/tkpCanvWind.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvWind.c,v 1.4 2008/07/14 08:21:26 matben Exp $ */ #include <stdio.h> diff --git a/pd/tkpath/generic/tkpCanvas.c b/pd/tkpath/generic/tkpCanvas.c index f726280cd0b1950120fd1ba7dd78fa859e8457ff..9c80e3ba43a994c2715696a8ae59a41ae7d65d4c 100644 --- a/pd/tkpath/generic/tkpCanvas.c +++ b/pd/tkpath/generic/tkpCanvas.c @@ -13,7 +13,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvas.c,v 1.16 2012/07/04 19:43:18 petasis Exp $ */ /* #define USE_OLD_TAG_SEARCH 1 */ @@ -1074,8 +1074,8 @@ CanvasWidgetCmd( char *arg; int length; - if (objc < 3) { - Tcl_WrongNumArgs(interp, 2, objv, "type coords ?arg arg ...?"); + if (objc < 2) { + Tcl_WrongNumArgs(interp, 1, objv, "type ?arg arg ...?"); result = TCL_ERROR; goto done; } diff --git a/pd/tkpath/generic/tkpCanvas.h b/pd/tkpath/generic/tkpCanvas.h index 061e290e10cdf3f7cd44a55249fcc54972901186..2402e1c5fa7bd835c1e4ffbd5563bb29b496101a 100644 --- a/pd/tkpath/generic/tkpCanvas.h +++ b/pd/tkpath/generic/tkpCanvas.h @@ -11,7 +11,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpCanvas.h,v 1.10 2008/07/23 07:08:39 matben Exp $ */ #ifndef _TKPCANVAS diff --git a/pd/tkpath/generic/tkpRectOval.c b/pd/tkpath/generic/tkpRectOval.c index 3900aa68d08ed76ed1d8d121349d052a04c009eb..f53923cc7dd556ef5f8abed88bd210ef37ce2217 100644 --- a/pd/tkpath/generic/tkpRectOval.c +++ b/pd/tkpath/generic/tkpRectOval.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpRectOval.c,v 1.6 2008/07/22 09:41:35 matben Exp $ */ #include <stdio.h> diff --git a/pd/tkpath/generic/tkpTrig.c b/pd/tkpath/generic/tkpTrig.c index 9d8faba568b87f0707e04917dd08ba63113e202f..35d8369b2f8539b3553ba042da759d417bb17a9c 100644 --- a/pd/tkpath/generic/tkpTrig.c +++ b/pd/tkpath/generic/tkpTrig.c @@ -11,7 +11,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpTrig.c,v 1.2 2008/06/05 14:39:49 matben Exp $ */ /* diff --git a/pd/tkpath/generic/tkpUtil.c b/pd/tkpath/generic/tkpUtil.c index d8ab9744ee7973c4e7139c7e483d9389a8139974..bf0106458f5854de0854561e63286986e6f3d799 100644 --- a/pd/tkpath/generic/tkpUtil.c +++ b/pd/tkpath/generic/tkpUtil.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id$ + * RCS: @(#) $Id: tkpUtil.c,v 1.7 2012/07/04 19:43:18 petasis Exp $ */ #include "tkInt.h"