[CSS Shapes] Refactor getExcludedIntervals since only one LineSegment is ever returned
authorbjonesbe@adobe.com <bjonesbe@adobe.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 8 Aug 2014 21:12:06 +0000 (21:12 +0000)
committerbjonesbe@adobe.com <bjonesbe@adobe.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 8 Aug 2014 21:12:06 +0000 (21:12 +0000)
https://bugs.webkit.org/show_bug.cgi?id=135757

Reviewed by Zoltan Horvath.

The interface for getExcludedIntervals was designed when shape-inside
was still a thing, and it was possible for a line in a shape to have
multiple segments. shape-outside can only have one segment per line,
so this refactors the code to simplify and reflect that reality.

No new test, no behavior change.

* rendering/shapes/BoxShape.cpp:
(WebCore::BoxShape::getExcludedInterval):
(WebCore::BoxShape::getExcludedIntervals): Deleted.
* rendering/shapes/BoxShape.h:
* rendering/shapes/PolygonShape.cpp:
(WebCore::PolygonShape::getExcludedInterval):
(WebCore::PolygonShape::getExcludedIntervals): Deleted.
* rendering/shapes/PolygonShape.h:
* rendering/shapes/RasterShape.cpp:
(WebCore::RasterShape::getExcludedInterval):
(WebCore::RasterShape::getExcludedIntervals): Deleted.
* rendering/shapes/RasterShape.h:
* rendering/shapes/RectangleShape.cpp:
(WebCore::RectangleShape::getExcludedInterval):
(WebCore::RectangleShape::getExcludedIntervals): Deleted.
* rendering/shapes/RectangleShape.h:
* rendering/shapes/Shape.h:
(WebCore::LineSegment::LineSegment):
* rendering/shapes/ShapeOutsideInfo.cpp:
(WebCore::ShapeOutsideInfo::logicalLeftOffset):
(WebCore::ShapeOutsideInfo::updateDeltasForContainingBlockLine):
(WebCore::ShapeOutsideInfo::computeSegmentsForLine): Deleted.
* rendering/shapes/ShapeOutsideInfo.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@172357 268f45cc-cd09-0410-ab3c-d52691b4dbfc

12 files changed:
Source/WebCore/ChangeLog
Source/WebCore/rendering/shapes/BoxShape.cpp
Source/WebCore/rendering/shapes/BoxShape.h
Source/WebCore/rendering/shapes/PolygonShape.cpp
Source/WebCore/rendering/shapes/PolygonShape.h
Source/WebCore/rendering/shapes/RasterShape.cpp
Source/WebCore/rendering/shapes/RasterShape.h
Source/WebCore/rendering/shapes/RectangleShape.cpp
Source/WebCore/rendering/shapes/RectangleShape.h
Source/WebCore/rendering/shapes/Shape.h
Source/WebCore/rendering/shapes/ShapeOutsideInfo.cpp
Source/WebCore/rendering/shapes/ShapeOutsideInfo.h

index 3f9756a..f7ed65f 100644 (file)
@@ -1,3 +1,41 @@
+2014-08-08  Bem Jones-Bey  <bjonesbe@adobe.com>
+
+        [CSS Shapes] Refactor getExcludedIntervals since only one LineSegment is ever returned
+        https://bugs.webkit.org/show_bug.cgi?id=135757
+
+        Reviewed by Zoltan Horvath.
+
+        The interface for getExcludedIntervals was designed when shape-inside
+        was still a thing, and it was possible for a line in a shape to have
+        multiple segments. shape-outside can only have one segment per line,
+        so this refactors the code to simplify and reflect that reality.
+
+        No new test, no behavior change.
+
+        * rendering/shapes/BoxShape.cpp:
+        (WebCore::BoxShape::getExcludedInterval): 
+        (WebCore::BoxShape::getExcludedIntervals): Deleted.
+        * rendering/shapes/BoxShape.h:
+        * rendering/shapes/PolygonShape.cpp:
+        (WebCore::PolygonShape::getExcludedInterval):
+        (WebCore::PolygonShape::getExcludedIntervals): Deleted.
+        * rendering/shapes/PolygonShape.h:
+        * rendering/shapes/RasterShape.cpp:
+        (WebCore::RasterShape::getExcludedInterval):
+        (WebCore::RasterShape::getExcludedIntervals): Deleted.
+        * rendering/shapes/RasterShape.h:
+        * rendering/shapes/RectangleShape.cpp:
+        (WebCore::RectangleShape::getExcludedInterval):
+        (WebCore::RectangleShape::getExcludedIntervals): Deleted.
+        * rendering/shapes/RectangleShape.h:
+        * rendering/shapes/Shape.h:
+        (WebCore::LineSegment::LineSegment):
+        * rendering/shapes/ShapeOutsideInfo.cpp:
+        (WebCore::ShapeOutsideInfo::logicalLeftOffset):
+        (WebCore::ShapeOutsideInfo::updateDeltasForContainingBlockLine):
+        (WebCore::ShapeOutsideInfo::computeSegmentsForLine): Deleted.
+        * rendering/shapes/ShapeOutsideInfo.h:
+
 2014-08-08  Brian J. Burg  <burg@cs.washington.edu>
 
         Web Inspector: add debugging flag to InspectorTest for unbuffered logging to stderr
index 11aae52..389aac9 100644 (file)
@@ -12,7 +12,7 @@
  *    copyright notice, this list of conditions and the following
  *    disclaimer in the documentation and/or other materials
  *    provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
@@ -112,28 +112,24 @@ FloatRoundedRect BoxShape::shapeMarginBounds() const
     return marginBounds;
 }
 
-void BoxShape::getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHeight, SegmentList& result) const
+LineSegment BoxShape::getExcludedInterval(LayoutUnit logicalTop, LayoutUnit logicalHeight) const
 {
     const FloatRoundedRect& marginBounds = shapeMarginBounds();
     if (marginBounds.isEmpty() || !lineOverlapsShapeMarginBounds(logicalTop, logicalHeight))
-        return;
+        return LineSegment();
 
     float y1 = logicalTop;
     float y2 = logicalTop + logicalHeight;
     const FloatRect& rect = marginBounds.rect();
 
-    if (!marginBounds.isRounded()) {
-        result.append(LineSegment(rect.x(), rect.maxX()));
-        return;
-    }
+    if (!marginBounds.isRounded())
+        return LineSegment(rect.x(), rect.maxX());
 
     float topCornerMaxY = std::max<float>(marginBounds.topLeftCorner().maxY(), marginBounds.topRightCorner().maxY());
     float bottomCornerMinY = std::min<float>(marginBounds.bottomLeftCorner().y(), marginBounds.bottomRightCorner().y());
 
-    if (topCornerMaxY <= bottomCornerMinY && y1 <= topCornerMaxY && y2 >= bottomCornerMinY) {
-        result.append(LineSegment(rect.x(), rect.maxX()));
-        return;
-    }
+    if (topCornerMaxY <= bottomCornerMinY && y1 <= topCornerMaxY && y2 >= bottomCornerMinY)
+        return LineSegment(rect.x(), rect.maxX());
 
     float x1 = rect.maxX();
     float x2 = rect.x();
@@ -157,7 +153,7 @@ void BoxShape::getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHei
     }
 
     ASSERT(x2 >= x1);
-    result.append(LineSegment(x1, x2));
+    return LineSegment(x1, x2);
 }
 
 void BoxShape::buildDisplayPaths(DisplayPaths& paths) const
index 7a1021a..809ba82 100644 (file)
@@ -12,7 +12,7 @@
  *    copyright notice, this list of conditions and the following
  *    disclaimer in the documentation and/or other materials
  *    provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
@@ -49,7 +49,7 @@ public:
 
     virtual LayoutRect shapeMarginLogicalBoundingBox() const override;
     virtual bool isEmpty() const override { return m_bounds.isEmpty(); }
-    virtual void getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHeight, SegmentList&) const override;
+    virtual LineSegment getExcludedInterval(LayoutUnit logicalTop, LayoutUnit logicalHeight) const override;
 
     virtual void buildDisplayPaths(DisplayPaths&) const override;
 
index 6c7fce3..8c2b7f9 100644 (file)
@@ -12,7 +12,7 @@
  *    copyright notice, this list of conditions and the following
  *    disclaimer in the documentation and/or other materials
  *    provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
@@ -117,17 +117,17 @@ LayoutRect PolygonShape::shapeMarginLogicalBoundingBox() const
     return LayoutRect(box);
 }
 
