Re: How do I get the enter key to press OK when in a GTk::Entry widget?



Garth's KidStuff wrote:
Hi All,

I've got a dialog with a Gtk:Entry widget and some other widgets.  I've set
the OK button the be the default and that works fine as long as the user
isn't editing text in the Entry widget.   How do I make the Entry widget
ignore the return key?
  

You do not want the enter to be ignored on the Entry, but rather that
the enter in the Entry activates the default button.

That is accomplished with gtk_entry_set_activates_default():
http://library.gnome.org/devel/gtk/unstable/GtkEntry.html#gtk-entry-set-activates-default


-- 
Death rays don't kill people, people kill people!!

Eduardo M KALINOWSKI
eduardo kalinowski com br
http://move.to/hpkb




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]