[Webkit-unassigned] [Bug 105260] table-caption stride over pages.

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Mar 1 01:51:03 PST 2013


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


Yuki Sekiguchi <yuki.sekiguchi at access-company.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hyatt at apple.com




--- Comment #10 from Yuki Sekiguchi <yuki.sekiguchi at access-company.com>  2013-03-01 01:53:26 PST ---
Hi  Dave,
Thank you for reviewing.

(In reply to comment #7)
> (From update of attachment 187800 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=187800&action=review
> 
> r-
> 
> > Source/WebCore/ChangeLog:11
> > +        When the first line block steps over pages, it sets strut to its parent RenderBlock (called P).
> > +        When the parent RenderBlock of P layouts P, it shifts P's position using struts of P.
> > +        This is executed at RenderBlock::adjustBlockChildForPagination() and layoutBlockChild().
> > +        However, when a RenderTable layouts RenderCaptions, it doesn't shift a position of RenderCaptions.
> 
> How about:
> 
> "In normal block layout, pagination struts are propagated from child blocks to parent blocks in order to indicate that an object needs to push to the next page. Table captions were setting a pagination strut for a push, but this strut was not being used. Make sure RenderTable applies the caption's pagination strut when placing the caption."
> 
> > Source/WebCore/rendering/RenderTable.cpp:358
> > -    caption->setLogicalLocation(LayoutPoint(caption->marginStart(), caption->marginBefore() + logicalHeight()));
> > +    caption->setLogicalLocation(LayoutPoint(caption->marginStart(), caption->marginBefore() + logicalHeight() + caption->paginationStrut()));
> 
> This is a good change. There are a few things you should do to keep it consistent with blocks though.
> 
> First, we should only add in the paginationStrut when the layout state says so. Second, you should clear out the child's pagination strut once you have factored it into the placement.
> 
> LayoutUnit captionLogicalTop = caption->marginBefore() + logicalHeight();
> if (layoutState->isPaginated()) {
>     captionLogicalTop += caption->paginationStrut();
>     caption->setPaginationStrut(0);
> }
> caption->setLogicalLocation(LayoutPoint(caption->marginStart(), captionLogicalTop));

Thank you for good advices.
I apply your suggestions.

-- 
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