Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 03151c3c082658b798db77fd097db1c481a5f3bb
      
https://github.com/WebKit/WebKit/commit/03151c3c082658b798db77fd097db1c481a5f3bb
  Author: Tyler Wilcock <[email protected]>
  Date:   2026-03-20 (Fri, 20 Mar 2026)

  Changed paths:
    A LayoutTests/accessibility/table-row-bounding-boxes-expected.txt
    A LayoutTests/accessibility/table-row-bounding-boxes.html
    M LayoutTests/platform/glib/TestExpectations
    M Source/WebCore/rendering/RenderTableRow.cpp
    M Source/WebCore/rendering/RenderTableSection.cpp

  Log Message:
  -----------
  AX: WebKit computes an incorrect bounding box for math table row and cells
https://bugs.webkit.org/show_bug.cgi?id=310200
rdar://172851295

Reviewed by Joshua Hoffman.

RenderTableRow and RenderTableSection never reported their bounds to
the accessibility geometry cache during the PaintPhase::Accessibility
paint phase. This meant the AXGeometryManager never cached rects for
these elements.

In the isolated tree, when no paint-cached rect exists, the fallback
path uses InitialLocalRect for size but overwrites the position with
the nearest painted ancestor's position. For table rows, that ancestor
is the <table> itself, so every row gets the table's top-left corner
as its position. This is observable with VoiceOver: the cursor appears
on the first row regardless of which row is focused.

The fix adds takeBounds calls for RenderTableSection (and its child
rows) and RenderTableRow during the accessibility paint phase, matching
what RenderBlock and RenderTable already do. RenderTableCell was not
affected because it inherits from RenderBlockFlow which already calls
takeBounds.

* LayoutTests/accessibility/table-row-bounding-boxes-expected.txt: Added.
* LayoutTests/accessibility/table-row-bounding-boxes.html: Added.
* Source/WebCore/rendering/RenderTableRow.cpp:
(WebCore::RenderTableRow::paint):
* Source/WebCore/rendering/RenderTableSection.cpp:
(WebCore::RenderTableSection::paintObject):

Canonical link: https://commits.webkit.org/309640@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to