UIA API versioning #11301

Open
opened 2026-01-31 02:43:48 +00:00 by claunia · 0 comments
Owner

Originally created by @codeofdusk on GitHub (Nov 6, 2020).

Originally assigned to: @carlos-zamora on GitHub.

Description of the new feature/enhancement

Since its initial implementation, UIA in conhost has had various levels of completeness and bugginess. To account for this, NVDA must slightly change its behaviour for the various versions. Selected examples:

  • Before #4018, a number of workarounds were necessary as the ends of ranges were not always exclusive. After this PR, those workarounds were not needed, but behaviour needed to change as not all lines ended in a newline character.
  • Before #4495, GetVisibleRanges was unreliable.
  • After #6986, NVDA might no longer need to use GetVisibleRanges in some cases to bound the console, as the thousands of empty lines will be removed from UIA.

Historically, NVDA has checked the Windows build number to determine which workarounds were needed. However, since newer OpenConsole can be run on older Windows, this is no longer sufficient. NVDA should be able to check which version of conhost is in use, perhaps by an API version (incremented for breaking UIA changes) in the automation ID for the text area.

Proposed technical implementation details (optional)

  • The automation ID is set in ScreenInfoUiaProviderBase::GetPropertyValue().
  • Note: You might consider localizing the name set in this function. NVDA specifically ignores the console's name (as it isn't localized and unnecessary for us), but other screen readers (such as Narrator) might not.
Originally created by @codeofdusk on GitHub (Nov 6, 2020). Originally assigned to: @carlos-zamora on GitHub. <!-- 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨 I ACKNOWLEDGE THE FOLLOWING BEFORE PROCEEDING: 1. If I delete this entire template and go my own path, the core team may close my issue without further explanation or engagement. 2. If I list multiple bugs/concerns in this one issue, the core team may close my issue without further explanation or engagement. 3. If I write an issue that has many duplicates, the core team may close my issue without further explanation or engagement (and without necessarily spending time to find the exact duplicate ID number). 4. If I leave the title incomplete when filing the issue, the core team may close my issue without further explanation or engagement. 5. If I file something completely blank in the body, the core team may close my issue without further explanation or engagement. All good? Then proceed! --> # Description of the new feature/enhancement Since its initial implementation, UIA in conhost has had various levels of completeness and bugginess. To account for this, NVDA must slightly change its behaviour for the various versions. Selected examples: * Before #4018, a number of workarounds were necessary as the ends of ranges were not always exclusive. After this PR, those workarounds were not needed, but behaviour needed to change as not all lines ended in a newline character. * Before #4495, `GetVisibleRanges` was unreliable. * After #6986, NVDA might no longer need to use `GetVisibleRanges` in some cases to bound the console, as the thousands of empty lines will be removed from UIA. Historically, NVDA has checked the Windows build number to determine which workarounds were needed. However, since newer OpenConsole can be run on older Windows, this is no longer sufficient. NVDA should be able to check which version of conhost is in use, perhaps by an API version (incremented for breaking UIA changes) in the automation ID for the text area. <!-- A clear and concise description of what the problem is that the new feature would solve. Describe why and how a user would use this new functionality (if applicable). --> # Proposed technical implementation details (optional) * The automation ID is set in `ScreenInfoUiaProviderBase::GetPropertyValue()`. * Note: You might consider localizing the name set in this function. NVDA specifically ignores the console's name (as it isn't localized and unnecessary for us), but other screen readers (such as Narrator) might not. <!-- A clear and concise description of what you want to happen. -->
claunia added the Issue-FeatureNeeds-TriageNeeds-Tag-FixResolution-Won't-Fix labels 2026-01-31 02:43:48 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#11301