Carbon Accessibility Reference

Framework
ApplicationServices/HIServices.h, Carbon/HIToolbox.h
Declared in
AXActionConstants.h
AXAttributeConstants.h
AXNotificationConstants.h
AXRoleConstants.h
AXValueConstants.h
CarbonEvents.h
HIAccessibility.h

Overview

This document describes the Carbon accessibility API. You use this API to make your Carbon application accessible to assistive applications and technologies, a process called access enabling.

Who Should Read This Document?

All Carbon application developers should read this document for information on specific functions and constants they may need to access-enable their applications. If you’re unsure which parts of the Carbon accessibility API you need, or if you’re new to accessibility in OS X, be sure to read the documents listed in “See Also.”

Organization of This Document

This document contains API reference in the following sections:

See Also

For more information on accessibility in general and access enabling Carbon applications in particular, you should read the following documents:

Functions

This section describes the functions some Carbon developers may need to use to access-enable their applications.

AXNotificationHIObjectNotify

Posts a notification for an accessibility object.

void AXNotificationHIObjectNotify (
   CFStringRef inNotification,
   HIObjectRef inHIObject,
   UInt64 inIdentifier
);
Parameters
inNotification

The string containing the name of the notification to broadcast.

inHIObject

The HIObjectRef portion of the accessibility object for which this notification applies.

inIdentifier

The 64-bit identifier portion of the accessibility object for which this notification applies.

Discussion

You use the AXNotificationHIObjectNotify function to broadcast changes in an accessibility object to assistive applications. For example, an accessibility object may want to broadcast that the window it represents has moved, or that an attribute value has changed. See “Notifications” for a list of possible notification constants. Note that accessibility objects representing standard user interface elements automatically send out notifications. In general, you do not need to post your own notifications unless you implement custom user interface elements.

Availability
  • Available in OS X version 10.2 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

AXUIElementCreateWithHIObjectAndIdentifier

Creates an accessibility object that represents a user interface element.

AXUIElementRef AXUIElementCreateWithHIObjectAndIdentifier (
   HIObjectRef inHIObject,
   UInt64 inIdentifier
);
Parameters
inHIObject

A reference to the user interface element this accessibility object represents. You must pass one of the following reference types: WindowRef, ControlRef, MenuRef, or an HIObjectRef.

inIdentifier

A 64-bit identifier to uniquely identify the accessibility object within the user interface element. Pass 0 to indicate the base object identified by the inHIObject parameter.

Return Value

The newly created accessibility object.

Discussion

If the accessibility object represents part of the substructure of a user interface element, then you must assign it a unique, nonzero identifier value. If the accessibility object represents a complex user interface object as a whole, you must give it the identifier value 0. For example, a segmented view containing five buttons can have six accessibility objects associated with it:

  • The segmented view as a whole, identified by its control reference (ControlRef) and identifier value 0.

  • The five button elements, identified by the segmented view reference and identifiers 1 through 5, respectively.

The accessibility object is a CFTypeRef object. You can use CFEqual to compare two accessibility objects. You must call CFRelease on the accessibility object when you no longer need it.

Availability
  • Available in OS X version 10.2 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

AXUIElementGetHIObject

Gets the user interface element the given accessibility object represents.

HIObjectRef AXUIElementGetHIObject (
   AXUIElementRef inUIElement
);
Parameters
inHIAccObj

The accessibility object whose user interface element you want to get.

Return Value

A reference to the user interface element associated with the passed-in accessibility object (or NULL if inHIAccObj is not a valid accessibility object).

Availability
  • Available in OS X version 10.2 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

AXUIElementGetIdentifier

Gets the unique identifier associated with an accessibility object.

void AXUIElementGetIdentifier (
   AXUIElementRef inUIElement,
   UInt64 *outIdentifier
);
Parameters
inHIAccObj

The accessibility object whose identifier you want to get.

outIdentifier

A pointer to a 64-bit integer. On return, outIdentifier contains the accessibility object’s identifier. If inHIAccObj is not a valid accessibility object, this function returns 0. Note that 0 is a valid identifier value, so you should not assume that inHIAccObj is invalid if you receive a 0 result.

Discussion

If you create your own accessibility objects to represent custom user interface elements or subviews, you can use the identifier this function returns to identify which accessibility object is being referenced.

Availability
  • Available in OS X version 10.2 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

HICopyAccessibilityActionDescription

Returns the system-defined action description string for a standard action.

CFStringRef HICopyAccessibilityActionDescription (
   CFStringRef inAction
);
Parameters
inAction

The action for which you want the system-defined description. See “Actions” for the action strings you can use.

Return Value

The system-defined description for the action. When you are finished with the CFString containing the description, you must use CFRelease to release it. If you pass in an unsupported action, the results are undefined.

Discussion

The HICopyAccessibilityActionDescription function is a convenience function you can use to get the current, system-defined action description for a given action. If you create an accessibility object that supports an action, you must supply the action description. Using this function allows you to take advantage of any changes or enhancements Apple might make.

Availability
  • Available in OS X version 10.4 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

HICopyAccessibilityRoleDescription

Returns the system-defined role description string for a standard role or role-subrole pair.

CFStringRef HICopyAccessibilityRoleDescription (
   CFStringRef inRole,
   CFStringRef inSubrole
);
Parameters
inRole

The role for which you want the system-defined description. See “Roles” for the role strings you can use.

inSubrole

The subrole for which you want the system-defined description. See “Subroles” for the subrole strings you can use. Pass NULL if your accessible object does not have a subrole.

Return Value

The system-defined description for the role or role-subrole pair. When you are finished with the CFString containing the description, you must use CFRelease to release it. If there is no system-defined role description associated with the role or role-subrole pair you pass in, this function returns NULL. If you pass in an unknown role or an unknown subrole, this function returns NULL.

Discussion

The HICopyAccessibilityRoleDescription function is a convenience function you can use if you have to provide the role description for an accessibility object you create. Instead of hard-coding a role description for an accessibility object, you should use this function to get the current, system-defined role description. This allows you to take advantage of any changes or enhancements Apple might make.

Availability
  • Available in OS X version 10.4 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

HIObjectIsAccessibilityIgnored

Returns whether the given HIObject is marked as ignored for accessibility purposes.

Boolean HIObjectIsAccessibilityIgnored (
   HIObjectRef inObject
);
Parameters
inObject

The object whose accessibility ignored state you wish to query.

Return Value

A Boolean value indicating whether the HIObject is ignored for accessibility purposes.

Availability
  • Available in OS X version 10.2 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

HIObjectOverrideAccessibilityContainment

Allows you to override the accessibility objects an HIObject would usually supply as the values of its kAXParentAttribute, kAXWindowAttribute, and kAXTopLevelUIElementAttribute attributes.

OSStatus HIObjectOverrideAccessibilityContainment (
   HIObjectRef inHIObject,
   AXUIElementRef inDesiredParent,
   AXUIElementRef inDesiredWindow,
   AXUIElementRef inDesiredTopLevelUIElement
);
Parameters
inHIObject

The HIObjectRef whose parent attribute you want to override.

inDesiredParent

The AXUIElementRef that you want the given HIObject to return as the value of its kAXParentAttribute attribute. This function makes a copy of the AXUIElementRef and you must release the inDesiredParent parameter after you call this function. Passing NULL in this parameter indicates you do not want the HIObject to override the value of its kAXParentAttribute attribute.

inDesiredWindow

The AXUIElementRef that you want the given HIObject to return as the value of its kAXWindowAttribute attribute. This function makes a copy of the AXUIElementRef and you must release the inDesiredWindow parameter after you call this function. Passing NULL in this parameter indicates you do not want the HIObject to override the value of its kAXWindowAttribute attribute (if the value exists).

inDesiredTopLevelUIElement

The AXUIElementRef that you want the given HIObject to return as the value of its kAXTopLevelUIElementAttribute attribute. This function makes a copy of the AXUIElementRef and you must release the inDesiredTopLevelUIElement parameter after you call this function. Passing NULL in this parameter indicates you do not want the HIObject to override the value of its kAXTopLevelUIElementAttribute attribute (if the value exists).

Return Value

An OSStatus result code. If the HIObjectRef is invalid, this function returns paramErr.

Discussion

This function allows you to change the parent that the given HIObject would usually supply to the accessibility hierarchy. For example, you might call this function on the menu of a pop-up control to ensure that the menu returns the pop-up control as its parent (rather than the application). Optionally, this function also allows you to change the window and top-level accessibility object the given HIObject would supply.

If the input HIObject is a standard toolbox object, such as an HIView or a menu, the input HIObject will not be included as an accessibility child of its normal parent. In all other cases, it is the client’s responsibility to ensure that the input HIObject is not included as an accessibility child of its normal parent.

If the desired AXUIElementRef parent represents an HIView, a menu, or a window, the input HIObject will be included automatically as an accessibility child of the specified parent. In all other cases, it is the client’s responsibility to manually include the input HIObject as an accessibility child of the specified parent. To represent an HIView, a menu, or a window, an AXUIElementRef must contain the appropriate HIObjectRef, as well as an identifier value of 0.

Note that similar rules don’t apply to the handling of the window and top-level element attributes, because those attributes don’t represent two-way relationships.

Not every type of HIObject supports a containment override; currently, HIViews, menus, and windows support containment overrides.

Availability
  • Available in OS X version 10.4 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

HIObjectSetAccessibilityIgnored

Marks an HIObject as ignored or unignored for accessibility purposes.

OSStatus HIObjectSetAccessibilityIgnored (
   HIObjectRef inObject,
   Boolean inIgnored
);
Parameters
inObject

