Class: Gtk::BuilderCScope
- Inherits:
-
Object
- Object
- Gtk::BuilderCScope
- Defined in:
- (unknown)
Instance Method Summary collapse
-
#add_callback_symbol(callback_name, callback_symbol) ⇒ nil
Adds the callback_symbol to the scope of builder under the given callback_name.
-
#add_callback_symbols(first_callback_name, first_callback_symbol, array) ⇒ nil
A convenience function to add many callbacks.
-
#initialize ⇒ Gtk::BuilderCScope
constructor
Creates a new
GtkBuilderCScopeobject to use with futureGtkBuilderinstances. -
#lookup_callback_symbol(callback_name) ⇒ GObject::Callback
Fetches a symbol previously added with gtk_builder_cscope_add_callback_symbol().
Constructor Details
#initialize ⇒ Gtk::BuilderCScope
Creates a new GtkBuilderCScope object to use with future
GtkBuilder instances.
Calling this function is only necessary if you want to add custom callbacks via [methodGtk.BuilderCScope.add_callback_symbol].
Instance Method Details
#add_callback_symbol(callback_name, callback_symbol) ⇒ nil
Adds the callback_symbol to the scope of builder under the given callback_name.
Using this function overrides the behavior of [methodGtk.Builder.create_closure] for any callback symbols that are added. Using this method allows for better encapsulation as it does not require that callback symbols be declared in the global namespace.
#add_callback_symbols(first_callback_name, first_callback_symbol, array) ⇒ nil
A convenience function to add many callbacks.
This is equivalent to calling [methodGtk.BuilderCScope.add_callback_symbol] for each symbol.
#lookup_callback_symbol(callback_name) ⇒ GObject::Callback
Fetches a symbol previously added with gtk_builder_cscope_add_callback_symbol().