[webkit-changes] [WebKit/WebKit] 9f3eab: [IFC][Ruby] Some characters are overlapped (Hiraga...

Alan Baradlay noreply at github.com
Fri Feb 9 10:36:56 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 9f3eab39f42a08b031da006e4bbdc2f8a01d5ead
      https://github.com/WebKit/WebKit/commit/9f3eab39f42a08b031da006e4bbdc2f8a01d5ead
  Author: Alan Baradlay <zalan at apple.com>
  Date:   2024-02-09 (Fri, 09 Feb 2024)

  Changed paths:
    A LayoutTests/fast/ruby/ruby-overhang-with-justified-content-overlap-expected.html
    A LayoutTests/fast/ruby/ruby-overhang-with-justified-content-overlap.html
    M Source/WebCore/layout/formattingContexts/inline/display/InlineDisplayContentBuilder.cpp

  Log Message:
  -----------
  [IFC][Ruby] Some characters are overlapped (Hiragana + Kanji character with Ruby)
https://bugs.webkit.org/show_bug.cgi?id=269064
<rdar://122501121>

Reviewed by Antti Koivisto.

1. When annotation is wide than the base content, we slightly pull adjacent content under the annotation on both sides
2. Pulling the "after" content (boxes to the right of the ruby) means shifting all the runs as one monolithic content.

However in case of justified alignment, as we are supposed to keep the spacing intact, we only adjust the adjacent run
by moving and expanding it (expanding ensure the rest of the "after" content stays stationary).

* LayoutTests/fast/ruby/ruby-overhang-with-justified-content-overlap-expected.html: Added.
* LayoutTests/fast/ruby/ruby-overhang-with-justified-content-overlap.html: Added.
* Source/WebCore/layout/formattingContexts/inline/display/InlineDisplayContentBuilder.cpp:
(WebCore::Layout::InlineDisplayContentBuilder::applyRubyOverhang):

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




More information about the webkit-changes mailing list