[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

hyatt at apple.com hyatt at apple.com
Wed Dec 22 13:42:09 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit c01df9eb651c527ba833e271f7972b52c4bdb907
Author: hyatt at apple.com <hyatt at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Sep 23 19:17:33 2010 +0000

    https://bugs.webkit.org/show_bug.cgi?id=46378, rename width/height on line boxes to logicalWidth/logicalHeight.
    
    Reviewed by Dan Bernstein.
    
    * editing/visible_units.cpp:
    (WebCore::previousLinePosition):
    (WebCore::nextLinePosition):
    * rendering/EllipsisBox.cpp:
    (WebCore::EllipsisBox::paint):
    (WebCore::EllipsisBox::paintSelection):
    (WebCore::EllipsisBox::nodeAtPoint):
    * rendering/InlineBox.cpp:
    (WebCore::InlineBox::logicalHeight):
    (WebCore::InlineBox::canAccommodateEllipsis):
    * rendering/InlineBox.h:
    (WebCore::InlineBox::InlineBox):
    (WebCore::InlineBox::hasVirtualLogicalHeight):
    (WebCore::InlineBox::setHasVirtualLogicalHeight):
    (WebCore::InlineBox::virtualLogicalHeight):
    (WebCore::InlineBox::setLogicalWidth):
    (WebCore::InlineBox::logicalWidth):
    * rendering/InlineFlowBox.cpp:
    (WebCore::InlineFlowBox::placeBoxesHorizontally):
    (WebCore::InlineFlowBox::placeBoxesVertically):
    (WebCore::InlineFlowBox::computeVerticalOverflow):
    (WebCore::InlineFlowBox::nodeAtPoint):
    (WebCore::InlineFlowBox::paintFillLayer):
    (WebCore::InlineFlowBox::paintBoxDecorations):
    (WebCore::InlineFlowBox::paintMask):
    (WebCore::InlineFlowBox::paintTextDecorations):
    (WebCore::InlineFlowBox::placeEllipsisBox):
    * rendering/InlineFlowBox.h:
    (WebCore::InlineFlowBox::visibleOverflowRect):
    (WebCore::InlineFlowBox::bottomLayoutOverflow):
    (WebCore::InlineFlowBox::rightLayoutOverflow):
    (WebCore::InlineFlowBox::layoutOverflowRect):
    (WebCore::InlineFlowBox::bottomVisualOverflow):
    (WebCore::InlineFlowBox::rightVisualOverflow):
    (WebCore::InlineFlowBox::visualOverflowRect):
    (WebCore::InlineFlowBox::setHorizontalOverflowPositions):
    (WebCore::InlineFlowBox::setVerticalOverflowPositions):
    * rendering/InlineTextBox.cpp:
    (WebCore::InlineTextBox::selectionRect):
    (WebCore::InlineTextBox::placeEllipsisBox):
    (WebCore::InlineTextBox::nodeAtPoint):
    (WebCore::InlineTextBox::paint):
    (WebCore::InlineTextBox::paintSelection):
    (WebCore::InlineTextBox::paintCustomHighlight):
    (WebCore::InlineTextBox::paintDecoration):
    (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
    (WebCore::InlineTextBox::paintTextMatchMarker):
    (WebCore::InlineTextBox::paintCompositionUnderline):
    * rendering/InlineTextBox.h:
    (WebCore::InlineTextBox::calculateBoundaries):
    (WebCore::InlineTextBox::setSpaceAdd):
    * rendering/RenderBlock.cpp:
    (WebCore::RenderBlock::paintEllipsisBoxes):
    (WebCore::RenderBlock::rightmostPosition):
    (WebCore::RenderBlock::adjustForBorderFit):
    (WebCore::RenderBlock::addFocusRingRects):
    * rendering/RenderBlockLineLayout.cpp:
    (WebCore::RenderBlock::computeHorizontalPositionsForLine):
    (WebCore::RenderBlock::checkLinesForTextOverflow):
    * rendering/RenderBox.cpp:
    (WebCore::RenderBox::paintCustomHighlight):
    (WebCore::RenderBox::containingBlockWidthForPositioned):
    * rendering/RenderFlexibleBox.cpp:
    (WebCore::RenderFlexibleBox::applyLineClamp):
    * rendering/RenderInline.cpp:
    (WebCore::RenderInline::absoluteRects):
    (WebCore::RenderInline::absoluteQuads):
    (WebCore::RenderInline::linesBoundingBox):
    (WebCore::RenderInline::addFocusRingRects):
    (WebCore::RenderInline::paintOutline):
    * rendering/RenderSVGInline.cpp:
    (WebCore::RenderSVGInline::createInlineFlowBox):
    (WebCore::RenderSVGInline::absoluteQuads):
    * rendering/RenderSVGInlineText.cpp:
    (WebCore::RenderSVGInlineText::createTextBox):
    * rendering/RenderSVGText.cpp:
    (WebCore::RenderSVGText::createRootInlineBox):
    * rendering/RenderText.cpp:
    (WebCore::RenderText::absoluteRects):
    (WebCore::RenderText::absoluteRectsForRange):
    (WebCore::RenderText::absoluteQuadsForRange):
    (WebCore::RenderText::positionForPoint):
    (WebCore::RenderText::localCaretRect):
    (WebCore::RenderText::linesBoundingBox):
    * rendering/RenderTreeAsText.cpp:
    (WebCore::writeTextRun):
    * rendering/RootInlineBox.cpp:
    (WebCore::RootInlineBox::canAccommodateEllipsis):
    (WebCore::RootInlineBox::placeEllipsis):
    (WebCore::RootInlineBox::addHighlightOverflow):
    (WebCore::RootInlineBox::paintCustomHighlight):
    (WebCore::RootInlineBox::fillLineSelectionGap):
    (WebCore::RootInlineBox::closestLeafChildForXPos):
    * rendering/SVGInlineFlowBox.h:
    (WebCore::SVGInlineFlowBox::SVGInlineFlowBox):
    (WebCore::SVGInlineFlowBox::virtualLogicalHeight):
    (WebCore::SVGInlineFlowBox::setLogicalHeight):
    * rendering/SVGInlineTextBox.cpp:
    (WebCore::SVGInlineTextBox::SVGInlineTextBox):
    * rendering/SVGInlineTextBox.h:
    (WebCore::SVGInlineTextBox::virtualLogicalHeight):
    (WebCore::SVGInlineTextBox::setLogicalHeight):
    (WebCore::SVGInlineTextBox::selectionHeight):
    * rendering/SVGRenderTreeAsText.cpp:
    (WebCore::writeRenderSVGTextBox):
    * rendering/SVGRootInlineBox.cpp:
    (WebCore::SVGRootInlineBox::layoutChildBoxes):
    (WebCore::SVGRootInlineBox::layoutRootBox):
    * rendering/SVGRootInlineBox.h:
    (WebCore::SVGRootInlineBox::SVGRootInlineBox):
    (WebCore::SVGRootInlineBox::virtualLogicalHeight):
    (WebCore::SVGRootInlineBox::setLogicalHeight):
    * rendering/TrailingFloatsRootInlineBox.h:
    (WebCore::TrailingFloatsRootInlineBox::TrailingFloatsRootInlineBox):
    (WebCore::TrailingFloatsRootInlineBox::virtualLogicalHeight):
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@68177 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 7619efc..056422d 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,125 @@
+2010-09-23  David Hyatt  <hyatt at apple.com>
+
+        Reviewed by Dan Bernstein.
+
+        https://bugs.webkit.org/show_bug.cgi?id=46378, rename width/height on line boxes to logicalWidth/logicalHeight.
+
+        * editing/visible_units.cpp:
+        (WebCore::previousLinePosition):
+        (WebCore::nextLinePosition):
+        * rendering/EllipsisBox.cpp:
+        (WebCore::EllipsisBox::paint):
+        (WebCore::EllipsisBox::paintSelection):
+        (WebCore::EllipsisBox::nodeAtPoint):
+        * rendering/InlineBox.cpp:
+        (WebCore::InlineBox::logicalHeight):
+        (WebCore::InlineBox::canAccommodateEllipsis):
+        * rendering/InlineBox.h:
+        (WebCore::InlineBox::InlineBox):
+        (WebCore::InlineBox::hasVirtualLogicalHeight):
+        (WebCore::InlineBox::setHasVirtualLogicalHeight):
+        (WebCore::InlineBox::virtualLogicalHeight):
+        (WebCore::InlineBox::setLogicalWidth):
+        (WebCore::InlineBox::logicalWidth):
+        * rendering/InlineFlowBox.cpp:
+        (WebCore::InlineFlowBox::placeBoxesHorizontally):
+        (WebCore::InlineFlowBox::placeBoxesVertically):
+        (WebCore::InlineFlowBox::computeVerticalOverflow):
+        (WebCore::InlineFlowBox::nodeAtPoint):
+        (WebCore::InlineFlowBox::paintFillLayer):
+        (WebCore::InlineFlowBox::paintBoxDecorations):
+        (WebCore::InlineFlowBox::paintMask):
+        (WebCore::InlineFlowBox::paintTextDecorations):
+        (WebCore::InlineFlowBox::placeEllipsisBox):
+        * rendering/InlineFlowBox.h:
+        (WebCore::InlineFlowBox::visibleOverflowRect):
+        (WebCore::InlineFlowBox::bottomLayoutOverflow):
+        (WebCore::InlineFlowBox::rightLayoutOverflow):
+        (WebCore::InlineFlowBox::layoutOverflowRect):
+        (WebCore::InlineFlowBox::bottomVisualOverflow):
+        (WebCore::InlineFlowBox::rightVisualOverflow):
+        (WebCore::InlineFlowBox::visualOverflowRect):
+        (WebCore::InlineFlowBox::setHorizontalOverflowPositions):
+        (WebCore::InlineFlowBox::setVerticalOverflowPositions):
+        * rendering/InlineTextBox.cpp:
+        (WebCore::InlineTextBox::selectionRect):
+        (WebCore::InlineTextBox::placeEllipsisBox):
+        (WebCore::InlineTextBox::nodeAtPoint):
+        (WebCore::InlineTextBox::paint):
+        (WebCore::InlineTextBox::paintSelection):
+        (WebCore::InlineTextBox::paintCustomHighlight):
+        (WebCore::InlineTextBox::paintDecoration):
+        (WebCore::InlineTextBox::paintSpellingOrGrammarMarker):
+        (WebCore::InlineTextBox::paintTextMatchMarker):
+        (WebCore::InlineTextBox::paintCompositionUnderline):
+        * rendering/InlineTextBox.h:
+        (WebCore::InlineTextBox::calculateBoundaries):
+        (WebCore::InlineTextBox::setSpaceAdd):
+        * rendering/RenderBlock.cpp:
+        (WebCore::RenderBlock::paintEllipsisBoxes):
+        (WebCore::RenderBlock::rightmostPosition):
+        (WebCore::RenderBlock::adjustForBorderFit):
+        (WebCore::RenderBlock::addFocusRingRects):
+        * rendering/RenderBlockLineLayout.cpp:
+        (WebCore::RenderBlock::computeHorizontalPositionsForLine):
+        (WebCore::RenderBlock::checkLinesForTextOverflow):
+        * rendering/RenderBox.cpp:
+        (WebCore::RenderBox::paintCustomHighlight):
+        (WebCore::RenderBox::containingBlockWidthForPositioned):
+        * rendering/RenderFlexibleBox.cpp:
+        (WebCore::RenderFlexibleBox::applyLineClamp):
+        * rendering/RenderInline.cpp:
+        (WebCore::RenderInline::absoluteRects):
+        (WebCore::RenderInline::absoluteQuads):
+        (WebCore::RenderInline::linesBoundingBox):
+        (WebCore::RenderInline::addFocusRingRects):
+        (WebCore::RenderInline::paintOutline):
+        * rendering/RenderSVGInline.cpp:
+        (WebCore::RenderSVGInline::createInlineFlowBox):
+        (WebCore::RenderSVGInline::absoluteQuads):
+        * rendering/RenderSVGInlineText.cpp:
+        (WebCore::RenderSVGInlineText::createTextBox):
+        * rendering/RenderSVGText.cpp:
+        (WebCore::RenderSVGText::createRootInlineBox):
+        * rendering/RenderText.cpp:
+        (WebCore::RenderText::absoluteRects):
+        (WebCore::RenderText::absoluteRectsForRange):
+        (WebCore::RenderText::absoluteQuadsForRange):
+        (WebCore::RenderText::positionForPoint):
+        (WebCore::RenderText::localCaretRect):
+        (WebCore::RenderText::linesBoundingBox):
+        * rendering/RenderTreeAsText.cpp:
+        (WebCore::writeTextRun):
+        * rendering/RootInlineBox.cpp:
+        (WebCore::RootInlineBox::canAccommodateEllipsis):
+        (WebCore::RootInlineBox::placeEllipsis):
+        (WebCore::RootInlineBox::addHighlightOverflow):
+        (WebCore::RootInlineBox::paintCustomHighlight):
+        (WebCore::RootInlineBox::fillLineSelectionGap):
+        (WebCore::RootInlineBox::closestLeafChildForXPos):
+        * rendering/SVGInlineFlowBox.h:
+        (WebCore::SVGInlineFlowBox::SVGInlineFlowBox):
+        (WebCore::SVGInlineFlowBox::virtualLogicalHeight):
+        (WebCore::SVGInlineFlowBox::setLogicalHeight):
+        * rendering/SVGInlineTextBox.cpp:
+        (WebCore::SVGInlineTextBox::SVGInlineTextBox):
+        * rendering/SVGInlineTextBox.h:
+        (WebCore::SVGInlineTextBox::virtualLogicalHeight):
+        (WebCore::SVGInlineTextBox::setLogicalHeight):
+        (WebCore::SVGInlineTextBox::selectionHeight):
+        * rendering/SVGRenderTreeAsText.cpp:
+        (WebCore::writeRenderSVGTextBox):
+        * rendering/SVGRootInlineBox.cpp:
+        (WebCore::SVGRootInlineBox::layoutChildBoxes):
+        (WebCore::SVGRootInlineBox::layoutRootBox):
+        * rendering/SVGRootInlineBox.h:
+        (WebCore::SVGRootInlineBox::SVGRootInlineBox):
+        (WebCore::SVGRootInlineBox::virtualLogicalHeight):
+        (WebCore::SVGRootInlineBox::setLogicalHeight):
+        * rendering/TrailingFloatsRootInlineBox.h:
+        (WebCore::TrailingFloatsRootInlineBox::TrailingFloatsRootInlineBox):
+        (WebCore::TrailingFloatsRootInlineBox::virtualLogicalHeight):
+
 2010-09-23  Matthew Delaney  <mdelaney at apple.com>
 
         Reviewed by Oliver Hunt.
diff --git a/WebCore/editing/visible_units.cpp b/WebCore/editing/visible_units.cpp
index 975caf2..d9ca223 100644
--- a/WebCore/editing/visible_units.cpp
+++ b/WebCore/editing/visible_units.cpp
@@ -563,7 +563,7 @@ VisiblePosition previousLinePosition(const VisiblePosition &visiblePosition, int
         root = box->root()->prevRootBox();
         // We want to skip zero height boxes.
         // This could happen in case it is a TrailingFloatsRootInlineBox.
-        if (root && root->height())
+        if (root && root->logicalHeight())
             containingBlock = renderer->containingBlock();
         else
             root = 0;
@@ -672,7 +672,7 @@ VisiblePosition nextLinePosition(const VisiblePosition &visiblePosition, int x)
         root = box->root()->nextRootBox();
         // We want to skip zero height boxes.
         // This could happen in case it is a TrailingFloatsRootInlineBox.
-        if (root && root->height())
+        if (root && root->logicalHeight())
             containingBlock = renderer->containingBlock();
         else
             root = 0;
diff --git a/WebCore/rendering/EllipsisBox.cpp b/WebCore/rendering/EllipsisBox.cpp
index 61cd524..1d71d35 100644
--- a/WebCore/rendering/EllipsisBox.cpp
+++ b/WebCore/rendering/EllipsisBox.cpp
@@ -62,7 +62,7 @@ void EllipsisBox::paint(PaintInfo& paintInfo, int tx, int ty)
 
     if (m_markupBox) {
         // Paint the markup box
-        tx += m_x + m_width - m_markupBox->x();
+        tx += m_x + m_logicalWidth - m_markupBox->x();
         ty += m_y + style->font().ascent() - (m_markupBox->y() + m_markupBox->renderer()->style(m_firstLine)->font().ascent());
         m_markupBox->paint(paintInfo, tx, ty);
     }
@@ -91,7 +91,7 @@ void EllipsisBox::paintSelection(GraphicsContext* context, int tx, int ty, Rende
     context->save();
     int y = root()->selectionTop();
     int h = root()->selectionHeight();
-    context->clip(IntRect(m_x + tx, y + ty, m_width, h));
+    context->clip(IntRect(m_x + tx, y + ty, m_logicalWidth, h));
     context->drawHighlightForText(font, TextRun(m_str.characters(), m_str.length(), false, 0, 0, false, style->visuallyOrdered()),
         IntPoint(m_x + tx, m_y + ty + y), h, c, style->colorSpace());
     context->restore();
@@ -105,7 +105,7 @@ bool EllipsisBox::nodeAtPoint(const HitTestRequest& request, HitTestResult& resu
     // Hit test the markup box.
     if (m_markupBox) {
         RenderStyle* style = m_renderer->style(m_firstLine);
-        int mtx = tx + m_width - m_markupBox->x();
+        int mtx = tx + m_logicalWidth - m_markupBox->x();
         int mty = ty + style->font().ascent() - (m_markupBox->y() + m_markupBox->renderer()->style(m_firstLine)->font().ascent());
         if (m_markupBox->nodeAtPoint(request, result, x, y, mtx, mty)) {
             renderer()->updateHitTestResult(result, IntPoint(x - mtx, y - mty));
@@ -113,7 +113,7 @@ bool EllipsisBox::nodeAtPoint(const HitTestRequest& request, HitTestResult& resu
         }
     }
 
-    IntRect boundsRect = IntRect(tx, ty, m_width, m_height);
+    IntRect boundsRect = IntRect(tx, ty, m_logicalWidth, m_height);
     if (visibleToHitTesting() && boundsRect.intersects(result.rectFromPoint(x, y))) {
         renderer()->updateHitTestResult(result, IntPoint(x - tx, y - ty));
         if (!result.addNodeToRectBasedTestResult(renderer()->node(), x, y, boundsRect))
diff --git a/WebCore/rendering/InlineBox.cpp b/WebCore/rendering/InlineBox.cpp
index 5475187..91cbaff 100644
--- a/WebCore/rendering/InlineBox.cpp
+++ b/WebCore/rendering/InlineBox.cpp
@@ -85,11 +85,11 @@ void InlineBox::showTreeForThis() const
 }
 #endif
 
-int InlineBox::height() const
+int InlineBox::logicalHeight() const
 {
 #if ENABLE(SVG)
-    if (hasVirtualHeight())
-        return virtualHeight();
+    if (hasVirtualLogicalHeight())
+        return virtualLogicalHeight();
 #endif
     
     if (renderer()->isText())
@@ -268,7 +268,7 @@ bool InlineBox::canAccommodateEllipsis(bool ltr, int blockEdge, int ellipsisWidt
     if (!m_renderer || !m_renderer->isReplaced())
         return true;
     
-    IntRect boxRect(m_x, 0, m_width, 10);
+    IntRect boxRect(m_x, 0, m_logicalWidth, 10);
     IntRect ellipsisRect(ltr ? blockEdge - ellipsisWidth : blockEdge, 0, ellipsisWidth, 10);
     return !(boxRect.intersects(ellipsisRect));
 }
diff --git a/WebCore/rendering/InlineBox.h b/WebCore/rendering/InlineBox.h
index ab0167c..fa1ebfe 100644
--- a/WebCore/rendering/InlineBox.h
+++ b/WebCore/rendering/InlineBox.h
@@ -42,14 +42,14 @@ public:
         , m_renderer(obj)
         , m_x(0)
         , m_y(0)
-        , m_width(0)
+        , m_logicalWidth(0)
         , m_firstLine(false)
         , m_constructed(false)
         , m_bidiEmbeddingLevel(0)
         , m_dirty(false)
         , m_extracted(false)
 #if ENABLE(SVG)
-        , m_hasVirtualHeight(false)
+        , m_hasVirtualLogicalHeight(false)
 #endif
         , m_endsWithBreak(false)
         , m_hasSelectedChildren(false)
@@ -67,7 +67,7 @@ public:
     {
     }
 
-    InlineBox(RenderObject* obj, int x, int y, int width, bool firstLine, bool constructed,
+    InlineBox(RenderObject* obj, int x, int y, int logicalWidth, bool firstLine, bool constructed,
               bool dirty, bool extracted, InlineBox* next, InlineBox* prev, InlineFlowBox* parent)
         : m_next(next)
         , m_prev(prev)
@@ -75,14 +75,14 @@ public:
         , m_renderer(obj)
         , m_x(x)
         , m_y(y)
-        , m_width(width)
+        , m_logicalWidth(logicalWidth)
         , m_firstLine(firstLine)
         , m_constructed(constructed)
         , m_bidiEmbeddingLevel(0)
         , m_dirty(dirty)
         , m_extracted(extracted)
 #if ENABLE(SVG)
-        , m_hasVirtualHeight(false)
+        , m_hasVirtualLogicalHeight(false)
 #endif
         , m_endsWithBreak(false)
         , m_hasSelectedChildren(false)   
@@ -140,9 +140,9 @@ public:
     virtual bool isSVGInlineTextBox() const { return false; }
     virtual bool isSVGRootInlineBox() const { return false; }
 
-    bool hasVirtualHeight() const { return m_hasVirtualHeight; }
-    void setHasVirtualHeight() { m_hasVirtualHeight = true; }
-    virtual int virtualHeight() const
+    bool hasVirtualLogicalHeight() const { return m_hasVirtualLogicalHeight; }
+    void setHasVirtualLogicalHeight() { m_hasVirtualLogicalHeight = true; }
+    virtual int virtualLogicalHeight() const
     {
         ASSERT_NOT_REACHED();
         return 0;
@@ -202,9 +202,6 @@ public:
     const RootInlineBox* root() const;
     RootInlineBox* root();
 
-    void setWidth(int w) { m_width = w; }
-    int width() const { return m_width; }
-
     // x() is the left side of the box in the parent's coordinate system.
     void setX(int x) { m_x = x; }
     int x() const { return m_x; }
@@ -213,7 +210,12 @@ public:
     void setY(int y) { m_y = y; }
     int y() const { return m_y; }
 
-    int height() const;
+    // The logical width is our extent in the line's overall inline direction, i.e., width for horizontal text and height for vertical text.
+    void setLogicalWidth(int w) { m_logicalWidth = w; }
+    int logicalWidth() const { return m_logicalWidth; }
+
+    // The logical height is our extent in the block flow direction, i.e., height for horizontal text and width for vertical text.
+    int logicalHeight() const;
 
     inline int baselinePosition(bool isRootLineBox) const { return renderer()->baselinePosition(m_firstLine, isRootLineBox); }
     inline int lineHeight(bool isRootLineBox) const { return renderer()->lineHeight(m_firstLine, isRootLineBox); }
@@ -266,7 +268,7 @@ public:
 
     int m_x;
     int m_y;
-    int m_width;
+    int m_logicalWidth;
     
     // Some of these bits are actually for subclasses and moved here to compact the structures.
 
@@ -279,7 +281,7 @@ private:
 protected:
     bool m_dirty : 1;
     bool m_extracted : 1;
-    bool m_hasVirtualHeight : 1;
+    bool m_hasVirtualLogicalHeight : 1;
 
     // for RootInlineBox
     bool m_endsWithBreak : 1;  // Whether the line ends with a <br>.
diff --git a/WebCore/rendering/InlineFlowBox.cpp b/WebCore/rendering/InlineFlowBox.cpp
index a71b796..e6e88b1 100644
--- a/WebCore/rendering/InlineFlowBox.cpp
+++ b/WebCore/rendering/InlineFlowBox.cpp
@@ -287,7 +287,7 @@ int InlineFlowBox::placeBoxesHorizontally(int xPos, bool& needsWordSpacing, Glyp
             // If letter-spacing is negative, we should factor that into right layout overflow. (Even in RTL, letter-spacing is
             // applied to the right, so this is not an issue with left overflow.
             int letterSpacing = min(0, (int)rt->style(m_firstLine)->font().letterSpacing());
-            rightLayoutOverflow = max(xPos + text->width() - letterSpacing, rightLayoutOverflow);
+            rightLayoutOverflow = max(xPos + text->logicalWidth() - letterSpacing, rightLayoutOverflow);
 
             GlyphOverflowAndFallbackFontsMap::iterator it = textBoxDataMap.find(static_cast<InlineTextBox*>(curr));
             GlyphOverflow* glyphOverflow = it == textBoxDataMap.end() ? 0 : &it->second.second;
@@ -303,9 +303,9 @@ int InlineFlowBox::placeBoxesHorizontally(int xPos, bool& needsWordSpacing, Glyp
             }
             
             leftVisualOverflow = min(xPos + childOverflowLeft, leftVisualOverflow);
-            rightVisualOverflow = max(xPos + text->width() + childOverflowRight, rightVisualOverflow);
+            rightVisualOverflow = max(xPos + text->logicalWidth() + childOverflowRight, rightVisualOverflow);
             
-            xPos += text->width();
+            xPos += text->logicalWidth();
         } else {
             if (curr->renderer()->isPositioned()) {
                 if (curr->renderer()->parent()->style()->direction() == LTR)
@@ -332,7 +332,7 @@ int InlineFlowBox::placeBoxesHorizontally(int xPos, bool& needsWordSpacing, Glyp
                  
                 RenderBox* box = toRenderBox(curr->renderer());
                 int childLeftOverflow = box->hasOverflowClip() ? 0 : box->leftLayoutOverflow();
-                int childRightOverflow = box->hasOverflowClip() ? curr->width() : box->rightLayoutOverflow();
+                int childRightOverflow = box->hasOverflowClip() ? curr->logicalWidth() : box->rightLayoutOverflow();
                 
                 leftLayoutOverflow = min(xPos + childLeftOverflow, leftLayoutOverflow);
                 rightLayoutOverflow = max(xPos + childRightOverflow, rightLayoutOverflow);
@@ -340,15 +340,15 @@ int InlineFlowBox::placeBoxesHorizontally(int xPos, bool& needsWordSpacing, Glyp
                 leftVisualOverflow = min(xPos + box->leftVisualOverflow(), leftVisualOverflow);
                 rightVisualOverflow = max(xPos + box->rightVisualOverflow(), rightVisualOverflow);
                
-                xPos += curr->width() + curr->boxModelObject()->marginRight();
+                xPos += curr->logicalWidth() + curr->boxModelObject()->marginRight();
             }
         }
     }
 
     xPos += borderRight() + paddingRight();
-    setWidth(xPos - startX);
-    rightVisualOverflow = max(x() + width() + boxShadowRight, rightVisualOverflow);
-    rightLayoutOverflow = max(x() + width(), rightLayoutOverflow);
+    setLogicalWidth(xPos - startX);
+    rightVisualOverflow = max(x() + logicalWidth() + boxShadowRight, rightVisualOverflow);
+    rightLayoutOverflow = max(x() + logicalWidth(), rightLayoutOverflow);
 
     setHorizontalOverflowPositions(leftLayoutOverflow, rightLayoutOverflow, leftVisualOverflow, rightVisualOverflow);
     return xPos;
@@ -516,7 +516,7 @@ void InlineFlowBox::placeBoxesVertically(int yPos, int maxHeight, int maxAscent,
         curr->setY(newY);
 
         if (childAffectsTopBottomPos) {
-            int boxHeight = curr->height();
+            int boxHeight = curr->logicalHeight();
             selectionTop = min(selectionTop, newY);
             selectionBottom = max(selectionBottom, newY + boxHeight);
         }
@@ -527,14 +527,14 @@ void InlineFlowBox::placeBoxesVertically(int yPos, int maxHeight, int maxAscent,
         setY(y() + baselinePosition(true) - font.ascent());
         if (hasTextChildren() || strictMode) {
             selectionTop = min(selectionTop, y());
-            selectionBottom = max(selectionBottom, y() + height());
+            selectionBottom = max(selectionBottom, y() + logicalHeight());
         }
     }
 }
 
 void InlineFlowBox::computeVerticalOverflow(int lineTop, int lineBottom, bool strictMode, GlyphOverflowAndFallbackFontsMap& textBoxDataMap)
 {
-    int boxHeight = height();
+    int boxHeight = logicalHeight();
 
     // Any spillage outside of the line top and bottom is not considered overflow.  We just ignore this, since it only happens
     // from the "your ascent/descent don't affect the line" quirk.
@@ -583,7 +583,7 @@ void InlineFlowBox::computeVerticalOverflow(int lineTop, int lineBottom, bool st
             }
             
             topVisualOverflow = min(curr->y() + childOverflowTop, topVisualOverflow);
-            bottomVisualOverflow = max(curr->y() + text->height() + childOverflowBottom, bottomVisualOverflow);
+            bottomVisualOverflow = max(curr->y() + text->logicalHeight() + childOverflowBottom, bottomVisualOverflow);
         } else  if (curr->renderer()->isRenderInline()) {
             InlineFlowBox* flow = static_cast<InlineFlowBox*>(curr);
             flow->computeVerticalOverflow(lineTop, lineBottom, strictMode, textBoxDataMap);
@@ -596,7 +596,7 @@ void InlineFlowBox::computeVerticalOverflow(int lineTop, int lineBottom, bool st
             RenderBox* box = toRenderBox(curr->renderer());
             int boxY = curr->y();
             int childTopOverflow = box->hasOverflowClip() ? 0 : box->topLayoutOverflow();
-            int childBottomOverflow = box->hasOverflowClip() ? curr->height() : box->bottomLayoutOverflow();
+            int childBottomOverflow = box->hasOverflowClip() ? curr->logicalHeight() : box->bottomLayoutOverflow();
             topLayoutOverflow = min(boxY + childTopOverflow, topLayoutOverflow);
             bottomLayoutOverflow = max(boxY + childBottomOverflow, bottomLayoutOverflow);
             topVisualOverflow = min(boxY + box->topVisualOverflow(), topVisualOverflow);
@@ -623,7 +623,7 @@ bool InlineFlowBox::nodeAtPoint(const HitTestRequest& request, HitTestResult& re
     }
 
     // Now check ourselves.
-    IntRect rect(tx + m_x, ty + m_y, m_width, height());
+    IntRect rect(tx + m_x, ty + m_y, m_logicalWidth, logicalHeight());
     if (visibleToHitTesting() && rect.intersects(result.rectFromPoint(x, y))) {
         renderer()->updateHitTestResult(result, IntPoint(x - tx, y - ty)); // Don't add in m_x or m_y here, we want coords in the containing block's space.
         if (!result.addNodeToRectBasedTestResult(renderer()->node(), x, y, rect))
@@ -727,13 +727,13 @@ void InlineFlowBox::paintFillLayer(const PaintInfo& paintInfo, const Color& c, c
         // but it isn't even clear how this should work at all.
         int xOffsetOnLine = 0;
         for (InlineFlowBox* curr = prevLineBox(); curr; curr = curr->prevLineBox())
-            xOffsetOnLine += curr->width();
+            xOffsetOnLine += curr->logicalWidth();
         int startX = tx - xOffsetOnLine;
         int totalWidth = xOffsetOnLine;
         for (InlineFlowBox* curr = this; curr; curr = curr->nextLineBox())
-            totalWidth += curr->width();
+            totalWidth += curr->logicalWidth();
         paintInfo.context->save();
-        paintInfo.context->clip(IntRect(tx, ty, width(), height()));
+        paintInfo.context->clip(IntRect(tx, ty, logicalWidth(), logicalHeight()));
         boxModelObject()->paintFillLayerExtended(paintInfo, c, fillLayer, startX, ty, totalWidth, h, this, op);
         paintInfo.context->restore();
     }
@@ -757,8 +757,8 @@ void InlineFlowBox::paintBoxDecorations(PaintInfo& paintInfo, int tx, int ty)
 
     int x = m_x;
     int y = m_y;
-    int w = width();
-    int h = height();
+    int w = logicalWidth();
+    int h = logicalHeight();
 
     // Constrain our background/border painting to the line top and bottom if necessary.
     bool noQuirksMode = renderer()->document()->inNoQuirksMode();
@@ -812,11 +812,11 @@ void InlineFlowBox::paintBoxDecorations(PaintInfo& paintInfo, int tx, int ty)
                 // but it isn't even clear how this should work at all.
                 int xOffsetOnLine = 0;
                 for (InlineFlowBox* curr = prevLineBox(); curr; curr = curr->prevLineBox())
-                    xOffsetOnLine += curr->width();
+                    xOffsetOnLine += curr->logicalWidth();
                 int startX = tx - xOffsetOnLine;
                 int totalWidth = xOffsetOnLine;
                 for (InlineFlowBox* curr = this; curr; curr = curr->nextLineBox())
-                    totalWidth += curr->width();
+                    totalWidth += curr->logicalWidth();
                 context->save();
                 context->clip(IntRect(tx, ty, w, h));
                 boxModelObject()->paintBorder(context, startX, ty, totalWidth, h, renderer()->style());
@@ -833,8 +833,8 @@ void InlineFlowBox::paintMask(PaintInfo& paintInfo, int tx, int ty)
 
     int x = m_x;
     int y = m_y;
-    int w = width();
-    int h = height();
+    int w = logicalWidth();
+    int h = logicalHeight();
 
     // Constrain our background/border painting to the line top and bottom if necessary.
     bool noQuirksMode = renderer()->document()->inNoQuirksMode();
@@ -883,11 +883,11 @@ void InlineFlowBox::paintMask(PaintInfo& paintInfo, int tx, int ty)
         // We need to adjust _tx and _ty by the width of all previous lines.
         int xOffsetOnLine = 0;
         for (InlineFlowBox* curr = prevLineBox(); curr; curr = curr->prevLineBox())
-            xOffsetOnLine += curr->width();
+            xOffsetOnLine += curr->logicalWidth();
         int startX = tx - xOffsetOnLine;
         int totalWidth = xOffsetOnLine;
         for (InlineFlowBox* curr = this; curr; curr = curr->nextLineBox())
-            totalWidth += curr->width();
+            totalWidth += curr->logicalWidth();
         paintInfo.context->save();
         paintInfo.context->clip(IntRect(tx, ty, w, h));
         boxModelObject()->paintNinePieceImage(paintInfo.context, startX, ty, totalWidth, h, renderer()->style(), maskNinePieceImage, compositeOp);
@@ -939,11 +939,11 @@ void InlineFlowBox::paintTextDecorations(PaintInfo& paintInfo, int tx, int ty, b
         ((!paintedChildren && ((deco & UNDERLINE) || (deco & OVERLINE))) || (paintedChildren && (deco & LINE_THROUGH))) &&
         shouldDrawTextDecoration(renderer())) {
         int x = m_x + borderLeft() + paddingLeft();
-        int w = m_width - (borderLeft() + paddingLeft() + borderRight() + paddingRight());
+        int w = m_logicalWidth - (borderLeft() + paddingLeft() + borderRight() + paddingRight());
         RootInlineBox* rootLine = root();
         if (rootLine->ellipsisBox()) {
             int ellipsisX = m_x + rootLine->ellipsisBox()->x();
-            int ellipsisWidth = rootLine->ellipsisBox()->width();
+            int ellipsisWidth = rootLine->ellipsisBox()->logicalWidth();
             bool ltr = renderer()->style()->direction() == LTR;
             if (rootLine == this) {
                 // Trim w and x so that the underline isn't drawn underneath the ellipsis.
@@ -1104,11 +1104,11 @@ int InlineFlowBox::placeEllipsisBox(bool ltr, int blockLeftEdge, int blockRightE
             result = currResult;
 
         if (ltr) {
-            visibleLeftEdge += box->width();
+            visibleLeftEdge += box->logicalWidth();
             box = box->nextOnLine();
         }
         else {
-            visibleRightEdge -= box->width();
+            visibleRightEdge -= box->logicalWidth();
             box = box->prevOnLine();
         }
     }
diff --git a/WebCore/rendering/InlineFlowBox.h b/WebCore/rendering/InlineFlowBox.h
index b4ba59f..454d298 100644
--- a/WebCore/rendering/InlineFlowBox.h
+++ b/WebCore/rendering/InlineFlowBox.h
@@ -151,19 +151,19 @@ public:
     int bottomVisibleOverflow() const { return std::max(bottomLayoutOverflow(), bottomVisualOverflow()); }
     int leftVisibleOverflow() const { return std::min(leftLayoutOverflow(), leftVisualOverflow()); }
     int rightVisibleOverflow() const { return std::max(rightLayoutOverflow(), rightVisualOverflow()); }
-    IntRect visibleOverflowRect() const { return m_overflow ? m_overflow->visibleOverflowRect() : IntRect(m_x, m_y, m_width, height());  }
+    IntRect visibleOverflowRect() const { return m_overflow ? m_overflow->visibleOverflowRect() : IntRect(m_x, m_y, m_logicalWidth, logicalHeight());  }
 
     int topLayoutOverflow() const { return m_overflow ? m_overflow->topLayoutOverflow() : m_y; }
-    int bottomLayoutOverflow() const { return m_overflow ? m_overflow->bottomLayoutOverflow() : m_y + height(); }
+    int bottomLayoutOverflow() const { return m_overflow ? m_overflow->bottomLayoutOverflow() : m_y + logicalHeight(); }
     int leftLayoutOverflow() const { return m_overflow ? m_overflow->leftLayoutOverflow() : m_x; }
-    int rightLayoutOverflow() const { return m_overflow ? m_overflow->rightLayoutOverflow() : m_x + m_width; }
-    IntRect layoutOverflowRect() const { return m_overflow ? m_overflow->layoutOverflowRect() : IntRect(m_x, m_y, m_width, height()); }
+    int rightLayoutOverflow() const { return m_overflow ? m_overflow->rightLayoutOverflow() : m_x + m_logicalWidth; }
+    IntRect layoutOverflowRect() const { return m_overflow ? m_overflow->layoutOverflowRect() : IntRect(m_x, m_y, m_logicalWidth, logicalHeight()); }
 
     int topVisualOverflow() const { return m_overflow ? m_overflow->topVisualOverflow() : m_y; }
-    int bottomVisualOverflow() const { return m_overflow ? m_overflow->bottomVisualOverflow() : m_y + height(); }
+    int bottomVisualOverflow() const { return m_overflow ? m_overflow->bottomVisualOverflow() : m_y + logicalHeight(); }
     int leftVisualOverflow() const { return m_overflow ? m_overflow->leftVisualOverflow() : m_x; }
-    int rightVisualOverflow() const { return m_overflow ? m_overflow->rightVisualOverflow() : m_x + m_width; }
-    IntRect visualOverflowRect() const { return m_overflow ? m_overflow->visualOverflowRect() : IntRect(m_x, m_y, m_width, height()); }
+    int rightVisualOverflow() const { return m_overflow ? m_overflow->rightVisualOverflow() : m_x + m_logicalWidth; }
+    IntRect visualOverflowRect() const { return m_overflow ? m_overflow->visualOverflowRect() : IntRect(m_x, m_y, m_logicalWidth, logicalHeight()); }
 
     void setHorizontalOverflowPositions(int leftLayoutOverflow, int rightLayoutOverflow, int leftVisualOverflow, int rightVisualOverflow);
     void setVerticalOverflowPositions(int topLayoutOverflow, int bottomLayoutOverflow, int topVisualOverflow, int bottomVisualOverflow, int boxHeight);
@@ -191,9 +191,9 @@ protected:
 inline void InlineFlowBox::setHorizontalOverflowPositions(int leftLayoutOverflow, int rightLayoutOverflow, int leftVisualOverflow, int rightVisualOverflow) 
 { 
     if (!m_overflow) {
-        if (leftLayoutOverflow == m_x && rightLayoutOverflow == m_x + m_width && leftVisualOverflow == m_x && rightVisualOverflow == m_x + m_width)
+        if (leftLayoutOverflow == m_x && rightLayoutOverflow == m_x + m_logicalWidth && leftVisualOverflow == m_x && rightVisualOverflow == m_x + m_logicalWidth)
             return;
-        m_overflow = adoptPtr(new RenderOverflow(IntRect(m_x, m_y, m_width, m_renderer->style(m_firstLine)->font().height())));    
+        m_overflow = adoptPtr(new RenderOverflow(IntRect(m_x, m_y, m_logicalWidth, m_renderer->style(m_firstLine)->font().height())));    
     }
 
     m_overflow->setLeftLayoutOverflow(leftLayoutOverflow);
@@ -207,7 +207,7 @@ inline void InlineFlowBox::setVerticalOverflowPositions(int topLayoutOverflow, i
     if (!m_overflow) {
         if (topLayoutOverflow == m_y && bottomLayoutOverflow == m_y + boxHeight && topVisualOverflow == m_y && bottomVisualOverflow == m_y + boxHeight)
             return;
-        m_overflow = adoptPtr(new RenderOverflow(IntRect(m_x, m_y, m_width, boxHeight)));
+        m_overflow = adoptPtr(new RenderOverflow(IntRect(m_x, m_y, m_logicalWidth, boxHeight)));
     }
 
     m_overflow->setTopLayoutOverflow(topLayoutOverflow);
diff --git a/WebCore/rendering/InlineTextBox.cpp b/WebCore/rendering/InlineTextBox.cpp
index eb5947c..5e968b6 100644
--- a/WebCore/rendering/InlineTextBox.cpp
+++ b/WebCore/rendering/InlineTextBox.cpp
@@ -139,10 +139,10 @@ IntRect InlineTextBox::selectionRect(int tx, int ty, int startPos, int endPos)
 
     IntRect r = enclosingIntRect(f.selectionRectForText(TextRun(characters, len, textObj->allowTabs(), textPos(), m_toAdd, direction() == RTL, m_dirOverride),
                                                         IntPoint(tx + m_x, ty + selTop), selHeight, sPos, ePos));
-    if (r.x() > tx + m_x + m_width)
+    if (r.x() > tx + m_x + m_logicalWidth)
         r.setWidth(0);
-    else if (r.right() - 1 > tx + m_x + m_width)
-        r.setWidth(tx + m_x + m_width - r.x());
+    else if (r.right() - 1 > tx + m_x + m_logicalWidth)
+        r.setWidth(tx + m_x + m_logicalWidth - r.x());
     return r;
 }
 
@@ -182,7 +182,7 @@ int InlineTextBox::placeEllipsisBox(bool flowIsLTR, int visibleLeftEdge, int vis
     // LTR: the left edge of the ellipsis is to the left of our text run.
     // RTL: the right edge of the ellipsis is to the right of our text run.
     bool ltrFullTruncation = flowIsLTR && ellipsisX <= m_x;
-    bool rtlFullTruncation = !flowIsLTR && ellipsisX >= (m_x + m_width);
+    bool rtlFullTruncation = !flowIsLTR && ellipsisX >= (m_x + m_logicalWidth);
     if (ltrFullTruncation || rtlFullTruncation) {
         // Too far.  Just set full truncation, but return -1 and let the ellipsis just be placed at the edge of the box.
         m_truncation = cFullTruncation;
@@ -190,7 +190,7 @@ int InlineTextBox::placeEllipsisBox(bool flowIsLTR, int visibleLeftEdge, int vis
         return -1;
     }
 
-    bool ltrEllipsisWithinBox = flowIsLTR && (ellipsisX < m_x + m_width);
+    bool ltrEllipsisWithinBox = flowIsLTR && (ellipsisX < m_x + m_logicalWidth);
     bool rtlEllipsisWithinBox = !flowIsLTR && (ellipsisX > m_x);
     if (ltrEllipsisWithinBox || rtlEllipsisWithinBox) {
         foundBox = true;
@@ -202,7 +202,7 @@ int InlineTextBox::placeEllipsisBox(bool flowIsLTR, int visibleLeftEdge, int vis
         if (ltr != flowIsLTR) {
           // Width in pixels of the visible portion of the box, excluding the ellipsis.
           int visibleBoxWidth = visibleRightEdge - visibleLeftEdge  - ellipsisWidth;
-          ellipsisX = ltr ? m_x + visibleBoxWidth : m_x + m_width - visibleBoxWidth;
+          ellipsisX = ltr ? m_x + visibleBoxWidth : m_x + m_logicalWidth - visibleBoxWidth;
         }
 
         int offset = offsetForPosition(ellipsisX, false);
@@ -228,7 +228,7 @@ int InlineTextBox::placeEllipsisBox(bool flowIsLTR, int visibleLeftEdge, int vis
         if (flowIsLTR)
             return m_x + widthOfVisibleText;
         else
-            return (m_x + m_width) - widthOfVisibleText - ellipsisWidth;
+            return (m_x + m_logicalWidth) - widthOfVisibleText - ellipsisWidth;
     }
     return -1;
 }
@@ -286,7 +286,7 @@ bool InlineTextBox::nodeAtPoint(const HitTestRequest&, HitTestResult& result, in
     if (isLineBreak())
         return false;
 
-    IntRect rect(tx + m_x, ty + m_y, m_width, height());
+    IntRect rect(tx + m_x, ty + m_y, m_logicalWidth, logicalHeight());
     if (m_truncation != cFullTruncation && visibleToHitTesting() && rect.intersects(result.rectFromPoint(x, y))) {
         renderer()->updateHitTestResult(result, IntPoint(x - tx, y - ty));
         if (!result.addNodeToRectBasedTestResult(renderer()->node(), x, y, rect))
@@ -367,9 +367,9 @@ void InlineTextBox::paint(PaintInfo& paintInfo, int tx, int ty)
     // FIXME: Technically we're potentially incorporating other visual overflow that had nothing to do with us.
     // Would it be simpler to just check our own shadow and stroke overflow by hand here?
     int leftOverflow = parent()->x() - parent()->leftVisualOverflow();
-    int rightOverflow = parent()->rightVisualOverflow() - (parent()->x() + parent()->width());
+    int rightOverflow = parent()->rightVisualOverflow() - (parent()->x() + parent()->logicalWidth());
     int xPos = tx + m_x - leftOverflow;
-    int w = width() + leftOverflow + rightOverflow;
+    int w = logicalWidth() + leftOverflow + rightOverflow;
     if (xPos >= paintInfo.rect.right() || xPos + w <= paintInfo.rect.x())
         return;
 
@@ -393,7 +393,7 @@ void InlineTextBox::paint(PaintInfo& paintInfo, int tx, int ty)
             // NOTE: WebKit's behavior differs from that of IE which appears to just overlay the ellipsis on top of the
             // truncated string i.e.  |Hello|CBA| -> |...lo|CBA|
             int widthOfVisibleText = toRenderText(renderer())->width(m_start, m_truncation, textPos(), m_firstLine);
-            int widthOfHiddenText = m_width - widthOfVisibleText;
+            int widthOfHiddenText = m_logicalWidth - widthOfVisibleText;
             // FIXME: The hit testing logic also needs to take this translation int account.
             tx += direction() == LTR ? widthOfHiddenText : -widthOfHiddenText;
         }
@@ -526,9 +526,9 @@ void InlineTextBox::paint(PaintInfo& paintInfo, int tx, int ty)
         updateGraphicsContext(context, textFillColor, textStrokeColor, textStrokeWidth, styleToUse->colorSpace());
         if (!paintSelectedTextSeparately || ePos <= sPos) {
             // FIXME: Truncate right-to-left text correctly.
-            paintTextWithShadows(context, font, textRun, 0, length, length, textOrigin, m_x + tx, m_y + ty, width(), height(), textShadow, textStrokeWidth > 0);
+            paintTextWithShadows(context, font, textRun, 0, length, length, textOrigin, m_x + tx, m_y + ty, logicalWidth(), logicalHeight(), textShadow, textStrokeWidth > 0);
         } else
-            paintTextWithShadows(context, font, textRun, ePos, sPos, length, textOrigin, m_x + tx, m_y + ty, width(), height(), textShadow, textStrokeWidth > 0);
+            paintTextWithShadows(context, font, textRun, ePos, sPos, length, textOrigin, m_x + tx, m_y + ty, logicalWidth(), logicalHeight(), textShadow, textStrokeWidth > 0);
 
         if (textStrokeWidth > 0)
             context->restore();
@@ -540,7 +540,7 @@ void InlineTextBox::paint(PaintInfo& paintInfo, int tx, int ty)
             context->save();
 
         updateGraphicsContext(context, selectionFillColor, selectionStrokeColor, selectionStrokeWidth, styleToUse->colorSpace());
-        paintTextWithShadows(context, font, textRun, sPos, ePos, length, textOrigin, m_x + tx, m_y + ty, width(), height(), selectionShadow, selectionStrokeWidth > 0);
+        paintTextWithShadows(context, font, textRun, sPos, ePos, length, textOrigin, m_x + tx, m_y + ty, logicalWidth(), logicalHeight(), selectionShadow, selectionStrokeWidth > 0);
 
         if (selectionStrokeWidth > 0)
             context->restore();
@@ -633,7 +633,7 @@ void InlineTextBox::paintSelection(GraphicsContext* context, int tx, int ty, Ren
         ePos = length;
     }
 
-    context->clip(IntRect(m_x + tx, y + ty, m_width, h));
+    context->clip(IntRect(m_x + tx, y + ty, m_logicalWidth, h));
     context->drawHighlightForText(font, TextRun(characters, length, textRenderer()->allowTabs(), textPos(), m_toAdd, 
                                   direction() == RTL, m_dirOverride || style->visuallyOrdered()),
                                   IntPoint(m_x + tx, y + ty), h, c, style->colorSpace(), sPos, ePos);
@@ -675,8 +675,8 @@ void InlineTextBox::paintCustomHighlight(int tx, int ty, const AtomicString& typ
         return;
 
     RootInlineBox* r = root();
-    FloatRect rootRect(tx + r->x(), ty + selectionTop(), r->width(), selectionHeight());
-    FloatRect textRect(tx + x(), rootRect.y(), width(), rootRect.height());
+    FloatRect rootRect(tx + r->x(), ty + selectionTop(), r->logicalWidth(), selectionHeight());
+    FloatRect textRect(tx + x(), rootRect.y(), logicalWidth(), rootRect.height());
 
     page->chrome()->client()->paintCustomHighlight(renderer()->node(), type, textRect, rootRect, true, false);
 }
@@ -691,11 +691,11 @@ void InlineTextBox::paintDecoration(GraphicsContext* context, int tx, int ty, in
     if (m_truncation == cFullTruncation)
         return;
 
-    int width = m_width;
+    int width = m_logicalWidth;
     if (m_truncation != cNoTruncation) {
         width = toRenderText(renderer())->width(m_start, m_truncation, textPos(), m_firstLine);
         if (direction() == RTL)
-            tx += (m_width - width);
+            tx += (m_logicalWidth - width);
     }
     
     // Get the text decoration colors.
@@ -793,7 +793,7 @@ void InlineTextBox::paintSpellingOrGrammarMarker(GraphicsContext* pt, int tx, in
         return;
 
     int start = 0;                  // start of line to draw, relative to tx
-    int width = m_width;            // how much line to draw
+    int width = m_logicalWidth;            // how much line to draw
 
     // Determine whether we need to measure text
     bool markerSpansWholeBox = true;
@@ -837,11 +837,11 @@ void InlineTextBox::paintSpellingOrGrammarMarker(GraphicsContext* pt, int tx, in
     // we pin to two pixels under the baseline.
     int lineThickness = cMisspellingLineThickness;
     int baseline = renderer()->style(m_firstLine)->font().ascent();
-    int descent = height() - baseline;
+    int descent = logicalHeight() - baseline;
     int underlineOffset;
     if (descent <= (2 + lineThickness)) {
         // Place the underline at the very bottom of the text in small/medium fonts.
-        underlineOffset = height() - lineThickness;
+        underlineOffset = logicalHeight() - lineThickness;
     } else {
         // In larger fonts, though, place the underline up near the baseline to prevent a big gap.
         underlineOffset = baseline + 2;
@@ -872,7 +872,7 @@ void InlineTextBox::paintTextMatchMarker(GraphicsContext* pt, int tx, int ty, co
             renderer()->theme()->platformInactiveTextSearchHighlightColor();
         pt->save();
         updateGraphicsContext(pt, color, color, 0, style->colorSpace());  // Don't draw text at all!
-        pt->clip(IntRect(tx + m_x, ty + y, m_width, h));
+        pt->clip(IntRect(tx + m_x, ty + y, m_logicalWidth, h));
         pt->drawHighlightForText(font, run, IntPoint(m_x + tx, y + ty), h, color, style->colorSpace(), sPos, ePos);
         pt->restore();
     }
@@ -969,7 +969,7 @@ void InlineTextBox::paintCompositionUnderline(GraphicsContext* ctx, int tx, int
         return;
     
     int start = 0;                 // start of line to draw, relative to tx
-    int width = m_width;           // how much line to draw
+    int width = m_logicalWidth;           // how much line to draw
     bool useWholeWidth = true;
     unsigned paintStart = m_start;
     unsigned paintEnd = end() + 1; // end points at the last char, not past it
@@ -995,7 +995,7 @@ void InlineTextBox::paintCompositionUnderline(GraphicsContext* ctx, int tx, int
     // If there's not enough space the underline will touch or overlap characters.
     int lineThickness = 1;
     int baseline = renderer()->style(m_firstLine)->font().ascent();
-    if (underline.thick && height() - baseline >= 2)
+    if (underline.thick && logicalHeight() - baseline >= 2)
         lineThickness = 2;
 
     // We need to have some space between underlines of subsequent clauses, because some input methods do not use different underline styles for those.
@@ -1005,7 +1005,7 @@ void InlineTextBox::paintCompositionUnderline(GraphicsContext* ctx, int tx, int
 
     ctx->setStrokeColor(underline.color, renderer()->style()->colorSpace());
     ctx->setStrokeThickness(lineThickness);
-    ctx->drawLineForText(IntPoint(tx + start, ty + height() - lineThickness), width, textRenderer()->document()->printing());
+    ctx->drawLineForText(IntPoint(tx + start, ty + logicalHeight() - lineThickness), width, textRenderer()->document()->printing());
 }
 
 int InlineTextBox::caretMinOffset() const
diff --git a/WebCore/rendering/InlineTextBox.h b/WebCore/rendering/InlineTextBox.h
index 7d828f3..2bf099b 100644
--- a/WebCore/rendering/InlineTextBox.h
+++ b/WebCore/rendering/InlineTextBox.h
@@ -74,7 +74,7 @@ private:
     virtual int selectionHeight();
 
 public:
-    virtual IntRect calculateBoundaries() const { return IntRect(x(), y(), width(), height()); }
+    virtual IntRect calculateBoundaries() const { return IntRect(x(), y(), logicalWidth(), logicalHeight()); }
 
     virtual IntRect selectionRect(int absx, int absy, int startPos, int endPos);
     bool isSelected(int startPos, int endPos) const;
@@ -102,7 +102,7 @@ private:
 public:
     virtual bool isLineBreak() const;
 
-    void setSpaceAdd(int add) { m_width -= m_toAdd; m_toAdd = add; m_width += m_toAdd; }
+    void setSpaceAdd(int add) { m_logicalWidth -= m_toAdd; m_toAdd = add; m_logicalWidth += m_toAdd; }
 
 private:
     virtual bool isInlineTextBox() const { return true; }    
diff --git a/WebCore/rendering/RenderBlock.cpp b/WebCore/rendering/RenderBlock.cpp
index 791a01a..d3dc001 100644
--- a/WebCore/rendering/RenderBlock.cpp
+++ b/WebCore/rendering/RenderBlock.cpp
@@ -2400,7 +2400,7 @@ void RenderBlock::paintEllipsisBoxes(PaintInfo& paintInfo, int tx, int ty)
         // We can check the first box and last box and avoid painting if we don't
         // intersect.
         int yPos = ty + firstLineBox()->y();
-        int h = lastLineBox()->y() + lastLineBox()->height() - firstLineBox()->y();
+        int h = lastLineBox()->y() + lastLineBox()->logicalHeight() - firstLineBox()->y();
         if (yPos >= paintInfo.rect.bottom() || yPos + h <= paintInfo.rect.y())
             return;
 
@@ -2409,7 +2409,7 @@ void RenderBlock::paintEllipsisBoxes(PaintInfo& paintInfo, int tx, int ty)
         // based off positions of our first line box or our last line box.
         for (RootInlineBox* curr = firstRootBox(); curr; curr = curr->nextRootBox()) {
             yPos = ty + curr->y();
-            h = curr->height();
+            h = curr->logicalHeight();
             if (curr->ellipsisBox() && yPos < paintInfo.rect.bottom() && yPos + h > paintInfo.rect.y())
                 curr->paintEllipsisBox(paintInfo, tx, ty);
         }
@@ -3477,7 +3477,7 @@ int RenderBlock::rightmostPosition(bool includeOverflowInterior, bool includeSel
         right = max(right, borderLeft() + paddingLeft() + paddingRight() + relativeOffset);
         if (childrenInline()) {
             for (InlineFlowBox* currBox = firstLineBox(); currBox; currBox = currBox->nextLineBox()) {
-                int childRightEdge = currBox->x() + currBox->width();
+                int childRightEdge = currBox->x() + currBox->logicalWidth();
                 
                 // If this node is a root editable element, then the rightmostPosition should account for a caret at the end.
                 // FIXME: Need to find another way to do this, since scrollbars could show when we don't want them to.
@@ -5519,7 +5519,7 @@ void RenderBlock::adjustForBorderFit(int x, int& left, int& right) const
                 if (box->firstChild())
                     left = min(left, x + box->firstChild()->x());
                 if (box->lastChild())
-                    right = max(right, x + box->lastChild()->x() + box->lastChild()->width());
+                    right = max(right, x + box->lastChild()->x() + box->lastChild()->logicalWidth());
             }
         }
         else {
@@ -5814,8 +5814,8 @@ void RenderBlock::addFocusRingRects(Vector<IntRect>& rects, int tx, int ty)
     if (!hasOverflowClip() && !hasControlClip()) {
         for (RootInlineBox* curr = firstRootBox(); curr; curr = curr->nextRootBox()) {
             int top = max(curr->lineTop(), curr->y());
-            int bottom = min(curr->lineBottom(), curr->y() + curr->height());
-            IntRect rect(tx + curr->x(), ty + top, curr->width(), bottom - top);
+            int bottom = min(curr->lineBottom(), curr->y() + curr->logicalHeight());
+            IntRect rect(tx + curr->x(), ty + top, curr->logicalWidth(), bottom - top);
             if (!rect.isEmpty())
                 rects.append(rect);
         }
diff --git a/WebCore/rendering/RenderBlockLineLayout.cpp b/WebCore/rendering/RenderBlockLineLayout.cpp
index 135185c..e103bd2 100644
--- a/WebCore/rendering/RenderBlockLineLayout.cpp
+++ b/WebCore/rendering/RenderBlockLineLayout.cpp
@@ -358,7 +358,7 @@ void RenderBlock::computeHorizontalPositionsForLine(RootInlineBox* lineBox, bool
                 const AtomicString& hyphenString = rt->style()->hyphenString();
                 hyphenWidth = rt->style(firstLine)->font().width(TextRun(hyphenString.characters(), hyphenString.length()));
             }
-            r->m_box->setWidth(rt->width(r->m_start, r->m_stop - r->m_start, totWidth, firstLine, &fallbackFonts, &glyphOverflow) + hyphenWidth);
+            r->m_box->setLogicalWidth(rt->width(r->m_start, r->m_stop - r->m_start, totWidth, firstLine, &fallbackFonts, &glyphOverflow) + hyphenWidth);
             if (!fallbackFonts.isEmpty()) {
                 ASSERT(r->m_box->isText());
                 GlyphOverflowAndFallbackFontsMap::iterator it = textBoxDataMap.add(static_cast<InlineTextBox*>(r->m_box), make_pair(Vector<const SimpleFontData*>(), GlyphOverflow())).first;
@@ -373,11 +373,11 @@ void RenderBlock::computeHorizontalPositionsForLine(RootInlineBox* lineBox, bool
         } else if (!r->m_object->isRenderInline()) {
             RenderBox* renderBox = toRenderBox(r->m_object);
             renderBox->calcWidth();
-            r->m_box->setWidth(renderBox->width());
+            r->m_box->setLogicalWidth(renderBox->width());
             totWidth += renderBox->marginLeft() + renderBox->marginRight();
         }
 
-        totWidth += r->m_box->width();
+        totWidth += r->m_box->logicalWidth();
     }
 
     // Armed with the total width of the line (without justification),
@@ -392,10 +392,10 @@ void RenderBlock::computeHorizontalPositionsForLine(RootInlineBox* lineBox, bool
             // particular with RTL blocks, wide lines should still spill out to the left.
             if (style()->direction() == LTR) {
                 if (totWidth > availableWidth && trailingSpaceRun)
-                    trailingSpaceRun->m_box->setWidth(max(0, trailingSpaceRun->m_box->width() - totWidth + availableWidth));
+                    trailingSpaceRun->m_box->setLogicalWidth(max(0, trailingSpaceRun->m_box->logicalWidth() - totWidth + availableWidth));
             } else {
                 if (trailingSpaceRun)
-                    trailingSpaceRun->m_box->setWidth(0);
+                    trailingSpaceRun->m_box->setLogicalWidth(0);
                 else if (totWidth > availableWidth)
                     x -= (totWidth - availableWidth);
             }
@@ -403,8 +403,8 @@ void RenderBlock::computeHorizontalPositionsForLine(RootInlineBox* lineBox, bool
         case JUSTIFY:
             if (numSpaces && !reachedEnd && !lineBox->endsWithBreak()) {
                 if (trailingSpaceRun) {
-                    totWidth -= trailingSpaceRun->m_box->width();
-                    trailingSpaceRun->m_box->setWidth(0);
+                    totWidth -= trailingSpaceRun->m_box->logicalWidth();
+                    trailingSpaceRun->m_box->setLogicalWidth(0);
                 }
                 break;
             }
@@ -414,7 +414,7 @@ void RenderBlock::computeHorizontalPositionsForLine(RootInlineBox* lineBox, bool
             // for right to left fall through to right aligned
             if (style()->direction() == LTR) {
                 if (totWidth > availableWidth && trailingSpaceRun)
-                    trailingSpaceRun->m_box->setWidth(max(0, trailingSpaceRun->m_box->width() - totWidth + availableWidth));
+                    trailingSpaceRun->m_box->setLogicalWidth(max(0, trailingSpaceRun->m_box->logicalWidth() - totWidth + availableWidth));
                 break;
             }
         case RIGHT:
@@ -424,15 +424,15 @@ void RenderBlock::computeHorizontalPositionsForLine(RootInlineBox* lineBox, bool
             // side of the block.
             if (style()->direction() == LTR) {
                 if (trailingSpaceRun) {
-                    totWidth -= trailingSpaceRun->m_box->width();
-                    trailingSpaceRun->m_box->setWidth(0);
+                    totWidth -= trailingSpaceRun->m_box->logicalWidth();
+                    trailingSpaceRun->m_box->setLogicalWidth(0);
                 }
                 if (totWidth < availableWidth)
                     x += availableWidth - totWidth;
             } else {
                 if (totWidth > availableWidth && trailingSpaceRun) {
-                    trailingSpaceRun->m_box->setWidth(max(0, trailingSpaceRun->m_box->width() - totWidth + availableWidth));
-                    totWidth -= trailingSpaceRun->m_box->width();
+                    trailingSpaceRun->m_box->setLogicalWidth(max(0, trailingSpaceRun->m_box->logicalWidth() - totWidth + availableWidth));
+                    totWidth -= trailingSpaceRun->m_box->logicalWidth();
                 } else
                     x += availableWidth - totWidth;
             }
@@ -441,9 +441,9 @@ void RenderBlock::computeHorizontalPositionsForLine(RootInlineBox* lineBox, bool
         case WEBKIT_CENTER:
             int trailingSpaceWidth = 0;
             if (trailingSpaceRun) {
-                totWidth -= trailingSpaceRun->m_box->width();
-                trailingSpaceWidth = min(trailingSpaceRun->m_box->width(), (availableWidth - totWidth + 1) / 2);
-                trailingSpaceRun->m_box->setWidth(max(0, trailingSpaceWidth));
+                totWidth -= trailingSpaceRun->m_box->logicalWidth();
+                trailingSpaceWidth = min(trailingSpaceRun->m_box->logicalWidth(), (availableWidth - totWidth + 1) / 2);
+                trailingSpaceRun->m_box->setLogicalWidth(max(0, trailingSpaceWidth));
             }
             if (style()->direction() == LTR)
                 x += max((availableWidth - totWidth) / 2, 0);
@@ -2104,7 +2104,7 @@ void RenderBlock::checkLinesForTextOverflow()
     for (RootInlineBox* curr = firstRootBox(); curr; curr = curr->nextRootBox()) {
         int blockRightEdge = rightOffset(curr->y(), curr == firstRootBox());
         int blockLeftEdge = leftOffset(curr->y(), curr == firstRootBox());
-        int lineBoxEdge = ltr ? curr->x() + curr->width() : curr->x();
+        int lineBoxEdge = ltr ? curr->x() + curr->logicalWidth() : curr->x();
         if ((ltr && lineBoxEdge > blockRightEdge) || (!ltr && lineBoxEdge < blockLeftEdge)) {
             // This line spills out of our box in the appropriate direction.  Now we need to see if the line
             // can be truncated.  In order for truncation to be possible, the line must have sufficient space to
diff --git a/WebCore/rendering/RenderBox.cpp b/WebCore/rendering/RenderBox.cpp
index 1dc4bfa..5c1489a 100644
--- a/WebCore/rendering/RenderBox.cpp
+++ b/WebCore/rendering/RenderBox.cpp
@@ -929,7 +929,7 @@ void RenderBox::paintCustomHighlight(int tx, int ty, const AtomicString& type, b
     InlineBox* boxWrap = inlineBoxWrapper();
     RootInlineBox* r = boxWrap ? boxWrap->root() : 0;
     if (r) {
-        FloatRect rootRect(tx + r->x(), ty + r->selectionTop(), r->width(), r->selectionHeight());
+        FloatRect rootRect(tx + r->x(), ty + r->selectionTop(), r->logicalWidth(), r->selectionHeight());
         FloatRect imageRect(tx + x(), rootRect.y(), width(), rootRect.height());
         page->chrome()->client()->paintCustomHighlight(node(), type, imageRect, rootRect, behindText, false);
     } else {
@@ -1856,9 +1856,9 @@ int RenderBox::containingBlockWidthForPositioned(const RenderBoxModelObject* con
     int fromRight;
     if (containingBlock->style()->direction() == LTR) {
         fromLeft = first->x() + first->borderLeft();
-        fromRight = last->x() + last->width() - last->borderRight();
+        fromRight = last->x() + last->logicalWidth() - last->borderRight();
     } else {
-        fromRight = first->x() + first->width() - first->borderRight();
+        fromRight = first->x() + first->logicalWidth() - first->borderRight();
         fromLeft = last->x() + last->borderLeft();
     }
 
diff --git a/WebCore/rendering/RenderFlexibleBox.cpp b/WebCore/rendering/RenderFlexibleBox.cpp
index 36ab375..f6ce243 100644
--- a/WebCore/rendering/RenderFlexibleBox.cpp
+++ b/WebCore/rendering/RenderFlexibleBox.cpp
@@ -993,7 +993,7 @@ void RenderFlexibleBox::applyLineClamp(FlexBoxIterator& iterator, bool relayoutC
             int totalWidth;
             InlineBox* anchorBox = lastLine->lastChild();
             if (anchorBox && anchorBox->renderer()->node() && anchorBox->renderer()->node()->isLink())
-                totalWidth = anchorBox->width() + font.width(TextRun(ellipsisAndSpace, 2));
+                totalWidth = anchorBox->logicalWidth() + font.width(TextRun(ellipsisAndSpace, 2));
             else {
                 anchorBox = 0;
                 totalWidth = font.width(TextRun(&horizontalEllipsis, 1));
@@ -1015,7 +1015,7 @@ void RenderFlexibleBox::applyLineClamp(FlexBoxIterator& iterator, bool relayoutC
             
             int blockEdge = ltr ? blockRightEdge : blockLeftEdge;
             if (!lastVisibleLine->canAccommodateEllipsis(ltr, blockEdge,
-                                                         lastVisibleLine->x() + lastVisibleLine->width(),
+                                                         lastVisibleLine->x() + lastVisibleLine->logicalWidth(),
                                                          totalWidth))
                 continue;
             
diff --git a/WebCore/rendering/RenderInline.cpp b/WebCore/rendering/RenderInline.cpp
index 1bee4e7..b4bfe2f 100644
--- a/WebCore/rendering/RenderInline.cpp
+++ b/WebCore/rendering/RenderInline.cpp
@@ -413,7 +413,7 @@ void RenderInline::absoluteRects(Vector<IntRect>& rects, int tx, int ty)
 {
     if (InlineFlowBox* curr = firstLineBox()) {
         for (; curr; curr = curr->nextLineBox())
-            rects.append(IntRect(tx + curr->x(), ty + curr->y(), curr->width(), curr->height()));
+            rects.append(IntRect(tx + curr->x(), ty + curr->y(), curr->logicalWidth(), curr->logicalHeight()));
     } else
         rects.append(IntRect(tx, ty, 0, 0));
 
@@ -432,7 +432,7 @@ void RenderInline::absoluteQuads(Vector<FloatQuad>& quads)
 {
     if (InlineFlowBox* curr = firstLineBox()) {
         for (; curr; curr = curr->nextLineBox()) {
-            FloatRect localRect(curr->x(), curr->y(), curr->width(), curr->height());
+            FloatRect localRect(curr->x(), curr->y(), curr->logicalWidth(), curr->logicalHeight());
             quads.append(localToAbsoluteQuad(localRect));
         }
     } else
@@ -563,12 +563,12 @@ IntRect RenderInline::linesBoundingBox() const
         for (InlineFlowBox* curr = firstLineBox(); curr; curr = curr->nextLineBox()) {
             if (curr == firstLineBox() || curr->x() < leftSide)
                 leftSide = curr->x();
-            if (curr == firstLineBox() || curr->x() + curr->width() > rightSide)
-                rightSide = curr->x() + curr->width();
+            if (curr == firstLineBox() || curr->x() + curr->logicalWidth() > rightSide)
+                rightSide = curr->x() + curr->logicalWidth();
         }
         result.setWidth(rightSide - leftSide);
         result.setX(leftSide);
-        result.setHeight(lastLineBox()->y() + lastLineBox()->height() - firstLineBox()->y());
+        result.setHeight(lastLineBox()->y() + lastLineBox()->logicalHeight() - firstLineBox()->y());
         result.setY(firstLineBox()->y());
     }
 
@@ -956,8 +956,8 @@ void RenderInline::addFocusRingRects(Vector<IntRect>& rects, int tx, int ty)
     for (InlineFlowBox* curr = firstLineBox(); curr; curr = curr->nextLineBox()) {
         RootInlineBox* root = curr->root();
         int top = max(root->lineTop(), curr->y());
-        int bottom = min(root->lineBottom(), curr->y() + curr->height());
-        IntRect rect(tx + curr->x(), ty + top, curr->width(), bottom - top);
+        int bottom = min(root->lineBottom(), curr->y() + curr->logicalHeight());
+        IntRect rect(tx + curr->x(), ty + top, curr->logicalWidth(), bottom - top);
         if (!rect.isEmpty())
             rects.append(rect);
     }
@@ -1013,8 +1013,8 @@ void RenderInline::paintOutline(GraphicsContext* graphicsContext, int tx, int ty
     for (InlineFlowBox* curr = firstLineBox(); curr; curr = curr->nextLineBox()) {
         RootInlineBox* root = curr->root();
         int top = max(root->lineTop(), curr->y());
-        int bottom = min(root->lineBottom(), curr->y() + curr->height());
-        rects.append(IntRect(curr->x(), top, curr->width(), bottom - top));
+        int bottom = min(root->lineBottom(), curr->y() + curr->logicalHeight());
+        rects.append(IntRect(curr->x(), top, curr->logicalWidth(), bottom - top));
     }
     rects.append(IntRect());
 
diff --git a/WebCore/rendering/RenderSVGInline.cpp b/WebCore/rendering/RenderSVGInline.cpp
index bc6bc12..5d12a61 100644
--- a/WebCore/rendering/RenderSVGInline.cpp
+++ b/WebCore/rendering/RenderSVGInline.cpp
@@ -39,7 +39,7 @@ RenderSVGInline::RenderSVGInline(Node* n)
 InlineFlowBox* RenderSVGInline::createInlineFlowBox()
 {
     InlineFlowBox* box = new (renderArena()) SVGInlineFlowBox(this);
-    box->setHasVirtualHeight();
+    box->setHasVirtualLogicalHeight();
     return box;
 }
 
@@ -90,7 +90,7 @@ void RenderSVGInline::absoluteQuads(Vector<FloatQuad>& quads)
 
     FloatRect textBoundingBox = object->strokeBoundingBox();
     for (InlineFlowBox* box = firstLineBox(); box; box = box->nextLineBox())
-        quads.append(localToAbsoluteQuad(FloatRect(textBoundingBox.x() + box->x(), textBoundingBox.y() + box->y(), box->width(), box->height())));
+        quads.append(localToAbsoluteQuad(FloatRect(textBoundingBox.x() + box->x(), textBoundingBox.y() + box->y(), box->logicalWidth(), box->logicalHeight())));
 }
 
 void RenderSVGInline::destroy()
diff --git a/WebCore/rendering/RenderSVGInlineText.cpp b/WebCore/rendering/RenderSVGInlineText.cpp
index 0539d27..f5ea5fc 100644
--- a/WebCore/rendering/RenderSVGInlineText.cpp
+++ b/WebCore/rendering/RenderSVGInlineText.cpp
@@ -56,7 +56,7 @@ void RenderSVGInlineText::styleDidChange(StyleDifference diff, const RenderStyle
 InlineTextBox* RenderSVGInlineText::createTextBox()
 {
     InlineTextBox* box = new (renderArena()) SVGInlineTextBox(this);
-    box->setHasVirtualHeight();
+    box->setHasVirtualLogicalHeight();
     return box;
 }
 
diff --git a/WebCore/rendering/RenderSVGText.cpp b/WebCore/rendering/RenderSVGText.cpp
index c20a509..804bc98 100644
--- a/WebCore/rendering/RenderSVGText.cpp
+++ b/WebCore/rendering/RenderSVGText.cpp
@@ -124,7 +124,7 @@ void RenderSVGText::layout()
 RootInlineBox* RenderSVGText::createRootInlineBox() 
 {
     RootInlineBox* box = new (renderArena()) SVGRootInlineBox(this);
-    box->setHasVirtualHeight();
+    box->setHasVirtualLogicalHeight();
     return box;
 }
 
diff --git a/WebCore/rendering/RenderText.cpp b/WebCore/rendering/RenderText.cpp
index d786e6a..2d386d2 100644
--- a/WebCore/rendering/RenderText.cpp
+++ b/WebCore/rendering/RenderText.cpp
@@ -263,7 +263,7 @@ PassRefPtr<StringImpl> RenderText::originalText() const
 void RenderText::absoluteRects(Vector<IntRect>& rects, int tx, int ty)
 {
     for (InlineTextBox* box = firstTextBox(); box; box = box->nextTextBox())
-        rects.append(IntRect(tx + box->x(), ty + box->y(), box->width(), box->height()));
+        rects.append(IntRect(tx + box->x(), ty + box->y(), box->logicalWidth(), box->logicalHeight()));
 }
 
 void RenderText::absoluteRectsForRange(Vector<IntRect>& rects, unsigned start, unsigned end, bool useSelectionHeight)
@@ -281,7 +281,7 @@ void RenderText::absoluteRectsForRange(Vector<IntRect>& rects, unsigned start, u
     for (InlineTextBox* box = firstTextBox(); box; box = box->nextTextBox()) {
         // Note: box->end() returns the index of the last character, not the index past it
         if (start <= box->start() && box->end() < end) {
-            IntRect r = IntRect(box->x(), box->y(), box->width(), box->height());
+            IntRect r = IntRect(box->x(), box->y(), box->logicalWidth(), box->logicalHeight());
             if (useSelectionHeight) {
                 IntRect selectionRect = box->selectionRect(0, 0, start, end);
                 r.setHeight(selectionRect.height());
@@ -297,7 +297,7 @@ void RenderText::absoluteRectsForRange(Vector<IntRect>& rects, unsigned start, u
             if (!r.isEmpty()) {
                 if (!useSelectionHeight) {
                     // change the height and y position because selectionRect uses selection-specific values
-                    r.setHeight(box->height());
+                    r.setHeight(box->logicalHeight());
                     r.setY(box->y());
                 }
                 FloatPoint origin = localToAbsolute(r.location());
@@ -380,7 +380,7 @@ void RenderText::absoluteQuadsForRange(Vector<FloatQuad>& quads, unsigned start,
             if (r.height()) {
                 if (!useSelectionHeight) {
                     // change the height and y position because selectionRect uses selection-specific values
-                    r.setHeight(box->height());
+                    r.setHeight(box->logicalHeight());
                     r.setY(box->y());
                 }
                 quads.append(localToAbsoluteQuad(FloatRect(r)));
@@ -425,7 +425,7 @@ VisiblePosition RenderText::positionForPoint(const IntPoint& point)
         offset = firstTextBox()->offsetForPosition(point.x());
         return createVisiblePosition(offset + firstTextBox()->start(), DOWNSTREAM);
     }
-    if (lastTextBox() && point.y() >= lastTextBox()->root()->lineTop() && point.x() >= lastTextBox()->m_x + lastTextBox()->m_width) {
+    if (lastTextBox() && point.y() >= lastTextBox()->root()->lineTop() && point.x() >= lastTextBox()->m_x + lastTextBox()->logicalWidth()) {
         // at the y coordinate of the last line or below
         // and the x coordinate is to the right of the last text box right edge
         offset = lastTextBox()->offsetForPosition(point.x());
@@ -444,7 +444,7 @@ VisiblePosition RenderText::positionForPoint(const IntPoint& point)
                     // the affinity must be downstream so the position doesn't jump back to the previous line
                     return createVisiblePosition(offset + box->start(), DOWNSTREAM);
 
-                if (point.x() < box->m_x + box->m_width)
+                if (point.x() < box->m_x + box->logicalWidth())
                     // and the x coordinate is to the left of the right edge of this box
                     // check to see if position goes in this box
                     return createVisiblePosition(offset + box->start(), offset > 0 ? VP_UPSTREAM_IF_POSSIBLE : DOWNSTREAM);
@@ -489,11 +489,11 @@ IntRect RenderText::localCaretRect(InlineBox* inlineBox, int caretOffset, int* e
     int caretWidthRightOfOffset = caretWidth - caretWidthLeftOfOffset;
 
     int rootLeft = box->root()->x();
-    int rootRight = rootLeft + box->root()->width();
+    int rootRight = rootLeft + box->root()->logicalWidth();
     // FIXME: should we use the width of the root inline box or the
     // width of the containing block for this?
     if (extraWidthToEndOfLine)
-        *extraWidthToEndOfLine = (box->root()->width() + rootLeft) - (left + 1);
+        *extraWidthToEndOfLine = (box->root()->logicalWidth() + rootLeft) - (left + 1);
 
     RenderBlock* cb = containingBlock();
     RenderStyle* cbStyle = cb->style();
@@ -1277,12 +1277,12 @@ IntRect RenderText::linesBoundingBox() const
         for (InlineTextBox* curr = firstTextBox(); curr; curr = curr->nextTextBox()) {
             if (curr == firstTextBox() || curr->x() < leftSide)
                 leftSide = curr->x();
-            if (curr == firstTextBox() || curr->x() + curr->width() > rightSide)
-                rightSide = curr->x() + curr->width();
+            if (curr == firstTextBox() || curr->x() + curr->logicalWidth() > rightSide)
+                rightSide = curr->x() + curr->logicalWidth();
         }
         result.setWidth(rightSide - leftSide);
         result.setX(leftSide);
-        result.setHeight(lastTextBox()->y() + lastTextBox()->height() - firstTextBox()->y());
+        result.setHeight(lastTextBox()->y() + lastTextBox()->logicalHeight() - firstTextBox()->y());
         result.setY(firstTextBox()->y());
     }
 
diff --git a/WebCore/rendering/RenderTreeAsText.cpp b/WebCore/rendering/RenderTreeAsText.cpp
index 8b3732b..ab6247b 100644
--- a/WebCore/rendering/RenderTreeAsText.cpp
+++ b/WebCore/rendering/RenderTreeAsText.cpp
@@ -439,7 +439,7 @@ static void writeTextRun(TextStream& ts, const RenderText& o, const InlineTextBo
     int y = run.m_y;
     if (o.containingBlock()->isTableCell())
         y -= toRenderTableCell(o.containingBlock())->intrinsicPaddingBefore();
-    ts << "text run at (" << run.m_x << "," << y << ") width " << run.m_width;
+    ts << "text run at (" << run.m_x << "," << y << ") width " << run.m_logicalWidth;
     if (run.direction() == RTL || run.m_dirOverride) {
         ts << (run.direction() == RTL ? " RTL" : " LTR");
         if (run.m_dirOverride)
diff --git a/WebCore/rendering/RootInlineBox.cpp b/WebCore/rendering/RootInlineBox.cpp
index e8f24b5..355a6be 100644
--- a/WebCore/rendering/RootInlineBox.cpp
+++ b/WebCore/rendering/RootInlineBox.cpp
@@ -72,7 +72,7 @@ bool RootInlineBox::canAccommodateEllipsis(bool ltr, int blockEdge, int lineBoxE
 {
     // First sanity-check the unoverflowed width of the whole line to see if there is sufficient room.
     int delta = ltr ? lineBoxEdge - blockEdge : blockEdge - lineBoxEdge;
-    if (width() - delta < ellipsisWidth)
+    if (logicalWidth() - delta < ellipsisWidth)
         return false;
 
     // Next iterate over all the line boxes on the line.  If we find a replaced element that intersects
@@ -85,7 +85,7 @@ void RootInlineBox::placeEllipsis(const AtomicString& ellipsisStr,  bool ltr, in
 {
     // Create an ellipsis box.
     EllipsisBox* ellipsisBox = new (renderer()->renderArena()) EllipsisBox(renderer(), ellipsisStr, this,
-                                                              ellipsisWidth - (markupBox ? markupBox->width() : 0), height(),
+                                                              ellipsisWidth - (markupBox ? markupBox->logicalWidth() : 0), logicalHeight(),
                                                               y(), !prevRootBox(),
                                                               markupBox);
     
@@ -95,8 +95,8 @@ void RootInlineBox::placeEllipsis(const AtomicString& ellipsisStr,  bool ltr, in
     setHasEllipsisBox(true);
 
     // FIXME: Do we need an RTL version of this?
-    if (ltr && (x() + width() + ellipsisWidth) <= blockRightEdge) {
-        ellipsisBox->m_x = x() + width();
+    if (ltr && (x() + logicalWidth() + ellipsisWidth) <= blockRightEdge) {
+        ellipsisBox->m_x = x() + logicalWidth();
         return;
     }
 
@@ -134,10 +134,10 @@ void RootInlineBox::addHighlightOverflow()
         return;
 
     // Highlight acts as a selection inflation.
-    FloatRect rootRect(0, selectionTop(), width(), selectionHeight());
+    FloatRect rootRect(0, selectionTop(), logicalWidth(), selectionHeight());
     IntRect inflatedRect = enclosingIntRect(page->chrome()->client()->customHighlightRect(renderer()->node(), renderer()->style()->highlight(), rootRect));
     setHorizontalOverflowPositions(leftLayoutOverflow(), rightLayoutOverflow(), min(leftVisualOverflow(), inflatedRect.x()), max(rightVisualOverflow(), inflatedRect.right()));
-    setVerticalOverflowPositions(topLayoutOverflow(), bottomLayoutOverflow(), min(topVisualOverflow(), inflatedRect.y()), max(bottomVisualOverflow(), inflatedRect.bottom()), height());
+    setVerticalOverflowPositions(topLayoutOverflow(), bottomLayoutOverflow(), min(topVisualOverflow(), inflatedRect.y()), max(bottomVisualOverflow(), inflatedRect.bottom()), logicalHeight());
 }
 
 void RootInlineBox::paintCustomHighlight(PaintInfo& paintInfo, int tx, int ty, const AtomicString& highlightType)
@@ -153,7 +153,7 @@ void RootInlineBox::paintCustomHighlight(PaintInfo& paintInfo, int tx, int ty, c
         return;
 
     // Get the inflated rect so that we can properly hit test.
-    FloatRect rootRect(tx + x(), ty + selectionTop(), width(), selectionHeight());
+    FloatRect rootRect(tx + x(), ty + selectionTop(), logicalWidth(), selectionHeight());
     FloatRect inflatedRect = page->chrome()->client()->customHighlightRect(renderer()->node(), highlightType, rootRect);
     if (inflatedRect.intersects(paintInfo.rect))
         page->chrome()->client()->paintCustomHighlight(renderer()->node(), highlightType, rootRect, rootRect, false, true);
@@ -253,7 +253,7 @@ GapRects RootInlineBox::fillLineSelectionGap(int selTop, int selHeight, RenderBl
                                                        rootBlock, blockX, blockY, tx, ty, paintInfo));
     if (rightGap)
         result.uniteRight(block()->fillRightSelectionGap(lastBox->parent()->renderer(),
-                                                         lastBox->x() + lastBox->width(), selTop, selHeight,
+                                                         lastBox->x() + lastBox->logicalWidth(), selTop, selHeight,
                                                          rootBlock, blockX, blockY, tx, ty, paintInfo));
 
     // When dealing with bidi text, a non-contiguous selection region is possible.
@@ -265,7 +265,7 @@ GapRects RootInlineBox::fillLineSelectionGap(int selTop, int selHeight, RenderBl
     // We can see that the |bbb| run is not part of the selection while the runs around it are.
     if (firstBox && firstBox != lastBox) {
         // Now fill in any gaps on the line that occurred between two selected elements.
-        int lastX = firstBox->x() + firstBox->width();
+        int lastX = firstBox->x() + firstBox->logicalWidth();
         bool isPreviousBoxSelected = firstBox->selectionState() != RenderObject::SelectionNone;
         for (InlineBox* box = firstBox->nextLeafChild(); box; box = box->nextLeafChild()) {
             if (box->selectionState() != RenderObject::SelectionNone) {
@@ -273,7 +273,7 @@ GapRects RootInlineBox::fillLineSelectionGap(int selTop, int selHeight, RenderBl
                     result.uniteCenter(block()->fillHorizontalSelectionGap(box->parent()->renderer(),
                                                                            lastX + tx, selTop + ty,
                                                                            box->x() - lastX, selHeight, paintInfo));
-                lastX = box->x() + box->width();
+                lastX = box->x() + box->logicalWidth();
             }
             if (box == lastBox)
                 break;
@@ -376,7 +376,7 @@ InlineBox* RootInlineBox::closestLeafChildForXPos(int x, bool onlyEditableLeaves
         // Return it.
         return firstLeaf;
 
-    if (x >= lastLeaf->m_x + lastLeaf->m_width && !lastLeaf->renderer()->isListMarker() && (!onlyEditableLeaves || isEditableLeaf(lastLeaf)))
+    if (x >= lastLeaf->m_x + lastLeaf->m_logicalWidth && !lastLeaf->renderer()->isListMarker() && (!onlyEditableLeaves || isEditableLeaf(lastLeaf)))
         // The x coordinate is greater or equal to right edge of the lastLeaf.
         // Return it.
         return lastLeaf;
@@ -385,7 +385,7 @@ InlineBox* RootInlineBox::closestLeafChildForXPos(int x, bool onlyEditableLeaves
     for (InlineBox* leaf = firstLeaf; leaf; leaf = leaf->nextLeafChild()) {
         if (!leaf->renderer()->isListMarker() && (!onlyEditableLeaves || isEditableLeaf(leaf))) {
             closestLeaf = leaf;
-            if (x < leaf->m_x + leaf->m_width)
+            if (x < leaf->m_x + leaf->m_logicalWidth)
                 // The x coordinate is less than the right edge of the box.
                 // Return it.
                 return leaf;
diff --git a/WebCore/rendering/SVGInlineFlowBox.h b/WebCore/rendering/SVGInlineFlowBox.h
index ab26297..80600f7 100644
--- a/WebCore/rendering/SVGInlineFlowBox.h
+++ b/WebCore/rendering/SVGInlineFlowBox.h
@@ -33,12 +33,12 @@ class SVGInlineFlowBox : public InlineFlowBox {
 public:
     SVGInlineFlowBox(RenderObject* obj)
         : InlineFlowBox(obj)
-        , m_height(0)
+        , m_logicalHeight(0)
     {
     }
 
-    virtual int virtualHeight() const { return m_height; }
-    void setHeight(int h) { m_height = h; }
+    virtual int virtualLogicalHeight() const { return m_logicalHeight; }
+    void setLogicalHeight(int h) { m_logicalHeight = h; }
 
     virtual void paint(PaintInfo&, int tx, int ty);
 
@@ -46,7 +46,7 @@ public:
     void layoutFlowBox();
 
 private:
-    int m_height;
+    int m_logicalHeight;
 };
 
 } // namespace WebCore
diff --git a/WebCore/rendering/SVGInlineTextBox.cpp b/WebCore/rendering/SVGInlineTextBox.cpp
index ccba5b4..c367598 100644
--- a/WebCore/rendering/SVGInlineTextBox.cpp
+++ b/WebCore/rendering/SVGInlineTextBox.cpp
@@ -40,7 +40,7 @@ namespace WebCore {
 
 SVGInlineTextBox::SVGInlineTextBox(RenderObject* object)
     : InlineTextBox(object)
-    , m_height(0)
+    , m_logicalHeight(0)
     , m_paintingResource(0)
     , m_paintingResourceMode(ApplyToDefaultMode)
 {
diff --git a/WebCore/rendering/SVGInlineTextBox.h b/WebCore/rendering/SVGInlineTextBox.h
index 7711db4..24957cf 100644
--- a/WebCore/rendering/SVGInlineTextBox.h
+++ b/WebCore/rendering/SVGInlineTextBox.h
@@ -42,11 +42,11 @@ public:
 
     virtual bool isSVGInlineTextBox() const { return true; }
 
-    virtual int virtualHeight() const { return m_height; }
-    void setHeight(int height) { m_height = height; }
+    virtual int virtualLogicalHeight() const { return m_logicalHeight; }
+    void setLogicalHeight(int height) { m_logicalHeight = height; }
 
     virtual int selectionTop() { return m_y; }
-    virtual int selectionHeight() { return m_height; }
+    virtual int selectionHeight() { return m_logicalHeight; }
     virtual int offsetForPosition(int x, bool includePartialGlyphs = true) const;
     virtual int positionForOffset(int offset) const;
 
@@ -91,7 +91,7 @@ private:
     FloatRect selectionRectForTextChunkPart(const SVGTextChunkPart&, int partStartPos, int partEndPos, RenderStyle*);
 
 private:
-    int m_height;
+    int m_logicalHeight;
     AffineTransform m_chunkTransformation;
     Vector<SVGTextChunkPart> m_svgTextChunkParts;
     mutable SVGTextChunkPart m_currentChunkPart;
diff --git a/WebCore/rendering/SVGRenderTreeAsText.cpp b/WebCore/rendering/SVGRenderTreeAsText.cpp
index 238f31d..4e26f52 100644
--- a/WebCore/rendering/SVGRenderTreeAsText.cpp
+++ b/WebCore/rendering/SVGRenderTreeAsText.cpp
@@ -392,7 +392,7 @@ static void writeRenderSVGTextBox(TextStream& ts, const RenderBlock& text)
         return;
 
     Vector<SVGTextChunk>& chunks = const_cast<Vector<SVGTextChunk>& >(box->svgTextChunks());
-    ts << " at (" << text.x() << "," << text.y() << ") size " << box->width() << "x" << box->height() << " contains " << chunks.size() << " chunk(s)";
+    ts << " at (" << text.x() << "," << text.y() << ") size " << box->logicalWidth() << "x" << box->logicalHeight() << " contains " << chunks.size() << " chunk(s)";
 
     if (text.parent() && (text.parent()->style()->visitedDependentColor(CSSPropertyColor) != text.style()->visitedDependentColor(CSSPropertyColor)))
         writeNameValuePair(ts, "color", text.style()->visitedDependentColor(CSSPropertyColor).name());
diff --git a/WebCore/rendering/SVGRootInlineBox.cpp b/WebCore/rendering/SVGRootInlineBox.cpp
index 6afdd99..715003f 100644
--- a/WebCore/rendering/SVGRootInlineBox.cpp
+++ b/WebCore/rendering/SVGRootInlineBox.cpp
@@ -196,8 +196,8 @@ void SVGRootInlineBox::layoutChildBoxes(InlineFlowBox* start)
             IntRect boxRect = textBox->calculateBoundaries();
             textBox->setX(boxRect.x());
             textBox->setY(boxRect.y());
-            textBox->setWidth(boxRect.width());
-            textBox->setHeight(boxRect.height());
+            textBox->setLogicalWidth(boxRect.width());
+            textBox->setLogicalHeight(boxRect.height());
         } else {
             ASSERT(child->isInlineFlowBox());
    
@@ -211,8 +211,8 @@ void SVGRootInlineBox::layoutChildBoxes(InlineFlowBox* start)
             IntRect boxRect = flowBox->calculateBoundaries();
             flowBox->setX(boxRect.x());
             flowBox->setY(boxRect.y());
-            flowBox->setWidth(boxRect.width());
-            flowBox->setHeight(boxRect.height());
+            flowBox->setLogicalWidth(boxRect.width());
+            flowBox->setLogicalHeight(boxRect.height());
         }
     }
 }
@@ -251,8 +251,8 @@ void SVGRootInlineBox::layoutRootBox()
     // Position ourselves.
     setX(0);
     setY(0);
-    setWidth(widthBlock);
-    setHeight(heightBlock);
+    setLogicalWidth(widthBlock);
+    setLogicalHeight(heightBlock);
     setBlockHeight(heightBlock);
     setLineTopBottomPositions(0, heightBlock);
 }
diff --git a/WebCore/rendering/SVGRootInlineBox.h b/WebCore/rendering/SVGRootInlineBox.h
index 4e61190..3570c70 100644
--- a/WebCore/rendering/SVGRootInlineBox.h
+++ b/WebCore/rendering/SVGRootInlineBox.h
@@ -39,14 +39,14 @@ class SVGRootInlineBox : public RootInlineBox {
 public:
     SVGRootInlineBox(RenderObject* obj)
         : RootInlineBox(obj)
-        , m_height(0)
+        , m_logicalHeight(0)
     {
     }
 
     virtual bool isSVGRootInlineBox() const { return true; }
 
-    virtual int virtualHeight() const { return m_height; }
-    void setHeight(int height) { m_height = height; }
+    virtual int virtualLogicalHeight() const { return m_logicalHeight; }
+    void setLogicalHeight(int height) { m_logicalHeight = height; }
 
     virtual void paint(PaintInfo&, int tx, int ty);
 
@@ -66,7 +66,7 @@ private:
     void layoutChildBoxes(InlineFlowBox* start);
 
 private:
-    int m_height;
+    int m_logicalHeight;
     Vector<SVGChar> m_svgChars;
     Vector<SVGTextChunk> m_svgTextChunks;
 };
diff --git a/WebCore/rendering/TrailingFloatsRootInlineBox.h b/WebCore/rendering/TrailingFloatsRootInlineBox.h
index 68bf637..d51d9b4 100644
--- a/WebCore/rendering/TrailingFloatsRootInlineBox.h
+++ b/WebCore/rendering/TrailingFloatsRootInlineBox.h
@@ -35,12 +35,12 @@ public:
     TrailingFloatsRootInlineBox(RenderObject* object) : RootInlineBox(object)
     {
 #if ENABLE(SVG)
-        setHasVirtualHeight();
+        setHasVirtualLogicalHeight();
 #endif
     }
 
 private:
-    virtual int virtualHeight() const { return 0; }
+    virtual int virtualLogicalHeight() const { return 0; }
 };
 
 } // namespace WebCore

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list