start page | rating of books | rating of authors | reviews | copyrights

Book HomeMastering Perl/TkSearch this book

9.14. Deleting Items

To remove an item (or more than one item) from the Canvas completely, use the delete method. It takes a list of tags or IDs to remove from the Canvas. It will delete all matches it finds for the tag names, so be careful you aren't deleting something you don't want to delete. Here is an example that uses three separate tag/IDs:

$canvas->delete("blue", "circle", $id_num);

You can specify only one tag/ID or as many as you want.



Library Navigation Links

Copyright © 2002 O'Reilly & Associates. All rights reserved.