The object whose accessibility ignored state you wish to change.

inIgnored

A Boolean value indicating whether to ignore the object (TRUE) or not (FALSE).

Return Value

An OSStatus signifying success or failure.

Discussion

An ignored HIObject is not shown to an assistive application that uses the accessibility APIs to examine the interface of your application. Your application’s accessibility implementation should still report an ignored HIObject as usual. The Carbon accessibility implementation automatically hides ignored HIObjects from assistive applications.

Note: By default, an HIObject is not ignored.

Availability
  • Available in OS X version 10.2 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

HIObjectSetAuxiliaryAccessibilityAttribute

Associates an additional accessibility attribute with an accessibility object (a UIElement) that is used to represent a given HIObject or part thereof.

OSStatus HIObjectSetAuxiliaryAccessibilityAttribute (
   HIObjectRef inHIObject,
   UInt64 inIdentifier,
   CFStringRef inAttributeName,
   CFTypeRef inAttributeData
);
Parameters
inHIObject

The HIObjectRef portion of the object-identifier pair to which the attribute data is associated.

inIdentifier

The 64-bit identifier portion of the object-identifier pair to which the attribute data is associated. Pass 0 in this parameter when you want to associate the attribute data to the HIObject as a whole. You might do this if, for example, you want to give a description attribute to the object representing a button.

inAttributeName

A CFStringRef of the name of the attribute. This string is retained before it is added to the auxiliary attribute storage area.

inAttributeData

A CFTypeRef containing the data supplied for the attribute’s value. This data is retained before it is added to the auxiliary attribute storage area; you may release this data after calling this function. If you pass NULL in this parameter, it indicates that the named auxiliary attribute should no longer be associated with the object-identifier pair and any named attribute data previously associated with the object-identifier pair will be released.

Return Value

An OSStatus result code. The function returns noErr if it was able to associate the attribute data with the HIObject. If the HIObjectRef is invalid, paramErr is returned.

Discussion

This function allows your application to provide the name of and data for an accessibility attribute you want to add to the UIElement that represents a given HIObject-identifier pair. Normally, accessibility attributes are only supplied dynamically through Carbon events, but this function allows you to supply them statically.

This function only allows you to associate attributes whose values never change. If you need to supply attribute whose values are determined dynamically or whose values are settable, you must install the necessary Carbon accessibility event handlers. See Accessibility Programming Guidelines for Carbon for more information about how this works.

This function is particularly useful for supplying the values of the kAXDescriptionAttribute, kAXTitleUIElementAttribute, kAXServesAsTitleForUIElementsAttribute, kAXLinkedUIElementsAttribute attributes and other attributes whose values are specific to the layout and usage of your application.

The auxiliary attribute store (containing attribute values you supply using this function) is consulted during the HIObject’s default handling of the Carbon accessibility attribute events. Therefore, any programmatic handling of a given accessibility attribute has the opportunity to override or block the consultation of the store. In general, if the toolbox or a Carbon event handler can provide the attribute value some other way, the store is not consulted.

Availability
  • Available in OS X version 10.4 and later.
  • Not available to 64-bit applications.
Declared In
HIAccessibility.h

Constants

This section describes the constants that define accessibility events and aspects of accessibility objects. The accessibility event constants are defined in CarbonEvents.h in the Carbon framework. The accessibility object constants are defined in header files in the ApplicationServices framework.

Accessibility Events

Accessibility Event Constants

Define accessibility events (kEventClassAccessibility).

enum
{
   kEventAccessibleGetChildAtPoint = 1,
   kEventAccessibleGetFocusedChild = 2,
   kEventAccessibleGetAllAttributeNames = 21,
   kEventAccessibleGetAllParameterizedAttributeNames = 25,
   kEventAccessibleGetNamedAttribute = 22,
   kEventAccessibleSetNamedAttribute = 23,
   kEventAccessibleIsNamedAttributeSettable = 24,
   kEventAccessibleGetAllActionNames = 41,
   kEventAccessiblePerformNamedAction = 42,
   kEventAccessibleGetNamedActionDescription = 44
};
Constants
kEventAccessibleGetChildAtPoint

A request sent by an assistive application to get the accessible child of the given accessibility object that contains the given point. The kEventParamMouseLocation parameter contains the location in global coordinates.

If you handle this event, you use the kEventParamAccessibleChild parameter to return an accessible first-order child of the accessibility object receiving the event. If there is no child at the given point, your handler should leave the kEventParamAccessibleChild parameter empty and return noErr. You must not set the kEventParamAccessibleChild parameter to a grandchild or more distant descendant of the accessible object receiving this event.

Declared in HIAccessibility.h.

Available in OS X version 10.2 and later.

kEventAccessibleGetFocusedChild

A request sent by an assistive application to get the accessible child of the given accessibility object that is part of the focus chain.

If you handle this event, you set the kEventParamAccessibleChild parameter to a first-order, accessible child that is focused or is the ancestor of a focused object. If there is no child in the focus chain, your handler should leave the kEventParamAccessibleChild parameter empty and return noErr. You must not set the kEventParamAccessibleChild parameter to a grandchild or more distant descendant of the accessible object receiving this event.

Declared in HIAccessibility.h.

Available in OS X version 10.2 and later.

kEventAccessibleGetAllAttributeNames

A request sent by an assistive application to get the names of all attributes the given accessibility object supports.

If you handle this event, you create a CFString object for the name of each non-parameterized attribute and add it to the mutable array in the kEventParamAccessibleAttributeNames parameter. If the accessibility object receiving the event supports parameterized attributes, you return them in the handler for the kEventAccessibleGetAllParameterizedAttributeNames event.

Declared in HIAccessibility.h.

Available in OS X version 10.2 and later.

kEventAccessibleGetAllParameterizedAttributeNames

A request sent by an assistive application to get the names of all parameterized attributes the given accessibility object supports.

If you handle this event, you create a CFString object for the name of each parameterized attribute and add it to the mutable array in the kEventParamAccessibleAttributeNames parameter. You must not return any regular, non-parameterized attribute names with this event. Instead, return regular attribute names in the handler for the kEventAccessibleGetAllAttributeNames event.

Declared in HIAccessibility.h.

Available in OS X version 10.3 and later.

kEventAccessibleGetNamedAttribute

A request sent by an assistive application to get the value of the given attribute.

If you handle this event, you determine if the given accessibility object supports the attribute named in the kEventParamAccessibleAttributeName parameter. If it does, you return the attribute’s value in the kEventParamAccessibleAttributeValue parameter. If the accessibility object does not support the attribute, return the eventNotHandledErr error. The type of the kEventParamAccessibleAttributeValue parameter varies with the type of the attribute’s value.

This event may also include the optional kEventParamAccessibleAttributeParameter parameter that describes the parameters of a parameterized attribute. Note that parameterized attributes were introduced in OS X version 10.3.

Declared in HIAccessibility.h.

Available in OS X version 10.2 and later.

kEventAccessibleSetNamedAttribute

A request sent by an assistive application to set the value of the given attribute to the passed-in value.

If you handle this event, you determine if the given accessibility object supports the attribute named in the kEventParamAccessibleAttributeName parameter and if the attribute is settable. Then, you set the named attribute’s value to the value supplied in the kEventParamAccessibleAttributeValue parameter. If you cannot handle this event (because, for example, the accessibility object does not support this attribute, the attribute is not settable, or the value is not appropriate), return the eventNotHandledErr error.

Declared in HIAccessibility.h.

Available in OS X version 10.2 and later.

kEventAccessibleIsNamedAttributeSettable

A request sent by an assistive application to find out if the given attribute’s value can be changed.

If you handle this event, you determine if the accessibility object supports the given attribute. If it does, you return a Boolean value in the kEventParamAccessibleAttributeSettable parameter that indicates whether the attribute’s value can be changed.

Declared in HIAccessibility.h.

Available in OS X version 10.2 and later.

kEventAccessibleGetAllActionNames

Sent by an assistive application to find out which actions the given accessibility object supports.

If you handle this event, you create a CFString object for the name of each action the given accessibility object supports and add it to the mutable array in the kEventParamAccessibleActionNames parameter.

Declared in HIAccessibility.h.

Available in OS X version 10.2 and later.

kEventAccessiblePerformNamedAction

Sent by an assistive application when it wants the given accessibility object to perform the given action.

If you handle this event, you determine if the accessibility object supports the action named in the kEventParamAccessibleActionName parameter. If it does, you perform it.

In OS X version 10.3 and later, this event includes the kEventParamAccessibilityEventQueued parameter, which indicates whether the event was queued. You check the value of this parameter before you perform an action that might result in a call to a routine that may not return immediately. If the event is queued, you can perform such an action without the possibility of causing an assistive application to receive a time-out error waiting for the action to complete. If the event is not queued, your handler can return the eventDeferAccessibilityEventErr to request that it be queued and sent to you later.

In versions of OS X prior to 10.3, events are always directly dispatched and you should perform a requested action even if it might cause an assistive application to receive a time-out error.

Declared in HIAccessibility.h.

Available in OS X version 10.2 and later.

kEventAccessibleGetNamedActionDescription

Sent by an assistive application to get the human-intelligible name of the given action.

If you handle this event, you determine if the given accessibility object supports the given action. If it does, you return the value of the action’s description property in the kEventParamAccessibleActionDescription parameter. To do this, you do not create a CFString object for the action description. Instead, you must modify the mutable string object in the kEventParamAccessibleActionDescription parameter to contain the action description.

Declared in HIAccessibility.h.

Available in OS X version 10.2 and later.

Discussion

