[a11y] Accessibility support of complex IME physical keyboard typing
Categories
(Firefox for Android :: Tooling, enhancement, P1)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox153 | --- | fixed |
People
(Reporter: mcarare, Assigned: mcarare)
References
Details
(Whiteboard: [fxdroid][group6] )
Attachments
(1 external file)
References:
Android 17 Behavior Changes: Accessibility support of complex IME physical keyboard typing
AccessibilityEvent.setTextChangeTypes(int)
TextAttribute.isTextSuggestionSelected()
Android 17 (API 37) introduces new AccessibilityEvent and TextAttribute APIs to enhance screen reader spoken feedback, particularly for CJKV (Chinese, Japanese, Korean, Vietnamese) language input. These changes allow apps to signal the nature of a text change—specifically whether it is part of an ongoing composition, a finalized commit, or the result of a specific conversion suggestion being selected.
While standard TextView components handle these signals automatically when targeting Android 17, apps that maintain a custom InputConnection are required to manually adopt these behaviors to maintain parity.
Currently, InlineAutocompleteEditText uses a custom InputConnectionWrapper to handle its autocomplete logic. Because it overrides the input connection, it does not automatically benefit from the platform's default handling.
The current behaviour needs to be updated to:
- Process the
TextAttributeprovided incommitTextandsetComposingText. - Signal the appropriate text change types (e.g., TEXT_CHANGE_TYPE_IN_COMPOSITION, TEXT_CHANGE_TYPE_COMMITTED_BY_IME) when dispatching TYPE_VIEW_TEXT_CHANGED accessibility events.
Updated•6 months ago
|
Comment 1•6 months ago
|
||
Marking access-s2 because it sounds like using a custom wrapper without explicit implementation handling prevents some ATs from functioning
| Assignee | ||
Comment 2•6 months ago
|
||
- Overrode
commitTextandsetComposingTextin theInputConnectionwrapper to support theTextAttributeparameter introduced in Android 15 (API 35). - Implemented tracking of
pendingTextChangeTypesto capture specific IME actions, such as text composition and conversion suggestion selection. - Updated
sendAccessibilityEventUncheckedto populateAccessibilityEvent.textChangeTypesforTYPE_VIEW_TEXT_CHANGEDevents on API 37 and above. - Ensured existing autocomplete removal logic is preserved within the new
InputConnectionmethod overrides.
Description
•