-void PolygonShape::getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHeight, SegmentList& result) const
+LineSegment PolygonShape::getExcludedInterval(LayoutUnit logicalTop, LayoutUnit logicalHeight) const
 {
     float y1 = logicalTop;
     float y2 = logicalTop + logicalHeight;
 
     if (m_polygon.isEmpty() || !m_polygon.boundingBox().overlapsYRange(y1 - shapeMargin(), y2 + shapeMargin()))
-        return;
+        return LineSegment();
 
     Vector<const FloatPolygonEdge*> overlappingEdges;
     if (!m_polygon.overlappingEdges(y1 - shapeMargin(), y2 + shapeMargin(), overlappingEdges))
-        return;
+        return LineSegment();
 
     FloatShapeInterval excludedInterval;
     for (unsigned i = 0; i < overlappingEdges.size(); i++) {
@@ -143,8 +143,10 @@ void PolygonShape::getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logica
         }
     }
 
-    if (!excludedInterval.isEmpty())
-        result.append(LineSegment(excludedInterval.x1(), excludedInterval.x2()));
+    if (excludedInterval.isEmpty())
+        return LineSegment();
+
+    return LineSegment(excludedInterval.x1(), excludedInterval.x2());
 }
 
 void PolygonShape::buildDisplayPaths(DisplayPaths& paths) const
index 7a6aab5..44fe629 100644 (file)
@@ -12,7 +12,7 @@
  *    copyright notice, this list of conditions and the following
  *    disclaimer in the documentation and/or other materials
  *    provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
@@ -67,7 +67,7 @@ public:
 
     virtual LayoutRect shapeMarginLogicalBoundingBox() const override;
     virtual bool isEmpty() const override { return m_polygon.isEmpty(); }
-    virtual void getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHeight, SegmentList&) const override;
+    virtual LineSegment getExcludedInterval(LayoutUnit logicalTop, LayoutUnit logicalHeight) const override;
 
     virtual void buildDisplayPaths(DisplayPaths&) const override;
 
index ac0c421..d8aff98 100644 (file)
@@ -12,7 +12,7 @@
  *    copyright notice, this list of conditions and the following
  *    disclaimer in the documentation and/or other materials
  *    provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
@@ -149,17 +149,17 @@ const RasterShapeIntervals& RasterShape::marginIntervals() const
     return *m_marginIntervals;
 }
 
-void RasterShape::getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHeight, SegmentList& result) const
+LineSegment RasterShape::getExcludedInterval(LayoutUnit logicalTop, LayoutUnit logicalHeight) const
 {
     const RasterShapeIntervals& intervals = marginIntervals();
     if (intervals.isEmpty())
-        return;
+        return LineSegment();
 
     int y1 = logicalTop;
     int y2 = logicalTop + logicalHeight;
     ASSERT(y2 >= y1);
     if (y2 < intervals.bounds().y() || y1 >= intervals.bounds().maxY())
-        return;
+        return LineSegment();
 
     y1 = std::max(y1, intervals.bounds().y());
     y2 = std::min(y2, intervals.bounds().maxY());
@@ -172,7 +172,7 @@ void RasterShape::getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logical
             excludedInterval.unite(intervals.intervalAt(y));
     }
 
-    result.append(LineSegment(excludedInterval.x1(), excludedInterval.x2()));
+    return LineSegment(excludedInterval.x1(), excludedInterval.x2());
 }
 
 } // namespace WebCore
index 4cd1892..b7b0135 100644 (file)
@@ -12,7 +12,7 @@
  *    copyright notice, this list of conditions and the following
  *    disclaimer in the documentation and/or other materials
  *    provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
@@ -61,7 +61,7 @@ public:
         ASSERT(y + m_offset >= 0 && static_cast<unsigned>(y + m_offset) < m_intervals.size());
         return m_intervals[y + m_offset];
     }
-    
+
     std::unique_ptr<RasterShapeIntervals> computeShapeMarginIntervals(int shapeMargin) const;
     void buildBoundsPath(Path&) const;
 
@@ -88,7 +88,7 @@ public:
 
     virtual LayoutRect shapeMarginLogicalBoundingBox() const override { return static_cast<LayoutRect>(marginIntervals().bounds()); }
     virtual bool isEmpty() const override { return m_intervals->isEmpty(); }
