sub go{ open (CHILD,"-|")||exec "perl script.pl"; while (){ $main->update; next if m/^\s*$/; chomp; s/^\s*DEBUGG(.+):\s*(\S)/\U$2/; $status->configure(-text=>"$_"); } close CHILD; $status->configure(-text=>"Status area"); }