[Webkit-unassigned] [Bug 62769] REGRESSION (r88913): <object> has wrong computed height

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jun 17 23:52:04 PDT 2011


https://bugs.webkit.org/show_bug.cgi?id=62769


Nikolas Zimmermann <zimmermann at kde.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |simon.fraser at apple.com




--- Comment #4 from Nikolas Zimmermann <zimmermann at kde.org>  2011-06-17 23:52:04 PST ---
Some background, for those who wonder what has changed:



int RenderReplaced::computeReplacedLogicalHeight() const
{
    // 10.5 Content height: the 'height' property: http://www.w3.org/TR/CSS21/visudet.html#propdef-height
    // If the height of the containing block is not specified explicitly (i.e., it depends on
    // content height), and this element is not absolutely positioned, the value computes to 'auto'.
    bool heightIsAuto = style()->logicalHeight().isAuto();
    if (!document()->inQuirksMode() && !isPositioned() && style()->logicalHeight().isPercent()) {
        if (RenderObject* containingBlock = this->containingBlock()) {
            while (containingBlock->isAnonymous())
                containingBlock = containingBlock->containingBlock();
            heightIsAuto = !containingBlock->style()->logicalHeight().isSpecified();
        }
    }

...

This behavior is correct according to 2.1. Though as you can see above I had to disable this logic for two cases:
1) document is in quirks mode: don't apply the height="xx" -> height="auto" computation.
2) containingBlock is anonymous, the spec doesn't say anything about this, and in order to not break table/mozilla/ it had to be done this way.

Hm, do we need more exceptions for PDF? I'm not sure. Maybe Dave can comment as well?
I'll also CC Simon Fraser, maybe he's got an opinion.

Side note: removing that heightIsAuto correction completely, will break some of the new CSS 2.1 testcases that I imported... *sigh*.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list