New issue
Advanced search Search tips

Issue 866337 link

Starred by 1 user

Issue metadata

Status: Available
Owner: ----
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 2
Type: Bug
Team-Accessibility



Sign in to add a comment

[Orca] Accessible text interface not implemented for static text elements; exposed through name instead

Project Member Reported by joanmari...@gmail.com, Jul 23

Issue description

UserAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3500.0 Safari/537.36

Steps to reproduce the problem:
1. Launch Chrome/Chromium
  * export ACCESSIBILITY_ENABLED=1, and
  * launch with --force-renderer-accessibility

2. Launch the attached accessible-event listener in a terminal

3. Load/reload "data:text/html,<p>foo</p>" in browser

What is the expected behavior?
The accessibility tree printed out by the listener would include the paragraph contents.

What went wrong?
The accessibility tree printed out by the listener lacks the contents because Chrome/Chromium does not implement AtkText.

Did this work before? N/A 

Chrome version: 70.0.3500.0  Channel: n/a
OS Version: 
Flash Version: 

Compare to: Firefox (with accessibility enabled), Epiphany

Comments: Instead of implementing the accessible text interface, Chrome/Chromium is exposing the content by giving the paragraph a child with ROLE_TEXT and putting the content into the accessible name of this object. Accessible names are meant to be small, label-like strings; not (potentially) an entire paragraph's worth of text. While the test case above is small, replacing "foo" with a large amount of text will result in that large amount of text being made the accessible name.

To be consistent with what Gecko and WebKitGtk do, the content should be exposed through the paragraph and not a child object. If maintaining the aforementioned child object is desired, that child object should instead be given ATK_ROLE_STATIC and should implement the accessible text interface for the reasons described under "Impact" below.

Documentation: https://developer.gnome.org/atk/stable/AtkText.html, https://developer.gnome.org/atk/stable/AtkObject.html#AtkRole (see ATK_ROLE_TEXT).

Impact: Orca provides navigation by character, word, and line in response to the user pressing arrow keys. In order to provide this access, Orca needs to be able to get a specified unit of text (character, word, or line) for a particular offset within the text. Because Chrome/Chromium doesn't implement the accessible text interface, this is not possible.

 
simple-tree.py
873 bytes View Download
Labels: Needs-Triage-M70
Components: -UI UI>Accessibility
Project Member

Comment 4 by bugdroid1@chromium.org, Aug 22

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ba40c8a2713097169e750be30fbe3f17159bd0d6

commit ba40c8a2713097169e750be30fbe3f17159bd0d6
Author: Martin Robinson <mrobinson@igalia.com>
Date: Wed Aug 22 12:43:31 2018

Expose the basic AtkText interface for text elements

AtkText is the proper way to expose static text to accessibility agents.
This change adds initial support for the interface, but there is quite a
bit of work left to properly expose hypertext as well as implement the
rest of the required interface functionality.

Bug: 866337
Change-Id: Iab121b1b18bc00bcbdd35bfa310e7a1a2b141e18
Reviewed-on: https://chromium-review.googlesource.com/1179752
Commit-Queue: Martin Robinson <mrobinson@igalia.com>
Reviewed-by: Dominic Mazzoni <dmazzoni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#584989}
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/content/browser/accessibility/browser_accessibility_com_win.cc
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/content/browser/accessibility/browser_accessibility_win.cc
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/ui/accessibility/platform/ax_platform_node_auralinux.cc
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/ui/accessibility/platform/ax_platform_node_auralinux.h
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/ui/accessibility/platform/ax_platform_node_auralinux_unittest.cc
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/ui/accessibility/platform/ax_platform_node_base.cc
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/ui/accessibility/platform/ax_platform_node_base.h
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/ui/accessibility/platform/ax_platform_node_mac.mm
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/ui/accessibility/platform/ax_platform_node_win.cc
[modify] https://crrev.com/ba40c8a2713097169e750be30fbe3f17159bd0d6/ui/accessibility/platform/ax_platform_node_win.h

