Copyright | Will Thompson Iñaki García Etxebarria and Jonas Platte |
---|---|
License | LGPL-2.1 |
Maintainer | Iñaki García Etxebarria |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
The Accessible
class is the base class for accessible
implementations for Widget
subclasses. It is a thin
wrapper around Object
, which adds facilities for associating
a widget with its accessible object.
An accessible implementation for a third-party widget should
derive from Accessible
and implement the suitable interfaces
from ATK, such as Text
or Selection
. To establish
the connection between the widget class and its corresponding
acccessible implementation, override the get_accessible vfunc
in WidgetClass
.
Synopsis
- newtype Accessible = Accessible (ManagedPtr Accessible)
- class (GObject o, IsDescendantOf Accessible o) => IsAccessible o
- toAccessible :: (MonadIO m, IsAccessible o) => o -> m Accessible
- accessibleConnectWidgetDestroyed :: (HasCallStack, MonadIO m, IsAccessible a) => a -> m ()
- accessibleGetWidget :: (HasCallStack, MonadIO m, IsAccessible a) => a -> m (Maybe Widget)
- accessibleSetWidget :: (HasCallStack, MonadIO m, IsAccessible a, IsWidget b) => a -> Maybe b -> m ()
- clearAccessibleWidget :: (MonadIO m, IsAccessible o) => o -> m ()
- constructAccessibleWidget :: (IsAccessible o, MonadIO m, IsWidget a) => a -> m (GValueConstruct o)
- getAccessibleWidget :: (MonadIO m, IsAccessible o) => o -> m (Maybe Widget)
- setAccessibleWidget :: (MonadIO m, IsAccessible o, IsWidget a) => o -> a -> m ()
Exported types
newtype Accessible Source #
Memory-managed wrapper type.
Accessible (ManagedPtr Accessible) |
Instances
Eq Accessible Source # | |
Defined in GI.Gtk.Objects.Accessible (==) :: Accessible -> Accessible -> Bool # (/=) :: Accessible -> Accessible -> Bool # | |
GObject Accessible Source # | |
Defined in GI.Gtk.Objects.Accessible | |
ManagedPtrNewtype Accessible Source # | |
Defined in GI.Gtk.Objects.Accessible toManagedPtr :: Accessible -> ManagedPtr Accessible | |
TypedObject Accessible Source # | |
Defined in GI.Gtk.Objects.Accessible | |
HasParentTypes Accessible Source # | |
Defined in GI.Gtk.Objects.Accessible | |
IsGValue (Maybe Accessible) Source # | Convert |
Defined in GI.Gtk.Objects.Accessible gvalueGType_ :: IO GType gvalueSet_ :: Ptr GValue -> Maybe Accessible -> IO () gvalueGet_ :: Ptr GValue -> IO (Maybe Accessible) | |
type ParentTypes Accessible Source # | |
Defined in GI.Gtk.Objects.Accessible |
class (GObject o, IsDescendantOf Accessible o) => IsAccessible o Source #
Type class for types which can be safely cast to Accessible
, for instance with toAccessible
.
Instances
(GObject o, IsDescendantOf Accessible o) => IsAccessible o Source # | |
Defined in GI.Gtk.Objects.Accessible |
toAccessible :: (MonadIO m, IsAccessible o) => o -> m Accessible Source #
Cast to Accessible
, 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
addRelationship, bindProperty, bindPropertyFull, connectWidgetDestroyed, forceFloating, freezeNotify, getv, initialize, isFloating, notify, notifyByPspec, notifyStateChange, peekParent, ref, refAccessibleChild, refRelationSet, refSink, refStateSet, removePropertyChangeHandler, removeRelationship, runDispose, stealData, stealQdata, thawNotify, unref, watchClosure.
Getters
getAccessibleId, getAttributes, getData, getDescription, getIndexInParent, getLayer, getMdiZorder, getNAccessibleChildren, getName, getObjectLocale, getParent, getProperty, getQdata, getRole, getWidget.
Setters
setAccessibleId, setData, setDataFull, setDescription, setName, setParent, setProperty, setRole, setWidget.
connectWidgetDestroyed
accessibleConnectWidgetDestroyed Source #
:: (HasCallStack, MonadIO m, IsAccessible a) | |
=> a |
|
-> m () |
Deprecated: (Since version 3.4)Use accessibleSetWidget
and its vfuncs.
This function specifies the callback function to be called when the widget corresponding to a GtkAccessible is destroyed.
getWidget
:: (HasCallStack, MonadIO m, IsAccessible a) | |
=> a |
|
-> m (Maybe Widget) | Returns: pointer to the |
Gets the Widget
corresponding to the Accessible
.
The returned widget does not have a reference added, so
you do not need to unref it.
Since: 2.22
setWidget
:: (HasCallStack, MonadIO m, IsAccessible a, IsWidget b) | |
=> a |
|
-> Maybe b | |
-> m () |
Sets the Widget
corresponding to the Accessible
.
accessible
will not hold a reference to widget
.
It is the caller’s responsibility to ensure that when widget
is destroyed, the widget is unset by calling this function
again with widget
set to Nothing
.
Since: 2.22
Properties
widget
No description available in the introspection data.
clearAccessibleWidget :: (MonadIO m, IsAccessible o) => o -> m () Source #
Set the value of the “widget
” property to Nothing
.
When overloading is enabled, this is equivalent to
clear
#widget
constructAccessibleWidget :: (IsAccessible o, MonadIO m, IsWidget a) => a -> m (GValueConstruct o) Source #
Construct a GValueConstruct
with valid value for the “widget
” property. This is rarely needed directly, but it is used by new
.
getAccessibleWidget :: (MonadIO m, IsAccessible o) => o -> m (Maybe Widget) Source #
Get the value of the “widget
” property.
When overloading is enabled, this is equivalent to
get
accessible #widget
setAccessibleWidget :: (MonadIO m, IsAccessible o, IsWidget a) => o -> a -> m () Source #
Set the value of the “widget
” property.
When overloading is enabled, this is equivalent to
set
accessible [ #widget:=
value ]