Table 1 shows the parameters related to accessibility events.

Table 1  Parameter names and types for accessibility event kinds

Event kind

Parameter name

Parameter type

kEventAccessibleGetChildAtPoint

kEventParamAccessibleObject

typeCFTypeRef (an AXUIElementRef)

kEventParamAccessibleMouseLocation

typeHIPoint

kEventParamAccessibleChild

typeCFTypeRef

kEventAccessibleGetFocusedChild

kEventParamAccessibleObject

typeCFTypeRef (an AXUIElementRef)

kEventParamAccessibleChild

typeCFTypeRef

kEventAccessibleGetAllAttributeNames

kEventParamAccessibleObject

typeCFTypeRef (an AXUIElementRef)

kEventParamAccessibleAttributeNames

typeCFMutableArrayRef

kEventAccessibleGetAllParameterizedAttributeNames

kEventParamAccessibleObject

typeCFTypeRef (an AXUIElementRef)

kEventParamAccessibleAttributeNames

typeCFMutableArrayRef

kEventAccessibleGetNamedAttribute

kEventParamAccessibleObject

typeCFTypeRef (an AXUIElementRef)

kEventParamAccessibleAttributeName

typeCFStringRef

kEventParamAccessibleAttributeParameter (Optional; introduced in OS X version 10.3)

typeCFTypeRef

kEventParamAccessibleAttributeValue

typeCFTypeRef (Varies with the type of the attribute value)

kEventAccessibleSetNamedAttribute

kEventParamAccessibleObject

typeCFTypeRef (an AXUIElementRef)

kEventParamAccessibleAttributeName

typeCFStringRef

kEventParamAccessibleAttribuuteValue

typeCFTypeRef (Varies with the type of the attribute value)

kEventAccessibleIsNamedAttributeSettable

kEventParamAccessibleObject

typeCFTypeRef (an AXUIElementRef)

kEventParamAccessibleAttributeName

typeCFStringRef

kEventParamAccessibleAttributeSettable

typeBoolean

kEventAccessibleGetAllActionNames

kEventParamAccessibleObject

typeCFTypeRef

kEventParamAccessibleActionNames

typeCFMutableArrayRef

kEventAccessiblePerformNamedAction

kEventParamAccessibleObject

typeCFTypeRef (an AXUIElementRef)

kEventParamAccessibleActionName

typeCFStringRef

kEventParamAccessibleEventQueued (Only in OS X version 10.3 and later)

typeBoolean

kEventAccessibleGetNamedActionDescription

kEventParamAccessibleObject

typeCFTypeRef (an AXUIElementRef)

kEventParamAccessibleActionName

typeCFStringRef

kEventParamAccessibleActionDescription

typeCFMutableStringRef

Accessibility Event Parameters

Define parameters related to accessibility events.

enum
{
   kEventParamAccessibleObject = ‘aojb’,
   kEventParamAccessibleChild = ‘achl’,
   kEventParamAccessibleAttributeName = ‘atnm’,
   kEventParamAccessibleAttributeNames = ‘atns’,
   kEventParamAccessibleAttributeValue = ‘atvl’,
   kEventParamAccessibleAttributeSettable = ‘atst’,
   kEventParamAccessibleAttributeParameter = ‘atpa’,
   kEventParamAccessibleActionName = ‘acnm’,
   kEventParamAccessibleActionNames = ‘acns’,
   kEventParamAccessibleActionDescription = ‘acds’,
   kEventParamAccessibleEventQueued = ‘aequ’
};
Constants
kEventParamAccessibleObject

Specifies an accessibility object. The parameter type is typeCFTypeRef, and the data must be of type AXUIElementRef.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleChild

Specifies the child accessibility object. The parameter type is typeCFTypeRef, and the data must be of type AXUIElementRef.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleAttributeName

Specifies an attribute name. The parameter type is typeCFStringRef.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleAttributeNames

Specifies an array of attribute names (each of type CFStringRef). The parameter type is typeCFMutableArrayRef.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleAttributeValue

Specifies the value of an attribute. The parameter type varies according to the attribute. However, this value must be one of the flat data types, such as point, rectangle, integer, float, or any CFType, and must be able to be packaged in a CFPropertyList. In particular, the data should not be a pointer, because you cannot be sure how long an assistive application will retain the value, or in what way it will interpret the value.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleAttributeSettable

Specifies whether an attribute is settable. The parameter type is typeBoolean.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleAttributeParameter

Specifies the parameters of a parameterized attribute. The parameter type is typeCFTypeRef.

Available in OS X v10.3 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleActionName

Specifies an action name. The parameter type is typeCFStringRef.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleActionNames

Specifies an array of action names (each of type CFStringRef) . The parameter type is typeCFMutableArrayRef.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleActionDescription

Specifes the description of an action. The parameter type is typeCFMutableStringRef.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

kEventParamAccessibleEventQueued

Specifies whether the event has been queued. The parameter type is typeBoolean.

Accessibility Event Class

Defines the event class for accessibility events.

enum
{
   kEventClassAccessibility = 'acce',
};
Constants
kEventClassAccessibility

Pass this value for the event class when registering for accessibility events.

Available in OS X v10.2 and later.

Declared in CarbonEvents.h.

Accessibility Object Constants

Roles

Define the values an accessibility object’s role attribute can have.

#define kAXApplicationRole  CFSTR("AXApplication")
#define kAXSystemWideRole   CFSTR("AXSystemWide")
#define kAXWindowRole       CFSTR("AXWindow")
#define kAXSheetRole        CFSTR("AXSheet")
#define kAXDrawerRole       CFSTR("AXDrawer")
#define kAXGrowAreaRole     CFSTR("AXGrowArea")
#define kAXImageRole        CFSTR("AXImage")
#define kAXUnknownRole      CFSTR("AXUnknown")
#define kAXButtonRole       CFSTR("AXButton")
#define kAXRadioButtonRole  CFSTR("AXRadioButton")
#define kAXCheckBoxRole     CFSTR("AXCheckBox")
#define kAXPopUpButtonRole  CFSTR("AXPopUpButton")
#define kAXMenuButtonRole   CFSTR("AXMenuButton")
#define kAXTabGroupRole     CFSTR("AXTabGroup")
#define kAXTableRole        CFSTR("AXTable")
#define kAXColumnRole       CFSTR("AXColumn")
#define kAXRowRole          CFSTR("AXRow")
#define kAXOutlineRole      CFSTR("AXOutline")
#define kAXBrowserRole      CFSTR("AXBrowser")
#define kAXScrollAreaRole   CFSTR("AXScrollArea")
#define kAXScrollBarRole    CFSTR("AXScrollBar")
#define kAXRadioGroupRole   CFSTR("AXRadioGroup")
#define kAXListRole         CFSTR("AXList")
#define kAXGroupRole        CFSTR("AXGroup")
#define kAXValueIndicatorRole CFSTR ("AXValueIndicator")
#define kAXComboBoxRole     CFSTR("AXComboBox")
#define kAXSliderRole       CFSTR("AXSlider")
#define kAXIncrementorRole  CFSTR("AXIncrementor")
#define kAXBusyIndicatorRole CFSTR ("AXBusyIndicator")
#define kAXProgressIndicatorRole  CFSTR("AXProgressIndicator")
#define kAXRelevanceIndicatorRole CFSTR("AXRelevanceIndicator")
#define kAXToolbarRole      CFSTR("AXToolbar")
#define kAXDisclosureTriangleRole CFSTR("AXDisclosureTriangle")
#define kAXTextFieldRole CFSTR("AXTextField")
#definekAXTextAreaRole      CFSTR("AXTextArea")
#define kAXStaticTextRole   CFSTR("AXStaticText")
#define kAXMenuBarRole      CFSTR("AXMenuBar")
#define kAXMenuBarItemRole  CFSTR("AXMenuBarItem")
#define kAXMenuRole         CFSTR("AXMenu")
#define kAXMenuItemRole     CFSTR("AXMenuItem")
#define kAXSplitGroupRole   CFSTR("AXSplitGroup")
#define kAXSplitterRole     CFSTR("AXSplitter")
#define kAXColorWellRole    CFSTR("AXColorWell")
#define kAXTimeFieldRole    CFSTR("AXTimeField")
#define kAXDateFieldRole    CFSTR("AXDateField")
#define kAXHelpTagRole      CFSTR("AXHelpTag")
#define kAXMatteRole        CFSTR("AXMatteRole")
#define kAXDockItemRole     CFSTR("AXDockItem")
Constants
kAXApplicationRole

An application.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXSystemWideRole

The system-wide accessibility object.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXWindowRole

A window.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXSheetRole

A sheet.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXDrawerRole

A drawer.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXGrowAreaRole

A grow control.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXImageRole

An image.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXUnknownRole

Generic role value for an unknown accessibility object.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXButtonRole

A button.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXRadioButtonRole

A radio button.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXCheckBoxRole

A check box.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXPopUpButtonRole

A pop-up button.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXMenuButtonRole

A menu button.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXTabGroupRole

A tab view.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXTableRole

A table.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXColumnRole

A column.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXRowRole

A row.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXOutlineRole

An accessibility object that displays row-based, hierarchically structured data, such as the list view in a Finder window.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXBrowserRole

An accessibility object that displays column-based, hierarchically structured data, such as the column view in a Finder window.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXScrollAreaRole

An accessibility object that displays data managed by scrolling controls.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXScrollBarRole

A scroll bar control.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXRadioGroupRole

A set of radio buttons.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXListRole

A list view.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXGroupRole

A group box. This role can also be used to group other views without any visual indication of the grouping.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXValueIndicatorRole

A control that indicates the value of an accessibility object, such as the scroller of a scroll bar control

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXComboBoxRole

A combo box control.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXSliderRole

A slider control.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXIncrementorRole

A stepper control (also known as the “little arrows”).

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXBusyIndicatorRole

An asynchronous progress indicator.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXProgressIndicatorRole

A determinate or indeterminate progress indicator.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXRelevanceIndicatorRole

A relevance indicator.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXToolbarRole

A toolbar.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXDisclosureTriangleRole

A disclosure triangle control.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXTextFieldRole

A text field.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXTextAreaRole

The editable text area in a control or window.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXStaticTextRole

A string of static text displayed in a window that is not part of any control.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXMenuBarRole

A menu bar.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXMenuBarItemRole

A menu bar item.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXMenuRole

A menu.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXMenuItemRole

A menu item.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXSplitGroupRole

A split view.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXSplitterRole

A splitter bar control.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXColorWellRole

A color well.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXTimeFieldRole

A field that displays time.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXDateFieldRole

A field that displays dates.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXHelpTagRole

A help tag.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXMatteRole

The outer view that represents the entire contents, including the view through the matte hole, the contents hidden by the matte frame, and the resizing and repositioning controls. An example of an object with a matte role is the iChat icon scaling window.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXDockItemRole

An icon that represents an item in the Dock.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

Discussion

The value of the role attribute describes what the object is, not what it does. See the “Roles and Associated Attributes” appendix in Accessibility Overview for more information on which attributes are associated with each role.

Subroles

Define the values for an accessibility object’s subrole attribute.

#define kAXCloseButtonSubrole       CFSTR("AXCloseButton")
#define kAXMinimizeButtonSubrole    CFSTR("AXMinimizeButton")
#define kAXZoomButtonSubrole        CFSTR("AXZoomButton")
#define kAXToolbarButtonSubrole     CFSTR("AXToolbarButton")
#define kAXSecureTextFieldSubrole   CFSTR("AXSecureTextField")
#define kAXTableRowSubrole          CFSTR("AXTableRow")
#define kAXOutlineRowSubrole        CFSTR("AXOutlineRow")
#define kAXUnknownSubrole           CFSTR("AXUnknown")
#define kAXStandardWindowSubrole    CFSTR("AXStandardWindow")
#define kAXDialogSubrole            CFSTR("AXDialog")
#define kAXSystemDialogSubrole      CFSTR("AXSystemDialog")
#define kAXFloatingWindowSubrole    CFSTR("AXFloatingWindow")
#define kAXSystemFloatingWindowSubrole CFSTR("AXSystemFloatingWindow")
#define kAXIncrementArrowSubrole    CFSTR("AXIncrementArrow")
#define kAXDecrementArrowSubrole    CFSTR("AXDecrementArrow")
#define kAXIncrementPageSubrole     CFSTR("AXIncrementPage")
#define kAXDecrementPageSubrole     CFSTR("AXDecrementPage")
#define kAXSortButtonSubrole        CFSTR("AXSortButton")
#define kAXSearchFieldSubrole       CFSTR("AXSearchField")
#define kAXApplicationDockItemSubrole CFSTR("AXApplicationDockItem")
#define kAXDocumentDockItemSubrole  CFSTR("AXDocumentDockItem")
#define kAXFolderDockItemSubrole    CFSTR("AXFolderDockItem")
#define kAXMinimizedWindowDockItemSubrole CFSTR("AXMinimizedWindowDockItem")
#define kAXURLDockItemSubrole       CFSTR("AXURLDockItem")
#define kAXDockExtraDockItemSubrole CFSTR("AXDockExtraDockItem")
#define kAXTrashDockItemSubrole     CFSTR("AXTrashDockItem")
#define kAXProcessSwitcherListSubrole CFSTR("AXProcessSwitcherList")
Constants
kAXCloseButtonSubrole

A close button (that is, the red button in a window’s title bar that closes the window).

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXMinimizeButtonSubrole

A minimize button (that is, the yellow button in a window’s title bar that minimizes the window into the Dock).

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXZoomButtonSubrole

A zoom button (that is, the green button in a window’s title bar that adjusts the window’s size).

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXToolbarButtonSubrole

A toolbar button (that is, the button in a window’s title bar that hides and reveals the toolbar).

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXSecureTextFieldSubrole

A text field intended to contain sensitive data and that displays the user’s input as a series of bullets.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXTableRowSubrole

A row in a table.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXOutlineRowSubrole

A row in an outline view (see kAXOutlineRole for a description of an outline view).

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXUnknownSubrole

A subrole for an unknown type of window. A window should include a subrole to further define its type. If your window does not conform to an existing subrole, you can use the unknown subrole. Alternatively, you can return the eventNotHandledErr error when your window is asked for its subrole.

Available in OS X v10.2 and later.

Declared in AXRoleConstants.h.

kAXStandardWindowSubrole

A standard window that includes a title bar (that is, not an inspector window or a sheet).

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXDialogSubrole

A dialog window, such as an alert.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXSystemDialogSubrole

A system-generated dialog window that floats on the top layer, regardless of which application is frontmost. Use this subrole only when a dialog or alert applies to the system as a whole, such as a shutdown dialog.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXFloatingWindowSubrole

A utility window.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXSystemFloatingWindowSubrole

A system-generated utility window.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXIncrementArrowSubrole

The up arrow of a scroll bar.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXDecrementArrowSubrole

The down arrow of a scroll bar.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXIncrementPageSubrole

The increment area in the scroll track of a scroll bar.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXDecrementPageSubrole

The decrement area in the scroll track of a scroll bar.

Available in OS X v10.3 and later.

Declared in AXRoleConstants.h.

kAXSortButtonSubrole

A column heading button in a list or column view.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXSearchFieldSubrole

A search field.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXApplicationDockItemSubrole

An icon in the Dock that represents an application.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXDocumentDockItemSubrole

An icon in the Dock that represents a document.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXFolderDockItemSubrole

An icon in the Dock that represents a folder.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXMinimizedWindowDockItemSubrole

An icon in the Dock that represents a minimized window.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXURLDockItemSubrole

An icon in the Dock that represents a URL.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXDockExtraDockItemSubrole

An icon in the Dock that represents a Dock Extra.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXTrashDockItemSubrole

The icon in the Dock that represents the Trash.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

kAXProcessSwitcherListSubrole

The display of running applications (processes) that appears when a user presses Command-Tab.

Available in OS X v10.4 and later.

Declared in AXRoleConstants.h.

Discussion

A subrole provides a more specific description of an accessibility object’s role. If an accessibility object is of a well-defined subtype, it can include the subrole attribute to provide additional information to an assistive application.

Attributes

Define the attributes available for accessibility objects.

//General attributes
#define kAXRoleAttribute                    CFSTR("AXRole")
#define kAXSubroleAttribute                 CFSTR("AXSubrole")
#define kAXRoleDescriptionAttribute         CFSTR("AXRoleDescription")
#define kAXHelpAttribute                    CFSTR("AXHelp")
#define kAXTitleAttribute                   CFSTR("AXTitle")
#define kAXValueAttribute                   CFSTR("AXValue")
#define kAXMinValueAttribute                CFSTR("AXMinValue")
#define kAXMaxValueAttribute                CFSTR("AXMaxValue")
#define kAXValueIncrementAttribute          CFSTR("AXValueIncrement")
#define kAXAllowedValuesAttribute           CFSTR("AXAllowedValues")
#define kAXEnabledAttribute                 CFSTR("AXEnabled")
#define kAXFocusedAttribute                 CFSTR("AXFocused")
#define kAXParentAttribute                  CFSTR("AXParent")
#define kAXChildrenAttribute                CFSTR("AXChildren")
#define kAXSelectedChildrenAttribute        CFSTR("AXSelectedChildren")
#define kAXVisibleChildrenAttribute         CFSTR("AXVisibleChildren")
#define kAXWindowAttribute                  CFSTR("AXWindow")
#define kAXTopLevelUIElementAttribute       CFSTR("AXTopLevelUIElement")
#define kAXPositionAttribute                CFSTR("AXPosition")
#define kAXSizeAttribute                    CFSTR("AXSize")
#define kAXOrientationAttribute             CFSTR("AXOrientation")
#define kAXDescriptionAttribute             CFSTR("AXDescription")
   
// Text-specific attributes
#define kAXSelectedTextAttribute            CFSTR("AXSelectedText")
#define kAXVisibleCharacterRangeAttribute CFSTR("AXVisibleCharacterRange")
#define kAXSelectedTextRangeAttribute       CFSTR("AXSelectedTextRange")
#define kAXNumberOfCharactersAttribute      CFSTR("AXNumberOfCharacters")
#define kAXSharedTextUIElementsAttribute    CFSTR("AXSharedTextUIElements")
#define kAXSharedCharacterRangeAttribute    CFSTR("AXSharedCharacterRange")
   
// Window-specific attributes
#define kAXMainAttribute                    CFSTR("AXMain")
#define kAXMinimizedAttribute               CFSTR("AXMinimized")
#define kAXCloseButtonAttribute             CFSTR("AXCloseButton")
#define kAXZoomButtonAttribute              CFSTR("AXZoomButton")
#define kAXMinimizeButtonAttribute          CFSTR("AXMinimizeButton")
#define kAXToolbarButtonAttribute           CFSTR("AXToolbarButton")
#define kAXGrowAreaAttribute                CFSTR("AXGrowArea")
#define kAXProxyAttribute                   CFSTR("AXProxy")
#define kAXModalAttribute                   CFSTR("AXModal")
#define kAXDefaultButtonAttribute           CFSTR("AXDefaultButton")
#define kAXCancelButtonAttribute            CFSTR("AXCancelButton")
   
