diff options
Diffstat (limited to 'generic')
-rw-r--r-- | generic/Icon.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/generic/Icon.c b/generic/Icon.c index 6b3ce64..94e7bec 100644 --- a/generic/Icon.c +++ b/generic/Icon.c @@ -695,12 +695,13 @@ GetAnchor(Item item, * * GetClipVertices -- * Get the clipping shape. + * Never ever call TRI_FREE on the tristrip returned by GetClipVertices. * ********************************************************************************** */ static ZnBool -GetClipVertices(Item item, - ZnPoly *poly) +GetClipVertices(Item item, + ZnTriStrip *tristrip) { IconItem icon = (IconItem) item; int w=0, h=0; @@ -714,7 +715,7 @@ GetClipVertices(Item item, Tk_SizeOfBitmap(item->wi->dpy, icon->mask, &w, &h); } points = (ZnPoint *) ZnListArray(item->wi->work_pts); - POLY_CONTOUR1(poly, points, 2); + TRI_STRIP1(tristrip, points, 2); points[0] = icon->pos_dev; points[1].x = points[0].x + w; points[1].y = points[0].y + h; @@ -787,6 +788,7 @@ static ItemClassStruct ICON_ITEM_CLASS = { NULL, /* GetFieldSet */ GetAnchor, GetClipVertices, + NULL, /* GetContours */ Coords, NULL, /* InsertChars */ NULL, /* DeleteChars */ |