Skip to Main Content
Learning Perl/Tk
book

Learning Perl/Tk

by Nancy Walsh
January 1999
Beginner content levelBeginner
373 pages
9h 43m
English
O'Reilly Media, Inc.
Content preview from Learning Perl/Tk

16.11. Atom Methods

Each widget is assigned a name, which is called an atom. The atom has a string name (you can get it for each widget by using the name method) and a 32-bit ID. These methods are used internally to handle things such as the selection mechanism.

To get the 32-bit ID for a given widget, send the name of the widget to the atom method:

$id = $widget->atom($widget->name());

You can do the opposite and use the ID to get the name of the atom back. To do so, use the atomname method:

$name = $widget->atomname($id);
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Mastering Perl/Tk

Mastering Perl/Tk

Stephen Lidie, Nancy Walsh

Publisher Resources

ISBN: 1565923146Supplemental ContentCatalog PageErrata