| Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
|---|---|
| License | LGPL-2.1 |
| Maintainer | Iñaki García Etxebarria |
| Safe Haskell | None |
| Language | Haskell2010 |
GI.IBus.Objects.HotkeyProfile
Description
An opaque data type representing an IBusHotkeyProfile.
Synopsis
- newtype HotkeyProfile = HotkeyProfile (ManagedPtr HotkeyProfile)
- class (GObject o, IsDescendantOf HotkeyProfile o) => IsHotkeyProfile o
- toHotkeyProfile :: (MonadIO m, IsHotkeyProfile o) => o -> m HotkeyProfile
- hotkeyProfileAddHotkey :: (HasCallStack, MonadIO m, IsHotkeyProfile a) => a -> Word32 -> Word32 -> Word32 -> m Bool
- hotkeyProfileAddHotkeyFromString :: (HasCallStack, MonadIO m, IsHotkeyProfile a) => a -> Text -> Word32 -> m Bool
- hotkeyProfileFilterKeyEvent :: (HasCallStack, MonadIO m, IsHotkeyProfile a) => a -> Word32 -> Word32 -> Word32 -> Word32 -> Ptr () -> m Word32
- hotkeyProfileLookupHotkey :: (HasCallStack, MonadIO m, IsHotkeyProfile a) => a -> Word32 -> Word32 -> m Word32
- hotkeyProfileNew :: (HasCallStack, MonadIO m) => m HotkeyProfile
- hotkeyProfileRemoveHotkey :: (HasCallStack, MonadIO m, IsHotkeyProfile a) => a -> Word32 -> Word32 -> m Bool
- hotkeyProfileRemoveHotkeyByEvent :: (HasCallStack, MonadIO m, IsHotkeyProfile a) => a -> Word32 -> m Bool
- type C_HotkeyProfileTriggerCallback = Ptr () -> Word32 -> Ptr () -> Ptr () -> IO ()
- type HotkeyProfileTriggerCallback = Word32 -> Ptr () -> IO ()
- afterHotkeyProfileTrigger :: (IsHotkeyProfile a, MonadIO m) => a -> Maybe Text -> HotkeyProfileTriggerCallback -> m SignalHandlerId
- genClosure_HotkeyProfileTrigger :: MonadIO m => HotkeyProfileTriggerCallback -> m (GClosure C_HotkeyProfileTriggerCallback)
- mk_HotkeyProfileTriggerCallback :: C_HotkeyProfileTriggerCallback -> IO (FunPtr C_HotkeyProfileTriggerCallback)
- noHotkeyProfileTriggerCallback :: Maybe HotkeyProfileTriggerCallback
- onHotkeyProfileTrigger :: (IsHotkeyProfile a, MonadIO m) => a -> Maybe Text -> HotkeyProfileTriggerCallback -> m SignalHandlerId
- wrap_HotkeyProfileTriggerCallback :: HotkeyProfileTriggerCallback -> C_HotkeyProfileTriggerCallback
Exported types
newtype HotkeyProfile Source #
Memory-managed wrapper type.
Constructors
| HotkeyProfile (ManagedPtr HotkeyProfile) |
Instances
| Eq HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile | |
| GObject HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile | |
| ManagedPtrNewtype HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile Methods toManagedPtr :: HotkeyProfile -> ManagedPtr HotkeyProfile | |
| TypedObject HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile Methods glibType :: IO GType | |
| IsGValue HotkeyProfile Source # | Convert |
Defined in GI.IBus.Objects.HotkeyProfile | |
| HasParentTypes HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile | |
| type ParentTypes HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile | |
class (GObject o, IsDescendantOf HotkeyProfile o) => IsHotkeyProfile o Source #
Type class for types which can be safely cast to HotkeyProfile, for instance with toHotkeyProfile.
Instances
| (GObject o, IsDescendantOf HotkeyProfile o) => IsHotkeyProfile o Source # | |
Defined in GI.IBus.Objects.HotkeyProfile | |
toHotkeyProfile :: (MonadIO m, IsHotkeyProfile o) => o -> m HotkeyProfile Source #
Cast to HotkeyProfile, for types for which this is known to be safe. For general casts, use castTo.
Methods
Overloaded methods
addHotkey
hotkeyProfileAddHotkey Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHotkeyProfile a) | |
| => a |
|
| -> Word32 |
|
| -> Word32 |
|
| -> Word32 |
|
| -> m Bool | Returns: Always |
Adds a hotkey and its associated event to an HotkeyProfile.
addHotkeyFromString
hotkeyProfileAddHotkeyFromString Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHotkeyProfile a) | |
| => a |
|
| -> Text |
|
| -> Word32 |
|
| -> m Bool | Returns: FALSE if |
Adds a hotkey and its associated event to an HotkeyProfile.
The hotkey is in string format, such like
<constant>Control+Shift+A</constant>.
filterKeyEvent
hotkeyProfileFilterKeyEvent Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHotkeyProfile a) | |
| => a |
|
| -> Word32 |
|
| -> Word32 |
|
| -> Word32 |
|
| -> Word32 |
|
| -> Ptr () |
|
| -> m Word32 | Returns: 0 if releasing a hotkey and the hotkey is not in the profile; an associated event otherwise. See also: trigger |
Emits a <constant>[trigger](#g:signal:trigger)</constant> signal when a hotkey is in a profile.
lookupHotkey
hotkeyProfileLookupHotkey Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHotkeyProfile a) | |
| => a |
|
| -> Word32 |
|
| -> Word32 |
|
| -> m Word32 | Returns: The event associated to the hotkey or 0 if the hotkey is not in the profile. |
No description available in the introspection data.
new
Arguments
| :: (HasCallStack, MonadIO m) | |
| => m HotkeyProfile | Returns: A newly allocated |
Creates a new HotkeyProfile.
removeHotkey
hotkeyProfileRemoveHotkey Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHotkeyProfile a) | |
| => a |
|
| -> Word32 |
|
| -> Word32 |
|
| -> m Bool | Returns: |
Removes the hotkey for an HotkeyProfile.
removeHotkeyByEvent
hotkeyProfileRemoveHotkeyByEvent Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHotkeyProfile a) | |
| => a |
|
| -> Word32 |
|
| -> m Bool | Returns: |
Removes the hotkey for an HotkeyProfile by event.
Signals
trigger
type C_HotkeyProfileTriggerCallback = Ptr () -> Word32 -> Ptr () -> Ptr () -> IO () Source #
Type for the callback on the (unwrapped) C side.
type HotkeyProfileTriggerCallback Source #
Arguments
| = Word32 |
|
| -> Ptr () |
|
| -> IO () |
Emitted when a hotkey is pressed and the hotkey is in profile.
Implement the member function trigger() in extended class to receive this signal.
<note><para>The last parameter, user_data is not actually a valid parameter. It is displayed because of GtkDoc bug.</para></note>
afterHotkeyProfileTrigger :: (IsHotkeyProfile a, MonadIO m) => a -> Maybe Text -> HotkeyProfileTriggerCallback -> m SignalHandlerId Source #
Connect a signal handler for the trigger signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after hotkeyProfile #trigger callback
This signal admits a optional parameter detail.
If it's not Nothing, we will connect to “trigger::detail” instead.
genClosure_HotkeyProfileTrigger :: MonadIO m => HotkeyProfileTriggerCallback -> m (GClosure C_HotkeyProfileTriggerCallback) Source #
Wrap the callback into a GClosure.
mk_HotkeyProfileTriggerCallback :: C_HotkeyProfileTriggerCallback -> IO (FunPtr C_HotkeyProfileTriggerCallback) Source #
Generate a function pointer callable from C code, from a C_HotkeyProfileTriggerCallback.
noHotkeyProfileTriggerCallback :: Maybe HotkeyProfileTriggerCallback Source #
A convenience synonym for .Nothing :: Maybe HotkeyProfileTriggerCallback
onHotkeyProfileTrigger :: (IsHotkeyProfile a, MonadIO m) => a -> Maybe Text -> HotkeyProfileTriggerCallback -> m SignalHandlerId Source #
Connect a signal handler for the trigger signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on hotkeyProfile #trigger callback
This signal admits a optional parameter detail.
If it's not Nothing, we will connect to “trigger::detail” instead.