Index: Source/core/rendering/shapes/ShapeOutsideInfo.cpp |
diff --git a/Source/core/rendering/shapes/ShapeOutsideInfo.cpp b/Source/core/rendering/shapes/ShapeOutsideInfo.cpp |
index ed3beb1933a8a4bbd2ab21571e50b4f69481aba4..6b4138b66064792b7e32429ee8adf85d9171312b 100644 |
--- a/Source/core/rendering/shapes/ShapeOutsideInfo.cpp |
+++ b/Source/core/rendering/shapes/ShapeOutsideInfo.cpp |
@@ -34,6 +34,7 @@ |
#include "core/rendering/RenderBlockFlow.h" |
#include "core/rendering/RenderBox.h" |
#include "core/rendering/RenderImage.h" |
+#include "platform/LengthFunctions.h" |
namespace WebCore { |
@@ -123,7 +124,9 @@ const Shape& ShapeOutsideInfo::computedShape() const |
const RenderStyle& containingBlockStyle = *m_renderer.containingBlock()->style(); |
WritingMode writingMode = containingBlockStyle.writingMode(); |
- Length margin = style.shapeMargin(); |
+ LayoutUnit maximumValue = m_renderer.containingBlock() ? m_renderer.containingBlock()->contentWidth() : LayoutUnit(); |
+ float margin = floatValueForLength(m_renderer.style()->shapeMargin(), maximumValue.toFloat()); |
+ |
float shapeImageThreshold = style.shapeImageThreshold(); |
ASSERT(style.shapeOutside()); |
const ShapeValue& shapeValue = *style.shapeOutside(); |