Details
-
Bug
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
5.15.10, 6.5.2
-
None
Description
TL;DR: Gtk and Qt each expose a "toggle" accessible action on tree items, but that action means/does something different. This makes toolkit-agnostic accessibility support more challenging.
Steps to reproduce:
- Build and run the Simple Tree Model example in Qt Creator
- Launch the Accerciser accessibility explorer
- Examine the Action associated with each cell using Accerciser's Interface Viewer
- Use Accerciser to perform the action
Expected results:* The "Toggle" action would not be exposed on every cell by default. Or it would at least do something other than selecting the item.
Actual results: The "Toggle" action is exposed on every cell by default and all it seems to do it select the item - even in the case of expandable items. (Aside: Why no "expand"/"collapse" action?)
*For historical reasons (Gtk accessibility in Linux), the "toggle" action was/is expected to be exposed on table cells which represented check boxes. This action could be used to change the checked state via accessibility API. BUT more importantly, it was a way for screen readers such as Orca to note that the "checked"/"unchecked" state should be announced for that cell.
Why this matters: I (Orca maintainer) made a change to Orca to normalize action names (Some toolkits capitalize names; others don't. Some insert punctuation; others don't. Etc.) This change was/is intended to increase the likelihood of Orca identifying actions correctly. Apparently it worked too well because now Orca announces each and every tree cell in Qt apps as an unchecked checkbox. (Qt capitalizes "Toggle"; Gtk does not.)
I will, of course, address this in Orca. But from some quick testing it appears that the way to address it will be to just ignore the "Toggle" action in Qt, at least for trees. And that seems unfortunate. UPDATE: I just landed that change in Orca.
That brings me back to my summary and TL;DR: it would be great if Gtk and Qt agreed upon what these actions should be named and what a named action should do. Adding these actions to Atspi would also be positive move, so I just filed https://gitlab.gnome.org/GNOME/at-spi2-core/-/issues/141. Input there is welcome.
In the meantime, is there an actual need (e.g. in Windows, perhaps) to expose the "Toggle" action on tree items by default? If no one is consuming this action on any platform, maybe it could be removed??