http://qs321.pair.com?node_id=108870


in reply to Problem following Tk demo in Advanced Perl Programming

change label to -lable

:)

Another reference (sic) to check out is Learning Perl Tk.

Big whoops! - thanks Graham! yes, -label

jefaf

Replies are listed 'Best First'.
Re: Problem following Tk demo in Advanced Perl Programming
by Graham (Deacon) on Aug 30, 2001 at 12:09 UTC
    Surely that should read "-label" So that the entire script is
    use Tk; $top = MainWindow->new(); $menu_bar = $top->Frame()->pack(side => 'top'); $search_mb = $menu_bar->Menubutton(text => 'Search', relief => 'raised', borderwidth => 2 )->pack(side => 'left', padx => 2 ); $search_mb->command(-label => 'Find', accelerator => 'Meta+F', underline => 0, command => sub {print "find\n"} ); MainLoop();