Skip to content

PowerPoint: read the text of SmartArt graphics - #21014

Closed
ChristosBouronikos wants to merge 1 commit into
nvaccess:masterfrom
ChristosBouronikos:powerpointSmartArtText
Closed

ChristosBouronikos wants to merge 1 commit into
nvaccess:masterfrom
ChristosBouronikos:powerpointSmartArtText

Conversation

@ChristosBouronikos

@ChristosBouronikos ChristosBouronikos commented Oct 16, 2026 •

Copy link
Copy Markdown

Link to issue number:

Fixes #10770

Summary of the issue:

The text of a SmartArt graphic (for example the bubbles of a flow chart) is not available as the text frame of the shape: a SmartArt shape has no text frame, and its text is held by its nodes. NVDA only reads the text of shapes which have a text frame, or an alternative text. A SmartArt graphic without an alternative text was therefore skipped when reading a slide in a slide show, and had no value when moving to it with Tab in the editor.

Description of user facing changes:

NVDA reads the text of SmartArt graphics:

  • In a slide show, as part of the slide.
  • In the editor, as the value of the shape when moving to it with Tab.

Description of developer facing changes:

None. A module level helper, iterSmartArtNodeTexts, is added to appModules.powerpnt.

Description of development approach:

iterSmartArtNodeTexts goes through shape.smartArt.allNodes in the order of the PowerPoint object model, and yields the text of the nodes which have some, with paragraph marks and soft line breaks turned into new lines. It is used by SlideShowWindow._getShapeText and Shape._get_value.

Testing strategy:

  • Added tests/unit/test_appModules/test_powerpnt_smartArt.py. The tests cover node order, skipping empty nodes, line break normalization, reading in a slide show, the value in the editor, and a graphic without nodes. Without the change, they fail.
  • The new tests and the lint checks (ruff, add-trailing-comma) pass locally using stand-ins for the Windows modules. The complete unit test suite also passes on Windows (Python 3.13, x64), run on a build of this branch in a private repository.
  • Manual testing in Microsoft PowerPoint is still outstanding. This PR is a draft until it has been done: a slide with a SmartArt flow chart, in a slide show and in the editor.

Known issues with pull request:

  • The nodes are read in the order of the object model, which is not necessarily the order of the flow of a diagram with several branches.
  • Only the text is read. The relation between nodes (levels, connections) is not reported.
  • Other pull requests changing Shape._get_value may need to be rebased on this one.

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.

A SmartArt graphic has no text frame, so its node text was neither read in slide shows nor available as the shape value in the editor. Read the text of its nodes.
@seanbudd seanbudd closed this Oct 16, 2026
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.

NVDA does not narrate text in PowerPoint SmartArt Flow Chart

2 participants