PFUIElement(Attributes)


A category on PFUIElement for attribute properties and methods.

Extends Class: PFUIElement
Declared In: PFUIElement.h

Discussion

The Attributes category on PFUIElement includes two kinds of attributes: nonparameterized attributes and parameterized attributes.

The nonparameterized attributes are declared as properties. To use them, you send a \ message to their receivers (where \ is the property name, such as AXRole to read the "AXRole" attribute), just as you would use a getter accessor method. They take no parameters, and they return an Objective-C object. To set those that are settable, you send a set\: message to their receivers passing an Objective-C object (where set\: incorporates the property name, such as setAXValue: to set the "AXValue" attribute), just as you would use a setter accessor method.

The parameterized attributes are implemented as methods. You send them to a receiver with a parameter, and the value returned depends on the value of the parameter.

The accessor methods specified by the properties in the Attributes category on PFUIElement return UI element attribute values for attributes having the same name as the property. All attributes declared in the AXAttributeConstants.h and NSAccessibility.h headers are included (except where they are marked obsolete). Note that some attributes appear in only one of those headers.

Individual properties are named according to the string value of the attribute, not its constant name in the AXAttributeConstants.h or NSAccessibility.h header. They are classified approximately the same as in AXAttributeConstants.h, which differs in minor ways from the classification in NSAccessibility.h. Classification of attributes is for ease of understanding only and has no functional significance. It can be misleading, because Apple encourages developers to use existing attribute names for custom objects where possible, and they may therefore be used for new purposes.

The properties in this category are mostly for convenience. Instead of using them, you can send -valueForAttribute: and -setValue:forAttribute: with the appropriate accessibility API constant from AXAttributeConstants.h (cast to NSString*) or NSAccessibility.h. These two methods use key-value coding to find and send one of these properties by name or, if it is not found, to fall back on a private method that calls the accessibility API directly. The net effect is that the framework will always find all attributes, even new attributes that are added to the accessibility API in future versions of Mac OS X and custom attributes that are implemented by other applications such as the Finder and Safari. You must send -valueForAttribute: and -setValue:forAttribute: instead of a specific property when you don't know in advance which attribute to use, for example, when using a list of attributes obtained from the -nonParameterizedAttributes method.

There is a slight efficiency advantage in sending an accessor message instead of using the -valueForAttribute: and -setValue:forAttribute: methods. Either technique will execute any special code, such as bug fixes, that is included in a particular accessor method.

All attribute values are Objective-C objects returned autoreleased.

See -attributes for information regarding the use of the attribute properties.



Groups

ATTRIBUTES - visual state

Group members:

AXEnabled

Whether the receiver is enabled.

AXFocused

Whether the receiver has keyboard focus.

AXPosition

The receiver's position on the screen.

AXSize

The receiver's size on the screen.

 

ATTRIBUTES - item

Group members:

AXHandles

The receiver's handle UI elements.

 

ATTRIBUTES - layout areas

Group members:

AXHorizontalUnitDescription

A localized string describing the receiver's horizontal units of measurement, suitable for display or speech.

AXHorizontalUnits

A technical, non-localized string representing the receiver's horizontal units of measurement.

AXVerticalUnitDescription

A localized string describing the receiver's vertical units of measurement, suitable for display or speech.

AXVerticalUnits

A technical, non-localized string representing the receiver's vertical units of measurement.

 

ATTRIBUTES - date/time-specific

Group members:

AXAMPMField

The AM/PM field in the receiving clock control.

AXDayField

The day field in the receiving clock control.

AXHourField

The hour field in the receiving clock control.

AXMinuteField

The minute field in the receiving clock control.

AXMonthField

The month field in the receiving clock control.

AXSecondField

The second field in the receiving clock control.

AXYearField

The year field in the receiving clock control.

 

ATTRIBUTES - level indicator

Group members:

AXCriticalValue

The receiving level indicator's critical value.

AXWarningValue

The receiving level indicator's warning value.

 

ATTRIBUTES - text-specific

Group members:

AXInsertionPointLineNumber

The line index of a naked insertion point in the receiving text object.

AXNumberOfCharacters

The number of characters in the receiver's text.

AXSelectedText

The receiver's selected text.

AXSelectedTextRange

The range of the receiver's text selection.

AXSelectedTextRanges

The ranges of the receiver's noncontiguous multiple text selections.

AXSharedCharacterRange

The range of characters in a larger text object that are contained in the receiving text view, which shares the text object with other text view elements.

AXSharedTextUIElements

An array containing all of the text view elements that share a larger text object, a portion of which is contained in the receiving text view.

AXVisibleCharacterRange

The range of the receiver's visible text.

 

ATTRIBUTES - stepper-specific

Group members:

AXDecrementButton

The receiving stepper's decrement button.

AXIncrementButton

The receiving stepper's increment button.

AXIncrementor

A stepper UI element.

 

PARAMETERIZED ATTRIBUTES - layout area

Group members:

-AXLayoutPointForScreenPoint:

Returns the point in the layout area coordinate system corresponding to screenPoint in top-left relative screen coordinates.

-AXLayoutSizeForScreenSize:

Returns the size in the layout area coordinate system corresponding to screenSize in screen coordinates.

-AXScreenPointForLayoutPoint:

Returns the point in top-left relative screen coordinates corresponding to layoutPoint in the layout area coordinate system.

-AXScreenSizeForLayoutSize:

Returns the size in screen coordinates corresponding to layoutSizein the layout area coordinate system.

 

ATTRIBUTES - hierarchy

Group members:

AXChildren

The receiver's children UI elements.

AXParent

The receiver's parent UI element.

AXSelectedChildren

The receiver's selected children UI elements.

AXTopLevelUIElement

The top-level UI element containing the receiver.

AXVisibleChildren

The receiver's visible children UI elements.

AXWindow

The window UI element containing the receiver.

 

ATTRIBUTES - cells

Group members:

AXColumnIndexRange

The range of the receiver's column indexes.

AXRowIndexRange

The range of the receiver's row indexes.

 

ATTRIBUTES - relationship

Group members:

AXLinkedUIElements

The UI elements that are linked to the receiver.

AXServesAsTitleForUIElements

The UI elements for which the receiver serves as title.

AXTitleUIElement

A separate UI element that serves as the receiver's title.

 

ATTRIBUTES - window, sheet, or drawer-specific

Group members:

AXCancelButton

The receiving window's cancel button.

AXCloseButton

The close button in the receiving window's title bar.

AXDefaultButton

The receiving window's default button.

AXGrowArea

The grow area in the bottom-right corner of the receiving window.

AXMain

Whether the receiver is the target application's main window.

AXMinimizeButton

The minimize button in the receiving window's title bar.

AXMinimized

Whether the receiving window is minimized to the Dock.

AXModal

Whether the receiver is a modal window.

AXProxy

The proxy icon in the receiving window's title bar representing the window's document.

AXToolbarButton

The toolbar button in the receiving window's title bar.

AXZoomButton

The zoom button in the receiving window's title bar.

 

ATTRIBUTES - slider-specific

Group members:

AXLabelUIElements

The labels for a slider or similar control.

AXLabelValue

The value of the receiving label.

 

ATTRIBUTES - screen matte-specific

Group members:

AXMatteContentUIElement

The object clipped by the receiving screen matte.

AXMatteHole

The bounds of the receiving screen matte's hole in screen coordinates.

 

ATTRIBUTES - search field-specific

Group members:

AXClearButton

The clear button element in the receiving search field.

AXSearchButton

The search button element in the receiving search field.

AXSearchMenu

The search pop-up menu element in the receiving search field.

 

PARAMETERIZED ATTRIBUTES - text suite

Group members:

-AXAttributedStringForRange:

Returns the text of the characters in characterRange in the receiving text object, as an attributed string.

-AXBoundsForRange:

Returns the bounds on the screen enclosing the characters in characterRange in the receiving text object.

-AXLineForIndex:

Returns the line index of the line containing the character at characterIndex in the receiving text object.

-AXRangeForIndex:

Returns the range of characters in the receiving text object composing the single glyph that contains characterIndex.

-AXRangeForLine:

Returns the range of characters contained in the line of text at lineIndex in the receiving text object.

-AXRangeForPosition:

Returns the range of characters in the receiving text object composing the single glyph located at glyphPosition, a point on the screen in top-left relative screen coordinates.

-AXRTFForRange:

Returns the text of the characters in characterRange in the receiving text object, as RTF data.

-AXStringForRange:

Returns the text of the characters in characterRange in the receiving text object, as a string.

-AXStyleRangeForIndex:

Returns the range of characters in the receiving text object composing a single style run that contains characterIndex.

 

ATTRIBUTES - application element-specific

Group members:

AXFocusedUIElement

The receiving application's focused UI element.

AXFocusedWindow

The receiving application's key window, the window that has keyboard focus.

AXFrontmost

Whether the receiving application is frontmost.

AXHidden

Whether the receiving application is hidden.

AXMainWindow

The receiving application's main window.

AXMenuBar

The receiving application's menu bar element.

AXWindows

The receiving application's open window elements.

 

ATTRIBUTES - value

Group members:

AXAllowedValues

An array of discrete values that the receiver can assume.

AXMaxValue

The largest legal value of the receiver.

AXMinValue

The smallest legal value of the receiver.

AXPlaceholderValue

The string that appears in a text field or similar element as its placeholder.

AXValue

The receiver's value.

AXValueDescription

A localized string describing the receiver's value, suitable for display or speech.

AXValueIncrement

The magnitude of each increment of the receiver's value.

AXValueWraps

Whether the receiver wraps; that is, if stepping in one direction eventually returns the receiver to its initial value.

 

ATTRIBUTES - Dock

Group members:

AXIsApplicationRunning

Whether the application represented by the receiving application dock item is running.

 

ATTRIBUTES - system-wide

Group members:

AXFocusedApplication

The receiving system-wide UI element's focused application element.

 

ATTRIBUTES - ruler-specific

Group members:

AXMarkerGroupUIElement

A group element containing the receiving text ruler's markers.

AXMarkerType

A technical, non-localized string designating the receiving text ruler marker's type.

AXMarkerTypeDescription

A localized string describing the receiving text ruler marker, suitable for display or speech.

AXMarkerUIElements

The receiving text ruler's marker elements.

AXMarkerValues

The values of the receiving text ruler's marker elements.

AXUnitDescription

A localized string describing the receiving text ruler's units of measurement, suitable for display or speech.

AXUnits

A technical, non-localized string representing the receiving text ruler's units of measurement.

 

PARAMETERIZED ATTRIBUTES - cell-based table

Group members:

-AXCellForColumnAndRow:

Returns the cell in the receiving cell-based table at the intersection of the column and row in columnAndRowArray.

 

ATTRIBUTES - grid

Group members:

AXColumnCount

The number of columns in the receiving grid element.

AXOrderedByRow

Whether the receiving grid element is ordered by rows.

AXRowCount

The number of rows in the receiving grid element.

 

ATTRIBUTES - menu or menu item-specific

Group members:

AXMenuItemCmdChar

The receiving menu item's keyboard shortcut as a single-character string.

AXMenuItemCmdGlyph

The receiving menu item's keyboard shortcut as a glyph code.

AXMenuItemCmdModifiers

The modifier key combination required by the receiving menu item's keyboard shortcut.

AXMenuItemCmdVirtualKey

The receiving menu item's keyboard shortcut as a virtual key code.

AXMenuItemMarkChar

The receiving menu item's mark character.

AXMenuItemPrimaryUIElement

The receiving menu item's primary menu item element.

AXShownMenuUIElement

The menu element currently being displayed.

 

ATTRIBUTES - table, outline, or browser-specific

Group members:

AXColumns

The columns of the receiving table or outline.

AXColumnTitles

The receiving browser's column title elements.

AXHeader

The receiving table or outline column's header element.

AXIndex

The index of the receiver.

AXRows

The rows of the receiving table or outline.

AXSelectedColumns

The selected columns of the receiving table or outline.

AXSelectedRows

The selected rows of the receiving table or outline.

