Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 13f7dd108d915648fbc9e624de579973fdcb1e5b
      
https://github.com/WebKit/WebKit/commit/13f7dd108d915648fbc9e624de579973fdcb1e5b
  Author: Alan Baradlay <[email protected]>
  Date:   2025-09-22 (Mon, 22 Sep 2025)

  Changed paths:
    M Source/WebCore/layout/formattingContexts/inline/InlineContentBreaker.cpp
    M Source/WebCore/layout/formattingContexts/inline/InlineContentBreaker.h
    M Source/WebCore/layout/formattingContexts/inline/InlineLineBuilder.cpp
    M Source/WebCore/layout/formattingContexts/inline/InlineLineBuilder.h

  Log Message:
  -----------
  [text shaping] Shaped content may break at arbitrary position causing 
incorrect resolved width
https://bugs.webkit.org/show_bug.cgi?id=299226

Reviewed by Antti Koivisto.

Let's reshape line candidate content when we need to break it up at arbitrary 
position.

1. Find shaping boundary end after trailing run (if there's one)
2. Walk back from trailing run to find boundary start.
3. Reshape from start until the last text content (trailing run may be inline 
box)
(in some cases the trailing content is the shaping start in which case we don't 
have to shape it anymore -at least not in the sense of across boxes)

* Source/WebCore/layout/formattingContexts/inline/InlineContentBreaker.cpp:
(WebCore::Layout::InlineContentBreaker::ContinuousContent::reset):
* Source/WebCore/layout/formattingContexts/inline/InlineContentBreaker.h:
(WebCore::Layout::InlineContentBreaker::ContinuousContent::setHasShapedContent):
(WebCore::Layout::InlineContentBreaker::ContinuousContent::hasShapedContent 
const):
* Source/WebCore/layout/formattingContexts/inline/InlineLineBuilder.cpp:
(WebCore::Layout::LineBuilder::collectShapeRanges const):
(WebCore::Layout::LineBuilder::applyShapingOnRunRange const):
(WebCore::Layout::LineBuilder::applyShapingIfNeeded):
(WebCore::Layout::LineBuilder::shapePartialLineCandidate const):
(WebCore::Layout::LineBuilder::handleInlineContent):
(WebCore::Layout::LineBuilder::commitCandidateContent):
(WebCore::Layout::LineBuilder::processLineBreakingResult):
(WebCore::Layout::LineBuilder::collectShapingRanges const): Deleted.
* Source/WebCore/layout/formattingContexts/inline/InlineLineBuilder.h:

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to