[Gtk-sharp-list] Using Gdk.Key.KP_Enter to accept input in a comboboxentry?

Jesper K. Pedersen linux at famped.dk
Mon Sep 15 16:21:03 EDT 2008


On Mon, 15 Sep 2008 20:07:31 +0200
"Jesper K. Pedersen" <linux at famped.dk> wrote:

> 
> I have a small application where a few of my users have noted a small
> "annoyance".
> They often use the numerical keypad enter key to enter/accept data on
> a computer and this works fine with regular Gtk.Entry entries.
> 
> When it comes to a Gtk.ComboBoxEntry you can not use the
> Gdk.Key.KP_Enter to accept entries - any ideas if this is a
> bug/feature that can be worked around?
> 
> I've tried with the simple hack of trying to grab keypressed events
> and emit the FinishEditing signal when coming accross the KP_Enter
> keypress
> - but my event handler for keypressed events doesnt get called at all.
> 
> Any ideas ?
>

I will just answer myself to close this question.

The sollution is to hook into the ComboBoxEntry.Entry Activated signal
handler and let that fire my accept data function.

Best regards
Jesper KP


More information about the Gtk-sharp-list mailing list