Skip to content

Report descriptions for .NET Framework WinForms ToolStrip menu items using UIA#20486

Open
cary-rowen wants to merge 2 commits into
nvaccess:masterfrom
cary-rowen:fix-winforms-menuitem-description
Open

Report descriptions for .NET Framework WinForms ToolStrip menu items using UIA#20486
cary-rowen wants to merge 2 commits into
nvaccess:masterfrom
cary-rowen:fix-winforms-menuitem-description

Conversation

@cary-rowen

@cary-rowen cary-rowen commented Jul 11, 2026

Copy link
Copy Markdown
Contributor

Link to issue number:

No issue. This was found while investigating #19335 and is separate from #20485.

Summary of the issue:

Classic .NET Framework Windows Forms ToolStrip menu items exposed through the native UIA provider can expose AccessibleDescription only through LegacyIAccessible. UIA FullDescription and HelpText are empty, so NVDA does not report the description.

Description of user facing changes:

NVDA now reports object descriptions for affected ToolStrip menu items.

Description of developer facing changes:

No public API changes.

Description of development approach:

Extend the existing UIA menu item description handling with a LegacyIAccessible description fallback. Standard UIA descriptions remain preferred. For affected .NET Framework WinForms ToolStripMenuItem providers, the fallback is used only when the standard description is missing or equals the object name. Descriptions equal to the name remain suppressed.

The fix is implemented directly in NVDAObjects.UIA.MenuItem. Cached UIA framework and provider metadata are used to limit the fallback to the affected .NET Framework WinForms ToolStripMenuItem providers, avoiding LegacyIAccessible queries for unrelated UIA menu items.

Testing strategy:

  • Manual testing across the .NET Framework 4.5.2, 4.7.2, 4.8 and 4.8.1 samples, plus the .NET 8 sample.
  • Unit tests cover standard UIA description precedence, LegacyIAccessible fallback, duplicate-name suppression, unsupported property values, and exclusion of WPF, modern .NET and non-ToolStrip providers.

Known issues with pull request:

None known.

Code Review Checklist:

  • Documentation:
    • Change log entry
    • User Documentation
    • Developer / Technical Documentation
    • Context sensitive help for GUI changes
  • Testing:
    • Unit tests
    • System (end to end) tests
    • Manual testing
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers
    • Localization in other languages / culture than English
  • API is compatible with existing add-ons.
  • Security precautions taken.

@cary-rowen cary-rowen force-pushed the fix-winforms-menuitem-description branch from 39417af to d864a96 Compare July 11, 2026 21:36
@cary-rowen cary-rowen marked this pull request as ready for review July 11, 2026 23:07
@cary-rowen cary-rowen requested a review from a team as a code owner July 11, 2026 23:07
@cary-rowen cary-rowen requested a review from SaschaCowley July 11, 2026 23:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant