[webkit-changes] [WebKit/WebKit] 5817fa: Bake offsets into shape-outside Shapes
Antti Koivisto
noreply at github.com
Tue Mar 7 09:49:25 PST 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 5817fa68b77f91160a62299c9c54fc7a01e4b761
https://github.com/WebKit/WebKit/commit/5817fa68b77f91160a62299c9c54fc7a01e4b761
Author: Antti Koivisto <antti at apple.com>
Date: 2023-03-07 (Tue, 07 Mar 2023)
Changed paths:
M Source/WebCore/rendering/shapes/Shape.cpp
M Source/WebCore/rendering/shapes/Shape.h
M Source/WebCore/rendering/shapes/ShapeOutsideInfo.cpp
M Source/WebCore/rendering/shapes/ShapeOutsideInfo.h
M Source/WebCore/rendering/style/ShapeValue.cpp
M Source/WebCore/rendering/style/ShapeValue.h
Log Message:
-----------
Bake offsets into shape-outside Shapes
https://bugs.webkit.org/show_bug.cgi?id=253499
rdar://106353011
Reviewed by Alan Baradlay.
Currently Shapes are varyingly relative to the margin/border/padding/content box.
The code that uses the shapes needs to recover this box and compute the real offset.
We can simplify the code by always making shapes relative to the same reference box (border box for now).
* Source/WebCore/rendering/shapes/Shape.cpp:
(WebCore::Shape::createShape):
(WebCore::Shape::createBoxShape):
* Source/WebCore/rendering/shapes/Shape.h:
* Source/WebCore/rendering/shapes/ShapeOutsideInfo.cpp:
(WebCore::ShapeOutsideInfo::computedShapePhysicalBoundingBox const):
(WebCore::ShapeOutsideInfo::shapeToRendererPoint const):
(WebCore::computeLogicalBoxSize):
(WebCore::makeShapeForShapeOutside):
(WebCore::logicalTopOffset):
(WebCore::logicalLeftOffset):
(WebCore::ShapeOutsideInfo::computeDeltasForContainingBlockLine):
(WebCore::ShapeOutsideInfo::shapeToRendererSize const): Deleted.
(WebCore::referenceBox): Deleted.
(WebCore::ShapeOutsideInfo::logicalTopOffset const): Deleted.
(WebCore::ShapeOutsideInfo::logicalLeftOffset const): Deleted.
* Source/WebCore/rendering/shapes/ShapeOutsideInfo.h:
* Source/WebCore/rendering/style/ShapeValue.cpp:
(WebCore::ShapeValue::effectiveCSSBox const):
* Source/WebCore/rendering/style/ShapeValue.h:
Canonical link: https://commits.webkit.org/261331@main
More information about the webkit-changes
mailing list