-    virtual void getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHeight, SegmentList&) const override;
+    virtual LineSegment getExcludedInterval(LayoutUnit logicalTop, LayoutUnit logicalHeight) const override;
 
     virtual void buildDisplayPaths(DisplayPaths& paths) const override
     {
index 5a15d1d..f3619d6 100644 (file)
@@ -12,7 +12,7 @@
  *    copyright notice, this list of conditions and the following
  *    disclaimer in the documentation and/or other materials
  *    provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
@@ -53,17 +53,17 @@ FloatRect RectangleShape::shapeMarginBounds() const
     return FloatRect(boundsX, boundsY, boundsWidth, boundsHeight);
 }
 
-void RectangleShape::getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHeight, SegmentList& result) const
+LineSegment RectangleShape::getExcludedInterval(LayoutUnit logicalTop, LayoutUnit logicalHeight) const
 {
     const FloatRect& bounds = shapeMarginBounds();
     if (bounds.isEmpty())
-        return;
+        return LineSegment();
 
     float y1 = logicalTop;
     float y2 = logicalTop + logicalHeight;
 
     if (y2 < bounds.y() || y1 >= bounds.maxY())
-        return;
+        return LineSegment();
 
     float x1 = bounds.x();
     float x2 = bounds.maxX();
@@ -85,7 +85,7 @@ void RectangleShape::getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logi
         }
     }
 
-    result.append(LineSegment(x1, x2));
+    return LineSegment(x1, x2);
 }
 
 void RectangleShape::buildDisplayPaths(DisplayPaths& paths) const
index 301df05..f0e3f0f 100644 (file)
@@ -12,7 +12,7 @@
  *    copyright notice, this list of conditions and the following
  *    disclaimer in the documentation and/or other materials
  *    provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
@@ -49,7 +49,7 @@ public:
 
     virtual LayoutRect shapeMarginLogicalBoundingBox() const override { return static_cast<LayoutRect>(shapeMarginBounds()); }
     virtual bool isEmpty() const override { return m_bounds.isEmpty(); }
-    virtual void getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHeight, SegmentList&) const override;
+    virtual LineSegment getExcludedInterval(LayoutUnit logicalTop, LayoutUnit logicalHeight) const override;
 
     virtual void buildDisplayPaths(DisplayPaths&) const override;
 
index 1435ffc..086715f 100644 (file)
@@ -12,7 +12,7 @@
  *    copyright notice, this list of conditions and the following
  *    disclaimer in the documentation and/or other materials
  *    provided with the distribution.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
 namespace WebCore {
 
 struct LineSegment {
+    LineSegment()
+        : logicalLeft(0)
+        , logicalRight(0)
+        , isValid(false)
+    {
+    }
+
     LineSegment(float logicalLeft, float logicalRight)
         : logicalLeft(logicalLeft)
         , logicalRight(logicalRight)
+        , isValid(true)
     {
     }
 
     float logicalLeft;
     float logicalRight;
+    bool isValid;
 };
 
 class BasicShape;
 class Image;
 class RoundedRect;
 
-typedef Vector<LineSegment> SegmentList;
-
-
 // A representation of a BasicShape that enables layout code to determine how to break a line up into segments
 // that will fit within or around a shape. The line is defined by a pair of logical Y coordinates and the
 // computed segments are returned as pairs of logical X coordinates. The BasicShape itself is defined in
@@ -74,7 +80,7 @@ public:
 
     virtual LayoutRect shapeMarginLogicalBoundingBox() const = 0;
     virtual bool isEmpty() const = 0;
-    virtual void getExcludedIntervals(LayoutUnit logicalTop, LayoutUnit logicalHeight, SegmentList&) const = 0;
+    virtual LineSegment getExcludedInterval(LayoutUnit logicalTop, LayoutUnit logicalHeight) const = 0;
 
     bool lineOverlapsShapeMarginBounds(LayoutUnit lineTop, LayoutUnit lineHeight) const { return lineOverlapsBoundingBox(lineTop, lineHeight, shapeMarginLogicalBoundingBox()); }
 
index 6c016bb..945f7ec 100644 (file)
@@ -282,7 +282,7 @@ LayoutUnit ShapeOutsideInfo::logicalLeftOffset() const
     case ViewBox: break;
     case BoxMissing: break;
     }
