Skip to content

Treat tables with 1 col or 1 row as layout tables in Outlook message viewer#12857

Merged
michaelDCurran merged 9 commits into
masterfrom
i11430
Sep 17, 2021
Merged

Treat tables with 1 col or 1 row as layout tables in Outlook message viewer#12857
michaelDCurran merged 9 commits into
masterfrom
i11430

Conversation

@michaelDCurran

Copy link
Copy Markdown
Member

Link to issue number:

Fixes #11430
Replaces #12820

Summary of the issue:

Microsoft Outlook uses a Microsoft word document control to present emails when both reading and composing. NVDA is in the process of switching to using UI Automation to access Microsoft Word document controls due to major performance advantages, and also due to Microsoft no longer maintaining the Office object model.
However, in the UI automation implementation exposed by MS Word document controls, it is impossible to identify the difference between a data table and a layout table. Thus, NVDa reports all layout tables when reading, which is extremely annoying, as the majority of HTML emails use many nested layout tables.

Description of how this pull request fixes the issue:

Tables are now classed as layout tables in MS Word document controls if the app is Outlook, and the table is read-only (Outlook is in message reading view) and the table only has either 1 column or 1 row.

Testing strategy:

With use UIA in MS Word controls enabled in NVDA's advanced settings:
• Create a table in Microsoft Word and ensure that NVDA still reports it (number of rows / columns, cell's row and column number etc).
• Create a table in Microsoft Outlook composition view and ensure that NVDA still reports it (number of rows / columns, cell's row and column number etc).
• Open an HTML email in Outlook that has layout tables, and ensure that the table is not reported when moving into and through the table's content with the arrow keys.

Known issues with pull request:

Treating tables with 1 column or 1 row as layout tables catches a good majority of layout tables. However, there will still be a few that will not be (they might have 2 columns say). However, the choice to suppress all tables in #12820 was not popular.

Change log entries:

Bug fixes

Code Review Checklist:

  • Pull Request description is up to date.
  • Unit tests.
  • System (end to end) tests.
  • Manual testing.
  • API is compatible with existing addons.
  • User Documentation.
  • Change log entry.
  • Context sensitive help for GUI changes.
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers

@michaelDCurran michaelDCurran requested a review from a team as a code owner September 16, 2021 22:26
@michaelDCurran

Copy link
Copy Markdown
Member Author

@LeonarddeR Your testing of this pr would be most welcome.

@codeofdusk

Copy link
Copy Markdown
Contributor

certain tables

Why not say "tables containing only one row or column"?

@LeonarddeR LeonarddeR left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works great for me. Data tables are properly read whereas most layout tables I've seen are properly silenced. I think I've seen one table that was incorrectly treated as data table compared to at least 50 where all was ok.

Comment thread user_docs/en/changes.t2t Outdated
- NVDA no longer treats the value of UIA sliders as always percentage based.
- Reporting the location of a cell in Microsoft Excel when accessed via UI Automation again works correctly on Windows 11. (#12782)
- NVDA no longer sets invalid Python locales. (#12753)
- When reading emails in Outlook via UI Automation, reporting of tables is now suppressed by default. (#11430)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this one should go away in favour of the latter.

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.

Suppress layout tables when reading messages in Outlook with UIA for Word enabled

5 participants