An interface for accessible objects containing formatted text.
The <GtkAccessibleText> interfaces is meant
to be implemented by accessible objects that have text formatted with
attributes, or non-trivial text contents.
You should use the Gtk.AccessibleProperty.LABEL or the
Gtk.AccessibleProperty.DESCRIPTION properties for accessible
objects containing simple, unformatted text.
Updates the position of the caret.
Implementations of the <GtkAccessibleText>
interface should call this function every time the caret has moved, in
order to notify assistive technologies.
Passed: a <GtkAccessibleText>.
the accessible object
Notifies assistive technologies of a change in contents.
Implementations of the <GtkAccessibleText>
interface should call this function every time their contents change as
the result of an operation, like an insertion or a removal.
Note: If the change is a deletion, this function must be called before removing the contents, if it is an insertion, it must be called after inserting the new contents.
Passed: a <GtkAccessibleText>.
the accessible object
Passed: a
<GtkAccessibleTextContentChange>,
or one of its symbols.
the type of change in the contents
Passed: an unsigned 32-bit integer.
the starting offset of the change, in characters
Passed: an unsigned 32-bit integer.
the end offset of the change, in characters
Updates the boundary of the selection.
Implementations of the <GtkAccessibleText>
interface should call this function every time the selection has moved,
in order to notify assistive technologies.
Passed: a <GtkAccessibleText>.
the accessible object
Retrieves the position of the caret inside the accessible object.
To override it in a new class, give register-type #:vfuncs
`((get-caret-position . ,procedure)). The procedure is called as
(procedure self) ⇒ %return.
Passed: the class whose implementation to call: a class that implements
<GtkAccessibleText>, or its GType number.
Passed: a <GtkAccessibleText>.
the accessible object
Returned: an unsigned 32-bit integer.
the position of the caret, in characters
Retrieve the current contents of the accessible object within the given range.
If end is G_MAXUINT, the end of the range is the full
content of the accessible object.
To override it in a new class, give register-type #:vfuncs
`((get-contents . ,procedure)). The procedure is called as
(procedure self start end) ⇒ %return.
Passed: the class whose implementation to call: a class that implements
<GtkAccessibleText>, or its GType number.
Passed: a <GtkAccessibleText>.
the accessible object
Passed: an unsigned 32-bit integer.
the beginning of the range, in characters
Passed: an unsigned 32-bit integer.
the end of the range, in characters
Returned: a <GBytes>.
the requested slice of the contents of the accessible object, as UTF-8. Note that the slice does not have to be NUL-terminated
Retrieve the current contents of the accessible object starting from the given offset, and using the given granularity.
The start and end values contain the boundaries of the text.
To override it in a new class, give register-type #:vfuncs
`((get-contents-at . ,procedure)). The procedure is called as
(procedure self offset granularity) ⇒ %return start end.
Passed: the class whose implementation to call: a class that implements
<GtkAccessibleText>, or its GType number.
Passed: a <GtkAccessibleText>.
the accessible object
Passed: an unsigned 32-bit integer.
the offset, in characters
Passed: a
<GtkAccessibleTextGranularity>,
or one of its symbols.
the granularity of the query
Returned: a <GBytes>.
the requested slice of the contents of the accessible object, as UTF-8. Note that the slice does not have to be NUL-terminated
Returned: an unsigned 32-bit integer.
the start of the range, in characters
Returned: an unsigned 32-bit integer.
the end of the range, in characters
Retrieves the default text attributes inside the accessible object.
Each attribute is composed by:
It is left to the implementation to determine the serialization format of the value to a string.
GTK provides support for various text attribute names and values, but implementations of this interface are free to add their own attributes.
To override it in a new class, give register-type #:vfuncs
`((get-default-attributes . ,procedure)). The procedure is called as
(procedure self) ⇒ attribute-names attribute-values.
Passed: the class whose implementation to call: a class that implements
<GtkAccessibleText>, or its GType number.
Passed: a <GtkAccessibleText>.
the accessible object
Returned: a vector, each a string.
the names of the default attributes inside the accessible object
Returned: a vector, each a string.
the values of the default attributes inside the accessible object
Obtains the extents of a range of text, in widget coordinates.
To override it in a new class, give register-type #:vfuncs
`((get-extents . ,procedure)). The procedure is called as
(procedure self start end extents) ⇒ %return.
Passed: the class whose implementation to call: a class that implements
<GtkAccessibleText>, or its GType number.
Passed: a <GtkAccessibleText>.
the accessible object
Passed: an unsigned 32-bit integer.
the start offset, in characters
Passed: an unsigned 32-bit integer.
the end offset, in characters, extents (out caller-allocates): return location for the extents
Passed: a <GrapheneRect>.
Returned: a boolean.
true if the extents were filled in, false otherwise
Gets the text offset at a given point.
To override it in a new class, give register-type #:vfuncs
`((get-offset . ,procedure)). The procedure is called as
(procedure self point) ⇒ %return offset.
Passed: the class whose implementation to call: a class that implements
<GtkAccessibleText>, or its GType number.
Passed: a <GtkAccessibleText>.
the accessible object
Passed: a <GraphenePoint>.
a point in widget coordinates of self
Returned: a boolean.
true if the offset was set, false otherwise
Returned: an unsigned 32-bit integer.
return location for the text offset at point
Sets the caret position.
To override it in a new class, give register-type #:vfuncs
`((set-caret-position . ,procedure)). The procedure is called as
(procedure self offset) ⇒ %return.
Passed: the class whose implementation to call: a class that implements
<GtkAccessibleText>, or its GType number.
Passed: a <GtkAccessibleText>.
the accessible object
Passed: an unsigned 32-bit integer.
the text offset in characters
Returned: a boolean.
true if the caret position was updated