107
edits
(start of ATK to UA) |
No edit summary |
||
Line 25: | Line 25: | ||
; AXChildrenAttribute : will return an array of all accessible children of the widget, skipping any ignored widgets on the way. | ; AXChildrenAttribute : will return an array of all accessible children of the widget, skipping any ignored widgets on the way. | ||
; AXParentAttribute : will return the accessible parent of this widget, skipping any ignored widgets on the way. | ; AXParentAttribute : will return the accessible parent of this widget, skipping any ignored widgets on the way. | ||
== Traversing the DOM (AtkDocument) == | |||
This does not currently exist in UA, like with many things that are web-specific. | |||
== Text editing (AtkEditableText) == | |||
=== Basic === | |||
To get/set the value of a text widget you use the [http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/Protocols/NSAccessibility_Protocol/Reference/Reference.html#//apple_ref/doc/c_ref/NSAccessibilityValueAttribute AXValueAttribute]. There are also some [http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/Protocols/NSAccessibility_Protocol/Reference/Reference.html#//apple_ref/doc/uid/20000945-DontLinkElementID_2 text-specific attributes]. | |||
Copying, cutting, pasting etc. are not actions in UA, but the user invokes the menu on the text widget ([http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/Protocols/NSAccessibility_Protocol/Reference/Reference.html#//apple_ref/doc/c_ref/NSAccessibilityShowMenuAction AXShowMenu action]) and then picks the action (copy, paste, cut, etc). | |||
A third-party could of course use standard Cocoa methods on the text widget to let the user perform this in some other way. | |||
=== Rich text-editing === | |||
Rich text-editing is done by querying a text widget for [http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/Protocols/NSAccessibility_Protocol/Reference/Reference.html#//apple_ref/doc/uid/20000945-DontLinkElementID_3 the attributes of specific ranges]. For example, you can: | |||
* Get the bounds of a range | |||
* Get the styled text of a range (as an NSAttributedText object) | |||
* Get the range for a line, or an index, or all visible characters | |||
etc. |
edits