Changeset 70816 in webkit
- Timestamp:
- Oct 28, 2010 3:12:29 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 12 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r70814 r70816 1 2010-10-28 David Hyatt <hyatt@apple.com> 2 3 Reviewed by James Robinson. 4 5 https://bugs.webkit.org/show_bug.cgi?id=48568 6 7 Backgrounds don't work right with vertical RenderInlines. Make background painting 8 do the right thing for vertical strips. 9 10 * fast/blockflow/background-horizontal-bt.html: Added. 11 * fast/blockflow/background-vertical-lr.html: Added. 12 * fast/blockflow/background-vertical-rl.html: Added. 13 * platform/mac/fast/blockflow/background-horizontal-bt-expected.checksum: Added. 14 * platform/mac/fast/blockflow/background-horizontal-bt-expected.png: Added. 15 * platform/mac/fast/blockflow/background-horizontal-bt-expected.txt: Added. 16 * platform/mac/fast/blockflow/background-vertical-lr-expected.checksum: Added. 17 * platform/mac/fast/blockflow/background-vertical-lr-expected.png: Added. 18 * platform/mac/fast/blockflow/background-vertical-lr-expected.txt: Added. 19 * platform/mac/fast/blockflow/background-vertical-rl-expected.checksum: Added. 20 * platform/mac/fast/blockflow/background-vertical-rl-expected.png: Added. 21 * platform/mac/fast/blockflow/background-vertical-rl-expected.txt: Added. 22 1 23 2010-10-28 Eric Carlson <eric.carlson@apple.com> 2 24 -
trunk/WebCore/ChangeLog
r70814 r70816 1 2010-10-28 David Hyatt <hyatt@apple.com> 2 3 Reviewed by James Robinson. 4 5 https://bugs.webkit.org/show_bug.cgi?id=48568 6 7 Backgrounds don't work right with vertical RenderInlines. Make background painting 8 do the right thing for vertical strips. 9 10 Added fast/blockflow/background-* tests 11 12 * rendering/InlineFlowBox.cpp: 13 (WebCore::InlineFlowBox::paintFillLayer): 14 1 15 2010-10-28 Eric Carlson <eric.carlson@apple.com> 2 16 -
trunk/WebCore/rendering/InlineFlowBox.cpp
r70813 r70816 756 756 else { 757 757 // We have a fill image that spans multiple lines. 758 // We need to adjust _tx and _ty by the width of all previous lines.758 // We need to adjust tx and ty by the width of all previous lines. 759 759 // Think of background painting on inlines as though you had one long line, a single continuous 760 760 // strip. Even though that strip has been broken up across multiple lines, you still paint it … … 763 763 // FIXME: What the heck do we do with RTL here? The math we're using is obviously not right, 764 764 // but it isn't even clear how this should work at all. 765 int xOffsetOnLine = 0;765 int logicalOffsetOnLine = 0; 766 766 for (InlineFlowBox* curr = prevLineBox(); curr; curr = curr->prevLineBox()) 767 xOffsetOnLine += curr->logicalWidth(); 768 int startX = tx - xOffsetOnLine; 769 int totalWidth = xOffsetOnLine; 767 logicalOffsetOnLine += curr->logicalWidth(); 768 int totalLogicalWidth = logicalOffsetOnLine; 770 769 for (InlineFlowBox* curr = this; curr; curr = curr->nextLineBox()) 771 totalWidth += curr->logicalWidth(); 770 totalLogicalWidth += curr->logicalWidth(); 771 int stripX = tx - (isVertical() ? 0 : logicalOffsetOnLine); 772 int stripY = ty - (isVertical() ? logicalOffsetOnLine : 0); 773 int stripWidth = isVertical() ? width() : totalLogicalWidth; 774 int stripHeight = isVertical() ? totalLogicalWidth : height(); 772 775 paintInfo.context->save(); 773 paintInfo.context->clip(IntRect(tx, ty, logicalWidth(), logicalHeight()));774 boxModelObject()->paintFillLayerExtended(paintInfo, c, fillLayer, st artX, ty, totalWidth, h, this, op);776 paintInfo.context->clip(IntRect(tx, ty, width(), height())); 777 boxModelObject()->paintFillLayerExtended(paintInfo, c, fillLayer, stripX, stripY, stripWidth, stripHeight, this, op); 775 778 paintInfo.context->restore(); 776 779 }
Note: See TracChangeset
for help on using the changeset viewer.