AXSortDirection

A technical, non-localized string designating the receiving column's sort direction.

AXVisibleColumns

The visible columns of the receiving table or outline.

AXVisibleRows

The visible rows of the receiving table or outline.

 

ATTRIBUTES - outline-specific

Group members:

AXDisclosedByRow

The receiving outline child row's parent row.

AXDisclosedRows

The expanded child rows of the receiving parent outline view row.

AXDisclosing

Whether the receiving outline view row is expanded.

AXDisclosureLevel

The indentation level of the receiving outline row.

 

ATTRIBUTES - informational

Group members:

AXDescription

A localized string specifically describing the receiver.

AXHelp

A localized string providing helpful information regarding the receiver.

AXRole

A technical, non-localized string representing the receiver's role.

AXRoleDescription

A localized string describing the receiver's role or subrole, suitable for display or speech.

AXSubrole

A technical, non-localized string representing the receiver's subrole.

AXTitle

A localized string that is the receiver's title.

 

ATTRIBUTES - cell-based tables

Group members:

AXColumnHeaderUIElements

The receiver's column header UI elements.

AXRowHeaderUIElements

The receiver's row header UI elements.

AXSelectedCells

The receiving cell-based table's selected cell UI elements.

AXVisibleCells

The receiving cell-based table's visible cell UI elements.

 

ATTRIBUTES - miscellaneous or role-specific

Group members:

AXContents

The main contents of the receiver.

AXDocument

The receiver's path as a file URL.

AXEdited

Whether the receiver has been edited since it was last saved.

AXExpanded

Whether the receiving disclosure triangle is expanded.

AXFilename

The receiver's file name.

AXHorizontalScrollBar

The receiving scroller's horizontal scroll bar element.

AXNextContents

The contents of the subview following the splitter bar in a split group or a similar divider.

AXOrientation

A technical, non-localized string designating the receiver's orientation on the screen.

AXOverflowButton

The receiving toolbar's overflow button element.

AXPreviousContents

The contents of the subview preceding the splitter bar in a split group or a similar divider.

AXSelected

Whether the receiver is selected.

AXSplitters

The splitter bar elements in the receiving split group.

AXTabs

The receiving tab group's tab elements.

AXURL

The receiver's associated file URL.

AXVerticalScrollBar

The receiving scroller's vertical scroll bar element.


Methods

-AXAttributedStringForRange:

Returns the text of the characters in characterRange in the receiving text object, as an attributed string.

-AXBoundsForRange:

Returns the bounds on the screen enclosing the characters in characterRange in the receiving text object.

-AXCellForColumnAndRow:

Returns the cell in the receiving cell-based table at the intersection of the column and row in columnAndRowArray.

-AXLayoutPointForScreenPoint:

Returns the point in the layout area coordinate system corresponding to screenPoint in top-left relative screen coordinates.

-AXLayoutSizeForScreenSize:

Returns the size in the layout area coordinate system corresponding to screenSize in screen coordinates.

-AXLineForIndex:

Returns the line index of the line containing the character at characterIndex in the receiving text object.

-AXRangeForIndex:

Returns the range of characters in the receiving text object composing the single glyph that contains characterIndex.

-AXRangeForLine:

Returns the range of characters contained in the line of text at lineIndex in the receiving text object.

-AXRangeForPosition:

Returns the range of characters in the receiving text object composing the single glyph located at glyphPosition, a point on the screen in top-left relative screen coordinates.

-AXRTFForRange:

Returns the text of the characters in characterRange in the receiving text object, as RTF data.

-AXScreenPointForLayoutPoint:

Returns the point in top-left relative screen coordinates corresponding to layoutPoint in the layout area coordinate system.

-AXScreenSizeForLayoutSize:

Returns the size in screen coordinates corresponding to layoutSizein the layout area coordinate system.

-AXStringForRange:

Returns the text of the characters in characterRange in the receiving text object, as a string.

-AXStyleRangeForIndex:

Returns the range of characters in the receiving text object composing a single style run that contains characterIndex.


AXAttributedStringForRange:


Returns the text of the characters in characterRange in the receiving text object, as an attributed string.

- (NSAttributedString *)AXAttributedStringForRange:(NSValue *)characterRange; 
Parameters
characterRange

An NSValue object encoding an NSRange structure describing a range of characters in the receiving text object, counting all characters from the beginning of the text object even if it flows across multiple text views.

Return Value

An NSAttributedString object containing the attributed string of the receiving text object in characterRange.

Discussion

This is a parameterized attribute method to read text objects. Given a character range in the receiving text object, it returns the characters in that range as an NSAttributedString object, including formatting.

The text attributes contained in the dictionary object associated with the attributed string returned by this method are not intended for visual display, but instead to provide information that is useful in the accessibility context. They differ from the text attributes in a standard text system NSAttributedString object and in its CFAttributedString counterpart. The keys are prefixed with "AX" instead of "NS", as in "AXFont" instead of "NSFont", and their contents may differ from the contents of their standard text system analogs. They are declared in the AXTextAttributedString.h header.

The accessibility attributed string returned by this method therefore cannot be displayed in a text view without first converting it to a standard attributed string. See -attributedStringFromAXAttributedString: for more information, and use that method to effect the conversion.

The characterRange parameter can be any range of characters in a text object. To obtain a character range for a specific line in a text object, see AXRangeForLine:. To obtain a character range for a style run in a text object, see AXStyleRangeForIndex:.

See also AXStringForRange: and AXRTFForRange:.


AXBoundsForRange:


Returns the bounds on the screen enclosing the characters in characterRange in the receiving text object.

- (NSValue *)AXBoundsForRange:(NSValue *)characterRange; 
Parameters
characterRange

An NSValue object encoding an NSRange structure describing a range of characters in the receiving text object, counting all characters from the beginning of the text object even if it flows across multiple text views.

Return Value

An NSValue object encoding an NSRect struct.

Discussion

This is a parameterized attribute method to read text objects. Given a character range in the receiving text object, it returns the bounds on the screen enclosing the characters.

The characterRange parameter can be any range of characters in a text object. To obtain a character range for a specific line in a text object, see AXRangeForLine:. To obtain a character range for a style run in a text object, see AXStyleRangeForIndex:.

In the case of a range of characters that encompasses more than one line, the returned bounds encloses all of the characters in the range, in all lines.

Use NSValue's -rectValue method to extract the NSRect structure of the result.


AXCellForColumnAndRow:


Returns the cell in the receiving cell-based table at the intersection of the column and row in columnAndRowArray.

- (PFUIElement *)AXCellForColumnAndRow:(NSArray *)columnAndRowArray; 
Parameters
columnAndRowArray

An NSArray object containing two NSNumber objects encoding integer values that are the column index and the row index (in that order) in the receiving cell-based table.

Return Value

A PFUIElement object.

Discussion

This is a parameterized attribute method to read cell-based table objects. Given an array containing the column index and the row index in the receiving cell-based table object, it returns the cell object. This method is available, for example, in Apple's Numbers application.

Availability: Introduced in Mac OS X v10.6.


AXLayoutPointForScreenPoint:


Returns the point in the layout area coordinate system corresponding to screenPoint in top-left relative screen coordinates.

- (NSValue *)AXLayoutPointForScreenPoint:(NSValue *)screenPoint; 
Parameters
screenPoint

An NSValue object encoding an NSPoint structure describing a position on the screen in top-left relative screen coordinates that is within a layout area.

Return Value

An NSValue object encoding an NSPoint structure.

Discussion

This is a parameterized attribute method to read cell-based table objects. Given a point on the screen in top-left relative screen coordinates, it returns the corresponding point in the receiving layout area in the layout area's coordinate system. This method is available, for example, in Apple's Numbers application.

The units of measurement used in the layout area may differ from those used on the screen. See AXHorizontalUnits and AXVerticalUnits.

Use NSValue's -pointValue method to extract the NSPoint structure of the result.

Availability: Introduced in Mac OS X v10.6.

See also AXScreenPointForLayoutPoint:.


AXLayoutSizeForScreenSize:


Returns the size in the layout area coordinate system corresponding to screenSize in screen coordinates.

- (NSValue *)AXLayoutSizeForScreenSize:(NSValue *)screenSize; 
Parameters
screenSize

An NSValue object encoding an NSSize structure describing the size on the screen in screen coordinates of a layout area.

Return Value

An NSValue object encoding an NSSize structure.

Discussion

This is a parameterized attribute method to read layout area objects. Given the size on the screen in screen coordinates, it returns the corresponding size of the receiving layout area in the layout area's coordinate system. This method is available, for example, in Apple's Numbers application.

The units of measurement used in the layout area may differ from those used on the screen. See AXHorizontalUnits and AXVerticalUnits.

Use NSValue's -sizeValue method to extract the NSSize structure of the result.

Availability: Introduced in Mac OS X v10.6.

See also AXScreenPointForLayoutPoint:.


AXLineForIndex:


Returns the line index of the line containing the character at characterIndex in the receiving text object.

- (NSNumber *)AXLineForIndex:(NSNumber *)characterIndex; 
Parameters
characterIndex

An NSNumber encoding an integer value that is the index of a character in the receiving text object, counting all characters from the beginning of the text object even if it flows across multiple text views.

Return Value

An NSNumber object encoding an integer value.

Discussion

This is a parameterized attribute method to read text objects. Given a character index in the receiving text object, it returns the index of the line of text in which the character appears.

This is a common way to use the parameterized text methods: start with a character index, typically obtained by reading the screen to obtain a reference to the glyph under the mouse pointer. See AXRangeForPosition: for information on obtaining the character range of the glyph at a specified screen position. A character's index is its sequential index, counting all characters from the beginning of the text object even if it flows across multiple text containers or views such as pages or columns.

It can be important in some circumstances to avoid using character indexes that fall in the middle of a glyph. See -AXRangeForIndex: for information about obtaining the starting character index and length of any glyph.

The result returned by this method can be ambiguous when you are attempting to determine the line index of a naked insertion point at characterIndex. See -AXInsertionPointLineNumber for information and a technique to resolve the ambiguity.

See -AXRangeForPosition: for information about obtaining the character index and length of a glyph on the screen for use in a screen reader application.

Use NSNumber's -intValue method to extract the integer value of the result.


AXRangeForIndex:


Returns the range of characters in the receiving text object composing the single glyph that contains characterIndex.

- (NSValue *)AXRangeForIndex:(NSNumber *)characterIndex; 
Parameters
characterIndex

An NSNumber encoding an integer value that is the index of a character in the receiving text object within a single glyph, counting all characters from the beginning of the text object even if it flows across multiple text views.

Return Value

An NSValue object encoding an NSRange structure.

Discussion

This is a parameterized attribute method to read text objects. Given a character index in the receiving text object, it returns the range of characters in the receiving text object composing the glyph.

This method is based on the premise that a glyph may be composed of one or more characters.

Use this method to obtain the character range of a single glyph based on its position within the receiving text view.

Use NSValue's -rangeValue method to extract the NSRange structure of the result.


AXRangeForLine:


Returns the range of characters contained in the line of text at lineIndex in the receiving text object.

- (NSValue *)AXRangeForLine:(NSNumber *)lineIndex; 
Parameters
lineIndex

An NSNumber encoding an integer value that is the index of a line, counting all lines from the beginning of the text object even if it flows aross multiple text views.

Return Value

An NSValue object encoding an NSRange structure.

Discussion

This is a parameterized attribute method to read text objects. Given a line index in the receiving text object, it returns the range of characters contained in the line of text.

A screen reader typically obtains the line index by first obtaining the character index under the mouse pointer and then calling AXLineForIndex:.

Use NSValue's -rangeValue method to extract the NSRange structure of the result.


AXRangeForPosition:


Returns the range of characters in the receiving text object composing the single glyph located at glyphPosition, a point on the screen in top-left relative screen coordinates.

- (NSValue *)AXRangeForPosition:(NSValue *)glyphPosition; 
Parameters
glyphPosition

