Putting the focus ring around paragraphs instead of nodes works poorly in Drive, because the whole document is being chosen as the paragraph's parent.
In addition, per-word highlighting isn't working.
Looks like per-word highlighting is broken because the text is being marked as "offscreen", and as a result the meta-genericContainer of the text is what's being spoken.
The text is offscreen because two of its ancestors have a size of (0, 0).
One of the ancestors may be kiz-zoomdocumentplugin-inner, which has size 0x0. The other is a div inside of that, also 0x0. But neither is overflow:hidden, so this may be a bug in calculating 'offscreen'.
Minimal example: the text here is being marked as offscreen but it should not be.
<div style="position:absolute; width: 0; height: 0; overflow: visible">
<span>Text</span>
</div>
This should also mark the inner div offscreen:
<div style="border: 1px solid #f00; width: 600px; height: 400px; overflow: hidden;">
Outer Div
<div style="border: 1px solid #00f; position: relative; top: 500px;">
Inner Div
</div>
</div>
It seems like position:absolute changes the container, but without information about whether the div should clip its children or not, we may do the calculation incorrectly.
A solution is to pass a flag clipsChildren that is set to true by default on rootWebArea, window, maybe dialog and a few more, set to false on most views, set to true with overflow:hidden or overflow: scroll. Then use this flag to determine if clipping even needs to be calculated in ax_tree::RelativeToTreeBounds.
Comment 1 by katie@chromium.org
, Nov 16 2017