summaryrefslogtreecommitdiff
path: root/Source/WebCore/rendering/RenderInline.cpp
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@nokia.com>2012-05-25 15:09:11 +0200
committerSimon Hausmann <simon.hausmann@nokia.com>2012-05-25 15:09:11 +0200
commita89b2ebb8e192c5e8cea21079bda2ee2c0c7dddd (patch)
treeb7abd9f49ae1d4d2e426a5883bfccd42b8e2ee12 /Source/WebCore/rendering/RenderInline.cpp
parent8d473cf9743f1d30a16a27114e93bd5af5648d23 (diff)
downloadqtwebkit-a89b2ebb8e192c5e8cea21079bda2ee2c0c7dddd.tar.gz
Imported WebKit commit eb5c1b8fe4d4b1b90b5137433fc58a91da0e6878 (http://svn.webkit.org/repository/webkit/trunk@118516)
Diffstat (limited to 'Source/WebCore/rendering/RenderInline.cpp')
-rw-r--r--Source/WebCore/rendering/RenderInline.cpp27
1 files changed, 17 insertions, 10 deletions
diff --git a/Source/WebCore/rendering/RenderInline.cpp b/Source/WebCore/rendering/RenderInline.cpp
index 38a874b4a..0c88749f7 100644
--- a/Source/WebCore/rendering/RenderInline.cpp
+++ b/Source/WebCore/rendering/RenderInline.cpp
@@ -31,6 +31,7 @@
#include "Page.h"
#include "RenderArena.h"
#include "RenderBlock.h"
+#include "RenderFlowThread.h"
#include "RenderLayer.h"
#include "RenderTheme.h"
#include "RenderView.h"
@@ -212,7 +213,8 @@ void RenderInline::updateAlwaysCreateLineBoxes(bool fullLayout)
|| style()->verticalAlign() != BASELINE
|| style()->textEmphasisMark() != TextEmphasisMarkNone
|| (checkFonts && (!parentStyle->font().fontMetrics().hasIdenticalAscentDescentAndLineGap(style()->font().fontMetrics())
- || parentStyle->lineHeight() != style()->lineHeight()));
+ || parentStyle->lineHeight() != style()->lineHeight()))
+ || (inRenderFlowThread() && enclosingRenderFlowThread()->hasRegionsWithStyling());
if (!alwaysCreateLineBoxes && checkFonts && document()->usesFirstLineRules()) {
// Have to check the first line style as well.
@@ -609,7 +611,7 @@ void RenderInline::absoluteRects(Vector<IntRect>& rects, const LayoutPoint& accu
if (continuation()) {
if (continuation()->isBox()) {
RenderBox* box = toRenderBox(continuation());
- continuation()->absoluteRects(rects, toLayoutPoint(accumulatedOffset - containingBlock()->location() + box->size()));
+ continuation()->absoluteRects(rects, toLayoutPoint(accumulatedOffset - containingBlock()->location() + box->locationOffset()));
} else
continuation()->absoluteRects(rects, toLayoutPoint(accumulatedOffset - containingBlock()->location()));
}
@@ -694,24 +696,24 @@ LayoutUnit RenderInline::marginBottom() const
return computeMargin(this, style()->marginBottom());
}
-LayoutUnit RenderInline::marginStart() const
+LayoutUnit RenderInline::marginStart(const RenderStyle* otherStyle) const
{
- return computeMargin(this, style()->marginStart());
+ return computeMargin(this, style()->marginStartUsing(otherStyle ? otherStyle : style()));
}
-LayoutUnit RenderInline::marginEnd() const
+LayoutUnit RenderInline::marginEnd(const RenderStyle* otherStyle) const
{
- return computeMargin(this, style()->marginEnd());
+ return computeMargin(this, style()->marginEndUsing(otherStyle ? otherStyle : style()));
}
-LayoutUnit RenderInline::marginBefore() const
+LayoutUnit RenderInline::marginBefore(const RenderStyle* otherStyle) const
{
- return computeMargin(this, style()->marginBefore());
+ return computeMargin(this, style()->marginBeforeUsing(otherStyle ? otherStyle : style()));
}
-LayoutUnit RenderInline::marginAfter() const
+LayoutUnit RenderInline::marginAfter(const RenderStyle* otherStyle) const
{
- return computeMargin(this, style()->marginAfter());
+ return computeMargin(this, style()->marginAfterUsing(otherStyle ? otherStyle : style()));
}
const char* RenderInline::renderName() const
@@ -1202,6 +1204,11 @@ void RenderInline::dirtyLineBoxes(bool fullLayout)
m_lineBoxes.dirtyLineBoxes();
}
+void RenderInline::deleteLineBoxTree()
+{
+ m_lineBoxes.deleteLineBoxTree(renderArena());
+}
+
InlineFlowBox* RenderInline::createInlineFlowBox()
{
return new (renderArena()) InlineFlowBox(this);