An NSValue object encoding an NSPoint structure describing a position on the screen in top-left relative screen coordinates that is within a single glyph.

Return Value

An NSValue object encoding an NSRange structure.

Discussion

This method is based on the premise that a glyph may be composed of one or more characters. It can be important to avoid using character indexes that fall in the middle of a glyph.

Use this method to obtain the character range of a single glyph based on its position on the screen, for example, the character range of the glyph under the mouse. See -elementAtPoint:withDelegate:error: for information about obtaining the current position of the mouse. In a screen reader application, use the resulting character range returned by this method as a route into the other parameterized methods which take a character index, character range, or (indirectly from the character index) line index as input. The location field of the character range is the character index of the first character of the glyph, and the length field of the character range is the number of characters to the next glyph.

Use NSValue's -rangeValue method to extract the NSRange structure of the result.


AXRTFForRange:


Returns the text of the characters in characterRange in the receiving text object, as RTF data.

- (NSData *)AXRTFForRange:(NSValue *)characterRange; 
Parameters
characterRange

An NSValue object encoding an NSRange structure describing a range of characters in the receiving text object, counting all characters from the beginning of the text object even if it flows across multiple text views.

Return Value

An NSData object containing the RTF data of the receiving text object in characterRange.

Discussion

This is a parameterized attribute method to read text objects. Given a character range in the receiving text object, it returns the characters in that range as an NSData object, including formatting.

The characterRange parameter can be any range of characters in a text object. To obtain a character range for a specific line in a text object, see AXRangeForLine:. To obtain a character range for a style run in a text object, see AXStyleRangeForIndex:.

See also AXStringForRange: and AXAttributedStringForRange:.


AXScreenPointForLayoutPoint:


Returns the point in top-left relative screen coordinates corresponding to layoutPoint in the layout area coordinate system.

- (NSValue *)AXScreenPointForLayoutPoint:(NSValue *)layoutPoint; 
Parameters
layoutPoint

An NSValue object encoding an NSPoint structure describing a position in the receiving layout area in layout area coordinates.

Return Value

An NSValue object encoding an NSPoint structure.

Discussion

This is a parameterized attribute method to read cell-based table objects. Given a point in the receiving layout area in the layout area's coordinate system, it returns the corresponding point on the screen in top-left relative screen coordinates.

The units of measurement used in the layout area may differ from those used on the screen. See AXHorizontalUnits and AXVerticalUnits.

Use NSValue's -pointValue method to extract the NSPoint structure of the result.

Availability: Introduced in Mac OS X v10.6.

See also AXScreenSizeForLayoutSize:.


AXScreenSizeForLayoutSize:


Returns the size in screen coordinates corresponding to layoutSizein the layout area coordinate system.

- (NSValue *)AXScreenSizeForLayoutSize:(NSValue *)layoutSize; 
Parameters
layoutSize

An NSValue object encoding an NSSize structure describing the size of the receiving layout area in the layout area's coordinate system.

Return Value

An NSValue object encoding an NSSize structure.

Discussion

This is a parameterized attribute method to read layout area objects. Given the size of the receiving layout area in the layout area's coordinate systemon, it returns the corresponding size on the screen in screen coordinates.

The units of measurement used in the layout area may differ from those used on the screen. See AXHorizontalUnits and AXVerticalUnits.

Use NSValue's -sizeValue method to extract the NSSize structure of the result.

Availability: Introduced in Mac OS X v10.6.

See also AXLayoutSizeForScreenSize:.


AXStringForRange:


Returns the text of the characters in characterRange in the receiving text object, as a string.

- (NSString *)AXStringForRange:(NSValue *)characterRange; 
Parameters
characterRange

An NSValue object encoding an NSRange structure describing a range of characters in the receiving text object, counting all characters from the beginning of the text object even if it flows across multiple text views.

Return Value

An NSString object.

Discussion

This is a parameterized attribute method to read text objects. Given a character range in the receiving text object, it returns the characters in that range as an NSString object.

The characterRange parameter can be any range of characters in a text object. To obtain a character range for a specific line in a text object, see AXRangeForLine:. To obtain a character range for a style run in a text object, see AXStyleRangeForIndex:.

See also AXRTFForRange: and AXAttributedStringForrange:.


AXStyleRangeForIndex:


Returns the range of characters in the receiving text object composing a single style run that contains characterIndex.

- (NSValue *)AXStyleRangeForIndex:(NSNumber *)characterIndex; 
Parameters
characterIndex

An NSNumber encoding an integer value that is the index of a character in the receiving text object, counting all characters from the beginning of the text object even if it flows across multiple text views.

Return Value

An NSValue object encoding an NSRange structure.

Discussion

This is a parameterized attribute method to read text objects. Given a character index in the receiving text object, it returns the range of characters in the receiving text object composing the style run.

Use NSValue's -rangeValue method to extract the NSRange structure of the result.

Properties

AXAllowedValues

An array of discrete values that the receiver can assume.

AXAMPMField

The AM/PM field in the receiving clock control.

AXCancelButton

The receiving window's cancel button.

AXChildren

The receiver's children UI elements.

AXClearButton

The clear button element in the receiving search field.

AXCloseButton

The close button in the receiving window's title bar.

AXColumnCount

The number of columns in the receiving grid element.

AXColumnHeaderUIElements

The receiver's column header UI elements.

AXColumnIndexRange

The range of the receiver's column indexes.

AXColumns

The columns of the receiving table or outline.

AXColumnTitles

The receiving browser's column title elements.

AXContents

The main contents of the receiver.

AXCriticalValue

The receiving level indicator's critical value.

AXDayField

The day field in the receiving clock control.

AXDecrementButton

The receiving stepper's decrement button.

AXDefaultButton

The receiving window's default button.

AXDescription

A localized string specifically describing the receiver.

AXDisclosedByRow

The receiving outline child row's parent row.

AXDisclosedRows

The expanded child rows of the receiving parent outline view row.

AXDisclosing

Whether the receiving outline view row is expanded.

AXDisclosureLevel

The indentation level of the receiving outline row.

AXDocument

The receiver's path as a file URL.

AXEdited

Whether the receiver has been edited since it was last saved.

AXEnabled

Whether the receiver is enabled.

AXExpanded

Whether the receiving disclosure triangle is expanded.

AXFilename

The receiver's file name.

AXFocused

Whether the receiver has keyboard focus.

AXFocusedApplication

The receiving system-wide UI element's focused application element.

AXFocusedUIElement

The receiving application's focused UI element.

AXFocusedWindow

The receiving application's key window, the window that has keyboard focus.

AXFrontmost

Whether the receiving application is frontmost.

AXGrowArea

The grow area in the bottom-right corner of the receiving window.

AXHandles

The receiver's handle UI elements.

AXHeader

The receiving table or outline column's header element.

AXHelp

A localized string providing helpful information regarding the receiver.

AXHidden

Whether the receiving application is hidden.

AXHorizontalScrollBar

The receiving scroller's horizontal scroll bar element.

AXHorizontalUnitDescription

A localized string describing the receiver's horizontal units of measurement, suitable for display or speech.

AXHorizontalUnits

A technical, non-localized string representing the receiver's horizontal units of measurement.

AXHourField

The hour field in the receiving clock control.

AXIncrementButton

The receiving stepper's increment button.

AXIncrementor

A stepper UI element.

AXIndex

The index of the receiver.

AXInsertionPointLineNumber

The line index of a naked insertion point in the receiving text object.

AXIsApplicationRunning

Whether the application represented by the receiving application dock item is running.

AXLabelUIElements

The labels for a slider or similar control.

AXLabelValue

The value of the receiving label.

AXLinkedUIElements

The UI elements that are linked to the receiver.

AXMain

Whether the receiver is the target application's main window.

AXMainWindow

The receiving application's main window.

AXMarkerGroupUIElement

A group element containing the receiving text ruler's markers.

AXMarkerType

A technical, non-localized string designating the receiving text ruler marker's type.

AXMarkerTypeDescription

A localized string describing the receiving text ruler marker, suitable for display or speech.

AXMarkerUIElements

The receiving text ruler's marker elements.

AXMarkerValues

The values of the receiving text ruler's marker elements.

AXMatteContentUIElement

The object clipped by the receiving screen matte.

AXMatteHole

The bounds of the receiving screen matte's hole in screen coordinates.

AXMaxValue

The largest legal value of the receiver.

AXMenuBar

The receiving application's menu bar element.

AXMenuItemCmdChar

The receiving menu item's keyboard shortcut as a single-character string.

AXMenuItemCmdGlyph

The receiving menu item's keyboard shortcut as a glyph code.

AXMenuItemCmdModifiers

The modifier key combination required by the receiving menu item's keyboard shortcut.

AXMenuItemCmdVirtualKey

The receiving menu item's keyboard shortcut as a virtual key code.

AXMenuItemMarkChar

The receiving menu item's mark character.

AXMenuItemPrimaryUIElement

The receiving menu item's primary menu item element.

AXMinimizeButton

The minimize button in the receiving window's title bar.

AXMinimized

Whether the receiving window is minimized to the Dock.

AXMinuteField

The minute field in the receiving clock control.

AXMinValue

The smallest legal value of the receiver.

AXModal

Whether the receiver is a modal window.

AXMonthField

The month field in the receiving clock control.

AXNextContents

The contents of the subview following the splitter bar in a split group or a similar divider.

AXNumberOfCharacters

The number of characters in the receiver's text.

AXOrderedByRow

Whether the receiving grid element is ordered by rows.

AXOrientation

A technical, non-localized string designating the receiver's orientation on the screen.

AXOverflowButton

The receiving toolbar's overflow button element.

AXParent

The receiver's parent UI element.

AXPlaceholderValue

The string that appears in a text field or similar element as its placeholder.

AXPosition

The receiver's position on the screen.

AXPreviousContents

The contents of the subview preceding the splitter bar in a split group or a similar divider.

AXProxy

The proxy icon in the receiving window's title bar representing the window's document.

AXRole

A technical, non-localized string representing the receiver's role.

AXRoleDescription

A localized string describing the receiver's role or subrole, suitable for display or speech.

AXRowCount

The number of rows in the receiving grid element.

AXRowHeaderUIElements

The receiver's row header UI elements.

AXRowIndexRange

The range of the receiver's row indexes.

AXRows

The rows of the receiving table or outline.

AXSearchButton

The search button element in the receiving search field.

AXSearchMenu

The search pop-up menu element in the receiving search field.

AXSecondField

The second field in the receiving clock control.

AXSelected

Whether the receiver is selected.

AXSelectedCells

The receiving cell-based table's selected cell UI elements.

AXSelectedChildren

The receiver's selected children UI elements.

AXSelectedColumns

The selected columns of the receiving table or outline.

AXSelectedRows

The selected rows of the receiving table or outline.

AXSelectedText

The receiver's selected text.

AXSelectedTextRange

The range of the receiver's text selection.

AXSelectedTextRanges

The ranges of the receiver's noncontiguous multiple text selections.

AXServesAsTitleForUIElements

The UI elements for which the receiver serves as title.

AXSharedCharacterRange

The range of characters in a larger text object that are contained in the receiving text view, which shares the text object with other text view elements.

AXSharedTextUIElements

An array containing all of the text view elements that share a larger text object, a portion of which is contained in the receiving text view.

AXShownMenuUIElement

The menu element currently being displayed.

AXSize

The receiver's size on the screen.

AXSortDirection

A technical, non-localized string designating the receiving column's sort direction.

AXSplitters

The splitter bar elements in the receiving split group.

AXSubrole

A technical, non-localized string representing the receiver's subrole.

AXTabs

The receiving tab group's tab elements.

AXTitle

A localized string that is the receiver's title.

AXTitleUIElement

A separate UI element that serves as the receiver's title.

AXToolbarButton

The toolbar button in the receiving window's title bar.

AXTopLevelUIElement

The top-level UI element containing the receiver.

AXUnitDescription

A localized string describing the receiving text ruler's units of measurement, suitable for display or speech.

AXUnits

A technical, non-localized string representing the receiving text ruler's units of measurement.

