[clip-path] Implement support for margin-box as reference box and box shape
authorkrit@webkit.org <krit@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 17 Jul 2018 16:52:04 +0000 (16:52 +0000)
committerkrit@webkit.org <krit@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 17 Jul 2018 16:52:04 +0000 (16:52 +0000)
commit1b25c4406ddeb739c0a94470795137bc36abc494
tree69407dd64e7e05c46c9275df7fe38f79b7a88624
parent4d48b358983a26a3687dfe198b8e24938934b828
[clip-path] Implement support for margin-box as reference box and box shape
https://bugs.webkit.org/show_bug.cgi?id=127984

Reviewed by Simon Fraser.

Compute the margin-box rectangle as needed for clip-path based on the actual
computed values for the margin-top, *-left, *-bottom, *-right properties.

Source/WebCore:

Test: css3/masking/clip-path-margin-box.html

* rendering/RenderBox.h:
(WebCore::RenderBox::marginBoxRect const):
* rendering/RenderBoxModelObject.h:
* rendering/RenderLayer.cpp:
(WebCore::computeReferenceBox):

LayoutTests:

* css3/masking/clip-path-circle-margin-box-expected.html: Added.
* css3/masking/clip-path-margin-box-expected.html: Added.
* css3/masking/clip-path-margin-box.html: Added.
* platform/mac/css3/masking/clip-path-circle-margin-box-expected.png: Removed.
* platform/mac/css3/masking/clip-path-circle-margin-box-expected.txt: Removed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@233886 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/css3/masking/clip-path-circle-margin-box-expected.html [new file with mode: 0644]
LayoutTests/css3/masking/clip-path-margin-box-expected.html [new file with mode: 0644]
LayoutTests/css3/masking/clip-path-margin-box.html [new file with mode: 0644]
LayoutTests/platform/mac/css3/masking/clip-path-circle-margin-box-expected.png [deleted file]
LayoutTests/platform/mac/css3/masking/clip-path-circle-margin-box-expected.txt [deleted file]
Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderBox.h
Source/WebCore/rendering/RenderBoxModelObject.h
Source/WebCore/rendering/RenderLayer.cpp