Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: bec322fbf04b922058bee860ab3d725c51956e60
      
https://github.com/WebKit/WebKit/commit/bec322fbf04b922058bee860ab3d725c51956e60
  Author: Alan Baradlay <[email protected]>
  Date:   2023-02-27 (Mon, 27 Feb 2023)

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

  Log Message:
  -----------
  [IFC] Floats never overflow though they may over-constrain the line
https://bugs.webkit.org/show_bug.cgi?id=253005

Reviewed by Antti Koivisto.

1. Floats shrink the available horizontal space for the inline content
2. When they shrink the line too much so that the (placed) inline content does 
not fit anymore (line is over-constrained)
   we need to suspend float layout at this vertical position. However inline 
layout can continue as long as there's still available space left.
3. Such "suspended" floats are placed when we get to the next available 
vertical position (next line in this case).

(Rename and move things around)

* Source/WebCore/layout/formattingContexts/inline/InlineFormattingContext.cpp:
(WebCore::Layout::InlineFormattingContext::lineLayout):
(WebCore::Layout::InlineFormattingContext::resetGeometryForClampedContent):
* Source/WebCore/layout/formattingContexts/inline/InlineFormattingContext.h:
* Source/WebCore/layout/formattingContexts/inline/InlineLineBuilder.cpp:
(WebCore::Layout::LineBuilder::layoutInlineContent):
(WebCore::Layout::LineBuilder::initialize):
(WebCore::Layout::LineBuilder::placeInlineContent):
(WebCore::Layout::LineBuilder::shouldTryToPlaceFloatBox const):
(WebCore::Layout::LineBuilder::tryPlacingFloatBox):
(WebCore::Layout::LineBuilder::isLastLineWithInlineContent const):
* Source/WebCore/layout/formattingContexts/inline/InlineLineBuilder.h:
(WebCore::Layout::LineBuilder::isFloatLayoutSuspended const):
* Source/WebCore/layout/formattingContexts/inline/InlineLineTypes.h:

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


_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to