AXURL

The receiver's associated file URL.

AXValue

The receiver's value.

AXValueDescription

A localized string describing the receiver's value, suitable for display or speech.

AXValueIncrement

The magnitude of each increment of the receiver's value.

AXValueWraps

Whether the receiver wraps; that is, if stepping in one direction eventually returns the receiver to its initial value.

AXVerticalScrollBar

The receiving scroller's vertical scroll bar element.

AXVerticalUnitDescription

A localized string describing the receiver's vertical units of measurement, suitable for display or speech.

AXVerticalUnits

A technical, non-localized string representing the receiver's vertical units of measurement.

AXVisibleCells

The receiving cell-based table's visible cell UI elements.

AXVisibleCharacterRange

The range of the receiver's visible text.

AXVisibleChildren

The receiver's visible children UI elements.

AXVisibleColumns

The visible columns of the receiving table or outline.

AXVisibleRows

The visible rows of the receiving table or outline.

AXWarningValue

The receiving level indicator's warning value.

AXWindow

The window UI element containing the receiver.

AXWindows

The receiving application's open window elements.

AXYearField

The year field in the receiving clock control.

AXZoomButton

The zoom button in the receiving window's title bar.


AXAllowedValues


An array of discrete values that the receiver can assume.

@property(
    readonly) NSArray *AXAllowedValues; 
Return Value

An NSArray object containing objects of any type (typically NSNumber).

Discussion

The AXAllowedValues attribute applies to a stepper and similar noncontinuous elements, returning an array of discrete values that the receiving element can assume. The objects in the array are of the same type as the manipulated element's AXValue attribute.


AXAMPMField


The AM/PM field in the receiving clock control.

@property(
    readonly) PFUIElement *AXAMPMField; 
Return Value

A PFUIElement object.

Discussion

The AXAMPMField attribute applies to a clock control element, returning its AMPM field.


AXCancelButton


The receiving window's cancel button.

@property(
    readonly) PFUIElement *AXCancelButton; 
Return Value

A PFUIElement object, or nil if the receiving window does not have a cancel button.

Discussion

The AXCancelButton attribute applies to a window object. It is a convenience method to make it easy to access a window's cancel button.


AXChildren


The receiver's children UI elements.

@property(
    readonly) NSArray *AXChildren; 
Return Value

An array of PFUIElement objects, or nil if the receiver does not have a children attribute.

Discussion

An element's AXChildren attribute represents all of the elements that it contains in the visual, on-screen element hierarchy. For example, a window's children are the elements, such as buttons and text fields, that appear at the top level of the window, and a menu's children are its menu items.

There is a one-to-many relationship between a parent and its children. A child can have only one parent, while a parent can have many children.

The AXParent and AXChildren attributes are key players in an assistive application's navigation up and down a target application's accessibility containment hierarchy.

A parent and its children must match in both directions. That is, a child's parent must have the child as one of its children, and a parent's child must have the parent as its only parent. Any failure of the accessibility containment hierarch to match in both directions is the result of an application bug. The bug may cause an element browser (which looks "up" the hierarchy from the "root" application element through its children) or a screen reader (which looks "down" the hierarchy from a "leaf" element on the screen through its parents) to fail. A surprising number of applications exhibit this bug with respect to some of their elements.

See also AXParent.


AXClearButton


The clear button element in the receiving search field.

@property(
    readonly) PFUIElement *AXClearButton; 
Return Value

A PFUIElement object, or nil if the receiving search field does not have a clear button.

Discussion

The AXClearButton attribute applies to a search field, returning its clear button.


AXCloseButton


The close button in the receiving window's title bar.

@property(
    readonly) PFUIElement *AXCloseButton; 
Return Value

A PFUIElement object, or nil if the receiving window does not have a close button.

Discussion

The AXCloseButton attribute applies to a window object. It is a convenience method to make it easy to access a window's close button.


AXColumnCount


The number of columns in the receiving grid element.

@property(
    readonly) NSNumber *AXColumnCount; 
Return Value

An NSNumber object encoding an integer value, or nil if the receiver does not have a column count attribute.

Discussion

The AXColumnCount attribute applies to grids, returning the number of columns in the table.

Use NSNumber's -intValue method or similar to extract the integer value of the result.

See also AXRowCount.


AXColumnHeaderUIElements


The receiver's column header UI elements.

@property(
    readonly) NSArray *AXColumnHeaderUIElements; 
Return Value

An array of PFUIElement objects, which may be nil if the receiver does not have a column header UI elements attribute.

Discussion

An element's AXColumnHeaderUIElements attribute represents its column header UI elements.

Availability: Introduced in Mac OS X v10.6.


AXColumnIndexRange


The range of the receiver's column indexes.

@property(
    readonly) NSValue *AXColumnIndexRange; 
Return Value

An NSValue object encoding an NSRange structure, or nil if the receiver does not have a selected column index range attribute.

Discussion

The AXColumnIndexRange attribute applies to tables, returning the range of column indexes in the table.

Use NSValue's -rangeValue method to extract the NSRange structure of the result.

Availability: Introduced in Mac OS X v10.6.

See also AXRowIndexRange.


AXColumns


The columns of the receiving table or outline.

@property(
    readonly) NSArray *AXColumns; 
Return Value

An array of PFUIElement objects.

Discussion

The AXColumns attribute applies to a table or outline, returning its column elements.


AXColumnTitles


The receiving browser's column title elements.

@property(
    readonly) NSArray *AXColumnTitles; 
Return Value

An array of PFUIElement objects.

Discussion

The AXColumnTitles attribute applies to a browser, returning its column titles. A column title is a static text item. Each of a browser's column titles is also a child of the browser.


AXContents


The main contents of the receiver.

@property(
    readonly) NSArray *AXContents; 
Return Value

An array of PFUIElement objects.

Discussion

The returned UI elements are the main informational elements contained by the receiver, omitting children that represent functional elements such as scrollbars. For example, the contents of a scroll area may be a text entry area or a table but would omit the scroll area's scroll bar or ruler, and the contents of a tab group would omit the tabs (radio buttons) themselves.

See also AXNextContents and AXPreviousContents.


AXCriticalValue


The receiving level indicator's critical value.

@property(
    readonly) id AXCriticalValue; 
Return Value

An object of any value, typically an NSNumber.

Discussion

The AXCriticalValue attribute applies to a level indicator, returning its critical value.

Availability: Introduced in Mac OS X v10.6.


AXDayField


The day field in the receiving clock control.

@property(
    readonly) PFUIElement *AXDayField; 
Return Value

A PFUIElement object.

Discussion

The AXDayField attribute applies to a clock control element, returning its day field.


AXDecrementButton


The receiving stepper's decrement button.

@property(
    readonly) PFUIElement *AXDecrementButton; 
Return Value

A PFUIElement object.

Discussion

The AXDecrementButton attribute applies to a stepper, returning its up arrow button.

See also AXIncrementButton.


AXDefaultButton


The receiving window's default button.

@property(
    readonly) PFUIElement *AXDefaultButton; 
Return Value

A PFUIElement object, or nil if the receiving window does not have a default button.

Discussion

The AXDefaultButton attribute applies to a window object. It is a convenience method to make it easy to access a window's default button.


AXDescription


A localized string specifically describing the receiver.

@property(
    readonly) NSString *AXDescription; 
Return Value

An NSString object, or nil if the receiver does not have a description attribute.

Discussion

An element's AXDescription attribute explains its function or purpose. It is slightly more specific than the role description attribute but less verbose than the help attribute. It is typically formed in English by combining a property of the specific application feature that the element represents or controls with its role description. For example, a slider's role description is "slider" while the description of a particular instance of a slider might be "line width slider".

See also AXRole, AXSubrole, AXRoleDescription, and AXHelp.


AXDisclosedByRow


The receiving outline child row's parent row.

@property(
    readonly) PFUIElement *AXDisclosedByRow; 
Return Value

A PFUIElement object.

Discussion

The AXDisclosedByRow attribute applies to an outline row, returning the parent row disclosing it.


AXDisclosedRows


The expanded child rows of the receiving parent outline view row.

@property(
    readonly) NSArray *AXDisclosedRows; 
Return Value

An array of PFUIElement objects.

Discussion

The AXDisclosedRows attribute applies to an outline row, returning its disclosed child rows.


AXDisclosing


Whether the receiving outline view row is expanded.

@property(
    readonly) NSNumber *AXDisclosing; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXDisclosing attribute applies to an outline row, indicating whether it is a parent row that is expanded to disclose its child rows.

Use NSNumber's -boolValue method to extract the BOOL value of the result.


AXDisclosureLevel


The indentation level of the receiving outline row.

@property(
    readonly) NSNumber *AXDisclosureLevel; 
Return Value

An NSNumber object encoding an integer value.

Discussion

The AXDisclosureLevel attribute applies to an outline row, returning the indentation level of its row object. The disclosure level is zero-based.

Use NSNumber's -intValue method to extract the integer value of the result.


AXDocument


The receiver's path as a file URL.

@property(
    readonly) NSString *AXDocument; 
Return Value

An NSString object, or nil if the receiving window has not been saved or does not have a document.

Discussion

The AXDocument attribute applies to an element that displays a file, such as a window element, returning its file path as a file URL.

See also AXURL and AXFilename.


AXEdited


Whether the receiver has been edited since it was last saved.

@property(
    readonly) NSNumber *AXEdited; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXEdited attribute typically applies to a document, indicating whether it is dirty. An element is edited if a user has made changes to it that have not yet been saved.

Use NSNumber's -boolValue method to extract the BOOL value of the result.


AXEnabled


Whether the receiver is enabled.

@property(
    readonly) NSNumber *AXEnabled; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

An element is enabled if a user can interact with it. Views, the menu bar, menu bar items, menus, and menu items always have an AXEnabled attribute; windows typically do not.

Use NSNumber's -boolValue method to extract the BOOL value of the result.


AXExpanded


Whether the receiving disclosure triangle is expanded.

@property(
    readonly) NSNumber *AXExpanded; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXExpanded attribute applies to disclosure triangle elements, indicating whether they are expanded or collapsed.

Use NSNumber's -boolValue method to extract the BOOL value of the result.


AXFilename


The receiver's file name.

@property(
    readonly) NSString *AXFilename; 
Return Value

An NSString object, or nil if the receiver does not have a filename attribute.

Discussion

The AXFilename attribute returns the file name associated with the receiver. For example, the Finder's finder item element recognizes the AXFilename attribute.

See also AXDocument and AXURL.


AXFocused


Whether the receiver has keyboard focus.

@property(
    readwrite,
    retain) NSNumber *AXFocused; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

Only one element in a window's accessibility containment hierarchy can have keyboard focus at any given time. To access the element having keyboard focus in a specific application no matter what window it is in, use AXFocusedUIElement. To access the window having keyboard focus in a specific application, use AXFocusedWindow. To access the active application system-wide, use AXFocusedApplication.

In the case of a window element, the window having keyboard focus need not be the application's main window. To determine if a window is the main window, use AXMain.

Keyboard events sent to an application are "typed" into the element currently having keyboard focus, if it is an editable text view or text field (except for command-down keyboard shortcuts, which are always handled by the application itself).

Use NSNumber's -boolValue method to extract the BOOL value of the result.

To assign keyboard focus to the receiver, call -setAXFocused: passing an NSNumber object encoding YES. To remove keyboard focus from the receiver, you must set focus to another element; passing an NSNumber object encoding NO to this property does nothing. Many elements cannot have keyboard focus.


AXFocusedApplication


The receiving system-wide UI element's focused application element.

@property(
    readonly) PFApplicationUIElement *AXFocusedApplication; 
Return Value

A PFApplicationUIElement object.

Discussion

The AXFocusedApplication attribute identifies the application element having keyboard focus; that is, the application having a UI element that is frontmost among all active applications.

See AXFocused for more information.


AXFocusedUIElement


The receiving application's focused UI element.

@property(
    readonly) PFUIElement *AXFocusedUIElement; 
Return Value

A PFUIElement object.