Project Member

Comment 5 by bugdroid1@chromium.org, Aug 22

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a2da3968305d8cda5294e528139504cb12c49b97

commit a2da3968305d8cda5294e528139504cb12c49b97
Author: Guido Urdaneta <guidou@chromium.org>
Date: Wed Aug 22 14:33:52 2018

Revert "Expose the basic AtkText interface for text elements"

This reverts commit ba40c8a2713097169e750be30fbe3f17159bd0d6.

Reason for revert: Causing failure on Linux Tests (dbg) bot.

See https://ci.chromium.org/p/chromium/builders/luci.chromium.ci/Linux%20Tests%20%28dbg%29%281%29%2832%29/52253

Sample logs:
[ RUN      ] AXPlatformNodeAuraLinuxTest.TestAtkText
../../ui/accessibility/platform/ax_platform_node_auralinux_unittest.cc:871: Failure
Value of: ATK_IS_TEXT(root_atk_object)
  Actual: false
Expected: true
Stack trace:
#0 0x000008299a59 StackTraceGetter::CurrentStackTrace()
#1 0x0000082be414 testing::internal::UnitTestImpl::CurrentOsStackTraceExceptTop()
#2 0x0000082bd86e testing::internal::AssertHelper::operator=()
#3 0x00000821fe0c ui::AXPlatformNodeAuraLinuxTest_TestAtkText_Test::TestBody()
#4 0x0000082f91eb testing::internal::HandleSehExceptionsInMethodIfSupported<>()
[  FAILED  ] AXPlatformNodeAuraLinuxTest.TestAtkText (2 ms)


Original change's description:
> Expose the basic AtkText interface for text elements
> 
> AtkText is the proper way to expose static text to accessibility agents.
> This change adds initial support for the interface, but there is quite a
> bit of work left to properly expose hypertext as well as implement the
> rest of the required interface functionality.
> 
> Bug: 866337
> Change-Id: Iab121b1b18bc00bcbdd35bfa310e7a1a2b141e18
> Reviewed-on: https://chromium-review.googlesource.com/1179752
> Commit-Queue: Martin Robinson <mrobinson@igalia.com>
> Reviewed-by: Dominic Mazzoni <dmazzoni@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#584989}

TBR=dmazzoni@chromium.org,mrobinson@igalia.com

