| 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.Atk.Interfaces.Hypertext
Description
The ATK interface which provides standard mechanism for manipulating hyperlinks.
An interface used for objects which implement linking between multiple resource or content locations, or multiple 'markers' within a single document. A Hypertext instance is associated with one or more Hyperlinks, which are associated with particular offsets within the Hypertext's included content. While this interface is derived from Text, there is no requirement that Hypertext instances have textual content; they may implement Image as well, and Hyperlinks need not have non-zero text offsets.
Synopsis
- newtype Hypertext = Hypertext (ManagedPtr Hypertext)
- class (GObject o, IsDescendantOf Hypertext o) => IsHypertext o
- toHypertext :: (MonadIO m, IsHypertext o) => o -> m Hypertext
- type family ResolveHypertextMethod (t :: Symbol) o where ...
- data HypertextGetLinkMethodInfo
- hypertextGetLink :: (HasCallStack, MonadIO m, IsHypertext a) => a -> Int32 -> m Hyperlink
- data HypertextGetLinkIndexMethodInfo
- hypertextGetLinkIndex :: (HasCallStack, MonadIO m, IsHypertext a) => a -> Int32 -> m Int32
- data HypertextGetNLinksMethodInfo
- hypertextGetNLinks :: (HasCallStack, MonadIO m, IsHypertext a) => a -> m Int32
- type HypertextLinkSelectedCallback = Int32 -> IO ()
- data HypertextLinkSelectedSignalInfo
- afterHypertextLinkSelected :: (IsHypertext a, MonadIO m) => a -> ((?self :: a) => HypertextLinkSelectedCallback) -> m SignalHandlerId
- onHypertextLinkSelected :: (IsHypertext a, MonadIO m) => a -> ((?self :: a) => HypertextLinkSelectedCallback) -> m SignalHandlerId
Exported types
Memory-managed wrapper type.
Constructors
| Hypertext (ManagedPtr Hypertext) |
Instances
class (GObject o, IsDescendantOf Hypertext o) => IsHypertext o Source #
Type class for types which can be safely cast to Hypertext, for instance with toHypertext.
Instances
| (GObject o, IsDescendantOf Hypertext o) => IsHypertext o Source # | |
Defined in GI.Atk.Interfaces.Hypertext | |
toHypertext :: (MonadIO m, IsHypertext o) => o -> m Hypertext Source #
Methods
Click to display all available methods, including inherited ones
Methods
bindProperty, bindPropertyFull, forceFloating, freezeNotify, getv, isFloating, notify, notifyByPspec, ref, refSink, runDispose, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getData, getLink, getLinkIndex, getNLinks, getProperty, getQdata.
Setters
type family ResolveHypertextMethod (t :: Symbol) o where ... Source #
Equations
getLink
data HypertextGetLinkMethodInfo Source #
Instances
| (signature ~ (Int32 -> m Hyperlink), MonadIO m, IsHypertext a) => OverloadedMethod HypertextGetLinkMethodInfo a signature Source # | |
Defined in GI.Atk.Interfaces.Hypertext Methods overloadedMethod :: a -> signature # | |
| OverloadedMethodInfo HypertextGetLinkMethodInfo (a :: Type) Source # | |
Defined in GI.Atk.Interfaces.Hypertext Methods | |
Arguments
| :: (HasCallStack, MonadIO m, IsHypertext a) | |
| => a |
|
| -> Int32 |
|
| -> m Hyperlink | Returns: the link in this hypertext document at
index |
Gets the link in this hypertext document at index
linkIndex
getLinkIndex
data HypertextGetLinkIndexMethodInfo Source #
Instances
| (signature ~ (Int32 -> m Int32), MonadIO m, IsHypertext a) => OverloadedMethod HypertextGetLinkIndexMethodInfo a signature Source # | |
Defined in GI.Atk.Interfaces.Hypertext Methods overloadedMethod :: a -> signature # | |
| OverloadedMethodInfo HypertextGetLinkIndexMethodInfo (a :: Type) Source # | |
Defined in GI.Atk.Interfaces.Hypertext Methods | |
hypertextGetLinkIndex Source #
Arguments
| :: (HasCallStack, MonadIO m, IsHypertext a) | |
| => a |
|
| -> Int32 |
|
| -> m Int32 | Returns: an index into the array of hyperlinks in |
Gets the index into the array of hyperlinks that is associated with
the character specified by charIndex.
getNLinks
data HypertextGetNLinksMethodInfo Source #
Instances
| (signature ~ m Int32, MonadIO m, IsHypertext a) => OverloadedMethod HypertextGetNLinksMethodInfo a signature Source # | |
Defined in GI.Atk.Interfaces.Hypertext Methods overloadedMethod :: a -> signature # | |
| OverloadedMethodInfo HypertextGetNLinksMethodInfo (a :: Type) Source # | |
Defined in GI.Atk.Interfaces.Hypertext Methods | |
Arguments
| :: (HasCallStack, MonadIO m, IsHypertext a) | |
| => a |
|
| -> m Int32 | Returns: the number of links within this hypertext document |
Gets the number of links within this hypertext document.
Signals
linkSelected
type HypertextLinkSelectedCallback Source #
The "link-selected" signal is emitted by an AtkHyperText object when one of the hyperlinks associated with the object is selected.
data HypertextLinkSelectedSignalInfo Source #
Instances
| SignalInfo HypertextLinkSelectedSignalInfo Source # | |||||
Defined in GI.Atk.Interfaces.Hypertext Associated Types
Methods connectSignal :: GObject o => o -> (o -> HaskellCallbackType HypertextLinkSelectedSignalInfo) -> SignalConnectMode -> Maybe Text -> IO SignalHandlerId # | |||||
| type HaskellCallbackType HypertextLinkSelectedSignalInfo Source # | |||||
afterHypertextLinkSelected :: (IsHypertext a, MonadIO m) => a -> ((?self :: a) => HypertextLinkSelectedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the linkSelected signal, to be run after the default handler. When overloading is enabled, this is equivalent to
after hypertext #linkSelected 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.
onHypertextLinkSelected :: (IsHypertext a, MonadIO m) => a -> ((?self :: a) => HypertextLinkSelectedCallback) -> m SignalHandlerId Source #
Connect a signal handler for the linkSelected signal, to be run before the default handler. When overloading is enabled, this is equivalent to
on hypertext #linkSelected callback