Discussion

The AXFocusedUIElement attribute applies to the application object, returning the element that currently has keyboard focus.

See AXFocused for more information.


AXFocusedWindow


The receiving application's key window, the window that has keyboard focus.

@property(
    readonly) PFUIElement *AXFocusedWindow; 
Return Value

A PFUIElement object.

Discussion

The AXFocusedWindow attribute applies to the application object, returning its key window.

See AXFocused for more information.


AXFrontmost


Whether the receiving application is frontmost.

@property(
    readwrite,
    retain) NSNumber *AXFrontmost; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXFrontmost attribute applies to the application object, indicating whether it is currently the active (frontmost) application.

Use NSNumber's -boolValue method to extract the BOOL value of the result.

To bring an application to the front, call -setAXFrontmost: passing an NSNumber object encoding YES. To bring another application to the front, you must send the -setAXMain: message to it; passing an NSNumber object encoding NO to this property does nothing.


AXGrowArea


The grow area in the bottom-right corner of the receiving window.

@property(
    readonly) PFUIElement *AXGrowArea; 
Return Value

A PFUIElement object, or nil if the receiving window does not have a grow area.

Discussion

The AXGrowArea attribute applies to a window object. It is a convenience method to make it easy to access a window's grow area element.


AXHandles


The receiver's handle UI elements.

@property(
    readonly) NSArray *AXHandles; 
Return Value

An array of PFUIElement objects, or nil if the receiver does not have a handles attribute.

Discussion

An element's AXHandles attribute represents all of the resize handles adorning a resizable UI element, such as a layout area item in Apple's Numbers application.

Availability: Introduced in Mac OS X v10.6.


AXHeader


The receiving table or outline column's header element.

@property(
    readonly) PFUIElement *AXHeader; 
Return Value

A PFUIElement object.

Discussion

The AXHeader attribute applies to a column in a table or outline, returning its header. A header may be a static text item, a sort button element representing the column's title, or another object. All of a table or outline column's headers are also collected in a group element that is a child of the table or outline.


AXHelp


A localized string providing helpful information regarding the receiver.

@property(
    readonly) NSString *AXHelp; 
Return Value

An NSString object, or nil if the receiver does not have a help attribute.

Discussion

An element's ASHelp attribute may be identical to the text of its help tag (tooltip), but it can be different. When different, it should be worded specifically to assist users with disabilities.

See also AXRole, AXSubrole, AXRoleDescription, and AXDescription.


AXHidden


Whether the receiving application is hidden.

@property(
    readwrite,
    retain) NSNumber *AXHidden; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXHidden attribute applies to the application object, indicating whether the application is currently hidden.

Use NSNumber's -boolValue method to extract the BOOL value of the result.

To hide an application, call -setAXHidden: passing an NSNumber object encoding YES; to unhide it, an NSNumber object encoding NO.


AXHorizontalScrollBar


The receiving scroller's horizontal scroll bar element.

@property(
    readonly) PFUIElement *AXHorizontalScrollBar; 
Return Value

A PFUIElement object.

Discussion

The AXHorizontalScrollBar attribute returns the horizontal scroll bar of the receiving scroll view.

See also AXVerticalScrollBar.


AXHorizontalUnitDescription


A localized string describing the receiver's horizontal units of measurement, suitable for display or speech.

@property(
    readonly) NSString *AXHorizontalUnitDescription; 
Return Value

An NSString object.

Discussion

An element's AXHorizontalUnitDescription attribute is used to explain to a user what the receiver's horizontal units of measurement are. It typically echoes the technical AXHorizontalUnits, but in human-readable form without the "AX" prefix and broken into discrete words. For example, an element whose horizontal units are "AXInches" has a role description of "inches".

Availability: Introduced in Mac OS X v10.6.

See also AXUnitDescription.


AXHorizontalUnits


A technical, non-localized string representing the receiver's horizontal units of measurement.

@property(
    readonly) NSString *AXHorizontalUnits; 
Return Value

An NSString object.

Discussion

The AXHorizontalUnits attribute represents the element's horizontal units of measurement using strings beginning with "AX" defined by the accessibility API, such as "AXInchesUnit" and "AXPointsUnit".

The accessibility API also provides localizable, human-readable descriptions of the element, suitable for display or speech, in the AXHorizontalUnitDescription attribute.

Availability: Introduced in Mac OS X v10.6.

See also AXUnits.


AXHourField


The hour field in the receiving clock control.

@property(
    readonly) PFUIElement *AXHourField; 
Return Value

A PFUIElement object.

Discussion

The AXHourField attribute applies to a clock control element, returning its hour field.


AXIncrementButton


The receiving stepper's increment button.

@property(
    readonly) PFUIElement *AXIncrementButton; 
Return Value

A PFUIElement object. See also AXDecrementButton.

Discussion

The AXIncrementButton attribute applies to a stepper, returning its down arrow button.


AXIncrementor


A stepper UI element.

@property(
    readonly) PFUIElement *AXIncrementor; 
Return Value

A PFUIElement object.

Discussion

The AXIncrementor attribute returns a stepper, such as the stepper in a clock element.


AXIndex


The index of the receiver.

@property(
    readonly) NSNumber *AXIndex; 
Return Value

An NSNumber object encoding an integer value.

Discussion

The AXIndex attribute returns an element's index, such as the index of a table or outline column. The index is zero-based.

Use NSNumber's -intValue method to extract the integer value of the result.


AXInsertionPointLineNumber


The line index of a naked insertion point in the receiving text object.

@property(
    readonly) NSNumber *AXInsertionPointLineNumber; 
Return Value

An NSNumber object encoding an integer value, or nil if text is currently selected in the receiver.

Discussion

Use the AXInsertionPointLineNumber attribute to determine whether a naked insertion point is at the end of one wrapped line or at the beginning of the next wrapped line of a word-wrapped line of text.

This attribute returns a line number only if no text is currently selected. It returns nil if text is currently selected in the receiver.

To determine the location of the insertion point as a character index, get the starting character index of the current selection range using AXSelectedTextRange. The location field of the structure it encodes holds a character index representing the insertion point whether or not text is currently selected. If the length of the current selection is greater than 0, you can determine the line index of the insertion point (that is, the line on which the first character of the selection is located) without ambiguity by calling -AXLineForIndex:. The line index can be important, for example, when you want to scroll to the insertion point.

To determine the line index of the insertion point when the length of the current selection is 0, two steps are required. This is because the character index is the same when there is no text selection and the insertion point is at the end of one wrapped line or the beginning of the next wrapped line (there is no return character separating wrapped lines). First, pass the character index of the current selection range to -AXLineForIndex:, as above, and note the result. Second, to distinguish between a naked insertion point that is located at the end of one wrapped line and one that is located at the beginning of the next wrapped line even though both have the same character index, use this property, AXInsertionPointLineNumber. If the result is nil, you know that the length of the current selection is greater than 0 and the line index returned by -AXLineForIndex: was therefore correct.

Use NSNumber's -intValue method or similar to extract the integer value of the result.


AXIsApplicationRunning


Whether the application represented by the receiving application dock item is running.

@property(
    readonly) NSNumber *AXIsApplicationRunning; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXIsApplicationRunning attribute indicates whether the application represented by the receiving application dock item is running.

Use NSNumber's -boolValue method to extract the BOOL value of the result.


AXLabelUIElements


The labels for a slider or similar control.

@property(
    readonly) NSArray *AXLabelUIElements; 
Return Value

An NSArray of PFUIElement objects.

Discussion

The AXLabelUIElements attribute applies to a slider or similar control, returning its label elements.


AXLabelValue


The value of the receiving label.

@property(
    readonly) NSNumber *AXLabelValue; 
Return Value

An NSNumber object encoding an integer or other numeric value.

Discussion

The AXLabelValue attribute applies to a slider or similar control, returning the value of the receiving label.

Use NSNumber's -intValue method or similar to extract the integer value of the result.


AXLinkedUIElements


The UI elements that are linked to the receiver.

@property(
    readonly) NSArray *AXLinkedUIElements; 
Return Value

An array of PFUIelement objects.

Discussion

An element's AXLinkedUIElements attribute represents elements that are associated with the receiver in the sense that their values depend upon the receiver's current value. For example, the contents of the To, From and Subject text fields and the Message text view of an e-mail message area in the user interface may depend upon which item is currently selected in an associated table listing available e-mail messages.


AXMain


Whether the receiver is the target application's main window.

@property(
    readwrite,
    retain) NSNumber *AXMain; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXMain attribute applies to a window object, returning whether it is the main window of the application.

An application may have a single main window whether it is the active application or not. If the application is inactive, its main window is the window that would be its main window if it were active.

The main window need not be the window having keyboard focus. To determine if it is the key window, use AXFocused.

To get the application's main window element, use AXMainWindow. To get its key window, the window that has keyboard focus, use AXFocusedWindow.

Use NSNumber's -boolValue method to extract the BOOL value of the result.

To set the receiver to be the target application's main window, call -setAXMain: passing an NSNumber object encoding YES. Whether making a window the target application's main window brings it in front of other windows belonging to the application is application-dependent. To make another window the main window, you must send the -setAXMain: message to it; passing an NSNumber object encoding NO to this property does nothing.


AXMainWindow


The receiving application's main window.

@property(
    readonly) PFUIElement *AXMainWindow; 
Return Value

A PFUIElement object.

Discussion

The AXMainWindow attribute applies to the application object, returning its main window.

See AXMain for more information.


AXMarkerGroupUIElement


A group element containing the receiving text ruler's markers.

@property(
    readonly) PFUIElement *AXMarkerGroupUIElement; 
Return Value

A PFUIElement object.

Discussion

The AXMarkerGroupUIElement attribute applies to a text ruler element. It is not documented. The rulers in Apple's TextEdit and Pages applications do not use this attribute.


AXMarkerType


A technical, non-localized string designating the receiving text ruler marker's type.

@property(
    readonly) NSString *AXMarkerType; 
Return Value

An NSString object.

Discussion

The AXMarkerType attribute applies to a text ruler marker, such as a left tab stop marker or the head indent marker, returning a string describing its type.

The result can be compared to the string constants NSAccessibilityLeftTabStopMarkerTypeValue ("AXLeftTabStopMarkerType"), NSAccessibilityRightTabStopMarkerTypeValue ("AXRightTabStopMarkerType"), NSAccessibilityCenterTabStopMarkerTypeValue ("AXCenterTabStopMarkerType"), NSAccessibilityDecimalTabStopMarkerTypeValue ("AXDecimalTabStopMarkerType"), NSAccessibilityHeadIndentMarkerTypeValue ("AXHeadIndentMarkerType"), NSAccessibilityTailIndentMarkerTypeValue ("AXTailIndentMarkerType"), NSAccessibilityFirstLineIndentMarkerTypeValue ("AXFirstLineIndentMarkerType"), NSAccessibilityUnknownMarkerTypeValue ("AXUnknownMarkerType").

See also AXMarkerTypeDescription.


AXMarkerTypeDescription


A localized string describing the receiving text ruler marker, suitable for display or speech.

@property(
    readonly) NSString *AXMarkerTypeDescription; 
Return Value

An NSString object.

Discussion

The AXMarkerTypeDescription attribute applies to a text ruler marker, such as a left tab stop marker or the head indent marker, returning a localized string describing its type.


AXMarkerUIElements


The receiving text ruler's marker elements.

@property(
    readonly) NSArray *AXMarkerUIElements; 
Return Value

An NSArray of PFUIElement objects.

Discussion

The AXMarkerUIElements attribute applies to a text ruler element, returning its marker elements, such as a left tab stop marker or the head indent marker.


AXMarkerValues


The values of the receiving text ruler's marker elements.

@property(
    readonly) NSArray *AXMarkerValues; 
Return Value

An NSArray of NSString.

Discussion

The AXMarkerValues attribute applies to a text ruler element. This attribute is not documented. The values of markers in the rulers in Apple's TextEdit and Pages applications are available using their AXValue attribute.


AXMatteContentUIElement


