Changeset 13483 in webkit


Ignore:
Timestamp:
Mar 26, 2006 2:58:26 PM (18 years ago)
Author:
eseidel
Message:

2006-03-25 Mitz Pettel <opendarwin.org@mitzpettel.com>

Reviewed by darin. Landed by eseidel.

  • manual-tests/left-overflow-repaint.html: Added.
  • rendering/RenderBlock.cpp: (WebCore::RenderBlock::overflowRect): Changed m_overflowWidth and m_overflowHeight to overflowWidth() and overflowHeight() since RenderTable overrides the latter.
  • rendering/RenderBox.cpp: (WebCore::RenderBox::getAbsoluteRepaintRect): Include top and left overflows.
  • rendering/RenderFlow.cpp: (WebCore::RenderFlow::getAbsoluteRepaintRect): Removed redundant code.
  • rendering/RenderTableCell.cpp: Removed subclass implementation of getAbsoluteRepaintRect().
  • rendering/RenderTableCell.h:
  • rendering/bidi.cpp: (WebCore::RenderBlock::layoutInlineChildren): Include left overflow in repaint rect.
Location:
trunk/WebCore
Files:
1 added
9 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r13482 r13483  
     12006-03-25  Mitz Pettel  <opendarwin.org@mitzpettel.com>
     2
     3        Reviewed by darin.  Landed by eseidel.
     4
     5        - fix http://bugzilla.opendarwin.org/show_bug.cgi?id=7916
     6          Box repaint rect does not include the left overflow
     7
     8        * manual-tests/left-overflow-repaint.html: Added.
     9        * rendering/RenderBlock.cpp:
     10        (WebCore::RenderBlock::overflowRect): Changed m_overflowWidth and m_overflowHeight
     11        to overflowWidth() and overflowHeight() since RenderTable overrides the latter.
     12        * rendering/RenderBox.cpp:
     13        (WebCore::RenderBox::getAbsoluteRepaintRect): Include top and left overflows.
     14        * rendering/RenderFlow.cpp:
     15        (WebCore::RenderFlow::getAbsoluteRepaintRect): Removed redundant code.
     16        * rendering/RenderTableCell.cpp: Removed subclass implementation of
     17        getAbsoluteRepaintRect().
     18        * rendering/RenderTableCell.h:
     19        * rendering/bidi.cpp:
     20        (WebCore::RenderBlock::layoutInlineChildren): Include left overflow in repaint rect.
     21
    1222006-03-25  Eric Seidel  <eseidel@apple.com>
    223
  • trunk/WebCore/dom/Element.cpp

    r13480 r13483  
    2626#include "Element.h"
    2727
    28 #include "CSSStyleSelector.h"
     28#include "cssstyleselector.h"
    2929#include "Document.h"
    3030#include "ExceptionCode.h"
    31 #include "htmlnames.h"
     31#include "HTMLNames.h"
    3232#include "Frame.h"
    3333#include "htmlnames.h"
  • trunk/WebCore/platform/Brush.h

    r13176 r13483  
    3838    };
    3939
    40     Brush::Brush(const Color &c = Color::black, BrushStyle style = SolidPattern)
     40    Brush(const Color &c = Color::black, BrushStyle style = SolidPattern)
    4141        : brushColor(c), brushStyle(style) { }
    4242
  • trunk/WebCore/rendering/RenderBlock.cpp

    r13480 r13483  
    364364    int l = overflowLeft(includeInterior);
    365365    int t = kMin(overflowTop(includeInterior), -borderTopExtra());
    366     return IntRect(l, t, m_overflowWidth - 2*l, m_overflowHeight + borderTopExtra() + borderBottomExtra() - 2*t);
     366    return IntRect(l, t, overflowWidth(includeInterior) - 2*l, overflowHeight(includeInterior) + borderTopExtra() + borderBottomExtra() - 2*t);
    367367}
    368368
  • trunk/WebCore/rendering/RenderBox.cpp

    r13397 r13483  
    769769IntRect RenderBox::getAbsoluteRepaintRect()
    770770{
    771     IntRect r(0, 0, overflowWidth(false), overflowHeight(false));
     771    IntRect r = overflowRect(false);
    772772    if (style()) {
    773773        if (style()->hasAppearance())
  • trunk/WebCore/rendering/RenderFlow.cpp

    r13397 r13483  
    507507       
    508508        return r;
    509     }
    510     else {
    511         if (firstLineBox() && firstLineBox()->topOverflow() < 0) {
    512             int ow = style() ? style()->outlineSize() : 0;
    513             IntRect r(-ow, -ow+firstLineBox()->topOverflow(),
    514                     overflowWidth(false)+ow*2,
    515                     overflowHeight(false)+ow*2-firstLineBox()->topOverflow());
    516             computeAbsoluteRepaintRect(r);
    517             return r;
    518         }
    519     }
    520 
    521     return RenderContainer::getAbsoluteRepaintRect();
     509    } else
     510        return RenderContainer::getAbsoluteRepaintRect();
    522511}
    523512
  • trunk/WebCore/rendering/RenderTableCell.cpp

    r13397 r13483  
    686686}
    687687
    688 IntRect RenderTableCell::getAbsoluteRepaintRect()
    689 {
    690     int ow = style() ? style()->outlineSize() : 0;
    691     IntRect r(-ow, -ow - borderTopExtra(),
    692             overflowWidth(false) + ow * 2, overflowHeight(false) + borderTopExtra() + borderBottomExtra() + ow * 2);
    693     computeAbsoluteRepaintRect(r);
    694     return r;
    695 }
    696 
    697688void RenderTableCell::paintBackgroundsBehindCell(PaintInfo& i, int _tx, int _ty, RenderObject* backgroundObject)
    698689{
  • trunk/WebCore/rendering/RenderTableCell.h

    r13393 r13483  
    107107#endif
    108108
    109     virtual IntRect getAbsoluteRepaintRect();
    110    
    111109    void paintBackgroundsBehindCell(PaintInfo&, int tx, int ty, RenderObject* backgroundObject);
    112110
  • trunk/WebCore/rendering/bidi.cpp

    r13480 r13483  
    17141714
    17151715    if (useRepaintRect) {
    1716         repaintRect.setWidth(kMax((int)m_width, m_overflowWidth));
     1716        repaintRect.setX(m_overflowLeft);
     1717        repaintRect.setWidth(kMax((int)m_width, m_overflowWidth) - m_overflowLeft);
    17171718        if (repaintRect.height() == 0)
    17181719            repaintRect.setHeight(kMax(oldLineBottom, m_overflowHeight) - repaintRect.y());
Note: See TracChangeset for help on using the changeset viewer.