Set toolkit name and version in the accessibility tree - #25167
#25167Open
DataTriny wants to merge 1 commit into
Open
Set toolkit name and version in the accessibility tree#25167DataTriny wants to merge 1 commit into
DataTriny wants to merge 1 commit into
Conversation
alice-i-cecile
approved these changes
Jul 26, 2026
Member
|
Very reasonable, thanks for fixing this upstream <3 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Objective
Some platform accessibility stacks (Windows and Linux) allow applications to communicate to assistive technologies which UI toolkit is used. This can be useful for assistive technology developers to investigate issues, to know where to report bugs or even to automatically patch malformed accessibility trees produced by certain applications or UI toolkits. Since accesskit 0.24.1, we set the toolkit name as "AccessKit" by default to at least redirect people to AccessKit, but it is better if downstream projects set the correct value themselves.
Solution
Populate
toolkit_nameandtoolkit_versionwhen building an AccessKitTreestruct. I usedenv!("CARGO_PKG_VERSION")to get Bevy's current version which works because all crates currently share the same, this would of course report the wrong value if this ever changed.Testing
On Windows I ran the button UI example and used the NVDA screen reader's NVDA+F1 command to get information on the focused widget. I observed that the UIAutomation ProviderDescription property correctly contained "Bevy 0.20.0-dev".