The object clipped by the receiving screen matte.

@property(
    readonly) PFUIElement *AXMatteContentUIElement; 
Return Value

A PFUIElement object.

Discussion

The AXMatteContentUIElement attribute applies to a screen matte, returning the element clipped by the screen matte.


AXMatteHole


The bounds of the receiving screen matte's hole in screen coordinates.

@property(
    readonly) NSValue *AXMatteHole; 
Return Value

An NSValue object encoding an NSRect structure.

Discussion

The AXMatteHole attribute applies to a screen matte, returning the rectangle bounding the screen matte's hole.

Use NSValue's -rectValue method to extract the NSRect structure of the result.


AXMaxValue


The largest legal value of the receiver.

@property(
    readonly) id AXMaxValue; 
Return Value

An object of any type (typically NSNumber), or nil if the receiver does not recognize a maximum value attribute.

Discussion

An element's AXMaxValue attribute is the largest value it can display. The returned value is an object of the same type as the receiving element's AXValue attribute.

In conjunction with its AXMinValue attribute, it enables a client to set the element's value within a valid range. The AXMaxValue attribute is typically recognized by elements that allow a user to set their values within a range of permissible values, such as sliders. A scroll bar may not recognize this attribute; its actual minimum and maximum values are always 0.0 and 1.0, respectively.

See also AXValue and AXMinValue.


AXMenuBar


The receiving application's menu bar element.

@property(
    readonly) PFUIElement *AXMenuBar; 
Return Value

A PFUIElement object.

Discussion

The AXMenuBar attribute applies to the application object, returning its one and only menu bar.

