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 |
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 HotkeyProfileTriggerCallback = Word32 -> Ptr () -> IO ()
- afterHotkeyProfileTrigger :: (IsHotkeyProfile a, MonadIO m) => a -> Maybe Text -> ((?self :: a) => HotkeyProfileTriggerCallback) -> m SignalHandlerId
- onHotkeyProfileTrigger :: (IsHotkeyProfile a, MonadIO m) => a -> Maybe Text -> ((?self :: a) => HotkeyProfileTriggerCallback) -> m SignalHandlerId
Exported types
newtype HotkeyProfile Source #
Memory-managed wrapper type.
Instances
Eq HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile (==) :: HotkeyProfile -> HotkeyProfile -> Bool # (/=) :: HotkeyProfile -> HotkeyProfile -> Bool # | |
GObject HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile | |
ManagedPtrNewtype HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile | |
TypedObject HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile | |
HasParentTypes HotkeyProfile Source # | |
Defined in GI.IBus.Objects.HotkeyProfile | |
IsGValue (Maybe HotkeyProfile) Source # | Convert |
Defined in GI.IBus.Objects.HotkeyProfile gvalueGType_ :: IO GType # gvalueSet_ :: Ptr GValue -> Maybe HotkeyProfile -> IO () # gvalueGet_ :: Ptr GValue -> IO (Maybe 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
Click to display all available methods, including inherited ones
Methods
addHotkey, addHotkeyFromString, bindProperty, bindPropertyFull, copy, destroy, filterKeyEvent, forceFloating, freezeNotify, getv, isFloating, lookupHotkey, notify, notifyByPspec, ref, refSink, removeHotkey, removeHotkeyByEvent, removeQattachment, runDispose, serializeObject, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getData, getProperty, getQattachment, getQdata.
Setters
addHotkey
hotkeyProfileAddHotkey Source #
:: (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 #
:: (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 #
:: (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 #
:: (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
:: (HasCallStack, MonadIO m) | |
=> m HotkeyProfile | Returns: A newly allocated |
Creates a new HotkeyProfile
.
removeHotkey
hotkeyProfileRemoveHotkey Source #
:: (HasCallStack, MonadIO m, IsHotkeyProfile a) | |
=> a |
|
-> Word32 |
|
-> Word32 |
|
-> m Bool | Returns: |
Removes the hotkey for an HotkeyProfile
.
removeHotkeyByEvent
hotkeyProfileRemoveHotkeyByEvent Source #
:: (HasCallStack, MonadIO m, IsHotkeyProfile a) | |
=> a |
|
-> Word32 |
|
-> m Bool |
Removes the hotkey for an HotkeyProfile
by event.
Signals
trigger
type HotkeyProfileTriggerCallback Source #
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 -> ((?self :: a) => 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.
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.
onHotkeyProfileTrigger :: (IsHotkeyProfile a, MonadIO m) => a -> Maybe Text -> ((?self :: a) => 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.