9.15. Deleting Tags

You can remove tags from items by using the dtag method. There are two forms:

$canvas->dtag(tag);
$canvas->dtag(tag/id, deltag);

The first one will search for items with the specified tag and then delete the tag. The second will search for items that match the tag or ID and then delete the deltag (if it exists) from that item. This allows you to delete a subset of the tabs, rather than every single tag.

Get Learning Perl/Tk now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.