// Menu-specific attributes
#define kAXMenuItemCmdCharAttribute         CFSTR("AXMenuItemCmdChar")
#define kAXMenuItemCmdVirtualKeyAttribute
   CFSTR("AXMenuItemCmdVirtualKey")
#define kAXMenuItemCmdGlyphAttribute        CFSTR("AXMenuItemCmdGlyph")
#define kAXMenuItemCmdModifiersAttribute
   CFSTR("AXMenuItemCmdModifiers")
#define kAXMenuItemMarkCharAttribute    CFSTR("AXMenuItemMarkChar")
#define kAXMenuItemPrimaryUIElementAttribute CFSTR("AXMenuItemPrimaryUIElement")
   
// Application-specific attributes
#define kAXMenuBarAttribute                     CFSTR("AXMenuBar")
#define kAXWindowsAttribute                     CFSTR("AXWindows")
#define kAXFrontmostAttribute                   CFSTR("AXFrontmost")
#define kAXHiddenAttribute                      CFSTR("AXHidden")
#define kAXMainWindowAttribute                  CFSTR("AXMainWindow")
#define kAXFocusedWindowAttribute               CFSTR("AXFocusedWindow")
#define kAXFocusedUIElementAttribute        CFSTR("AXFocusedUIElement")
   
// Miscellaneous attributes
#define kAXHeaderAttribute                  CFSTR("AXHeader")
#define kAXEditedAttribute                  CFSTR("AXEdited")
#define kAXValueWrapsAttribute              CFSTR("AXValueWraps")
#define kAXTabsAttribute                    CFSTR("AXTabs")
#define kAXTitleUIElementAttribute          CFSTR("AXTitleUIElement")
#define kAXHorizontalScrollBarAttribute     CFSTR("AXHorizontalScrollBar")
#define kAXVerticalScrollBarAttribute       CFSTR("AXVerticalScrollBar")
#define kAXOverflowButtonAttribute          CFSTR("AXOverflowButton")
#define kAXFilenameAttribute                CFSTR("AXFilename")
#define kAXExpandedAttribute                CFSTR("AXExpanded")
#define kAXSelectedAttribute                CFSTR("AXSelected")
#define kAXSplittersAttribute               CFSTR("AXSplitters")
#define kAXNextContentsAttribute            CFSTR("AXNextContents")
#define kAXDocumentAttribute                CFSTR("AXDocument")
#define kAXDecrementButtonAttribute         CFSTR("AXDecrementButton")
#define kAXIncrementButtonAttribute         CFSTR("AXIncrementButton")
#define kAXPreviousContentsAttribute        CFSTR("AXPreviousContents")
#define kAXContentsAttribute                CFSTR("AXContents")
#define kAXIncrementorAttribute             CFSTR("AXIncrementor")
#define kAXHourFieldAttribute               CFSTR("AXHourField")
#define kAXMinuteFieldAttribute             CFSTR("AXMinuteField")
#define kAXSecondFieldAttribute             CFSTR("AXSecondField")
#define kAXAMPMFieldAttribute               CFSTR("AXAMPMField")
#define kAXDayFieldAttribute                CFSTR("AXDayField")
#define kAXMonthFieldAttribute              CFSTR("AXMonthField")
#define kAXYearFieldAttribute               CFSTR("AXYearField")
#define kAXColumnTitleAttribute             CFSTR("AXColumnTitles")
#define kAXURLAttribute                     CFSTR("AXURL")
#define kAXLabelUIElementsAttribute         CFSTR("AXLabelUIElements")
#define kAXLabelValueAttribute              CFSTR("AXLabelValue")
#define kAXShownMenuUIElementAttribute      CFSTR("AXShownMenuUIElement")
#define kAXServesAsTitleForUIElementsAttribute           CFSTR("AXServesAsTitleForUIElements")
#define kAXLinkedUIElementsAttribute CFSTR("AXLinkedUIElements")
   
// Table and outline view attributes
#define kAXRowsAttribute                    CFSTR("AXRows")
#define kAXVisibleRowsAttribute             CFSTR("AXVisibleRows")
#define kAXSelectedRowsAttribute            CFSTR("AXSelectedRows")
#define kAXColumnsAttribute                 CFSTR("AXColumns")
#define kAXVisibleColumnsAttribute          CFSTR("AXVisibleColumns")
#define kAXSelectedColumnsAttribute         CFSTR("AXSelectedColumns")
#define kAXSortDirectionAttribute           CFSTR("AXSortDirection")
#define kAXColumnHeaderUIElementsAttribute CFSTR("AXColumnHeaderUIElements")
#define kAXIndexAttribute                   CFSTR("AXIndex")
#define kAXDisclosingAttribute              CFSTR("AXDisclosing")
#define kAXDisclosedRowsAttribute           CFSTR("AXDisclosedRows")
#define kAXDisclosedByRowAttribute          CFSTR("AXDisclosedByRow")
   
// Matte attributes
#define kAXMatteHoleAttribute               CFSTR("AXMatteHole")
#define kAXMatteContentUIElementAttribute CFSTR("AXMatteContentUIElement")
   
   
// Dock attributes
#define kAXIsApplicationRunningAttribute CFSTR("AXIsApplicationRunning")
   
// System-wide attributes
#define kAXFocusedApplicationAttribute      CFSTR("AXFocusedApplication")
Constants
kAXRoleAttribute

The role, or type, of this accessibility object (for example, AXButton). This string is for identification purposes only and does not need to be localized. All accessibility objects must include this attribute.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXSubroleAttribute

The subrole of this accessibility object (for example, AXCloseButton). The subrole provides additional information about the accessibility object to an assistive application. This string is for identification purposes only and does not need to be localized. This attribute is necessary only for an accessibility object whose AXRole attribute does not adequately describe its meaning.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXRoleDescriptionAttribute

A localized string describing the role (for example, “button”). This string must be readable by (or speakable to) the user. All accessibility objects must include this attribute. To get the system-defined role description string for a given role, use the HICopyAccessibilityRoleDescription function.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXHelpAttribute

A localized string containing help text for this accessibility object. An accessibility object that provides help information should include this attribute.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXTitleAttribute

The title associated with this accessibility object. A title is text that the object displays as part of its visual interface, such as the text “OK” on an OK button. This string must be localizable and human-intelligible. This attribute is required for all accessibility objects that display a string in their visual interfaces.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXValueAttribute

The value associated with this accessibility object (for example, a scroller value). The value of an accessibility object is user-modifiable and represents the setting of the associated user interface element, such as the contents of an editable text field or the position of a scroller. This attribute is required if an accessibility object’s value state conveys information to the user or if the user can define the value of the object.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMinValueAttribute

The minimum value this accessibility object can display (for example, the minimum value of a scroller control). This attribute is used only in conjunction with the AXValue attribute.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMaxValueAttribute

The maximum value this accessibility object can display (for example, the maximum value of a scroller control). This attribute is used only in conjunction with the AXValue attribute.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXValueIncrementAttribute

The amount an accessibility object’s value changes as the result of a single action (for example, how far a scroller travels with one mouse click). This attribute is used only in conjunction with the AXValue attribute.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXAllowedValuesAttribute

An array of the allowed values for an accessibility object. This attribute indicates the subset of values to which an accessibility object can be set. For example, a slider control displays a large range of values, but the accessibility object representing the slider can be set to only a few specific values within that range. This attribute is used only in conjunction with the AXValue attribute.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXEnabledAttribute

Indicates whether the user can interact with the accessibility object. For example, the AXEnabled attribute of a disabled button is false. This attribute is required for accessibility objects that represent views, menus, and menu items. This attribute is not required for accessibility objects that represent windows.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXFocusedAttribute

Indicates whether the accessibility object currently has the keyboard focus. Note that you can set the value of the AXFocused attribute to true to accept keyboard focus. This attribute is required for all accessibility objects representing elements that can receive keyboard focus.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXParentAttribute

This accessibility object’s parent object in the accessibility hierarchy. This attribute is required for all accessibility objects except the application-level accessibility object.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXChildrenAttribute

An array of the first-order accessibility objects contained by this accessibility object. An accessibility object may be a member of only one AXChildren array. This attribute is required for all accessibility objects that contain accessible child objects.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXSelectedChildrenAttribute

An array of selected first-order accessibility objects contained by this accessibility object. For example, the selected subelements of a list view are contained in the AXSelectedChildren array of the list view’s accessibility object. The members of the AXSelectedChildren array are a subset of the members of this accessibility object’s AXChildren array. This attribute is required for accessibility objects that contain selectable child objects.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXVisibleChildrenAttribute

An array of first-order accessibility objects contained by this accessibility object that are visible to a sighted user. For example, a list view’s AXVisibleChildren array would contain the list’s subelements that are currently scrolled into view. The members of the AXVisibleChildren array are a subset of the members of this accessibility object’s AXChildren array. This attribute is recommended for accessibility objects whose child objects can be scrolled out of view or otherwise obscured.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXWindowAttribute

The window element that contains this accessibility object. An accessibility object that is contained in a window includes this attribute so an assistive application easily can find the window without having to step through all intervening objects in the accessibility hierarchy. Note that the value of the AXWindow attribute must be an accessibility object that represents a window, not a sheet or drawer. For a similar attribute that is less restrictive, see kAXTopLevelUIElementAttribute. The AXWindow attribute is required for all accessibility elements whose parent or more distant ancestor represents a window.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXPositionAttribute

The global screen coordinates of the top-left corner of this accessibility object. Note that the coordinates 0,0 represent the top-left corner of the screen that displays the menu bar. All accessibility objects that have a screen position (in other words, are visible on the screen) should include this attribute.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXTopLevelUIElementAttribute

The window, sheet, or drawer element that contains this accessibility object. An accessibility object that is contained in a window, sheet, or drawer includes this attribute so an assistive application easily can find that element without having to step through all intervening objects in the accessibility hierarchy. This attribute is required for all accessibility objects whose parent or more distant ancestor represents a window, drawer, or sheet.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXSizeAttribute

The vertical and horizontal dimensions of this accessibility object. This attribute is required for all accessibility objects that are visible on the screen.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXOrientationAttribute

Indicates whether this accessibility object is displayed or interacted with in a vertical or a horizontal manner. The interpretation of an element, such as a slider, can change depending on whether it is oriented vertically or horizontally. Using the value of this attribute, an assistive application can communicate this information to the user. This attribute is required for any accessibility object, such as a scroller or slider, whose semantic meaning varies with the object’s orientation.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXDescriptionAttribute

The purpose of this accessibility object. The description string must be localizable and human-intelligible and it must be all lower case and include no punctuation. The string should briefly describe this accessibility object’s purpose, without including the object’s role description. This attribute is required for all accessibility objects that do not provide enough descriptive information in the title attribute.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXSelectedTextAttribute

The currently selected text within this accessibility object. This attribute is required for all accessibility objects that represent editable text elements.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXSelectedTextRangeAttribute

Indicates the range of characters (not bytes) that defines the currently selected text within this accessibility object. This attribute is required for all accessibility objects that represent editable text elements.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXVisibleCharacterRangeAttribute

Indicates the range of characters (not bytes) that are scrolled into view within this accessibility object. This attribute is required only for accessibility objects that represent an editable text area (objects of role AXTextArea), not for any other text-related accessibility objects.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXNumberOfCharactersAttribute

The total number of characters (not bytes) in the editable text element represented by this accessibility object. This attribute is required for all accessibility objects that represent editable text elements.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXSharedTextUIElementsAttribute

An array of accessibility objects with which the text of this accessibility object is shared. In a multi-column document, for example, each column may be represented by a separate accessibility object. However, the text in the document may flow from one column to the other. You get the value of this attribute if you need to know with which accessibility object this accessibility object shares its text. This attribute is recommended for sets of accessibility objects that share text in a single window. (See kAXSharedCharacterRange for a related attribute.)

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXSharedCharacterRangeAttribute

The portion of shared text this accessibility object currently displays. In a multi-column document, for example, each column may be represented by a separate accessibility object. However, the text in the document may flow from one column to the other. Get the value of this attribute if you need to know the specific range of characters this accessibility object currently displays. This attribute is recommended for sets of accessibility objects that share text in a single window. (See kAXSharedTextUIElementsAttribute for a related attribute.)

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXMainAttribute

Indicates whether the window represented by this accessibility object is the main application window. Note that a window can be main even though it does not have keyboard focus. This attribute is recommended for all accessibility objects that represent windows.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMinimizedAttribute

Indicates whether the window represented by this accessibility object is currently minimized in the Dock. This attribute is recommended for all accessibility objects that represent windows that can be minimized.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXCloseButtonAttribute

The close button of the window represented by this accessibility object. An accessibility object includes this attribute to help an assistive application easily find a window’s close button, without having to traverse the accessibility hierarchy. This attribute is recommended for all accessibility objects that represent windows that contain a close button.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXZoomButtonAttribute

The zoom button of the window represented by this accessibility object. An accessibility object includes this attribute to help an assistive application easily find a window’s zoom button, without having to traverse the accessibility hierarchy. This attribute is recommended for all accessibility objects that represent windows that contain a zoom button.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMinimizeButtonAttribute

The minimize button of the window represented by this accessibility object. An accessibility object includes this attribute to help an assistive application easily find a window’s minimize button, without having to traverse the accessibility hierarchy. This attribute is recommended for all accessibility objects that represent windows that contain a minimize button.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXToolbarButtonAttribute

The toolbar button of the window represented by this accessibility object. An accessibility object includes this attribute to help an assistive application easily find a window’s toolbar button, without having to traverse the accessibility hierarchy. This attribute is recommended for all accessibility objects that represent windows that contain a toolbar button.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXGrowAreaAttribute

The grow area of the window represented by this accessibility object. An accessibility object includes this attribute to help an assistive application easily find a window’s grow area, without having to traverse the accessibility hierarchy. This attribute is recommended for all accessibility objects that represent windows that contain a grow area.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXProxyAttribute

The document proxy of the window represented by this accessibility object. An accessibility object includes this attribute to help an assistive application easily find a window’s document proxy, without having to traverse the accessibility hierarchy. This attribute is recommended for all accessibility objects that represent windows that display a document proxy.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXModalAttribute

Indicates whether the window represented by this accessibility object is modal. This attribute is recommended for all accessibility objects that represent windows.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXDefaultButtonAttribute

The default button of the window represented by this accessibility object. An accessibility object includes this attribute to help an assistive application easily find a window’s default button, without having to traverse the accessibility hierarchy. This attribute is recommended for all accessibility objects that represent windows that contain a default button.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXCancelButtonAttribute

The cancel button of the window represented by this accessibility object. An accessibility object includes this attribute to help an assistive application easily find a window’s cancel button, without having to traverse the accessibility hierarchy. This attribute is recommended for all accessibility objects that represent windows that contain a cancel button.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXMenuItemCmdCharAttribute

The primary key in the keyboard shortcut for the command represented by this accessibility object. For example, “O” is the primary key in the keyboard shortcut for the Open command.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMenuItemCmdVirtualKeyAttribute

The key code associated with the physical key in the keyboard shortcut for the command represented by this accessibility object. For example, Return and Enter are different physical keys that can produce the same character. If an assistive application needs to be able to distinguish between them, it can view the virtual key codes.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMenuItemCmdGlyphAttribute

The glyph displayed for a physical key in the keyboard shortcut for the command represented by this accessibility object, if it is different from the visible result of pressing the key. The Delete key, for example, produces an invisible character, but it is associated with a visible glyph.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMenuItemCmdModifiersAttribute

An integer mask that represents the modifier keys held down in the keyboard shortcut for the command represented by this accessibility object.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMenuItemMarkCharAttribute

The symbol displayed to the left of the menu item represented by this accessibility object. For example, in the Window menu, a checkmark appears next to the active document’s name. For more information on the standard symbols that can appear next to menu items, see Apple Human Interface Guidelines.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMenuItemPrimaryUIElementAttribute

The accessibility object representing the primary menu item in a group of dynamic menu items. Dynamic menu item are commands that change when the user presses a modifier key, such as Minimize Window and Minimize All Windows. Within each group, each dynamic menu item’s accessibility object includes this attribute and in each case the attribute’s value is the accessibility object representing the primary menu item.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXMenuBarAttribute

The accessibility object representing the menu bar of this application. The application-level accessibility object includes this attribute to help an assistive application easily find the menu bar. This attribute is recommended for all application-level accessibility objects.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXWindowsAttribute

An array of accessibility objects representing this application’s windows. This attribute is recommended for all application-level accessibility objects.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXFrontmostAttribute

Indicates whether the application represented by this accessibility object is active. This attribute is recommended for all application-level accessibility objects.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXHiddenAttribute

Indicates whether the application represented by this accessibility object is hidden. This attribute is recommended for all application-level accessibility objects.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMainWindowAttribute

The accessibility object representing this application’s main window. This attribute is recommended for all application-level accessibility objects.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXFocusedWindowAttribute

The accessibility object that represents the currently focused window of this application. This attribute is recommended for all application-level accessibility objects.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXFocusedUIElemenAttribute

The accessibility object that represents the currently focused user interface element in this application. This attribute is recommended for all application-level accessibility objects.

kAXHeaderAttribute

The accessibility object representing the header element of this accessibility object. For example, a table or an outline view can have a header element that displays column or row headers. An accessibility object includes this attribute to help an assistive application easily find embedded header information. This attribute is recommended for all accessibility objects that represent elements that display header information.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXEditedAttribute

Indicates whether the user interface element represented by this accessibility object has been edited. For example, a document window indicates it has been edited by displaying a black dot in its close button. This attribute is recommended for all accessibility objects that represent editable user interface elements.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXTitleUIElementAttribute

An accessibility object that represents a static text title associated with another accessibility object.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXValueWrapsAttribute

Indicates whether the value displayed in the user interface element represented by this accessibility object wraps around.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXTabsAttribute

An array of accessibility objects representing the tabs this accessibility object displays. An accessibility object includes this attribute to help an assistive application easily distinguish a tab view’s tabs from its other children. This attribute is recommended for all accessibility objects that represent tab views.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXHorizontalScrollBarAttribute

The horizontal scroll bar displayed by the user interface element this accessibility object represents. This is a convenience attribute an assistive application can use easily to find the scroll bar without traversing the accessibility hierarchy. This attribute is recommended for all accessibility objects that display a horizontal scroll bar.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXVerticalScrollBarAttribute

The vertical scroll bar displayed by the user interface element this accessibility object represents. This is a convenience attribute an assistive application can use easily to find the scroll bar without traversing the accessibility hierarchy. This attribute is recommended for all accessibility objects that display a vertical scroll bar.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXOverflowButtonAttribute

Identifies which child of an accessibility object representing a toolbar is the overflow button (if any). This attribute is optional.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXFilenameAttribute

The filename associated with this accessibility object. This attribute is optional.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXExpandedAttribute

Indicates whether the menu displayed by the combo box or pop-up menu represented by this accessibility object is currently expanded. This attribute is recommended for all accessibility objects that display a pop-up menu.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXSelectedAttribute

Indicates whether the row or column element represented by this accessibility object is selected. This attribute is recommended for all accessibility objects that represent selectable rows or columns.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXSplittersAttribute

An array of views and splitter bar elements displayed by the split view represented by this accessibility object. This is a convenience attribute that helps an assistive application easily find these elements.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXNextContentsAttribute

The group of accessibility objects representing the elements on one side of a splitter bar. (Which side of the splitter bar is considered “next” is determined by the value of the splitter bar’s orientation attribute.) This attribute is recommended for an accessibility object that represents the splitter bar in a split view.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXPreviousContentsAttribute

The group of accessibility objects representing the elements on one side of a splitter bar. (Which side of the splitter bar is considered “previous” is determined by the value of the splitter bar’s orientation attribute.) This attribute is recommended for an accessibility object that represents the splitter bar in a split view.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXDocumentAttribute

The URL of the open document represented by this accessibility object. This attribute represents the URL as a string object.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXIncrementButtonAttribute

The increment element associated with the user interface object this accessibility object represents. This attribute can be used to provide convenient access to the increment area of a custom user interface object. To refer to the increment button associated with a date or time field, see kAXIncrementorAttribute.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXDecrementButtonAttribute

The decrement element associated with the user interface object this accessibility object represents. This attribute can be used to provide convenient access to the decrement area of a custom user interface object.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXContentsAttribute

Content-containing accessibility objects that are children of this accessibility object. For example, a tab view contains children that represent both the tab controls and the content displayed for each tab. The accessibility object representing a tab view can include only the content-display children in its AXContents attribute to help an assistive application provide more targeted information to the user. This attribute is recommended for any accessibility object whose children represent both content and control elements.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXIncrementorAttribute

The incrementor of a time or date field represented by this accessibility object. This attribute is required for accessibility objects that represent time or date field elements that display an incrementor.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXHourFieldAttribute

The hour field of a time field represented by this accessibility object. This attribute is required for accessibility objects that represent time fields that display hours.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXMinuteFieldAttribute

The minute field of a time field represented by this accessibility object. This attribute is required for accessibility objects that represent time fields that display minutes.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXSecondFieldAttribute

The second field of a time field represented by this accessibility object. This attribute is required for accessibility objects that represent time fields that display seconds.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXAMPMFieldAttribute

The AM/PM field of a time field represented by this accessibility object. This attribute is required for accessibility objects that represent time fields that display AM/PM settings.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXDayFieldAttribute

The day field of a time field represented by this accessibility object. This attribute is required for accessibility objects that represent time fields that display days.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXMonthFieldAttribute

The month field of a time field represented by this accessibility object. This attribute is required for accessibility objects that represent time fields that display months.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXYearFieldAttribute

The year field of a time field represented by this accessibility object. This attribute is required for accessibility objects that represent time fields that display years.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXColumnTitleAttribute

The title of the column element represented by this accessibility object. Note that, because column titles are sometimes the children of a separate header element, the value of this attribute can refer to an element that is not a child of the column accessibility object.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXURLAttribute

The URL that describes the location of the document or application represented by this accessibility object.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXLabelUIElementsAttribute

An array of accessibility objects representing the labels displayed near the control represented by this accessibility object. For example, a slider control might display labels that indicate the range of values the slider can represent. Because these labels are not displayed as part of the slider’s visual interface, an assistive application does not know they are associated with the slider. By including accessibility objects representing the labels in this attribute, you make this association explicit.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXLabelValueAttribute

The value of the label represented by this accessibility object. This attribute is required for all accessibility objects that represent labels.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXShownMenuUIElementAttribute

An array of accessibility objects that represent the contextual or Dock menus provided by this accessibility object.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXServesAsTitleForUIElementsAttribute

An array of accessibility objects for which this accessibility object serves as the title. For example, a piece of static text can serve as a title for one or more user interface elements. Because this static text string is not displayed as part of any user interface element’s visual interface, an assistive application does not know the title is associated with user interface elements. By including this attribute in the accessibility object representing the title, you specify the accessibility objects with which this title is associated.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXLinkedUIElementsAttribute

An array of accessibility objects with which this accessibility object is related. For example, the contents of a list item can be displayed in another pane or window. The list item and the separately displayed contents are related, but this relationship may not be apparent to an assistive application. To make such a relationship explicit, you include this attribute in the accessibility objects representing the related user interface elements.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXRowsAttribute

An array of the accessibility objects representing the rows in this table or outline view.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXVisibleRowsAttribute

An array of the accessibility objects representing the currently visible rows in this table or outline view.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXSelectedRowsAttribute

An array of the accessibility objects representing the currently selected rows in this table or outline view.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXColumnsAttribute

An array of the accessibility objects representing the columns in this browser view.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXVisibleColumnsAttribute

An array of the accessibility objects representing the currently visible columns in this browser view.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXSelectedColumnsAttribute

An array of the accessibility objects representing the currently selected columns in this browser view.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXSortDirectionAttribute

The sort direction of this accessibility object’s contents. For example, a list view’s contents may be sorted in ascending or descending order.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXColumnHeaderUIElementsAttribute

An array of accessibility objects representing the column headers of this table or browser view.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXIndexAttribute

The index of the row or column represented by this accessibility object.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXDisclosingAttribute

Indicates whether a row in an outline view represented by this accessibility object has an open or closed disclosure triangle. true indicates an open disclosure triangle; false indicates a closed disclosure triangle.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXDisclosedRowsAttribute

An array of accessibility objects representing the disclosed rows of this user interface element.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXDisclosedByRowAttribute

The accessibility object representing the disclosing row.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXMatteHoleAttribute

The accessibility object that represents the area available to the user through the matte hole.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXMatteContentUIElementAttribute

The accessibility object clipped by the matte.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXIsApplicationRunningAttribute

Indicates if the application represented by the Dock icon this accessibility object represents is currently running.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXFocusedApplicationAttribute

Indicates the application element that is currently accepting keyboard input. This attribute is supported by the system-wide accessibility object to help an assistive application quickly determine the application that is accepting keyboard input. After the assistive application gets the accessibility object representing this application, it can send a message to the application asking for its focused accessibility object.

Available in OS X v10.2 and later.

Declared in AXAttributeConstants.h.

kAXInsertionPointLineNumberAttribute

The line number of the insertion point in the text associated with this accessibility object.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

Discussion

See the “Roles and Associated Attributes” appendix in Accessibility Overview for more information on which attributes are associated with a specific role.

Parameterized Attributes

Define the parameterized attributes an accessibility object can have.

// Text-suite parameterized attributes
#define kAXLineForIndexParameterizedAttribute CFSTR("AXLineForIndex")
#define kAXRangeForLineParameterizedAttribute          CFSTR("AXRangeForLine")
#define kAXStringForRangeParameterizedAttribute         CFSTR("AXStringForRange")
#define kAXRangeForPositionParameterizedAttribute CFSTR("AXRangeForPosition")
#define kAXRangeForIndexParameterizedAttribute CFSTR("AXRangeForIndex")
#define kAXBoundsForRangeParameterizedAttribute CFSTR("AXBoundsForRange")
#define kAXRTFForRangeParameterizedAttribute CFSTR("AXRTFForRange")
#define kAXAttributedStringForRangeParameterizedAttribute  CFSTR("AXAttributedStringForRange")
#define kAXStyleRangeForIndexParameterizedAttribute CFSTR("AXStyleRangeForIndex")
#define kAXInsertionPointLineNumberAttribute CFSTR("AXInsertionPointLineNumber")
Constants
kAXLineForIndexParameterizedAttribute

Given an indexed character, the line number of the text associated with this accessibility object that contains the character.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXRangeForLineParameterizedAttribute

Given a line number, the range of characters of the text associated with this accessibility object that contains the line number.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXStringForRangeParameterizedAttribute

A substring of the text associated with this accessibility object that is specified by the given character range.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXRangeForPositionParameterizedAttribute

The composed character range in the text associated with this accessibility object that is specified by the given screen coordinates. This parameterized attribute returns the complete range of characters (including surrogate pairs of multi-byte glyphs) at the given screen coordinates.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXRangeForIndexParameterizedAttribute

The composed character range in the text associated with this accessibility object that is specified by the given index value. This parameterized attribute returns the complete range of characters (including surrogate pairs of multi-byte glyphs) at the given index.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXBoundsForRangeParameterizedAttribute

The bounding rectangle of the text associated with this accessibility object that is specified by the given range. This is the bounding rectangle a sighted user would see on the display screen, in pixels.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXRTFForRangeParameterizedAttribute

The RTF representation of the text associated with this accessibility object that is specified by the given range.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

kAXAttributedStringForRangeParameterizedAttribute

The CFAttributedStringType representation of the text associated with this accessibility object that is specified by the given range.

Available in OS X v10.4 and later.

Declared in AXAttributeConstants.h.

kAXStyleRangeForIndexParameterizedAttribute

Given a character index, the range of text associated with this accessibility object over which the style in effect at that character index applies.

Available in OS X v10.3 and later.

Declared in AXAttributeConstants.h.

Discussion

Parameterized attributes allow you to pass in additional values to get more specific information about the text associated with an accessibility object.

Availability
  • Available in OS X version 10.3 and later.

Actions

Define the actions an accessibility object can perform.

