From d16a4cd3d2692cbcc5901b28a8f2cd589a92e473 Mon Sep 17 00:00:00 2001 From: Mikhail Lipin Date: Fri, 16 Aug 2019 04:54:30 -0700 Subject: [PATCH 01/11] Adding Accessibility doc for Core WinForms. --- ...indows-forms-accessibility-improvements.md | 97 +++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 docs/framework/winforms/windows-forms-accessibility-improvements.md diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md new file mode 100644 index 0000000000000..8b07f585441b6 --- /dev/null +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -0,0 +1,97 @@ +--- +title: "Windows Forms Accessibility Improvements" +ms.date: "08/16/2019" +helpviewer_keywords: + - "Windows Forms accessibility" + - "accessibility" +ms.assetid: +--- +# Accessibility improvements in Windows Forms controls for .NET Core + +## Scope +Major + +## Version Introduced +.NET Core 3.0 + +## Change Description +The Windows Forms is continuing to improve how it works with accessibility technologies to better support Windows Forms customers. These include the following changes: +- Changes in various areas of interaction with accessibility client applications including Narrator. +- Changes in the Accessible hierarchy (improving navigation through the UI Automation tree). + +- [x] The quirks which were used in .NET Framework 4.7.1 - 4.8 to opt-in/out new accessibility features have been removed, so previously quirked behavior is now enabled by default. + +### Recommended Action +__The changes which could be opted in or out in .NET Framework 4.7.1 - 4.8 are now enabled by default and cannot be opted out__ + +Applications now benefit from all the new accessibility features (introduced in .NET Framework 4.7.1 - 4.8) without additional configuration. + +__Improved ListBox Accessibility support__ +- Enabled UIA support for ListBox control. +- Improved ListBox Accessibility support by adding the ScrollItem pattern to ListBox items and by enhancing the accessibility event raising and handling and Narrator navigation through the items (caps lock navigation is not correct and does not throw the navigation outside the control unintentionally). + +__Improved CheckedListBox Accessibility support__ +- Corrected CheckedListBox Bounds provided by accessibility properties for entries. Improved overall ListBox and CheckedListBox accessibility (corrected pproperty values and event model). + +__Improved ComboBox Accessibility support__ +- Updated the process of getting ComboBox items' accessibility objects to enable generating IDs for items instead of getting hash codes from items which maybe unsafe in case of GetHashCode function is overriden. + +__Improved DataGridView Accessibility support__ +- Corrected DataGridView Bounds provided by accessibility properties for columns, rows, cells and corresponding headers, imroved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. +- Corrected Value.IsReadOnly property value providing for accessible client applications. The property now shows correct IsReadOnly status for cells. +- Fixed the issue with CellParsing event raising for the very first cell change. Cell value is now can be changed without any issues including the very first DataGridView control interaction. + +__Improved PropertyGrid Accessibility support__ +- Corrected PropertyGrid Bounds provided by accessibility properties for grid entries, imroved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. +- Corrected accessible names and descriptions of subcontrols to not include control type names and to avoid double announcement for control type names. + +__Improved Menu Accessibility support__ +- Improved Menu accessible navigation, corrected menu accessible control types for submenus to make submenus of type 'Menu' instead of 'MenuItem'. + +__Improved ToolStrip Accessibility support__ +- Improved navigation through items. Corrected ToolStrip and Menu shift-tab navigation (back-looping the menu items when shift-tab up-arrow is pressed - navigate to the bottom menu element) + +__Improved PrintPreviewControl and PrintPreviewDialog Accessibility support__ +- Improved accessible navigation (including Narrator navigation) through menu items. +- Improved High Contrast themes support and made the control element more contrasted. + +__StringCollectionEditor Accessibility support__ +- Added StringCollectionEditor with improved accessibility support. + +__UI automation support for DataGridView, PropertyGrid, ListBox, ComboBox, ToolStrip and other controls__ +Note: UI automation support is enabled for controls in runtime but is not used in design time. +For an overview of UI automation, see the [UI Automation Overview](https://docs.microsoft.com/dotnet/framework/ui-automation/ui-automation-overview). + + +### Affected APIs +None + +### Category +Windows Forms + + + + + From 4eaedda7c25fce0dd2ad7249702aef78e5f18e47 Mon Sep 17 00:00:00 2001 From: Mikhail Lipin Date: Fri, 16 Aug 2019 05:28:56 -0700 Subject: [PATCH 02/11] Fixing code review points. --- .../windows-forms-accessibility-improvements.md | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md index 8b07f585441b6..7554af18a7f20 100644 --- a/docs/framework/winforms/windows-forms-accessibility-improvements.md +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -18,6 +18,7 @@ Major The Windows Forms is continuing to improve how it works with accessibility technologies to better support Windows Forms customers. These include the following changes: - Changes in various areas of interaction with accessibility client applications including Narrator. - Changes in the Accessible hierarchy (improving navigation through the UI Automation tree). +- Changes in keyboard navigation. - [x] The quirks which were used in .NET Framework 4.7.1 - 4.8 to opt-in/out new accessibility features have been removed, so previously quirked behavior is now enabled by default. @@ -34,22 +35,20 @@ __Improved CheckedListBox Accessibility support__ - Corrected CheckedListBox Bounds provided by accessibility properties for entries. Improved overall ListBox and CheckedListBox accessibility (corrected pproperty values and event model). __Improved ComboBox Accessibility support__ -- Updated the process of getting ComboBox items' accessibility objects to enable generating IDs for items instead of getting hash codes from items which maybe unsafe in case of GetHashCode function is overriden. +- Updated the process of getting ComboBox items' accessibility objects to enable generating IDs for items instead of getting hash codes from items which may be unsafe in case of GetHashCode function is overriden. __Improved DataGridView Accessibility support__ -- Corrected DataGridView Bounds provided by accessibility properties for columns, rows, cells and corresponding headers, imroved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. +- Corrected DataGridView Bounds provided by accessibility properties for columns, rows, cells and corresponding headers, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. - Corrected Value.IsReadOnly property value providing for accessible client applications. The property now shows correct IsReadOnly status for cells. - Fixed the issue with CellParsing event raising for the very first cell change. Cell value is now can be changed without any issues including the very first DataGridView control interaction. __Improved PropertyGrid Accessibility support__ -- Corrected PropertyGrid Bounds provided by accessibility properties for grid entries, imroved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. +- Corrected PropertyGrid Bounds provided by accessibility properties for grid entries, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. - Corrected accessible names and descriptions of subcontrols to not include control type names and to avoid double announcement for control type names. -__Improved Menu Accessibility support__ -- Improved Menu accessible navigation, corrected menu accessible control types for submenus to make submenus of type 'Menu' instead of 'MenuItem'. - __Improved ToolStrip Accessibility support__ -- Improved navigation through items. Corrected ToolStrip and Menu shift-tab navigation (back-looping the menu items when shift-tab up-arrow is pressed - navigate to the bottom menu element) +- Improved navigation through ToolStrip items. Corrected ToolStrip and Menu shift-tab navigation (back-looping the menu items when shift-tab up-arrow is pressed - navigate to the bottom menu element) +- Improved Menu accessible navigation, corrected menu accessible control types for submenus to make submenus of type 'Menu' instead of 'MenuItem'. __Improved PrintPreviewControl and PrintPreviewDialog Accessibility support__ - Improved accessible navigation (including Narrator navigation) through menu items. From d070ab38054516da12a61ee452847a863dea3c95 Mon Sep 17 00:00:00 2001 From: Mikhail Lipin Date: Thu, 7 Nov 2019 16:59:46 +0300 Subject: [PATCH 03/11] Adding information about MonthCalendar control accessibility changes. --- .../winforms/windows-forms-accessibility-improvements.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md index 7554af18a7f20..28d7ea9b3136f 100644 --- a/docs/framework/winforms/windows-forms-accessibility-improvements.md +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -57,6 +57,13 @@ __Improved PrintPreviewControl and PrintPreviewDialog Accessibility support__ __StringCollectionEditor Accessibility support__ - Added StringCollectionEditor with improved accessibility support. +__Improved MonthCalendar Accessibility support__ +- Added UI Automation server providers to MonthCalendar control, added UI Automation Grid pattern and Table pattern providers. +- Changed _table_ accessible control type to _calendar_ accessible control type for MonthCalendar except the case when the control has a preceeding label control which defines MonthCalendar control accessible name, in this specific case accessible control type becomes _table_. +- Improved announcement of selected date for MonthCalendar control. +- Improved MounthCalendar control support for screen readers and other accessibility tools. At this moment users are able to navigate the control elements and interact with these elements using keyboard only input (For Narrator: ca use CAPS + arrow keys to navigation thru the control elements and CAPS + Enter to invoke element default action). Improved arrow key navigation across MonthCalendar child elements accompanied with focusing rectangle (blue focus rectangle for Narrator). +- Improved accessibility for hit test action for MonthCalendar control elements to allow getting MonthCalendar child accessible element by provided coordinates. + __UI automation support for DataGridView, PropertyGrid, ListBox, ComboBox, ToolStrip and other controls__ Note: UI automation support is enabled for controls in runtime but is not used in design time. For an overview of UI automation, see the [UI Automation Overview](https://docs.microsoft.com/dotnet/framework/ui-automation/ui-automation-overview). From 819d7f721bf90effabdfb8879c233a92e180b634 Mon Sep 17 00:00:00 2001 From: Mikhail Lipin Date: Thu, 7 Nov 2019 17:19:46 +0300 Subject: [PATCH 04/11] Fixing review points. --- ...indows-forms-accessibility-improvements.md | 83 ++++++------------- 1 file changed, 25 insertions(+), 58 deletions(-) diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md index 28d7ea9b3136f..4badc52e275ce 100644 --- a/docs/framework/winforms/windows-forms-accessibility-improvements.md +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -4,19 +4,12 @@ ms.date: "08/16/2019" helpviewer_keywords: - "Windows Forms accessibility" - "accessibility" -ms.assetid: +author: "M-Lipin" --- -# Accessibility improvements in Windows Forms controls for .NET Core +# Accessibility improvements in Windows Forms controls for .NET Core 3.0 -## Scope -Major - -## Version Introduced -.NET Core 3.0 - -## Change Description -The Windows Forms is continuing to improve how it works with accessibility technologies to better support Windows Forms customers. These include the following changes: -- Changes in various areas of interaction with accessibility client applications including Narrator. +Windows Forms is continuing to improve how it works with accessibility technologies to better support Windows Forms customers. These include the following changes: +- Changes in various areas of interaction with accessibility client applications, including Narrator. - Changes in the Accessible hierarchy (improving navigation through the UI Automation tree). - Changes in keyboard navigation. @@ -25,79 +18,53 @@ The Windows Forms is continuing to improve how it works with accessibility techn ### Recommended Action __The changes which could be opted in or out in .NET Framework 4.7.1 - 4.8 are now enabled by default and cannot be opted out__ -Applications now benefit from all the new accessibility features (introduced in .NET Framework 4.7.1 - 4.8) without additional configuration. +Starting with .NET Core 3.0, Windows Forms applications benefit from all the new accessibility features (introduced in .NET Framework 4.7.1 - 4.8) without additional configuration. -__Improved ListBox Accessibility support__ +## Improved ListBox Accessibility support +On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.ListBox control: - Enabled UIA support for ListBox control. -- Improved ListBox Accessibility support by adding the ScrollItem pattern to ListBox items and by enhancing the accessibility event raising and handling and Narrator navigation through the items (caps lock navigation is not correct and does not throw the navigation outside the control unintentionally). +- Improved ListBox accessibility support by adding the ScrollItem pattern to ListBox items and by enhancing the accessibility event raising and handling and Narrator navigation through the items (caps lock navigation is not correct and does not throw the navigation outside the control unintentionally). -__Improved CheckedListBox Accessibility support__ +## Improved CheckedListBox Accessibility support +On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.CheckedListBox control: - Corrected CheckedListBox Bounds provided by accessibility properties for entries. Improved overall ListBox and CheckedListBox accessibility (corrected pproperty values and event model). -__Improved ComboBox Accessibility support__ +## Improved ComboBox Accessibility support +On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.ComboBox control: - Updated the process of getting ComboBox items' accessibility objects to enable generating IDs for items instead of getting hash codes from items which may be unsafe in case of GetHashCode function is overriden. -__Improved DataGridView Accessibility support__ +## Improved DataGridView Accessibility support +On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.DataGridView control: - Corrected DataGridView Bounds provided by accessibility properties for columns, rows, cells and corresponding headers, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. - Corrected Value.IsReadOnly property value providing for accessible client applications. The property now shows correct IsReadOnly status for cells. - Fixed the issue with CellParsing event raising for the very first cell change. Cell value is now can be changed without any issues including the very first DataGridView control interaction. -__Improved PropertyGrid Accessibility support__ +## Improved PropertyGrid Accessibility support +On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.PropertyGrid control: - Corrected PropertyGrid Bounds provided by accessibility properties for grid entries, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. - Corrected accessible names and descriptions of subcontrols to not include control type names and to avoid double announcement for control type names. -__Improved ToolStrip Accessibility support__ +## Improved ToolStrip Accessibility support +On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.ToolStrip control: - Improved navigation through ToolStrip items. Corrected ToolStrip and Menu shift-tab navigation (back-looping the menu items when shift-tab up-arrow is pressed - navigate to the bottom menu element) - Improved Menu accessible navigation, corrected menu accessible control types for submenus to make submenus of type 'Menu' instead of 'MenuItem'. -__Improved PrintPreviewControl and PrintPreviewDialog Accessibility support__ +## Improved PrintPreviewControl and PrintPreviewDialog Accessibility support +On .NET Core, Windows Forms includes the following changes that affect the print controls: - Improved accessible navigation (including Narrator navigation) through menu items. - Improved High Contrast themes support and made the control element more contrasted. -__StringCollectionEditor Accessibility support__ -- Added StringCollectionEditor with improved accessibility support. +## StringCollectionEditor Accessibility support +On .NET Core, Windows Forms gets StringCollectionEditor with improved accessibility support. -__Improved MonthCalendar Accessibility support__ +## Improved MonthCalendar Accessibility support (available in .NET Core 3.1) +On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.MonthCalendar control: - Added UI Automation server providers to MonthCalendar control, added UI Automation Grid pattern and Table pattern providers. - Changed _table_ accessible control type to _calendar_ accessible control type for MonthCalendar except the case when the control has a preceeding label control which defines MonthCalendar control accessible name, in this specific case accessible control type becomes _table_. - Improved announcement of selected date for MonthCalendar control. - Improved MounthCalendar control support for screen readers and other accessibility tools. At this moment users are able to navigate the control elements and interact with these elements using keyboard only input (For Narrator: ca use CAPS + arrow keys to navigation thru the control elements and CAPS + Enter to invoke element default action). Improved arrow key navigation across MonthCalendar child elements accompanied with focusing rectangle (blue focus rectangle for Narrator). - Improved accessibility for hit test action for MonthCalendar control elements to allow getting MonthCalendar child accessible element by provided coordinates. -__UI automation support for DataGridView, PropertyGrid, ListBox, ComboBox, ToolStrip and other controls__ +## UI automation support for DataGridView, PropertyGrid, ListBox, ComboBox, ToolStrip and other controls Note: UI automation support is enabled for controls in runtime but is not used in design time. For an overview of UI automation, see the [UI Automation Overview](https://docs.microsoft.com/dotnet/framework/ui-automation/ui-automation-overview). - - -### Affected APIs -None - -### Category -Windows Forms - - - - - From 60a677c62018327e0782c4b50be89a24dc26e586 Mon Sep 17 00:00:00 2001 From: Mikhail Lipin Date: Thu, 7 Nov 2019 17:43:22 +0300 Subject: [PATCH 05/11] Adding comments about DataGridView and Tooltip accessibility improvements. --- .../winforms/windows-forms-accessibility-improvements.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md index 4badc52e275ce..cbc70a08b9d7c 100644 --- a/docs/framework/winforms/windows-forms-accessibility-improvements.md +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -38,6 +38,7 @@ On .NET Core, Windows Forms includes the following changes that affect the xref: - Corrected DataGridView Bounds provided by accessibility properties for columns, rows, cells and corresponding headers, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. - Corrected Value.IsReadOnly property value providing for accessible client applications. The property now shows correct IsReadOnly status for cells. - Fixed the issue with CellParsing event raising for the very first cell change. Cell value is now can be changed without any issues including the very first DataGridView control interaction. +- Improved DataGridView background color contrast when using Windows High Contrast themes. Changed DataGridView default back color when using HC#1, HC#2, and HC Black themes. ## Improved PropertyGrid Accessibility support On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.PropertyGrid control: @@ -65,6 +66,9 @@ On .NET Core, Windows Forms includes the following changes that affect the xref: - Improved MounthCalendar control support for screen readers and other accessibility tools. At this moment users are able to navigate the control elements and interact with these elements using keyboard only input (For Narrator: ca use CAPS + arrow keys to navigation thru the control elements and CAPS + Enter to invoke element default action). Improved arrow key navigation across MonthCalendar child elements accompanied with focusing rectangle (blue focus rectangle for Narrator). - Improved accessibility for hit test action for MonthCalendar control elements to allow getting MonthCalendar child accessible element by provided coordinates. +## Improved ToolTips accessibility (available in .NET Core 3.1) +- Added ability to announce a tooltip text by screen reader applications (NVDA/Narrator). Screen reader application can now announce the text of keyboard or mouse tooltip of any WinForms control that configured to show tooltip/s. + ## UI automation support for DataGridView, PropertyGrid, ListBox, ComboBox, ToolStrip and other controls Note: UI automation support is enabled for controls in runtime but is not used in design time. For an overview of UI automation, see the [UI Automation Overview](https://docs.microsoft.com/dotnet/framework/ui-automation/ui-automation-overview). From fdad7ce0debd082f4d4ffd622f942d61423c100a Mon Sep 17 00:00:00 2001 From: Mikhail Lipin Date: Tue, 19 Nov 2019 15:34:16 +0300 Subject: [PATCH 06/11] Fixing code review points: added description, fixed date and references. --- .../windows-forms-accessibility-improvements.md | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md index cbc70a08b9d7c..dbc68a571a002 100644 --- a/docs/framework/winforms/windows-forms-accessibility-improvements.md +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -1,6 +1,7 @@ --- title: "Windows Forms Accessibility Improvements" -ms.date: "08/16/2019" +description: Learn about the ways in which .NET Core WinForms attempts to improve accessibility in comparison with .NET Framework WinForms. +ms.date: "11/19/2019" helpviewer_keywords: - "Windows Forms accessibility" - "accessibility" @@ -21,32 +22,32 @@ __The changes which could be opted in or out in .NET Framework 4.7.1 - 4.8 are n Starting with .NET Core 3.0, Windows Forms applications benefit from all the new accessibility features (introduced in .NET Framework 4.7.1 - 4.8) without additional configuration. ## Improved ListBox Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.ListBox control: +On .NET Core, Windows Forms includes the following changes that affect the : - Enabled UIA support for ListBox control. - Improved ListBox accessibility support by adding the ScrollItem pattern to ListBox items and by enhancing the accessibility event raising and handling and Narrator navigation through the items (caps lock navigation is not correct and does not throw the navigation outside the control unintentionally). ## Improved CheckedListBox Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.CheckedListBox control: +On .NET Core, Windows Forms includes the following changes that affect the : - Corrected CheckedListBox Bounds provided by accessibility properties for entries. Improved overall ListBox and CheckedListBox accessibility (corrected pproperty values and event model). ## Improved ComboBox Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.ComboBox control: +On .NET Core, Windows Forms includes the following changes that affect the : - Updated the process of getting ComboBox items' accessibility objects to enable generating IDs for items instead of getting hash codes from items which may be unsafe in case of GetHashCode function is overriden. ## Improved DataGridView Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.DataGridView control: +On .NET Core, Windows Forms includes the following changes that affect the : - Corrected DataGridView Bounds provided by accessibility properties for columns, rows, cells and corresponding headers, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. - Corrected Value.IsReadOnly property value providing for accessible client applications. The property now shows correct IsReadOnly status for cells. - Fixed the issue with CellParsing event raising for the very first cell change. Cell value is now can be changed without any issues including the very first DataGridView control interaction. - Improved DataGridView background color contrast when using Windows High Contrast themes. Changed DataGridView default back color when using HC#1, HC#2, and HC Black themes. ## Improved PropertyGrid Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.PropertyGrid control: +On .NET Core, Windows Forms includes the following changes that affect the : - Corrected PropertyGrid Bounds provided by accessibility properties for grid entries, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. - Corrected accessible names and descriptions of subcontrols to not include control type names and to avoid double announcement for control type names. ## Improved ToolStrip Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.ToolStrip control: +On .NET Core, Windows Forms includes the following changes that affect the : - Improved navigation through ToolStrip items. Corrected ToolStrip and Menu shift-tab navigation (back-looping the menu items when shift-tab up-arrow is pressed - navigate to the bottom menu element) - Improved Menu accessible navigation, corrected menu accessible control types for submenus to make submenus of type 'Menu' instead of 'MenuItem'. @@ -59,7 +60,7 @@ On .NET Core, Windows Forms includes the following changes that affect the print On .NET Core, Windows Forms gets StringCollectionEditor with improved accessibility support. ## Improved MonthCalendar Accessibility support (available in .NET Core 3.1) -On .NET Core, Windows Forms includes the following changes that affect the xref:System.Windows.Forms.MonthCalendar control: +On .NET Core, Windows Forms includes the following changes that affect the : - Added UI Automation server providers to MonthCalendar control, added UI Automation Grid pattern and Table pattern providers. - Changed _table_ accessible control type to _calendar_ accessible control type for MonthCalendar except the case when the control has a preceeding label control which defines MonthCalendar control accessible name, in this specific case accessible control type becomes _table_. - Improved announcement of selected date for MonthCalendar control. From 1bb46656812466880aa16be3d7fe6952f5c42c41 Mon Sep 17 00:00:00 2001 From: Mikhail Lipin Date: Wed, 4 Dec 2019 15:39:01 +0300 Subject: [PATCH 07/11] Updating document as per review suggestion. Co-Authored-By: Igor Velikorossov --- .../winforms/windows-forms-accessibility-improvements.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md index dbc68a571a002..8297d71b971d6 100644 --- a/docs/framework/winforms/windows-forms-accessibility-improvements.md +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -28,7 +28,8 @@ On .NET Core, Windows Forms includes the following changes that affect the : -- Corrected CheckedListBox Bounds provided by accessibility properties for entries. Improved overall ListBox and CheckedListBox accessibility (corrected pproperty values and event model). +- Corrected CheckedListBox Bounds provided by accessibility properties for entries. +- Improved overall ListBox and CheckedListBox accessibility (corrected property values and event model). ## Improved ComboBox Accessibility support On .NET Core, Windows Forms includes the following changes that affect the : From 7b0c2fb2798a3eb186b796833801c94b8a4b0263 Mon Sep 17 00:00:00 2001 From: Mikhail Lipin Date: Wed, 4 Dec 2019 16:01:31 +0300 Subject: [PATCH 08/11] Fixing the comment about menu acessibility updates: replaced Menu with MenuStrip term. --- .../winforms/windows-forms-accessibility-improvements.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md index 8297d71b971d6..395aebc8ec20e 100644 --- a/docs/framework/winforms/windows-forms-accessibility-improvements.md +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -49,8 +49,8 @@ On .NET Core, Windows Forms includes the following changes that affect the : -- Improved navigation through ToolStrip items. Corrected ToolStrip and Menu shift-tab navigation (back-looping the menu items when shift-tab up-arrow is pressed - navigate to the bottom menu element) -- Improved Menu accessible navigation, corrected menu accessible control types for submenus to make submenus of type 'Menu' instead of 'MenuItem'. +- Improved navigation through ToolStrip, MenuStrip and StatusStrip items. Corrected ToolStrip and MenuStrip shift-tab navigation (back-looping the menu items when shift-tab up-arrow is pressed - navigate to the bottom menu element) +- Improved MenuStrip accessible navigation, corrected menu accessible control types for submenus to make submenus of type 'Menu' instead of 'MenuItem'. ## Improved PrintPreviewControl and PrintPreviewDialog Accessibility support On .NET Core, Windows Forms includes the following changes that affect the print controls: From 222d96d799248e441287664a762290d00ce6a7e4 Mon Sep 17 00:00:00 2001 From: Andy De George <2672110+Thraka@users.noreply.github.com> Date: Mon, 20 Apr 2020 08:55:40 -0700 Subject: [PATCH 09/11] Apply suggestions from code review Co-Authored-By: Ron Petrusha <10886961+rpetrusha@users.noreply.github.com> --- .../winforms/windows-forms-accessibility-improvements.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md index 395aebc8ec20e..e734063aa988d 100644 --- a/docs/framework/winforms/windows-forms-accessibility-improvements.md +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -14,10 +14,9 @@ Windows Forms is continuing to improve how it works with accessibility technolog - Changes in the Accessible hierarchy (improving navigation through the UI Automation tree). - Changes in keyboard navigation. -- [x] The quirks which were used in .NET Framework 4.7.1 - 4.8 to opt-in/out new accessibility features have been removed, so previously quirked behavior is now enabled by default. -### Recommended Action -__The changes which could be opted in or out in .NET Framework 4.7.1 - 4.8 are now enabled by default and cannot be opted out__ +> [!IMPORTANT] +> Accessibility changes made in .NET Framework 4.7.1 through .NET Framework 4.8 are included in .NET Core 3.0 and are enabled by default. The .NET Framework supported compatibility switches that allowed applications to opt out of the new accessibility behavior. .NET Core, on the other hand, does not support these settings and does not allow applications to opt out of accessibility behavior. Starting with .NET Core 3.0, Windows Forms applications benefit from all the new accessibility features (introduced in .NET Framework 4.7.1 - 4.8) without additional configuration. From fc700e06b442e079494b4b744996b349701f1279 Mon Sep 17 00:00:00 2001 From: Andy De George <2672110+Thraka@users.noreply.github.com> Date: Mon, 20 Apr 2020 13:20:30 -0700 Subject: [PATCH 10/11] Fixed acro problems; more xref links --- ...indows-forms-accessibility-improvements.md | 125 +++++++++++------- 1 file changed, 74 insertions(+), 51 deletions(-) diff --git a/docs/framework/winforms/windows-forms-accessibility-improvements.md b/docs/framework/winforms/windows-forms-accessibility-improvements.md index e734063aa988d..38f41ba64f3c5 100644 --- a/docs/framework/winforms/windows-forms-accessibility-improvements.md +++ b/docs/framework/winforms/windows-forms-accessibility-improvements.md @@ -1,7 +1,7 @@ --- title: "Windows Forms Accessibility Improvements" -description: Learn about the ways in which .NET Core WinForms attempts to improve accessibility in comparison with .NET Framework WinForms. -ms.date: "11/19/2019" +description: Learn about the ways in which .NET Core Windows Forms attempts to improve accessibility in comparison with .NET Framework Windows Forms. +ms.date: "04/20/2020" helpviewer_keywords: - "Windows Forms accessibility" - "accessibility" @@ -9,67 +9,90 @@ author: "M-Lipin" --- # Accessibility improvements in Windows Forms controls for .NET Core 3.0 -Windows Forms is continuing to improve how it works with accessibility technologies to better support Windows Forms customers. These include the following changes: +Windows Forms is continuing to improve how it works with accessibility technologies to better support Windows Forms customers. These improvements include the following changes: + - Changes in various areas of interaction with accessibility client applications, including Narrator. - Changes in the Accessible hierarchy (improving navigation through the UI Automation tree). - Changes in keyboard navigation. - > [!IMPORTANT] -> Accessibility changes made in .NET Framework 4.7.1 through .NET Framework 4.8 are included in .NET Core 3.0 and are enabled by default. The .NET Framework supported compatibility switches that allowed applications to opt out of the new accessibility behavior. .NET Core, on the other hand, does not support these settings and does not allow applications to opt out of accessibility behavior. +> Accessibility changes made in .NET Framework 4.7.1 through .NET Framework 4.8 are included in .NET Core 3.0 and above, and are enabled by default. The .NET Framework supported compatibility switches that allowed applications to opt out of the new accessibility behavior. On the other hand, .NET Core doesn't support these settings and doesn't allow applications to opt out of accessibility behavior. Starting with .NET Core 3.0, Windows Forms applications benefit from all the new accessibility features (introduced in .NET Framework 4.7.1 - 4.8) without additional configuration. -## Improved ListBox Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the : -- Enabled UIA support for ListBox control. -- Improved ListBox accessibility support by adding the ScrollItem pattern to ListBox items and by enhancing the accessibility event raising and handling and Narrator navigation through the items (caps lock navigation is not correct and does not throw the navigation outside the control unintentionally). - -## Improved CheckedListBox Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the : -- Corrected CheckedListBox Bounds provided by accessibility properties for entries. -- Improved overall ListBox and CheckedListBox accessibility (corrected property values and event model). - -## Improved ComboBox Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the : -- Updated the process of getting ComboBox items' accessibility objects to enable generating IDs for items instead of getting hash codes from items which may be unsafe in case of GetHashCode function is overriden. - -## Improved DataGridView Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the : -- Corrected DataGridView Bounds provided by accessibility properties for columns, rows, cells and corresponding headers, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. -- Corrected Value.IsReadOnly property value providing for accessible client applications. The property now shows correct IsReadOnly status for cells. -- Fixed the issue with CellParsing event raising for the very first cell change. Cell value is now can be changed without any issues including the very first DataGridView control interaction. -- Improved DataGridView background color contrast when using Windows High Contrast themes. Changed DataGridView default back color when using HC#1, HC#2, and HC Black themes. - -## Improved PropertyGrid Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the : -- Corrected PropertyGrid Bounds provided by accessibility properties for grid entries, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, its viewport and scrolls. +## ListBox Accessibility support + +The following changes apply to the control: + +- Enabled UI Automation support for `ListBox` control. +- Improved `ListBox` accessibility support by adding the to `ListBox` items and by enhancing the accessibility event raising and handling and Narrator navigation through the items (caps lock navigation isn't correct and doesn't throw the navigation outside the control unintentionally). + +## CheckedListBox Accessibility support + +The following changes apply to the control: + +- Corrected `CheckedListBox` Bounds provided by accessibility properties for entries. +- Improved overall `ListBox` and `CheckedListBox` accessibility: corrected property values and event model. + +## ComboBox Accessibility support + +The following changes apply to the control: + +- Updated the process of getting `ComboBox` items' accessibility objects to enable generating IDs for items instead of getting hash codes from items, which may be unsafe in case the function is overridden. + +## DataGridView Accessibility support + +The following changes apply to the control: + +- Corrected `DataGridView.Bounds` provided by accessibility properties for columns, rows, cells and corresponding headers, improved performance of bounding rectangle calculation. All accessibility bounds are represented correctly taking into account the bounds of entire control, along with its viewport. +- Corrected `Value.IsReadOnly` property value providing for accessible client applications. The property now shows correct `IsReadOnly` status for cells. +- Fixed the issue with event raising for the first cell change. Cell value can be changed without any issues including the first `DataGridView` control interaction. +- Improved `DataGridView` background color contrast when using Windows High Contrast themes. Changed `DataGridView` default back color when using HC#1, HC#2, and HC Black themes. + +## PropertyGrid Accessibility support + +The following changes apply to the control: + +- Corrected `PropertyGrid.Bounds` provided by accessibility properties for grid entries, improved performance of bounding rectangle calculation. For now all accessibility bounds are represented correctly taking into account the bounds of entire control, along with its viewport. - Corrected accessible names and descriptions of subcontrols to not include control type names and to avoid double announcement for control type names. -## Improved ToolStrip Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the : -- Improved navigation through ToolStrip, MenuStrip and StatusStrip items. Corrected ToolStrip and MenuStrip shift-tab navigation (back-looping the menu items when shift-tab up-arrow is pressed - navigate to the bottom menu element) -- Improved MenuStrip accessible navigation, corrected menu accessible control types for submenus to make submenus of type 'Menu' instead of 'MenuItem'. +## ToolStrip Accessibility support + +The following changes apply to the control: + +- Improved navigation through `ToolStrip`, `MenuStrip`, and `StatusStrip` items. Corrected `ToolStrip` and `MenuStrip` shift-tab navigation, back-looping the menu items when shift-tab up-arrow is pressed, which navigates to the bottom menu element. +- Improved `MenuStrip` accessible navigation, corrected menu accessible control types for submenus to make submenus of type 'Menu' instead of 'MenuItem'. + +## PrintPreviewControl and PrintPreviewDialog Accessibility support + +The following changes apply to the print controls: -## Improved PrintPreviewControl and PrintPreviewDialog Accessibility support -On .NET Core, Windows Forms includes the following changes that affect the print controls: - Improved accessible navigation (including Narrator navigation) through menu items. - Improved High Contrast themes support and made the control element more contrasted. ## StringCollectionEditor Accessibility support -On .NET Core, Windows Forms gets StringCollectionEditor with improved accessibility support. - -## Improved MonthCalendar Accessibility support (available in .NET Core 3.1) -On .NET Core, Windows Forms includes the following changes that affect the : -- Added UI Automation server providers to MonthCalendar control, added UI Automation Grid pattern and Table pattern providers. -- Changed _table_ accessible control type to _calendar_ accessible control type for MonthCalendar except the case when the control has a preceeding label control which defines MonthCalendar control accessible name, in this specific case accessible control type becomes _table_. -- Improved announcement of selected date for MonthCalendar control. -- Improved MounthCalendar control support for screen readers and other accessibility tools. At this moment users are able to navigate the control elements and interact with these elements using keyboard only input (For Narrator: ca use CAPS + arrow keys to navigation thru the control elements and CAPS + Enter to invoke element default action). Improved arrow key navigation across MonthCalendar child elements accompanied with focusing rectangle (blue focus rectangle for Narrator). -- Improved accessibility for hit test action for MonthCalendar control elements to allow getting MonthCalendar child accessible element by provided coordinates. - -## Improved ToolTips accessibility (available in .NET Core 3.1) -- Added ability to announce a tooltip text by screen reader applications (NVDA/Narrator). Screen reader application can now announce the text of keyboard or mouse tooltip of any WinForms control that configured to show tooltip/s. - -## UI automation support for DataGridView, PropertyGrid, ListBox, ComboBox, ToolStrip and other controls -Note: UI automation support is enabled for controls in runtime but is not used in design time. -For an overview of UI automation, see the [UI Automation Overview](https://docs.microsoft.com/dotnet/framework/ui-automation/ui-automation-overview). + +Windows Forms designer now uses the string collection editor with improved accessibility support. + +## MonthCalendar Accessibility support (available in .NET Core 3.1) + +The following changes apply to the control: + +- Added UI Automation server providers to `MonthCalendar` control, added UI Automation Grid pattern and Table pattern providers. +- Changed _table_ accessible control type to _calendar_ accessible control type for `MonthCalendar` except the case when the control has a preceding label control that defines `MonthCalendar` control accessible name, in this specific case accessible control type becomes _table_. +- Improved announcement of selected date for `MonthCalendar` control. +- Improved `MonthCalendar` control support for screen readers and other accessibility tools. At this moment, users can navigate the control elements and interact with these elements using keyboard-only input. With Narrator, use CAPS + arrow keys to navigation through the control elements and CAPS + Enter to invoke element default action. +- Improved arrow key navigation across `MonthCalendar` child elements with a focusing rectangle: blue focus rectangle for Narrator. +- Improved accessibility for hit test action for `MonthCalendar` control elements to allow getting `MonthCalendar` child accessible element by provided coordinates. + +## ToolTips accessibility (available in .NET Core 3.1) + +- Added ability to announce a tooltip text by screen reader applications such as NVDA and Narrator. Screen reader application can now announce the text of keyboard or mouse tooltip of any Windows Forms control that configured to show tooltips. + +## UI automation support for DataGridView, PropertyGrid, ListBox, ComboBox, ToolStrip, and other controls + +UI Automation support is enabled for controls at runtime but isn't used during design time. For an overview of UI automation, see the [UI Automation Overview](https://docs.microsoft.com/dotnet/framework/ui-automation/ui-automation-overview). + +## See also + +- [Accessibility Best Practices](../ui-automation/accessibility-best-practices.md). From 30a14725f98f2cc37f5cdb88682614db432de608 Mon Sep 17 00:00:00 2001 From: Andy De George <2672110+Thraka@users.noreply.github.com> Date: Mon, 20 Apr 2020 13:26:23 -0700 Subject: [PATCH 11/11] Add new article to TOC --- docs/framework/winforms/toc.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/framework/winforms/toc.yml b/docs/framework/winforms/toc.yml index 3b9ecbffdea5e..bfd39e7e0eb2d 100644 --- a/docs/framework/winforms/toc.yml +++ b/docs/framework/winforms/toc.yml @@ -35,8 +35,6 @@ items: - name: "How to: Respond to Font Scheme Changes in a Windows Forms Application" href: how-to-respond-to-font-scheme-changes-in-a-windows-forms-application.md - - name: Disable DPI Awareness in Visual Studio - href: disable-dpi-awareness-visual-studio.md - name: High DPI Support In Windows Forms href: high-dpi-support-in-windows-forms.md - name: Changing the Appearance of Windows Forms @@ -132,6 +130,8 @@ href: additional-security-considerations-in-windows-forms.md - name: ClickOnce Deployment for Windows Forms href: clickonce-deployment-for-windows-forms.md + - name: Accessibility improvements with .NET Core 3.0 + href: windows-forms-accessibility-improvements.md - name: "How to: Access Keyed Collections in Windows Forms" href: how-to-access-keyed-collections-in-windows-forms.md - name: Enhancing Windows Forms Applications