| Copyright | Will Thompson and Iñaki García Etxebarria |
|---|---|
| License | LGPL-2.1 |
| Maintainer | Iñaki García Etxebarria |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
GI.Keybinder.Functions
Description
Synopsis
- bind :: (HasCallStack, MonadIO m) => Text -> Handler -> m Bool
- getCurrentEventTime :: (HasCallStack, MonadIO m) => m Word32
- init :: (HasCallStack, MonadIO m) => m ()
- setUseCookedAccelerators :: (HasCallStack, MonadIO m) => Bool -> m ()
- supported :: (HasCallStack, MonadIO m) => m Bool
- unbind :: (HasCallStack, MonadIO m) => Text -> m ()
Methods
bind
Arguments
| :: (HasCallStack, MonadIO m) | |
| => Text |
|
| -> Handler |
|
| -> m Bool | Returns: |
Grab a key combination globally and register a callback to be called each time the key combination is pressed.
Since: 0.3.0
getCurrentEventTime
Arguments
| :: (HasCallStack, MonadIO m) | |
| => m Word32 | Returns: the current event timestamp |
No description available in the introspection data.
init
init :: (HasCallStack, MonadIO m) => m () Source #
Initialize the keybinder library.
This function must be called after initializing GTK, before calling any other function in the library. Can only be called once.
setUseCookedAccelerators
setUseCookedAccelerators Source #
Arguments
| :: (HasCallStack, MonadIO m) | |
| => Bool |
|
| -> m () |
"Cooked" accelerators use symbols produced by using modifiers such as shift or altgr, for example if "!" is produced by "Shift+1".
If cooked accelerators are enabled, use "<Ctrl>exclam" to bind "Ctrl+!" If disabled, use "<Ctrl><Shift>1" to bind "Ctrl+Shift+1". These two examples are not equal on all keymaps.
The cooked accelerator keyvalue and modifiers are provided by the
function gdk_keymap_translate_keyboard_state()
Cooked accelerators are useful if you receive keystrokes from GTK to bind, but raw accelerators can be useful if you or the user inputs accelerators as text.
Default: Enabled. Should be set before binding anything.
supported
Arguments
| :: (HasCallStack, MonadIO m) | |
| => m Bool | Returns: TRUE if keybindings are supported |
No description available in the introspection data.