gi-gtk3-3.0.44: Gtk 3.x bindings

Copyright | Will Thompson and Iñaki García Etxebarria
License | LGPL-2.1
Maintainer | Iñaki García Etxebarria
Safe Haskell | None
Language | Haskell2010

GI.Gtk.Objects.EventControllerKey

Contents

- Exported types
- Methods
  - forward
  - getGroup
  - getImContext
  - new
  - setImContext
- Signals
  - focusIn
  - focusOut
  - imUpdate
  - keyPressed
  - keyReleased
  - modifiers

Description

`EventControllerKey` is an event controller meant for situations where you need access to key events.

This object was added in 3.24.

Synopsis

- newtype EventControllerKey = EventControllerKey (ManagedPtr EventControllerKey)
- class (GObject o, IsDescendantOf EventControllerKey o) => IsEventControllerKey o
- toEventControllerKey :: (MonadIO m, IsEventControllerKey o) => o -> m EventControllerKey
- eventControllerKeyForward :: (HasCallStack, MonadIO m, IsEventControllerKey a, IsWidget b) => a -> b -> m Bool
- eventControllerKeyGetGroup :: (HasCallStack, MonadIO m, IsEventControllerKey a) => a -> m Word32
- eventControllerKeyGetImContext :: (HasCallStack, MonadIO m, IsEventControllerKey a) => a -> m IMContext
- eventControllerKeyNew :: (HasCallStack, MonadIO m, IsWidget a) => a -> m EventControllerKey
- eventControllerKeySetImContext :: (HasCallStack, MonadIO m, IsEventControllerKey a, IsIMContext b) => a -> b -> m ()
- type EventControllerKeyFocusInCallback = IO ()
- afterEventControllerKeyFocusIn :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyFocusInCallback) -> m SignalHandlerId
- onEventControllerKeyFocusIn :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyFocusInCallback) -> m SignalHandlerId
- type EventControllerKeyFocusOutCallback = IO ()
- afterEventControllerKeyFocusOut :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyFocusOutCallback) -> m SignalHandlerId
- onEventControllerKeyFocusOut :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyFocusOutCallback) -> m SignalHandlerId
- type EventControllerKeyImUpdateCallback = IO ()
- afterEventControllerKeyImUpdate :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyImUpdateCallback) -> m SignalHandlerId
- onEventControllerKeyImUpdate :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyImUpdateCallback) -> m SignalHandlerId
- type EventControllerKeyKeyPressedCallback = Word32 -> Word32 -> [ModifierType] -> IO Bool
- afterEventControllerKeyKeyPressed :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyKeyPressedCallback) -> m SignalHandlerId
- onEventControllerKeyKeyPressed :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyKeyPressedCallback) -> m SignalHandlerId
- type EventControllerKeyKeyReleasedCallback = Word32 -> Word32 -> [ModifierType] -> IO ()
- afterEventControllerKeyKeyReleased :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyKeyReleasedCallback) -> m SignalHandlerId
- onEventControllerKeyKeyReleased :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyKeyReleasedCallback) -> m SignalHandlerId
- type EventControllerKeyModifiersCallback = [ModifierType] -> IO Bool
- afterEventControllerKeyModifiers :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyModifiersCallback) -> m SignalHandlerId
- onEventControllerKeyModifiers :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyModifiersCallback) -> m SignalHandlerId

# Exported types

newtype EventControllerKey Source #

Memory-managed wrapper type.

Constructors

EventControllerKey (ManagedPtr EventControllerKey) |

#### Instances

Instances details

