Skip to content

PowerPoint: report table header rows and columns - #21017

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

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

Conversation

@ChristosBouronikos

@ChristosBouronikos ChristosBouronikos commented Oct 16, 2026 •

Copy link
Copy Markdown

Link to issue number:

Fixes #19063

Summary of the issue:

In a PowerPoint table, the options "Header Row" and "First Column" of the table design tab define which cells are headers. NVDA gave every cell the role of an ordinary table cell, so headers were not recognized, and the text of the headers was not reported when moving between the other cells of the table.

Description of user facing changes:

In tables in the PowerPoint editor:

  • Cells in the header row are reported as column headers, and cells in the first column as row headers, when the corresponding table style options are on.
  • When moving to another cell, NVDA reports the text of the row header and column header, according to the "Headers" option in the "Tables" group of Document Formatting settings.

Description of developer facing changes:

None.

Description of development approach:

TableCell computed its role as a constant. It now has:

  • role: column header for the first row if Table.FirstRow is set, otherwise row header for the first column if Table.FirstCol is set, otherwise table cell. The first cell of a table with both options is therefore a column header.
  • rowHeaderText and columnHeaderText: the text of the first cell of the same row or column, for cells which are not themselves a header of that kind, and only when the corresponding option is set. The base NVDAObject properties are used by the existing table reporting code.

Testing strategy:

  • Added tests/unit/test_appModules/test_powerpnt_tableHeaders.py. The tests cover the roles with both options, the corner cell, both options off, header text from the first row and column, headers having no header of their own kind, and each option being independent. 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: the presentation attached to the issue, with the options on and off, moving through the table with Tab and with the arrow keys.

Known issues with pull request:

  • Tables in slide shows are read as flat text, and are not affected.
  • Merged cells have not been tested.
  • An empty header cell results in no header text being reported.

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.

Every table cell had the role of an ordinary cell. Use the Header Row and First Column table style options to give header cells their roles and to provide the header text of other cells.
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 recognize table row headers in Microsoft PowerPoint

2 participants