Bug 129299 - [New Multicolumn] -webkit-column-break-inside:avoid doesn't work
Summary: [New Multicolumn] -webkit-column-break-inside:avoid doesn't work
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Morten Stenshorne
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-25 04:42 PST by Morten Stenshorne
Modified: 2014-02-25 08:04 PST (History)
6 users (show)

See Also:


Attachments
Test case (522 bytes, text/html)
2014-02-25 04:42 PST, Morten Stenshorne
no flags Details
Patch (4.33 KB, patch)
2014-02-25 05:23 PST, Morten Stenshorne
no flags Details | Formatted Diff | Diff
Patch (4.44 KB, patch)
2014-02-25 06:28 PST, Morten Stenshorne
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Morten Stenshorne 2014-02-25 04:42:19 PST
It works in the old/current multicol implementation.
Comment 1 Morten Stenshorne 2014-02-25 04:42:36 PST
Created attachment 225134 [details]
Test case
Comment 2 Morten Stenshorne 2014-02-25 04:44:27 PST
Bug in Blink: https://code.google.com/p/chromium/issues/detail?id=346661
Comment 3 Morten Stenshorne 2014-02-25 05:23:53 PST
Created attachment 225139 [details]
Patch
Comment 4 Andrei Bucur 2014-02-25 06:01:10 PST
Comment on attachment 225139 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=225139&action=review

r=me with some nits.

> Source/WebCore/ChangeLog:7
> +

Please add a short textual description of what the patch does.

> Source/WebCore/rendering/RenderBlockFlow.cpp:1696
> +    bool isInsideMulticolFlowThread = flowThread && !flowThread->isRenderNamedFlowThread();

In RenderLayer::updatePagination() the check for a multi-column flow thread is RenderObject::isInFlowRenderFlowThread(). I think it makes sense to use it here as well.
Comment 5 Morten Stenshorne 2014-02-25 06:07:56 PST
Comment on attachment 225139 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=225139&action=review

>> Source/WebCore/ChangeLog:7
>> +
> 
> Please add a short textual description of what the patch does.

Will do, once I know your opinion about the other issue raised.

>> Source/WebCore/rendering/RenderBlockFlow.cpp:1696
>> +    bool isInsideMulticolFlowThread = flowThread && !flowThread->isRenderNamedFlowThread();
> 
> In RenderLayer::updatePagination() the check for a multi-column flow thread is RenderObject::isInFlowRenderFlowThread(). I think it makes sense to use it here as well.

That should work as well. However, please take a look at RenderBlockFlow::applyAfterBreak() and RenderBlockFlow::applyBeforeBreak(), which checks for multi-column flow thread in the same way as I did here. I suggest that we keep it as it is. Or should I rather change applyAfterBreak() and applyBeforeBreak() as well.
Comment 6 Andrei Bucur 2014-02-25 06:26:00 PST
Comment on attachment 225139 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=225139&action=review

>>> Source/WebCore/rendering/RenderBlockFlow.cpp:1696
>>> +    bool isInsideMulticolFlowThread = flowThread && !flowThread->isRenderNamedFlowThread();
>> 
>> In RenderLayer::updatePagination() the check for a multi-column flow thread is RenderObject::isInFlowRenderFlowThread(). I think it makes sense to use it here as well.
> 
> That should work as well. However, please take a look at RenderBlockFlow::applyAfterBreak() and RenderBlockFlow::applyBeforeBreak(), which checks for multi-column flow thread in the same way as I did here. I suggest that we keep it as it is. Or should I rather change applyAfterBreak() and applyBeforeBreak() as well.

For this patch, I guess not. Keep it as it is then. I'll file a new bug to switch to isInFlow/isOutOfFlowRenderFlowThread getters where it makes sense.
Comment 7 Morten Stenshorne 2014-02-25 06:28:47 PST
Created attachment 225146 [details]
Patch
Comment 8 WebKit Commit Bot 2014-02-25 07:29:32 PST
Comment on attachment 225146 [details]
Patch

Rejecting attachment 225146 [details] from commit-queue.

mstensho@opera.com does not have committer permissions according to http://trac.webkit.org/browser/trunk/Tools/Scripts/webkitpy/common/config/contributors.json.

- If you do not have committer rights please read http://webkit.org/coding/contributing.html for instructions on how to use bugzilla flags.

- If you have committer rights please correct the error in Tools/Scripts/webkitpy/common/config/contributors.json by adding yourself to the file (no review needed).  The commit-queue restarts itself every 2 hours.  After restart the commit-queue will correctly respect your committer rights.
Comment 9 WebKit Commit Bot 2014-02-25 08:04:42 PST
Comment on attachment 225146 [details]
Patch

Clearing flags on attachment: 225146

Committed r164649: <http://trac.webkit.org/changeset/164649>
Comment 10 WebKit Commit Bot 2014-02-25 08:04:46 PST
All reviewed patches have been landed.  Closing bug.