Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DataGridView's scrollbars shouldn't include their control type in their accessible names #2965

Closed
Tanya-Solyanik opened this issue Mar 10, 2020 · 1 comment · Fixed by #3038
Assignees
Labels
a11y-MAS High Priority - Accessibility violation of Microsoft Accessibility Standards tenet-accessibility MAS violation, UIA issue; problems with accessibility standards

Comments

@Tanya-Solyanik
Copy link
Member

Tanya-Solyanik commented Mar 10, 2020

Steps to reproduce:

  1. Create a new WinForms .NET 4.8 app in VS.
  2. Add a DataGridView which shows a horizontal scroll bar when run.
  3. Run the app and have the Accessibility Insights for Windows tool examine the UI.

Result: The accessible name of the scrollbar is "Horizontal Scroll Bar", and so given that this includes the same (case insensitive) text as its localized control type of "scroll bar", Accessibility Insights reports this as an error.

Expected: A control shouldn't include its control type in its accessible name, and so the accessible name should be "Horizontal". (It's a similar case for the vertical scroll bar too.)

from @guybark: I spent a while trying to figure out how the accessible name is ending up as "Horizontal Scroll Bar". In https://referencesource.microsoft.com/#System.Windows.Forms/winforms/Managed/System/WinForms/DataGridView.cs, it sets this.horizScrollBar.AccessibleName to SR.GetString(SR.DataGridView_AccHorizontalScrollBarAccName), and in the code I found, that's "Horizontal" as it should be. But it seems that by the time a UIA client gets supplied the name, its "Horizontal Scroll Bar".

ported from AzDo 1071939

@Tanya-Solyanik Tanya-Solyanik added the tenet-accessibility MAS violation, UIA issue; problems with accessibility standards label Mar 10, 2020
@merriemcgaw merriemcgaw added this to the 5.0 milestone Mar 19, 2020
@merriemcgaw merriemcgaw added the a11y-MAS High Priority - Accessibility violation of Microsoft Accessibility Standards label Mar 19, 2020
@ghost ghost added the 🚧 work in progress Work that is current in progress label Apr 3, 2020
@RussKie RussKie modified the milestones: 5.0 Previews 1-4, 5.0 Apr 20, 2020
@ghost ghost removed the 🚧 work in progress Work that is current in progress label Jul 8, 2020
@RussKie RussKie removed this from the 5.0 milestone Jul 16, 2020
@Ashley-Li
Copy link

Verified the issue with latest NET SDK 6.0.100-alpha.1.20557.2, the issue has been fixed that get correct information("Vertical" scroll bar) about the DataGridView using inspect app.
image

@ghost ghost locked as resolved and limited conversation to collaborators Feb 1, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
a11y-MAS High Priority - Accessibility violation of Microsoft Accessibility Standards tenet-accessibility MAS violation, UIA issue; problems with accessibility standards
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants