Re: When is a signal a "keybinding" signal?



murrayc t-online de (Murray Cumming) writes:

> In gtkmm 2.4, we don't want to wrap "keybinding" signals, because
> apparently we're not suppose to and we were caught out when GTK+ 2.2
> changed the API of some of those signals.
> 
> So I'd like to know what signals are "keybinding" signals. I thought I
> could just check for uses of gtk_binding_entry_add_signal(), but that's
> used on GtkEntry's "activate" signal, and I'm told that that's not a
> keybinding signal.

activate is probably about the only exception in that direction,
though there may be some keybinding signals which are not
bound in the default key theme. Generally, the properties of keybinding 
signals are:

 - They have a default handler that actually does an action
 - They are used in a call to gtk_binding_entry_add_signal() 
 - They are not emitted by GTK+ except in response to keyboard
   events.

Moving forward, the plan is generally not to put keybinding signals
into the class structure, which should be a pretty clear indication
of their nature. See _gtk_binding_signal_new().

But, no there is no deterministic way of finding out if something
is a keybinding signal, currently, unless it is documented.

Regards,
                                        Owen



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