home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam  


Book HomeMastering Perl/TkSearch this book

13.3. Widget's ID

You use the id method to get X11 window ID or Win32 HWND for a widget:

$id = $widget->id;
print "$id\n";
# Prints 0x9c944c

This returns a hex value. A common use for this method is to embed a Tk window in another application. The PerlPlus Netscape plug-in does just this. It is described in Chapter 22, "Perl/Tk and the Web".



Library Navigation Links

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