Changeset 167727 in webkit


Ignore:
Timestamp:
Apr 23, 2014 3:19:19 PM (10 years ago)
Author:
hyatt@apple.com
Message:

[New Multicolumn] fast/multicol/fixed-column-percent-logical-height-orthogonal-writing-mode.html fails
https://bugs.webkit.org/show_bug.cgi?id=132078

Reviewed by Anders Carlsson.

  • rendering/RenderBox.cpp:

(WebCore::RenderBox::skipContainingBlockForPercentHeightCalculation):
Add a parameter to test for orthogonal writing modes. If we're perpendicular,
then we should not skip the flow thread, since we resolve relative to the column width,
and that is always set.

(WebCore::RenderBox::computePercentageLogicalHeight):
Patched to pass in whether or not the box and the ancestor block are perpendicular.

  • rendering/RenderBox.h:

Patched the signature of skipContainingBlockForPercentHeightCalculation

Location:
trunk/Source/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r167724 r167727  
     12014-04-23  David Hyatt  <hyatt@apple.com>
     2
     3        [New Multicolumn] fast/multicol/fixed-column-percent-logical-height-orthogonal-writing-mode.html fails
     4        https://bugs.webkit.org/show_bug.cgi?id=132078
     5
     6        Reviewed by Anders Carlsson.
     7
     8        * rendering/RenderBox.cpp:
     9        (WebCore::RenderBox::skipContainingBlockForPercentHeightCalculation):
     10        Add a parameter to test for orthogonal writing modes. If we're perpendicular,
     11        then we should not skip the flow thread, since we resolve relative to the column width,
     12        and that is always set.
     13
     14        (WebCore::RenderBox::computePercentageLogicalHeight):
     15        Patched to pass in whether or not the box and the ancestor block are perpendicular.
     16
     17        * rendering/RenderBox.h:
     18        Patched the signature of skipContainingBlockForPercentHeightCalculation
     19
    1202014-04-23  Myles C. Maxfield  <mmaxfield@apple.com>
    221
  • trunk/Source/WebCore/rendering/RenderBox.cpp

    r167706 r167727  
    27132713}
    27142714
    2715 bool RenderBox::skipContainingBlockForPercentHeightCalculation(const RenderBox* containingBlock) const
     2715bool RenderBox::skipContainingBlockForPercentHeightCalculation(const RenderBox* containingBlock, bool isPerpendicularWritingMode) const
    27162716{
    27172717    // Flow threads for multicol or paged overflow should be skipped. They are invisible to the DOM,
    27182718    // and percent heights of children should be resolved against the multicol or paged container.
    2719     if (containingBlock->isInFlowRenderFlowThread())
     2719    if (containingBlock->isInFlowRenderFlowThread() && !isPerpendicularWritingMode)
    27202720        return true;
    27212721
     
    27352735    const RenderBox* containingBlockChild = this;
    27362736    LayoutUnit rootMarginBorderPaddingHeight = 0;
    2737     while (!cb->isRenderView() && skipContainingBlockForPercentHeightCalculation(cb)) {
     2737    bool isHorizontal = isHorizontalWritingMode();
     2738    while (!cb->isRenderView() && skipContainingBlockForPercentHeightCalculation(cb, isHorizontal != cb->isHorizontalWritingMode())) {
    27382739        if (cb->isBody() || cb->isRoot())
    27392740            rootMarginBorderPaddingHeight += cb->marginBefore() + cb->marginAfter() + cb->borderAndPaddingLogicalHeight();
     
    27522753    bool includeBorderPadding = isTable();
    27532754
    2754     if (isHorizontalWritingMode() != cb->isHorizontalWritingMode())
     2755    if (isHorizontal != cb->isHorizontalWritingMode())
    27552756        availableHeight = containingBlockChild->containingBlockLogicalWidthForContent();
    27562757    else if (hasOverrideContainingBlockLogicalHeight())
  • trunk/Source/WebCore/rendering/RenderBox.h

    r167706 r167727  
    670670    bool repaintLayerRectsForImage(WrappedImagePtr image, const FillLayer* layers, bool drawingBackground);
    671671
    672     bool skipContainingBlockForPercentHeightCalculation(const RenderBox* containingBlock) const;
     672    bool skipContainingBlockForPercentHeightCalculation(const RenderBox* containingBlock, bool isPerpendicularWritingMode) const;
    673673   
    674674    LayoutUnit containingBlockLogicalWidthForPositioned(const RenderBoxModelObject* containingBlock, RenderRegion* = 0, bool checkForPerpendicularWritingMode = true) const;
Note: See TracChangeset for help on using the changeset viewer.