Eq EventControllerKey Source # |
Instance details Defined in GI.Gtk.Objects.EventControllerKey Methods (==) :: EventControllerKey -> EventControllerKey -> Bool Source # (/=) :: EventControllerKey -> EventControllerKey -> Bool Source #
GObject EventControllerKey Source # |
Instance details Defined in GI.Gtk.Objects.EventControllerKey
ManagedPtrNewtype EventControllerKey Source # |
Instance details Defined in GI.Gtk.Objects.EventControllerKey Methods toManagedPtr :: EventControllerKey -> ManagedPtr EventControllerKey Source #
TypedObject EventControllerKey Source # |
Instance details Defined in GI.Gtk.Objects.EventControllerKey Methods glibType :: IO GType Source #
HasParentTypes EventControllerKey Source # |
Instance details Defined in GI.Gtk.Objects.EventControllerKey
IsGValue (Maybe EventControllerKey) Source # | Convert `EventControllerKey` to and from `GValue`. See `toGValue` and `fromGValue`.
Instance details Defined in GI.Gtk.Objects.EventControllerKey Methods gvalueGType_ :: IO GType Source # gvalueSet_ :: Ptr GValue -> Maybe EventControllerKey -> IO () Source # gvalueGet_ :: Ptr GValue -> IO (Maybe EventControllerKey) Source #
type ParentTypes EventControllerKey Source # |
Instance details Defined in GI.Gtk.Objects.EventControllerKey type ParentTypes EventControllerKey = '[EventController, Object]

class (GObject o, IsDescendantOf EventControllerKey o) => IsEventControllerKey o Source #

Type class for types which can be safely cast to `EventControllerKey`, for instance with `toEventControllerKey`.

#### Instances

Instances details

(GObject o, IsDescendantOf EventControllerKey o) => IsEventControllerKey o Source # |
Instance details Defined in GI.Gtk.Objects.EventControllerKey

toEventControllerKey :: (MonadIO m, IsEventControllerKey o) => o -> m EventControllerKey Source #

Cast to `EventControllerKey`, for types for which this is known to be safe. For general casts, use `castTo`.

# Methods

### Click to display all available methods, including inherited ones

Expand

#### Methods

bindProperty, bindPropertyFull, forceFloating, forward, freezeNotify, getv, handleEvent, isFloating, notify, notifyByPspec, ref, refSink, reset, runDispose, stealData, stealQdata, thawNotify, unref, watchClosure.

#### Getters

getData, getGroup, getImContext, getPropagationPhase, getProperty, getQdata, getWidget.

#### Setters

setData, setDataFull, setImContext, setPropagationPhase, setProperty.

## forward

eventControllerKeyForward :: (HasCallStack, MonadIO m, IsEventControllerKey a, IsWidget b) => a -> b -> m Bool Source #

No description available in the introspection data.

## getGroup

eventControllerKeyGetGroup :: (HasCallStack, MonadIO m, IsEventControllerKey a) => a -> m Word32 Source #

No description available in the introspection data.

## getImContext

eventControllerKeyGetImContext Source #

Arguments

:: (HasCallStack, MonadIO m, IsEventControllerKey a) |
=> a | `controller`: a `EventControllerKey`
-> m IMContext | Returns: the IM context

Gets the IM context of a key controller.

Since: 3.24

## new

eventControllerKeyNew :: (HasCallStack, MonadIO m, IsWidget a) => a -> m EventControllerKey Source #

No description available in the introspection data.

## setImContext

eventControllerKeySetImContext :: (HasCallStack, MonadIO m, IsEventControllerKey a, IsIMContext b) => a -> b -> m () Source #

No description available in the introspection data.

# Signals

## focusIn

type EventControllerKeyFocusInCallback = IO () Source #

No description available in the introspection data.

afterEventControllerKeyFocusIn :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyFocusInCallback) -> m SignalHandlerId Source #

Connect a signal handler for the focusIn signal, to be run after the default handler. When overloading is enabled, this is equivalent to

    after eventControllerKey #focusIn callback

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit `?self` parameter. Note that this requires activating the `ImplicitParams` GHC extension.

onEventControllerKeyFocusIn :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyFocusInCallback) -> m SignalHandlerId Source #

Connect a signal handler for the focusIn signal, to be run before the default handler. When overloading is enabled, this is equivalent to

    on eventControllerKey #focusIn callback

## focusOut

type EventControllerKeyFocusOutCallback = IO () Source #

No description available in the introspection data.

afterEventControllerKeyFocusOut :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyFocusOutCallback) -> m SignalHandlerId Source #