-    
+
     ASSERT_NOT_REACHED();
     return LayoutUnit();
 }
@@ -303,23 +303,10 @@ bool ShapeOutsideInfo::isEnabledFor(const RenderBox& box)
     return false;
 }
 
-SegmentList ShapeOutsideInfo::computeSegmentsForLine(LayoutUnit lineTop, LayoutUnit lineHeight) const
+void ShapeOutsideInfo::updateDeltasForContainingBlockLine(const RenderBlockFlow& containingBlock, const FloatingObject& floatingObject, LayoutUnit lineTop, LayoutUnit lineHeight)
 {
     ASSERT(lineHeight >= 0);
-    SegmentList segments;
-
-    computedShape().getExcludedIntervals((lineTop - logicalTopOffset()), std::min(lineHeight, shapeLogicalBottom() - lineTop), segments);
-
-    for (size_t i = 0; i < segments.size(); i++) {
-        segments[i].logicalLeft += logicalLeftOffset();
-        segments[i].logicalRight += logicalLeftOffset();
-    }
-    
-    return segments;
-}
 
-void ShapeOutsideInfo::updateDeltasForContainingBlockLine(const RenderBlockFlow& containingBlock, const FloatingObject& floatingObject, LayoutUnit lineTop, LayoutUnit lineHeight)
-{
     LayoutUnit borderBoxTop = containingBlock.logicalTopForFloat(&floatingObject) + containingBlock.marginBeforeForChild(m_renderer);
     LayoutUnit borderBoxLineTop = lineTop - borderBoxTop;
 
@@ -331,14 +318,14 @@ void ShapeOutsideInfo::updateDeltasForContainingBlockLine(const RenderBlockFlow&
         LayoutUnit floatMarginBoxWidth = containingBlock.logicalWidthForFloat(&floatingObject);
 
         if (computedShape().lineOverlapsShapeMarginBounds(m_referenceBoxLineTop, m_lineHeight)) {
-            SegmentList segments = computeSegmentsForLine(borderBoxLineTop, lineHeight);
-            if (segments.size()) {
+            LineSegment segment = computedShape().getExcludedInterval((borderBoxLineTop - logicalTopOffset()), std::min(lineHeight, shapeLogicalBottom() - borderBoxLineTop));
+            if (segment.isValid) {
                 LayoutUnit logicalLeftMargin = containingBlock.style().isLeftToRightDirection() ? containingBlock.marginStartForChild(m_renderer) : containingBlock.marginEndForChild(m_renderer);
-                LayoutUnit rawLeftMarginBoxDelta = segments.first().logicalLeft + logicalLeftMargin;
+                LayoutUnit rawLeftMarginBoxDelta = segment.logicalLeft + logicalLeftOffset() + logicalLeftMargin;
                 m_leftMarginBoxDelta = clampTo<LayoutUnit>(rawLeftMarginBoxDelta, LayoutUnit(), floatMarginBoxWidth);
 
                 LayoutUnit logicalRightMargin = containingBlock.style().isLeftToRightDirection() ? containingBlock.marginEndForChild(m_renderer) : containingBlock.marginStartForChild(m_renderer);
-                LayoutUnit rawRightMarginBoxDelta = segments.last().logicalRight - containingBlock.logicalWidthForChild(m_renderer) - logicalRightMargin;
+                LayoutUnit rawRightMarginBoxDelta = segment.logicalRight + logicalLeftOffset() - containingBlock.logicalWidthForChild(m_renderer) - logicalRightMargin;
                 m_rightMarginBoxDelta = clampTo<LayoutUnit>(rawRightMarginBoxDelta, -floatMarginBoxWidth, LayoutUnit());
                 m_lineOverlapsShape = true;
                 return;
index d6b68dd..71beb06 100644 (file)
@@ -96,8 +96,6 @@ public:
 private:
     std::unique_ptr<Shape> createShapeForImage(StyleImage*, float shapeImageThreshold, WritingMode, float margin) const;
 
-    SegmentList computeSegmentsForLine(LayoutUnit lineTop, LayoutUnit lineHeight) const;
-
     LayoutUnit logicalTopOffset() const;
     LayoutUnit logicalLeftOffset() const;