There are typically two menu bars visible on the screen at a time, the active application's menu bar and the systemUIServer application's menu bar. The latter is located in the top-right corner of the same screen that displays the active application's menu bar. Its children are all of the system's menu extras, such as the clock menu extra. (This does not include a variety of third-party buttons that may appear to the left of the SystemUIServer's menu bar.)


AXMenuItemCmdChar


The receiving menu item's keyboard shortcut as a single-character string.

@property(
    readonly) NSString *AXMenuItemCmdChar; 
Return Value

An NSString object, an empty string if the receiving menu item does not have a keyboard shortcut that is represented by a character.

Discussion

The AXMenuItemCmdChar attribute applies to a menu item, returning its keyboard shortcut as a character if it is implemented as a key represented by a character such as "X".


AXMenuItemCmdGlyph


The receiving menu item's keyboard shortcut as a glyph code.

@property(
    readonly) NSNumber *AXMenuItemCmdGlyph; 
Return Value

An NSNumber object encoding an integer value, or nil if the receiving menu item does not have a keyboard shortcut that is represented by a glyph code.

Discussion

The AXMenuItemCmdGlyph attribute applies to a menu item, returning its keyboard shortcut as a glyph code, if it is implemented as a key represented by a glyph code.

Glyph codes returned by this method are described in the Carbon Menu Manager documentation and declared in Menus.h in the Carbon HIToolbox framework. They are numbers representing all of the control and function keys on the keyboard. For example, the glyph code for the left arrow key is kMenuLeftArrowGlyph, 0x64 or 100, and for the right arrow key, kMenuRightArrowGlyph, 0x65 or 101.

Use NSNumber's -intValue method to extract the integer value of the result.


AXMenuItemCmdModifiers


The modifier key combination required by the receiving menu item's keyboard shortcut.

@property(
    readonly) NSNumber *AXMenuItemCmdModifiers; 
Return Value

An NSNumber object encoding an integer value, or nil if the receiving menu item does not have a keyboard shortcut.

Discussion

The AXMenuItemCmdModifiers attribute applies to a menu item, returning the modifier key combination required by its keyboard shortcut.

The modifier key combination is the Modifier Key Mask described in the Carbon Menu Manager documentation and declared in Menus.h in the Carbon HIToolbox framework. It is a number representing a particular combination of modifier keys. The number is based on the combination of bits in a 4-bit bit field where bit 0 is the Shift key, kMenuShiftModifie; bit 1 is the Option key, kMenuOptionModifier; bit 2 is the Control key, kMenuControlModifier; and bit 3 means the Command key is not required, kMenuNoCommandModifier. The Command key is assumed unless bit 3 is set, and it is not included in the mask. Thus, for example, the number 0 means that only the Command key is required; 1, Command-Shift; 2, Command-Option; 3, Command-Shift-Option; 4, Command-Control; and so on.

Use NSNumber's -intValue method to extract the integer value of the result.


AXMenuItemCmdVirtualKey


The receiving menu item's keyboard shortcut as a virtual key code.

@property(
    readonly) NSNumber *AXMenuItemCmdVirtualKey; 
Return Value

An NSNumber object encoding an integer value, or nil if the receiving menu item does not have a keyboard shortcut that is represented by a virtual key code.

Discussion

The AXMenuItemCmdVirtualKey attribute applies to a menu item, returning its keyboard shortcut as a virtual key code if it is implemented as a key represented by a virtual key code.

Virtual key codes returned by this method are the keycodes described in Inside Macintosh Volume V. They are the same keycodes returned by NSEvent's -keyCode method. They are hardware-independent numbers representing specific keys on the keyboard. They are generally used to represent keyboard shortcuts only when there is more than one key that returns the same character or glyph code.

Use NSNumber's -intValue method to extract the integer value of the result.


AXMenuItemMarkChar


The receiving menu item's mark character.

@property(
    readonly) NSString *AXMenuItemMarkChar; 
Return Value

An NSString object, or an empty string if the mark character is not currently set because the menu is closed or the receiving menu item does not have a mark character.

Discussion

The AXMenuItemMarkChar attribute applies to a menu item, returning its mark character, such as a check mark.

Many applications set a menu item's mark character only as the menu is being opened. For this reason, it may not be possible to obtain the mark character except by first opening the menu. The PFAssistive framework does not do this automatically, but a client can do it by sending -activateApplication and then sending -performAction: to perform an AXPress action on the menu to open it.


AXMenuItemPrimaryUIElement


The receiving menu item's primary menu item element.

@property(
    readonly) PFUIElement *AXMenuItemPrimaryUIElement; 
Return Value

A PFUIElement object, or nil if the menu item does not have a secondary menu item element.

Discussion

The AXMenuItemPrimaryUIElement attribute applies to a menu item, returning its primary menu item element. Some menu items have both a primary menu item element and a secondary menu item element that appears when the Option key is held down.


AXMinimizeButton


The minimize button in the receiving window's title bar.

@property(
    readonly) PFUIElement *AXMinimizeButton; 
Return Value

A PFUIElement object, or nil if the receiving window does not have a minimize button.

Discussion

The AXMinimizeButton attribute applies to a window object. It is a convenience method to make it easy to access a window's minimize button.


AXMinimized


Whether the receiving window is minimized to the Dock.

@property(
    readwrite,
    retain) NSNumber *AXMinimized; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXMinimized attribute applies to a window object, returning whether it is currently minimized to the Dock.

Use NSNumber's -boolValue method to extract the BOOL value of the result.

To minimize a window, call -setAXMinimized: passing an NSNumber object encoding YES; to maximize it, an NSNumber object encoding NO.


AXMinuteField


The minute field in the receiving clock control.

@property(
    readonly) PFUIElement *AXMinuteField; 
Return Value

A PFUIElement object.

Discussion

The AXMinuteField attribute applies to a clock control element, returning its minute field.


AXMinValue


The smallest legal value of the receiver.

@property(
    readonly) id AXMinValue; 
Return Value

An object of any type (typically NSNumber), or nil if the receiver does not have a minimum value attribute.

Discussion

An element's AXMinValue attribute represents the smallest value it can display. The returned value is an object of the same type as the receiving element's AXValue attribute.

In conjunction with its AXMaxValue attribute, it enables a client to set the element's value within a valid range. The AXMinValue attribute is typically recognized by elements that allow a user to set their values within a range of permissible values, such as sliders. A scroll bar may not recognize this attribute; its actual minimum and maximum values are always 0.0 and 1.0, respectively.

See also AXValue and AXMaxValue.


AXModal


Whether the receiver is a modal window.

@property(
    readonly) NSNumber *AXModal; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXModal attribute applies to a window object, returning YES if the window is modal.

Use NSNumber's -boolValue method to extract the BOOL value of the result.


AXMonthField


The month field in the receiving clock control.

@property(
    readonly) PFUIElement *AXMonthField; 
Return Value

A PFUIElement object.

Discussion

The AXMonthField attribute applies to a clock control element, returning its month field.


AXNextContents


The contents of the subview following the splitter bar in a split group or a similar divider.

@property(
    readonly) id AXNextContents; 
Return Value

An array of PFUIElement objects.

Discussion

The AXNextContents attribute returns all of the elements contained in the subview following a divider element, such as a splitter bar in a split group.


AXNumberOfCharacters


The number of characters in the receiver's text.

@property(
    readonly) NSNumber *AXNumberOfCharacters; 
Return Value

An NSNumber object encoding an integer value, or nil if the receiver does not have a number of characters attribute.

Discussion

The AXNumberOfCharacters attribute applies to text elements, such as a text view or a text field. It returns the number of Unicode characters in the receiver's text, not the number of bytes.

Use NSNumber's -intValue method or similar to extract the integer value of the result.


AXOrderedByRow


Whether the receiving grid element is ordered by rows.

@property(
    readonly) NSNumber *AXOrderedByRow; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXOrderedByRow attribute indicates whether the receiving grid element is ordered by rows.

Use NSNumber's -boolValue method to extract the BOOL value of the result.


AXOrientation


A technical, non-localized string designating the receiver's orientation on the screen.

@property(
    readonly) NSString *AXOrientation; 
Return Value

An NSString object.

Discussion

The AXOrientation attribute applies to elements having a vertical or horizontal orientation, such as scroll bars and split views.

The result can be compared to the string constants NSAccessibilityHorizontalOrientationValue ("AXVerticalOrientation"), NSAccessibilityVerticalOrientationValue ("AXHorizontalOrientation", and NSAccessibiliityUnknownOrientationValue ("AXUnknownOrientation". NSAccessibilityUnknownOrientationValue was added to the NSAccessibility protocol in Mac OS X 10.6 Snow Leopard to match the existing kAXUnknownOrientationValue constant.


AXOverflowButton


The receiving toolbar's overflow button element.

@property(
    readonly) PFUIElement *AXOverflowButton; 
Return Value

A PFUIElement object.

Discussion

The AXOverflowButton attribute applies to a toolbar, returning its overflow button.


AXParent


The receiver's parent UI element.

@property(
    readonly) PFUIElement *AXParent; 
Return Value

A PFUIElement or PFApplicationUIElement object, or nil if the receiver is the root application element.

Discussion

An element's AXParent attribute represents the element containing it in the visual, on-screen accessibility containment hierarchy. This may not be its immediate container in the application's programmatic view hierarchy, because the view hierarchy often includes unseen objects that are irrelevant to accessibility and therefore ignored by it. For example, a drawer's parent is the window from which the drawer opened, not the unseen programmatic window object that contains the drawer's view. More conventionally, a push button's parent may be a group or a window, a window's parent is the root application element, a menu item's parent is a menu, a menu bar item's parent is the menu bar, and a menu's parent may be a menu bar item or a menu item.

The AXParent and AXChildren properties are key players in an assistive application's navigation up and down a target application's accessibility containment hierarchy.

This property returns nil if the receiver is the target application's root UI element. Every element in the visual element hierarchy has a parent, except for the root application element.

See the AXChildren property for requirements regarding the relationship between a parent and its children.


AXPlaceholderValue


The string that appears in a text field or similar element as its placeholder.

@property(
    readonly) NSString *AXPlaceholderValue; 
Return Value

An NSString object.

Discussion

The AXPlaceholder attribute typically applies to text fields, returning the string that appears in the element as its placeholder.

Availability: Introduced in Mac OS X v10.6.


AXPosition


The receiver's position on the screen.

@property(
    readwrite,
    retain) NSValue *AXPosition; 
Return Value

An NSValue object encoding an NSPoint structure.

Discussion

An element's screen position in the accessibility API is its top-left corner in global top-left relative screen coordinates, where {0.0, 0.0} is the top-left corner of the screen displaying the menu bar and values increase in magnitude to the right and downwards.

Use NSValue's -pointValue method to extract the NSPoint structure of the result.

To set the receiver's position, call -setAXPosition: passing an NSValue object encoding the desired point in top-left relative screen coordinates. When setting a window's position, the accessibility API does not allow its title bar to be moved into the menu bar or the Dock. Instead, the window is moved to the nearest valid position. Many elements cannot be moved.


AXPreviousContents


The contents of the subview preceding the splitter bar in a split group or a similar divider.

@property(
    readonly) id AXPreviousContents; 
Return Value

An array of PFUIElement objects.

Discussion

The AXPreviousContents attribute returns all of the elements contained in the subview preceding a divider element, such as a splitter bar in a split group.


AXProxy


The proxy icon in the receiving window's title bar representing the window's document.

@property(
    readonly) PFUIElement *AXProxy; 
Return Value

A PFUIElement object, or nil if the receiving window does not have a proxy icon (that is, if the receiver's document has never been saved or it does not have a document).

Discussion

The AXProxy attribute applies to a window object. It is a convenience method to make it easy to access a window's proxy icon.


AXRole


A technical, non-localized string representing the receiver's role.

@property(
    readonly) NSString *AXRole; 
Return Value

An NSString object.

Discussion

The AXRole attribute represents the element's role using strings beginning with "AX" defined by the accessibility API, such as "AXButton" and "AXWindow", or custom strings defined by an application, such as the Finder's "AXFinderItem" and Safari's "AXWebArea".

The accessibility API also provides localizable, human-readable descriptions of the element, suitable for display or speech, in the AXRoleDescription attribute and in the more verbose AXDescription attribute indicating the exact function or purpose of a specific element.

All elements have an AXRole attribute, even if it is "AXUnknown". Some elements supplement the generic role attribute with an AXSubrole attribute indicating one of several subcategories of the basic role. See AXSubrole for more information.

See also AXHelp.


AXRoleDescription


A localized string describing the receiver's role or subrole, suitable for display or speech.

@property(
    readonly) NSString *AXRoleDescription; 
Return Value

An NSString object.

Discussion

An element's AXRoleDescription attribute is used to explain to a user what the element is. It typically echoes the technical AXRole or AXSubrole attribute, but in human-readable form without the "AX" prefix and broken into discrete words. For example, an element whose role is "AXWindow" and whose subrole is "AXDialog" has a role description of "dialog".

See also AXRole, AXSubrole, AXDescription, and AXHelp.


AXRowCount


The number of rows in the receiving grid element.

@property(
    readonly) NSNumber *AXRowCount; 
Return Value

An NSNumber object encoding an integer value, or nil if the receiver does not have a row count attribute.

Discussion

The AXRowCount attribute applies to grids, returning the number of rows in the table.

Use NSNumber's -intValue method or similar to extract the integer value of the result.

See also AXColumnCount.


AXRowHeaderUIElements


The receiver's row header UI elements.

@property(
    readonly) NSArray *AXRowHeaderUIElements; 
Return Value

An array of PFUIElement objects, which may be nil if the receiver does not have a row header UI elements attribute.

Discussion

An element's AXRowHeaderUIElements attribute represents its row header UI elements.

Availability: Introduced in Mac OS X v10.6.


AXRowIndexRange


The range of the receiver's row indexes.

@property(
    readonly) NSValue *AXRowIndexRange; 
Return Value

An NSValue object encoding an NSRange structure, or nil if the receiver does not have a selected row index range attribute.

Discussion

The AXRowIndexRange attribute applies to tables, returning the range of row indexes in the table.

Use NSValue's -rangeValue method to extract the NSRange structure of the result.

Availability: Introduced in Mac OS X v10.6.

See also AXColumnIndexRange.


AXRows


The rows of the receiving table or outline.

@property(
    readonly) NSArray *AXRows; 
Return Value

An array of PFUIElement objects.

Discussion

The AXRows attribute applies to a table or outline, returning its row elements.


AXSearchButton


The search button element in the receiving search field.

@property(
    readonly) PFUIElement *AXSearchButton; 
Return Value

A PFUIElement object.

Discussion

The AXSearchButton attribute applies to a search field, returning its search button.


AXSearchMenu


The search pop-up menu element in the receiving search field.

@property(
    readonly) PFUIElement *AXSearchMenu; 
Return Value

A PFUIElement object.

Discussion

The AXSearchMenu attribute applies to a search field, returning its search menu, or nil if the receiving search field does not have a search menu.


AXSecondField


The second field in the receiving clock control.

@property(
    readonly) PFUIElement *AXSecondField; 
Return Value

A PFUIElement object.

Discussion

The AXSecondField attribute applies to a clock control element, returning its second field.


AXSelected


Whether the receiver is selected.

@property(
    readonly) NSNumber *AXSelected; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXSelected attribute indicates whether a user-selectable element is selected in the user interface.

Use NSNumber's -boolValue method to extract the BOOL value of the result.


AXSelectedCells


The receiving cell-based table's selected cell UI elements.

@property(
    readwrite,
    retain) NSArray *AXSelectedCells; 
Return Value

An array of PFUIElement objects, which may be empty, or nil if the receiver does not have a selected cells attribute..

Discussion

An element's AXSelectedCells attribute represents the subset of its cells that are currently selected in the user interface. For example, it may identify the cells that are selected in a table in Apple's Numbers application.

To change the selection in the user interface, call -setAXSelectedCells: passing an NSArray object containing PFUIElement objects that are cells of the receiver, or an empty array to clear the current selection.

Availability: Introduced in Mac OS X v10.6.


AXSelectedChildren


The receiver's selected children UI elements.

@property(
    readwrite,
    retain) NSArray *AXSelectedChildren; 
Return Value

An array of PFUIElement objects, which may be empty, or nil if the receiver does not have a selected children attribute.

Discussion

An element's AXSelectedChildren attribute represents the subset of its children that are currently selected in the user interface. For example, it may identify the items that are selected in a table, outline or browser column list, or the Finder items that are selected on the desktop.

To change the selection in the user interface, call -setAXSelectedChildren: passing an NSArray object containing PFUIElement objects that are children of the receiver, or an empty array to clear the current selection.


AXSelectedColumns


The selected columns of the receiving table or outline.

@property(
    readwrite,
    retain) NSArray *AXSelectedColumns; 
Return Value

An array of PFUIElement objects.

Discussion

The AXSelectedColumns attribute applies to a table or outline, returning the subset of its column objects that are currently selected.

Prior to Mac OS X 10.6 Snow Leopard, this attribute incorrectly returned the selected column indexes.

To change the selection in the user interface, call -setAXSelectedColumns: passing an NSArray object containing PFUIElement objects that are columns of the receiver, or an empty array to clear the current selection.


AXSelectedRows


The selected rows of the receiving table or outline.

@property(
    readwrite,
    retain) NSArray *AXSelectedRows; 
Return Value

An array of PFUIElement objects.

Discussion

The AXSelectedRows attribute applies to a table or outline, returning the subset of its row elements that are currently selected.

To change the selection in the user interface, call -setAXSelectedRows: passing an NSArray object containing PFUIElement objects that are rows of the receiver, or an empty array to clear the current selection.


AXSelectedText


The receiver's selected text.

@property(
    readwrite,
    retain) NSString *AXSelectedText; 
Return Value

An NSString object, or nil if the receiver does not have a selected text attribute.

Discussion

The AXSelectedText attribute applies to text elements, such as a text view or a text field, returning the portion of the element's text that is currently selected.

To set the receiver's selected text, call -setAXSelectedText: passing an NSString object representing the new text for the selection. Setting the selected text removes the text that is currently selected and inserts text in its place at the insertion point. The insertion point remains unchanged, but the length of the selection may change. To select different text instead of replacing the text that is currently selected, call -setAXSelectedTextRange: or -setAXSelectedTextRanges:.

See also AXSelectedTextRange and AXSelectedTextRanges.


AXSelectedTextRange


The range of the receiver's text selection.

@property(
    readwrite,
    retain) NSValue *AXSelectedTextRange; 
Return Value

An NSValue object encoding an NSRange structure, or nil if the receiver does not have a selected text range attribute.

Discussion

The AXSelectedTextRange attribute applies to editable text elements, such as a text view or a text field, returning the range of characters of the portion of the receiver's text that is currently selected. It is a range of Unicode characters, not bytes. The insertion point is a range having a length of 0.

Use NSValue's -rangeValue method to extract the NSRange structure of the result.

To set the receiver's selected text range, call -setAXSelectedTextRange: passing an NSValue object encoding the range for a new selection. To replace the currently selected text with different text, instead of selecting different text, call -setAXSelectedText:.

See also AXSelectedText and AXSelectedTextRanges.


AXSelectedTextRanges


The ranges of the receiver's noncontiguous multiple text selections.

@property(
    readwrite,
    retain) NSArray *AXSelectedTextRanges; 
Return Value

An NSArray object containing NSValue objects encoding noncontiguous NSRange structures, or nil if the receiver does not have a selected text range attribute.

Discussion

The AXSelectedTextRange attribute applies to editable text elements, such as a text view or a text field, returning an array of the ranges of characters of the portions of the receiver's text that are currently part of a noncontiguous multiple selection. They are ranges of Unicode characters, not bytes. The insertion point is an array containing a single empty selection range, which has a length of 0.

Use NSValue's -rangeValue method to extract the NSRange structure of any NSValue object in the array.

To set the receiver's selected text ranges, call -setAXSelectedTextRanges: passing an NSArray object containing NSValue objects encoding the ranges for a new multiple selection.

See also AXSelectedText and AXSelectedTextRange.


AXServesAsTitleForUIElements


The UI elements for which the receiver serves as title.

@property(
    readonly) id AXServesAsTitleForUIElements; 
Return Value

An array of PFUIelement objects.

Discussion

The AXServesAsTitleForUIElements attribute represents all of the elements for which the receiver serves as title in the user interface.

This attribute is rarely available because application developers must provide it in code; it cannot be set in Interface Builder.

The AXServesAsTitleForUIElements attribute is the inverse of -AXTitleUIElement.


AXSharedCharacterRange


The range of characters in a larger text object that are contained in the receiving text view, which shares the text object with other text view elements.

@property(
    readonly) NSValue *AXSharedCharacterRange; 
Return Value

An NSValue object encoding an NSRange structure.

Discussion

The AXSharedCharacterRange attribute typically applies to text views, not text fields. It returns the range of characters in a larger text object that are contained in the receiving text view, which shares the text object with other text view elements, such as the range of characters in one of multiple text columns that share a single text object. It returns the range of Unicode characters in the receiver's text, not the range of bytes.

Use NSValue's -rangeValue method to extract the NSRange structure of the result.


AXSharedTextUIElements


An array containing all of the text view elements that share a larger text object, a portion of which is contained in the receiving text view.

@property(
    readonly) NSArray *AXSharedTextUIElements; 
Return Value

An array of PFUIelement objects.

Discussion

The AXSharedTextUIElements attribute typically applies to text views, not text fields. It returns all of the text views that share the larger text object, part of which is contained in the receiving text view, such as multiple text columns across which the text object flows.


AXShownMenuUIElement


The menu element currently being displayed.

@property(
    readonly) PFUIElement *AXShownMenuUIElement; 
Return Value

A PFUIElement object.

Discussion

The AXShownMenuUIElement attribute returns the open menu associated with the receiver, or nil if no menu is open for on the receiver. For example, the Finder's Finder item element and the Dock's Dock item element recognize the AXShownMenuUIElement attribute.


AXSize


The receiver's size on the screen.

@property(
    readwrite,
    retain) NSValue *AXSize; 
Return Value

An NSValue object encoding an NSSize structure.

Discussion

An element's size on the screen is its horizontal and vertical dimensions.

Use NSValue's -sizeValue method to extract the NSSize structure of the result.

To set the receiver's position, call -setAXSize: passing an NSValue object encoding the desired size. Many elements cannot be resized.


AXSortDirection


A technical, non-localized string designating the receiving column's sort direction.

@property(
    readonly) NSString *AXSortDirection; 
Return Value

An NSString object.

Discussion

The AXSortDirection attribute applies to elements having a sort direction, such as column headers in tables and outlines.

The result can be compared to the string constants NSAccessibilityAscendingSortDirectionValue ("AXAscendingSortDirection"), NSAccessibilityDescendingSortDirectionValue ("AXDescendingSortDirection"), and NSAccessibilityUnknownSortDirectionValue ("AXUnknownSortDirection").


AXSplitters


The splitter bar elements in the receiving split group.

@property(
    readonly) NSArray *AXSplitters; 
Return Value

An array of PFUIElement objects.

Discussion

The splitter bar elements are also children of the split group.


AXSubrole


A technical, non-localized string representing the receiver's subrole.

@property(
    readonly) NSString *AXSubrole; 
Return Value

An NSString object, or nil if the receiver does not have a subrole attribute.

Discussion

Some elements have an AXSubrole attribute more specifically defining their role. The subrole is a string beginning with "AX" defined by the accessibility API, such as "AXCloseButton" and "AXZoomButton" for the AXButton role and "AXStandardWindow" and "AXDialog" for the AXWindow role, or a custom subrole defined by an application.

When an element has a subrole, its AXRoleDescription attribute typically reflects the subrole rather than the role.

See also AXRole, AXRoleDescription, AXDescription, and AXHelp.


AXTabs


The receiving tab group's tab elements.

@property(
    readonly) NSArray *AXTabs; 
Return Value

An array of PFUIElement objects.

Discussion

The AXTabs attribute applies to a tab group element, returning its tabs. The role of the tabs is AXRadioButton.


AXTitle


A localized string that is the receiver's title.

@property(
    readonly) NSString *AXTitle; 
Return Value

An NSString object, or nil if the receiver does not have a title attribute.

Discussion

Many elements have AXTitle attributes, such as a button. The title is the text that an application displays as part of its normal visual interface, such as "OK" for an OK button or the text of a menu item.

Elements are often associated with a separate UI element in the visual interface that serves as their title, such as a static text field. See AXTitleUIElement for more information.


AXTitleUIElement


A separate UI element that serves as the receiver's title.

@property(
    readonly) PFUIElement *AXTitleUIElement; 
Return Value

A PFUIElement object.

Discussion

An element's AXTitleUIElement attribute represents a separate element that is associated with the receiver and serves as its title, such as the static text field in a window's title bar or the static text field to the left of a text field or pop-up button.

The AXTitleUIElement attribute is the inverse of AXServesAsTitleForUIElements.


AXToolbarButton


The toolbar button in the receiving window's title bar.

@property(
    readonly) PFUIElement *AXToolbarButton; 
Return Value

A PFUIElement object, or nil if the receiving window does not have a toolbar button.

Discussion

The AXToolbarButton attribute applies to a window object. It is a convenience method to make it easy to access a window's toolbar button.


AXTopLevelUIElement


The top-level UI element containing the receiver.

@property(
    readonly) PFUIElement *AXTopLevelUIElement; 
Return Value

A PFUIElement object.

Discussion

The AXTopLevelUIElement attribute is a convenient shortcut, providing immediate access to an element's top-level container without requiring explicit traversal of the intervening hierarchy.

The AXTopLevelUIElement attribute is similar to AXWindow, but the element returned can be something other than a window element, such as a sheet or a drawer. The top level UI element of an application dock item is the Dock application's list of dock items.


AXUnitDescription


A localized string describing the receiving text ruler's units of measurement, suitable for display or speech.

@property(
    readonly) NSString *AXUnitDescription; 
Return Value

An NSString object.

Discussion

The AXUnitDescription attribute applies to a text ruler element, returning a localized string describing its units of measurement.

See also AXUnits.


AXUnits


A technical, non-localized string representing the receiving text ruler's units of measurement.

@property(
    readonly) NSString *AXUnits; 
Return Value

An NSString object.

Discussion

The AXUnits attribute applies to a text ruler element, returning a string describing its units of measurement.

The result can be compared to the string constants NSAccessibilityInchesUnitValue ("AXInchesUnit"), NSAccessibilityCentimetersUnitValue ("AXCentimentersUnit"), NSAccessibilityPointsUnitValue ("AXPointsUnit"), NSAccessibilityPicasUnitValue ("AXPicasUnit"), and NSAccessibilityUnknownUnitValue ("AXUnknownUnit").

See also AXUnitDescription.


AXURL


The receiver's associated file URL.

@property(
    readonly) NSURL *AXURL; 
Return Value

An NSURL object representing the file URL associated with the receiver, or nil for elements that don't have a file URL such as a volume or iDisk.

Discussion

The AXURL attribute returns the file URL associated with the receiver. For example, the Finder's finder item element recognizes the AXURL attribute.

See also AXDocument and AXFilename>.


AXValue


The receiver's value.

@property(
    readwrite,
    retain) id AXValue; 
Return Value

An object of any type, or nil if the receiver does not have a value attribute.

Discussion

An element typically has a value attribute if a user can modify it by interacting with it on the screen. In addition, many elements have values even though they are not modifiable by a user, such as a static text field.

The value can be almost any type, but it is always the same type for any given element. For example, a text field's value is the text it contains, a scroll bar's value is a real number between 0.0 and 1.0 representing the position of its thumb, and a checkbox's value is an integer, either 1 or 0 depending on whether it is checked.

To set the receiver's value, call -setAXValue: passing an object of the appropriate type. Some elements, such as a checkbox, can only be modified by clicking. In those cases, the element supports an AXPress action instead of a settable value attribute.

See also AXValueDescription.


AXValueDescription


A localized string describing the receiver's value, suitable for display or speech.

@property(
    readonly) id AXValueDescription; 
Return Value

An NSString object, or nil if the receiver does not have a value attribute.

Discussion

An element's AXValueDescription attribute is used to explain to a user what the element's value is.

See also AXValue.


AXValueIncrement


The magnitude of each increment of the receiver's value.

@property(
    readonly) id AXValueIncrement; 
Return Value

An object of any type (typically NSNumber).

Discussion

The AXValueIncrement attribute applies to a stepper and similar elements, returning the amount by which the value manipulated by the stepper or similar element changes with a single click. The returned value is an object of the same type as the receiving element's AXValue attribute.


AXValueWraps


Whether the receiver wraps; that is, if stepping in one direction eventually returns the receiver to its initial value.

@property(
    readonly) NSNumber *AXValueWraps; 
Return Value

An NSNumber object encoding a BOOL value.

Discussion

The AXValueWraps attribute applies to a stepper and similar elements, returning whether its value wraps around to its minimum value when the maximum value is exceeded, and vice versa.

Use NSNumber's -boolValue method to extract the BOOL value of the result.


AXVerticalScrollBar


The receiving scroller's vertical scroll bar element.

@property(
    readonly) PFUIElement *AXVerticalScrollBar; 
Return Value

A PFUIElement object. See also AXHorizontalScrollBar.

Discussion

The AXVerticalScrollBar attribute returns the vertical scroll bar of the receiving scroll view.


AXVerticalUnitDescription


A localized string describing the receiver's vertical units of measurement, suitable for display or speech.

@property(
    readonly) NSString *AXVerticalUnitDescription; 
Return Value

An NSString object.

Discussion

An element's AXVerticalUnitDescription attribute is used to explain to a user what the receiver's vertical units of measurement are. It typically echoes the technical AXVerticalUnits, but in human-readable form without the "AX" prefix and broken into discrete words. For example, an element whose vertical units are "AXInches" has a role description of "inches".

Availability: Introduced in Mac OS X v10.6.

See also AXUnitDescription.


AXVerticalUnits


A technical, non-localized string representing the receiver's vertical units of measurement.

@property(
    readonly) NSString *AXVerticalUnits; 
Return Value

An NSString object.

Discussion

The AXVerticalUnits attribute represents the element's vertical units of measurement using strings beginning with "AX" defined by the accessibility API, such as "AXInchesUnit" and "AXPointsUnit".

The accessibility API also provides localizable, human-readable descriptions of the element, suitable for display or speech, in the AXVerticalUnitDescription attribute.

Availability: Introduced in Mac OS X v10.6.

See also AXUnits.


AXVisibleCells


The receiving cell-based table's visible cell UI elements.

@property(
    readonly) NSArray *AXVisibleCells; 
Return Value

An array of PFUIElement objects, which may be empty, or nil if the receiver does not have a selected cells attribute..

Discussion

An element's AXVisibleCells attribute represents a subset of its cells that are currently visible in their container; for example, the cells of a table in Apple's Numbers application that are scrolled into view.

Availability: Introduced in Mac OS X v10.6.


AXVisibleCharacterRange


The range of the receiver's visible text.

@property(
    readonly) NSValue *AXVisibleCharacterRange; 
Return Value

An NSValue object encoding an NSRange structure, or nil if the receiver does not have a visible text range attribute.

Discussion

The AXVisibleCharacterRange attribute typically applies to text views, not text fields, returning the range of characters of the portion of the receiver's text that is currently scrolled into view. It includes whole lines even if they are clipped horizontally. It is a range of Unicode characters, not a range of bytes.

Use NSValue's -rangeValue method to extract the NSRange structure of the result.


AXVisibleChildren


The receiver's visible children UI elements.

@property(
    readonly) NSArray *AXVisibleChildren; 
Return Value

An array of PFUIElement objects, or nil if the receiver does not have a visible children attribute.

Discussion

An element's AXVisibleChildren attribute represents a subset of its children that are currently visible in their container; for example, the rows of a table or outline view that are scrolled into view.


AXVisibleColumns


The visible columns of the receiving table or outline.

@property(
    readonly) NSArray *AXVisibleColumns; 
Return Value

An array of PFUIElement objects.

Discussion

The AXVisibleColumns attribute applies to a table or outline, returning the subset of its column elements that are scrolled into view.


AXVisibleRows


The visible rows of the receiving table or outline.

@property(
    readonly) NSArray *AXVisibleRows; 
Return Value

An array of PFUIElement objects.

Discussion

The AXVisibleRows attribute applies to a table or outline, returning the subset of its row elements that are scrolled into view.


AXWarningValue


The receiving level indicator's warning value.

@property(
    readonly) id AXWarningValue; 
Return Value

An object of any value, typically an NSNumber.

Discussion

The AXWarningValue attribute applies to a level indicator, returning its warning value.

Availability: Introduced in Mac OS X v10.6.


AXWindow


The window UI element containing the receiver.

@property(
    readonly) PFUIElement *AXWindow; 
Return Value

A PFUIElement object.

Discussion

The AXWindow attribute is a convenient shortcut, providing immediate access to an element's containing window without requiring explicit traversal of the intervening hierarchy.

The AXWindow attribute is similar to AXTopLevelUIElement except that the element returned can only be a window element, not a sheet or a drawer element.

Returns the window from which a sheet or drawer opens if the receiver is a sheet or a drawer, not the window containing the views in the sheet or drawer.


AXWindows


The receiving application's open window elements.

@property(
    readonly) NSArray *AXWindows; 
Return Value

An array of PFUIElement objects.

Discussion

The AXWindows attribute applies to the application object, listing all of its windows.


AXYearField


The year field in the receiving clock control.

@property(
    readonly) PFUIElement *AXYearField; 
Return Value

A PFUIElement object.

Discussion

The AXYearField attribute applies to a clock control element, returning its year field.


AXZoomButton


The zoom button in the receiving window's title bar.

@property(
    readonly) PFUIElement *AXZoomButton; 
Return Value

A PFUIElement object, or nil if the receiving window does not have a zoom button.

Discussion

The AXZoomButton attribute applies to a window object. It is a convenience method to make it easy to access a window's zoom button.

Last Updated: Monday, July 19, 2010