Change-Id: Idb25bb0c8bd494b10f6eed2fd213552178a5f62b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 866337
Reviewed-on: https://chromium-review.googlesource.com/1184924
Reviewed-by: Guido Urdaneta <guidou@chromium.org>
Commit-Queue: Guido Urdaneta <guidou@chromium.org>
Cr-Commit-Position: refs/heads/master@{#585013}
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/content/browser/accessibility/browser_accessibility_com_win.cc
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/content/browser/accessibility/browser_accessibility_win.cc
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/ui/accessibility/platform/ax_platform_node_auralinux.cc
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/ui/accessibility/platform/ax_platform_node_auralinux.h
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/ui/accessibility/platform/ax_platform_node_auralinux_unittest.cc
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/ui/accessibility/platform/ax_platform_node_base.cc
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/ui/accessibility/platform/ax_platform_node_base.h
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/ui/accessibility/platform/ax_platform_node_mac.mm
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/ui/accessibility/platform/ax_platform_node_win.cc
[modify] https://crrev.com/a2da3968305d8cda5294e528139504cb12c49b97/ui/accessibility/platform/ax_platform_node_win.h

Project Member

Comment 7 by bugdroid1@chromium.org, Aug 23

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/81230539ed20a47bcca1af6678d8dca09da7db1b

commit 81230539ed20a47bcca1af6678d8dca09da7db1b
Author: Martin Robinson <mrobinson@igalia.com>
Date: Thu Aug 23 09:35:23 2018

Re-land: Expose the basic AtkText interface for text elements

Originally landed: crrev.com/c/1179752
Reverted: crrev.com/c/1184924

AtkText is the proper way to expose static text to accessibility agents.
This change adds initial support for the interface, but there is quite a
bit of work left to properly expose hypertext as well as implement the
rest of the required interface functionality.

Bug: 866337
Change-Id: I8fa54ac382d82168f3b32a4430dcce5223ea4a76
Reviewed-on: https://chromium-review.googlesource.com/1185190
Commit-Queue: Martin Robinson <mrobinson@igalia.com>
Reviewed-by: Dominic Mazzoni <dmazzoni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#585435}
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/content/browser/accessibility/browser_accessibility_com_win.cc
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/content/browser/accessibility/browser_accessibility_win.cc
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/ui/accessibility/platform/ax_platform_node_auralinux.cc
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/ui/accessibility/platform/ax_platform_node_auralinux.h
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/ui/accessibility/platform/ax_platform_node_auralinux_unittest.cc
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/ui/accessibility/platform/ax_platform_node_base.cc
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/ui/accessibility/platform/ax_platform_node_base.h
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/ui/accessibility/platform/ax_platform_node_mac.mm
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/ui/accessibility/platform/ax_platform_node_win.cc
[modify] https://crrev.com/81230539ed20a47bcca1af6678d8dca09da7db1b/ui/accessibility/platform/ax_platform_node_win.h

Project Member

Comment 8 by bugdroid1@chromium.org, Aug 28

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/319f3b006f2a920ae84469b30552bfcccf1728eb

commit 319f3b006f2a920ae84469b30552bfcccf1728eb
Author: Martin Robinson <mrobinson@igalia.com>
Date: Tue Aug 28 17:34:47 2018

Expose AtkText on more elements

This change exposes the AtkText interface on all accessibility elements
and uses the, now shared, ComputeHypertext in order to compute composite
text for elements that have multiple children. Once we start exposing
the hypertext interface, we can start testing the embedding of objects
into the hypertext itself. The plan is also to eventually expose the
interface on objects that need it.

Unfortunately, since hypertext computation is now triggered by the
content code, we must move the existing AtkText unit test to content as
well alongside the new one.

Bug: 866337
Change-Id: I8cc738dd0e14cf95ecdffa2370d242fb447aa9b6
Reviewed-on: https://chromium-review.googlesource.com/1190782
Commit-Queue: Martin Robinson <mrobinson@igalia.com>
Reviewed-by: Dominic Mazzoni <dmazzoni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#586772}
[modify] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/content/browser/accessibility/browser_accessibility_auralinux.cc
[modify] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/content/browser/accessibility/browser_accessibility_auralinux.h
[add] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/content/browser/accessibility/browser_accessibility_auralinux_unittest.cc
[modify] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/content/browser/accessibility/browser_accessibility_manager_auralinux.cc
[modify] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/content/browser/accessibility/browser_accessibility_manager_auralinux.h
[modify] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/content/test/BUILD.gn
[modify] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/ui/accessibility/platform/ax_platform_node_auralinux.cc
[modify] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/ui/accessibility/platform/ax_platform_node_auralinux.h
[modify] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/ui/accessibility/platform/ax_platform_node_auralinux_unittest.cc
[modify] https://crrev.com/319f3b006f2a920ae84469b30552bfcccf1728eb/ui/accessibility/platform/ax_platform_node_base.h

Project Member

Comment 9 by bugdroid1@chromium.org, Sep 18

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/d8b9f643a827c30587ad46846a14ea5b9d3b230e

commit d8b9f643a827c30587ad46846a14ea5b9d3b230e
Author: Martin Robinson <mrobinson@igalia.com>
Date: Tue Sep 18 17:34:16 2018

Implement the AtkHypertext interface for Aura Linux

This allows accessibility clients to have access to the links available
in the text provided by the AtkText interface. Implementing this
interface also allows us to write a fully-fleshed out text for the
contents provided by the AtkText interface.

Bug: 866337
Change-Id: I38e200512a835014922b51df677203e853d6ef4b
Reviewed-on: https://chromium-review.googlesource.com/1227942
Commit-Queue: Martin Robinson <mrobinson@igalia.com>
Reviewed-by: Dominic Mazzoni <dmazzoni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592096}
[modify] https://crrev.com/d8b9f643a827c30587ad46846a14ea5b9d3b230e/content/browser/accessibility/browser_accessibility_auralinux_unittest.cc
[modify] https://crrev.com/d8b9f643a827c30587ad46846a14ea5b9d3b230e/ui/accessibility/platform/ax_platform_node_auralinux.cc
[modify] https://crrev.com/d8b9f643a827c30587ad46846a14ea5b9d3b230e/ui/accessibility/platform/ax_platform_node_auralinux.h

