Class: Gtk::EventControllerKey

Inherits:
EventController show all
Defined in:
(unknown)

Instance Method Summary collapse

Methods inherited from EventController

#current_event, #current_event_device, #current_event_state, #current_event_time, #name, #name=, #propagation_limit, #propagation_limit=, #propagation_phase, #propagation_phase=, #reset, #static_name=, #widget, #widget=

Constructor Details

#initializeGtk::EventController

Creates a new event controller that will handle key events.

Instance Method Details

#forward(widget) ⇒ Boolean

Forwards the current event of this controller to a widget.

This function can only be used in handlers for the [signalGtk.EventControllerKey::key-pressed], [signalGtk.EventControllerKey::key-released] or [signalGtk.EventControllerKey::modifiers] signals.

Parameters:

Returns:

  • (Boolean)

    whether the widget handled the event

#groupInteger

Gets the key group of the current event of this controller.

See [methodGdk.KeyEvent.get_layout].

Returns:

  • (Integer)

    the key group

#im_contextGtk::IMContext

Gets the input method context of the key controller.

Returns:

#im_context=(im_context) ⇒ nil

Sets the input method context of the key controller.

Parameters:

Returns:

  • (nil)