use strict; use warnings; use Tk; my $tk = Tk::MainWindow->new(); $tk->bind('Tk::MainWindow','',\&badger); #print $tk->bind(); MainLoop(); sub badger { print "badger\n";