Beast said: > muppet wrote: >> You can set the label to be the mnemonic for another widget. >> >> # new() is aliased to new_with_mnemonic() in the perl bindings: >> $label = Gtk2::Label->new ('_User Name'); >> $entry = Gtk2::Entry->new; >> # set $label to be the mnemonic for $entry >> $label->set_mnemonic_for ($entry); > > It seems does not work with my version of perl-gtk > > *** unhandled exception in callback: > *** Can't locate object method "set_mnemonic_for" via package > "Gtk2::Label" at Testing.pm line 35, <DATA> line 225. > *** ignoring at ./testme.pl line 10, <DATA> line 225.
My mistake --- it should be $label->set_mnemonic_widget ($entry); http://gtk2-perl.sourceforge.net/doc/pod/Gtk2/Label.html#_label_set_mnemonic_ http://developer.gnome.org/doc/API/2.0/gtk/GtkLabel.html#id2859257 > I also need to use new_with_mnemonic instead of just new(); Right again. I apologize -- i hadn't had my caffeine yet. :-( -- muppet <scott at asofyet dot org> _______________________________________________ gtk-perl-list mailing list gtk-perl-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-perl-list