// Accessibility actions.
#define kAXPressAction          CFSTR("AXPress")
#define kAXIncrementAction      CFSTR("AXIncrement")
#define kAXDecrementAction      CFSTR("AXDecrement")
#define kAXConfirmAction        CFSTR("AXConfirm")
#define kAXCancelAction         CFSTR("AXCancel")
#define kAXRaiseAction          CFSTR("AXRaise")
#define kAXShowMenuAction       CFSTR("AXShowMenu")
Constants
kAXPressAction

Simulates a single click, such as on a button.

Available in OS X v10.2 and later.

Declared in AXActionConstants.h.

kAXIncrementAction

Increments the value of the accessibility object. The amount the value is incremented by is determined by the value of the kAXValueIncrementAttribute attribute.

Available in OS X v10.2 and later.

Declared in AXActionConstants.h.

kAXDecrementAction

Decrements the value of the accessibility object. The amount the value is decremented by is determined by the value of the kAXValueIncrementAttribute attribute.

Available in OS X v10.2 and later.

Declared in AXActionConstants.h.

kAXConfirmAction

Simulates pressing the Return key.

Available in OS X v10.2 and later.

Declared in AXActionConstants.h.

kAXCancelAction

Simulates pressing a Cancel button.

Available in OS X v10.2 and later.

Declared in AXActionConstants.h.

kAXRaiseAction

Causes a window to become as frontmost as is allowed by the containing application’s circumstances. Note that an application’s floating windows (such as inspector windows) might remain above a window that performs the raise action.

Available in OS X v10.3 and later.

Declared in AXActionConstants.h.

kAXShowMenuAction

Simulates the opening of a contextual menu in the element represented by this accessibility object. This action can also be used to simulate the display of a menu that is preassociated with an element, such as the menu that displays when a user clicks Safari’s back button slowly.

Available in OS X v10.4 and later.

Declared in AXActionConstants.h.

Notifications

Define the notifications that can be broadcast by an accessibility object.

// Focus notifications
#define kAXMainWindowChangedNotification CFSTR("AXMainWindowChanged")
#define kAXFocusedWindowChangedNotification CFSTR("AXFocusedWindowChanged")
#define kAXFocusedUIElementChangedNotification       CFSTR("AXFocusedUIElementChanged")
   
// Application notifications
#define kAXApplicationActivatedNotification CFSTR("AXApplicationActivated")
#define kAXApplicationDeactivatedNotification CFSTR("AXApplicationDeactivated")
#define kAXApplicationHiddenNotification CFSTR("AXApplicationHidden")
#define kAXApplicationShownNotification CFSTR("AXApplicationShown")
   
// Window notifications
#define kAXWindowCreatedNotification    CFSTR("AXWindowCreated")
#define kAXWindowMovedNotification      CFSTR("AXWindowMoved")
#define kAXWindowResizedNotification    CFSTR("AXWindowResized")
#define kAXWindowMiniaturizedNotification CFSTR("AXWindowMiniaturized")
#define kAXWindowDeminiaturizedNotification CFSTR("AXWindowDeminiaturized")
   
// New drawer,
   sheet,
   and help tag notifications
#define kAXDrawerCreatedNotification    CFSTR("AXDrawerCreated")
#define kAXSheetCreatedNotification     CFSTR("AXSheetCreated")
#define kAXHelpTagCreatedNotification   CFSTR("AXHelpTagCreated")
   
// Element notifications
#define kAXValueChangedNotification     CFSTR("AXValueChanged")
#define kAXUIElementDestroyedNotification       CFSTR("AXUIElementDestroyed")
   
// Menu notifications
#define kAXMenuOpenedNotification       CFSTR("AXMenuOpened")
#define kAXMenuClosedNotification       CFSTR("AXMenuClosed")
#define kAXMenuItemSelectedNotification CFSTR("AXMenuItemSelected")
   
// Table and outline view notifications
#define kAXRowCountChangedNotification  CFSTR("AXRowCountChanged")
   
// Miscellaneous notifications
#define kAXSelectedChildrenChangedNotification       CFSTR("AXSelectedChildrenChanged")
#define kAXResizedNotification          CFSTR("AXResized")
#define kAXMovedNotification            CFSTR("AXMoved")
#define kAXCreatedNotification          CFSTR("AXCreated")
Constants
kAXMainWindowChangedNotification

The main window has changed.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXFocusedWindowChangedNotification

The focused window has changed.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXFocusedUIElementChangedNotification

The focused accessibility object has changed.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXApplicationActivatedNotification

The application was activated (that is, brought to front).

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXApplicationDeactivatedNotification

The application was deactivated.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXApplicationHiddenNotification

The application was hidden.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXApplicationShownNotification

The application was shown (that is, a hidden application is now visible).

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXWindowCreatedNotification

A window was created. Carbon automatically sends this notification when window is created, as long as the window is implemented using Carbon window mechanisms.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXWindowMovedNotification

The window was moved (this notification is sent at the end of the window-move operation, not during it).

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXWindowResizedNotification

The window was resized (this notification is sent at the end of the window-resize operation, not during it).

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXWindowMiniaturizedNotification

The application was minimized (that is, moved into the Dock).

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXWindowDeminiaturizedNotification

The window was moved out of the Dock.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXDrawerCreatedNotification

A drawer was created (that is, a drawer now extends from this window).

Available in OS X v10.3 and later.

Declared in AXNotificationConstants.h.

kAXSheetCreatedNotification

A sheet was created (that is, a modal dialog now extends from this window).

Available in OS X v10.3 and later.

Declared in AXNotificationConstants.h.

kAXHelpTagCreatedNotification

A help tag is now visible for this accessibility object.

Available in OS X v10.4 and later.

Declared in AXNotificationConstants.h.

kAXValueChangedNotification

The value of an accessibility object’s value attribute was changed.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXUIElementDestroyedNotification

An accessibility object was disposed of.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXMenuOpenedNotification

A menu was opened.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXMenuClosedNotification

A menu was closed.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXMenuItemSelectedNotification

A menu item was selected.

Available in OS X v10.2 and later.

Declared in AXNotificationConstants.h.

kAXRowCountChangedNotification

The number of rows in this table was changed.

Available in OS X v10.4 and later.

Declared in AXNotificationConstants.h.

kAXSelectedChildrenChangedNotification

A different subset of this accessibility object’s children were selected.

Available in OS X v10.4 and later.

Declared in AXNotificationConstants.h.

kAXResizedNotification

The window has changed size.

Available in OS X v10.4 and later.

Declared in AXNotificationConstants.h.

kAXMovedNotification

The position of this accessibility object was changed.

Available in OS X v10.4 and later.

Declared in AXNotificationConstants.h.

kAXCreatedNotification

An accessibility object was created.

Available in OS X v10.4 and later.

Declared in AXNotificationConstants.h.

Orientations and Sort Directions

Define the values for the orientation and sort-direction attributes of some accessibility objects.

// Orientations
#define kAXHorizontalOrientationValue CFSTR("AXHorizontalOrientation")
#define kAXVerticalOrientationValue CFSTR("AXVerticalOrientation")
#define kAXUnknownOrientationValue  CFSTR("AXUnknownOrientation")
   
// Sort directions
#define kAXAscendingSortDirectionValue CFSTR("AXAscendingSortDirection")
#define kAXDescendingSortDirectionValue CFSTR("AXDescendingSortDirection")
#define kAXUnknownSortDirectionValue CFSTR("AXUnknownSortDirection")
Constants
kAXHorizontalOrientationValue

This object is oriented horizontally.

Available in OS X v10.2 and later.

Declared in AXValueConstants.h.

kAXVerticalOrientationValue

This object is oriented vertically.

Available in OS X v10.2 and later.

Declared in AXValueConstants.h.

kAXUnknownOrientationValue

The orientation of this object is unknown.

Available in OS X v10.4 and later.

Declared in AXValueConstants.h.

kAXAscendingSortDirectionValue

This object’s contents are sorted in ascending order.

Available in OS X v10.4 and later.

Declared in AXValueConstants.h.

AXDescendingSortDirection

This object’s contents are sorted in descending order.

kAXUnknownSortDirectionValue

The sort order of this object is unknown.

Available in OS X v10.4 and later.

Declared in AXValueConstants.h.

Discussion

See kAXOrientationAttribute and kAXSortDirectionAttribute for more information on the attributes for which you can use these values.

Result Codes

The result codes returned by the Carbon accessibility implementation are listed below. Other result codes defined in AXError.h are of use only to assistive applications.

Result CodeValueDescription
kAXErrorIllegalArgument -25201

The value received in this event is an invalid value for this attribute. This also applies for invalid parameters in parameterized attributes.

Available in OS X v10.2 and later.

kAXErrorInvalidUIElement -25202

The accessibility object received in this event is invalid.

Available in OS X v10.2 and later.

kAXErrorInvalidUIElementObserver -25203

The observer for the accessibility object received in this event is invalid.

Available in OS X v10.2 and later.

kAXErrorCannotComplete -25204

A fundamental error has occurred, such as a failure to allocate memory during processing.

Available in OS X v10.2 and later.

kAXErrorAttributeUnsupported -25205

The referenced attribute is not supported. Alternatively, you can return the eventNotHandledErr error.

Available in OS X v10.2 and later.

kAXErrorActionUnsupported -25206

The referenced action is not supported. Alternatively, you can return the eventNotHandledErr error.

Available in OS X v10.2 and later.

kAXErrorAPIDisabled -25211

Assistive applications are not enabled in System Preferences.

Available in OS X v10.2 and later.

kAXErrorParameterizedAttributeUnsupported -25213

The parameterized attribute is not supported. Alternatively, you can return the eventNotHandledErr error.

Available in OS X v10.3 and later.