Project Member

Comment 10 by bugdroid1@chromium.org, Sep 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/90815d42b45e4dc346f85df41a55cbe2ff0b9b8a

commit 90815d42b45e4dc346f85df41a55cbe2ff0b9b8a
Author: Martin Robinson <mrobinson@igalia.com>
Date: Fri Sep 21 08:49:07 2018

Add character accessors for AtkText interface

Bug: 866337
Change-Id: I581dbbc08382b668ac503ee2ccdb5c7acf1c2995
Reviewed-on: https://chromium-review.googlesource.com/1233733
Commit-Queue: Martin Robinson <mrobinson@igalia.com>
Reviewed-by: Dominic Mazzoni <dmazzoni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#593124}
[modify] https://crrev.com/90815d42b45e4dc346f85df41a55cbe2ff0b9b8a/ui/accessibility/platform/ax_platform_node_auralinux.cc
[modify] https://crrev.com/90815d42b45e4dc346f85df41a55cbe2ff0b9b8a/ui/accessibility/platform/ax_platform_node_auralinux_unittest.cc

Components: UI>Accessibility>Compatibility
Status: Available (was: Unconfirmed)
Project Member

Comment 12 by bugdroid1@chromium.org, Sep 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/862b6d0d12c51a9c7a99b8b0414e2ec0ddf72376

commit 862b6d0d12c51a9c7a99b8b0414e2ec0ddf72376
Author: Martin Robinson <mrobinson@igalia.com>
Date: Fri Sep 21 23:31:36 2018

Properly give AtkHyperlink offsets for links from AtkHypertext

This currently requires an o(n) walk through the list of hyperlinks, but
a future rework of AXHypertext can fix this issue. Since this change
requires adding a C++ class member to AXAtkHyperlink, we give it a private
section and initialize it with placement new. This also requires us to
call the destructor manually during GObject finalization.

Bug: 866337
Change-Id: Ib0902268ff8a9da3750649dc7f4de8782d5fd893
Reviewed-on: https://chromium-review.googlesource.com/1238500
Reviewed-by: Dominic Mazzoni <dmazzoni@chromium.org>
Commit-Queue: Dominic Mazzoni <dmazzoni@chromium.org>
Cr-Commit-Position: refs/heads/master@{#593377}
[modify] https://crrev.com/862b6d0d12c51a9c7a99b8b0414e2ec0ddf72376/content/browser/accessibility/browser_accessibility_auralinux_unittest.cc
[modify] https://crrev.com/862b6d0d12c51a9c7a99b8b0414e2ec0ddf72376/ui/accessibility/platform/ax_platform_atk_hyperlink.cc
[modify] https://crrev.com/862b6d0d12c51a9c7a99b8b0414e2ec0ddf72376/ui/accessibility/platform/ax_platform_atk_hyperlink.h
[modify] https://crrev.com/862b6d0d12c51a9c7a99b8b0414e2ec0ddf72376/ui/accessibility/platform/ax_platform_node_auralinux.cc

Sign in to add a comment