Function
GtkBindingEntryadd_signal
Declaration [src]
void
gtk_binding_entry_add_signal (
GtkBindingSet* binding_set,
guint keyval,
GdkModifierType modifiers,
const gchar* signal_name,
guint n_args,
...
)
Description [src]
Override or install a new key binding for keyval with modifiers on
binding_set. When the binding is activated, signal_name will be
emitted on the target widget, with n_args Varargs used as arguments.
Each argument to the signal must be passed as a pair of varargs: the
GType of the argument, followed by the argument value (which must
be of the given type). There must be n_args pairs in total.
Adding a Key Binding
GtkBindingSet *binding_set;
GdkModifierType modmask = GDK_CONTROL_MASK;
int count = 1;
gtk_binding_entry_add_signal (binding_set,
GDK_KEY_space,
modmask,
"move-cursor", 2,
GTK_TYPE_MOVEMENT_STEP, GTK_MOVEMENT_PAGES,
G_TYPE_INT, count,
G_TYPE_BOOLEAN, FALSE);
This function is not directly available to language bindings.
Parameters
binding_set-
Type:
GtkBindingSetA
GtkBindingSetto install an entry for.The data is owned by the caller of the function. keyval-
Type:
guintKey value of binding to install.
modifiers-
Type:
GdkModifierTypeKey modifier of binding to install.
signal_name-
Type:
const gchar*Signal to execute upon activation.
The data is owned by the caller of the function. The value is a NUL terminated UTF-8 string. n_args-
Type:
guintNumber of arguments to
signal_name. ...-
Type:
Arguments to
signal_name.