Connect a signal handler for the focusOut signal, to be run after the default handler. When overloading is enabled, this is equivalent to

    after eventControllerKey #focusOut callback

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit `?self` parameter. Note that this requires activating the `ImplicitParams` GHC extension.

onEventControllerKeyFocusOut :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyFocusOutCallback) -> m SignalHandlerId Source #

Connect a signal handler for the focusOut signal, to be run before the default handler. When overloading is enabled, this is equivalent to

    on eventControllerKey #focusOut callback

## imUpdate

type EventControllerKeyImUpdateCallback = IO () Source #

No description available in the introspection data.

afterEventControllerKeyImUpdate :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyImUpdateCallback) -> m SignalHandlerId Source #

Connect a signal handler for the imUpdate signal, to be run after the default handler. When overloading is enabled, this is equivalent to

    after eventControllerKey #imUpdate callback

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit `?self` parameter. Note that this requires activating the `ImplicitParams` GHC extension.

onEventControllerKeyImUpdate :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyImUpdateCallback) -> m SignalHandlerId Source #

Connect a signal handler for the imUpdate signal, to be run before the default handler. When overloading is enabled, this is equivalent to

    on eventControllerKey #imUpdate callback

## keyPressed

type EventControllerKeyKeyPressedCallback Source #

Arguments

= Word32 | `keyval`: the pressed key.
-> Word32 | `keycode`: the raw code of the pressed key.
-> [ModifierType] | `state`: the bitmask, representing the state of modifier keys and pointer buttons. See `ModifierType`.
-> IO Bool | Returns: `True` if the key press was handled, `False` otherwise.

This signal is emitted whenever a key is pressed.

Since: 3.24

afterEventControllerKeyKeyPressed :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyKeyPressedCallback) -> m SignalHandlerId Source #

Connect a signal handler for the keyPressed signal, to be run after the default handler. When overloading is enabled, this is equivalent to

    after eventControllerKey #keyPressed callback

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit `?self` parameter. Note that this requires activating the `ImplicitParams` GHC extension.

onEventControllerKeyKeyPressed :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyKeyPressedCallback) -> m SignalHandlerId Source #

Connect a signal handler for the keyPressed signal, to be run before the default handler. When overloading is enabled, this is equivalent to

    on eventControllerKey #keyPressed callback

## keyReleased

type EventControllerKeyKeyReleasedCallback Source #

Arguments

= Word32 | `keyval`: the released key.
-> Word32 | `keycode`: the raw code of the released key.
-> [ModifierType] | `state`: the bitmask, representing the state of modifier keys and pointer buttons. See `ModifierType`.
-> IO () |

This signal is emitted whenever a key is released.

Since: 3.24

afterEventControllerKeyKeyReleased :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyKeyReleasedCallback) -> m SignalHandlerId Source #

Connect a signal handler for the keyReleased signal, to be run after the default handler. When overloading is enabled, this is equivalent to

    after eventControllerKey #keyReleased callback

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit `?self` parameter. Note that this requires activating the `ImplicitParams` GHC extension.

onEventControllerKeyKeyReleased :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyKeyReleasedCallback) -> m SignalHandlerId Source #

Connect a signal handler for the keyReleased signal, to be run before the default handler. When overloading is enabled, this is equivalent to

    on eventControllerKey #keyReleased callback

## modifiers

type EventControllerKeyModifiersCallback = [ModifierType] -> IO Bool Source #

No description available in the introspection data.

afterEventControllerKeyModifiers :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyModifiersCallback) -> m SignalHandlerId Source #

Connect a signal handler for the modifiers signal, to be run after the default handler. When overloading is enabled, this is equivalent to

    after eventControllerKey #modifiers callback

By default the object invoking the signal is not passed to the callback. If you need to access it, you can use the implit `?self` parameter. Note that this requires activating the `ImplicitParams` GHC extension.

onEventControllerKeyModifiers :: (IsEventControllerKey a, MonadIO m) => a -> ((?self :: a) => EventControllerKeyModifiersCallback) -> m SignalHandlerId Source #

Connect a signal handler for the modifiers signal, to be run before the default handler. When overloading is enabled, this is equivalent to

    on eventControllerKey #modifiers callback