use strict; use warnings; use Tk; my $mw = tkinit (); $mw->Button(-text => 'watch', -command => sub{$mw->configure(-cursor => 'watch'); $mw->update; sleep 4; $mw->configure(-cursor => ''); } )->pack; MainLoop;