The UNO Accessibility API (also called UAA in the following) is modeled closely after Java Accessibility API in version 1.4 and the the Gnome Accessibility API. The UAA is part of the offapi project. You can browse the CVS archive at com/sun/star/accessibility or have a look at the documentation here.
The UAA represents both structure and content of the GUI. Here GUI included the views of documents that are embedded therein.
Each top-level window of the GUI is represented as a tree of accessibility objects. Each accessibility object stands for one GUI element or one object of a document view:
This tree structure is realized by implementing the
XAccessibleContext
interface. To go up
towards the root of a tree you can get an object's parent. To go down
towards the leaves of a tree you can retrieve all the children of an
object.
XAccessibleContext
interface. Relation sets as
returned by the XAccessibleContext::getAccessibleRelationSet()
are defined
by the XAccessibleRelationSet
interface.
Each node of the tree that implements XAccessibleContext
gives access to different
facets of the represented GUI element or document part. These are
AccessibleRole
collection of
constants there is a set of predefined roles that is suitable for the elements
of the GUI whereas there are no (not yet) roles for the direct support of the
document.AccessibleStateType
constants collection can be for example
"active", "hidden", or "checked". Again there is a predefined set of states
suitable for GUI elements but maybe not sufficient to represent states of
document parts.AccessibleRole
service. In general there should be as few
actions as possible. It is better to offer additional functionality through
the clasical means of the GUI.XAccessibleComponent
interface.
It can be queried for instance for its bounding-box or for the child node at a
given point on the screen.XAccessibleText
(read
only) and XAccessibleEditableText
. There is also the interface
XAccessibleHypertext
for texts that contain
hyperlinks.XAccessibleTable
.XAccessibleImage
.XAccessibleValue
interface.The tree modeled by the UAA is not a static data
structure. Because of scrolling the document window, changing its content, or
modifying the contents of GUI controls, the structure and content of single
nodes and sub-trees is constantly changing. These changes are notified to the
AT by sending events to registered listeners (among them the AT). The kind of
event that is sent for a specific change depends on the UAA interfaces that
the node that represents the modified object does support and on the actual
implementation of these interfaces. Listeners to accessibility events
implement the XAccessibleEventListener
interface while broadcasters
implement the
XAccessibleEventBroadcaster
interface.
Events are AccessibleEventObject
structures, their types
are described in the AccessibleEventId
constants group.
The XAccessible
interface allows the decoupling
of the implementation of the UAA from the implementation of the rest of
the UNO API. Its only method, getAccessibleContext()
,
returns
an object that implements the AccessibleContext
service.
This may or may not be done by a class other than the one that implements the
XAccessible
interface. This has the big advantage, that the
existing API implementation needs only minimal modifications.
Java interfaces AccessibleComponent
and AccessibleExtendedComponent
have been rearranged into the UAA interfaces XAccessibleComponent
and XAccessibleExtendedComponent
.
Java interfaces AccessibleTable
and
AccessibleExtendedTable
have been merged into the single
UNO interface XAccessibleTable
.
Java interfaces AccessibleText
and
AccessibleEditableText
have been rearranged into the UAA interfaces XAccessibleText
and XAccessibleEditableText
to better reflect the read only and
read/write access to text.
The Java class AccessibleBundle
is not supported, because it is
not necessary in the UNO environment.
The Java class AccessibleResourceBundle
is not supported, because it
is deprecated in the Java API.
The Java classes AccessibleRelation
,
AccessibleRole
, and AccessibleState
are realized
by UNO constants collections
AccessibleRelationType
, AccessibleRole
, and AccessibleStateType
due to different API designs.
The Java interface AccessibleIcon
has been renamed into
the UNO interface XAccessibleImage
to represent its more general approach.
The methods of the Java class AccessibleHyperlink
regarding actions have been
removed. Instead the UNO service AccessibleHyperlink
supports
in addition to the interface XAccessibleHyperlink
also the
XAccessibleAction
interface.
More details of the UAA can be found in the API reference.
The services that expose application specific details of the UAA can be found here for the GUI, Writer, Calc, Draw/Impress, and Chart.