Source/WebCore/ChangeLog

 12013-03-07 Zoltan Horvath <zoltan@webkit.org>
 2
 3 [CSS Exclusions][CSS Regions] Shape-inside on a parent element does not affect region content
 4 https://bugs.webkit.org/show_bug.cgi?id=111379
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 If the region doesn't have a shape-inside, but one of its parent element has one, then we should
 9 apply the most immediate one to the content.
 10
 11 Tests: fast/regions/shape-inside/shape-inside-on-parent-element.html
 12 fast/regions/shape-inside/shape-inside-on-regions.html
 13
 14 * rendering/RenderBlockLineLayout.cpp:
 15 (WebCore::RenderBlock::layoutExclusionShapeInsideInfo): Add a loop what steps upwards on the rendertree
 16 and returns the most immediate shape-inside if it exists.
 17
1182013-03-07 Vsevolod Vlasov <vsevik@chromium.org>
219
320 Web Inspector: Styles sidebar pane toolbar disappears in horizontal split mode.
145088

Source/WebCore/rendering/RenderBlockLineLayout.cpp

8383 if (!shapeInsideInfo && flowThreadContainingBlock()) {
8484 LayoutUnit offset = logicalHeight() + logicalHeightForLine(this, false);
8585 RenderRegion* region = regionAtBlockOffset(offset);
86  return region ? region->exclusionShapeInsideInfo() : 0;
 86 if (region) {
 87 if (region->exclusionShapeInsideInfo())
 88 return region->exclusionShapeInsideInfo();
 89
 90 RenderBlock* parent = toRenderBlock(region->parent());
 91 while (parent) {
 92 if (parent->exclusionShapeInsideInfo())
 93 return parent->exclusionShapeInsideInfo();
 94 parent = toRenderBlock(parent->parent());
 95 }
 96 }
8797 }
8898 return shapeInsideInfo;
8999}
145084

LayoutTests/fast/regions/shape-inside-on-regions-expected.html

1 <!DOCTYPE HTML>
2 <html>
3 <head>
4  <script>
5  if (window.internals)
6  window.internals.settings.setCSSExclusionsEnabled(true);
7  </script>
8  <style>
9  #page { font: 16px Ahem, sans-serif; }
10 
11  #region1 {
12  width: 180px;
13  height: 100px;
14  -webkit-shape-inside: rectangle(0, 0, 130px, 90px);
15  margin-top: 10px;
16  }
17  #region2 {
18  width: 300px;
19  height: 145px;
20  -webkit-shape-inside: rectangle(0, 0, 220px, 150px);
21  margin-top: 60px;
22  }
23  #region3 {
24  width: 300px;
25  height: 50px;
26  margin-top: 60px;
27  }
28  </style>
29 </head>
30 <body>
31  <div id="page">
32  <div id="region1">
33  X X X X X
34  <p>X X</p>
35  <p style="color: green">X X X X</p>
36  </div>
37  <div id="region2">
38  <p style="color: green;">X X</p>
39  <p style="color: orange">X X X X</p>
40  <p>X X X X X X X X<p style="color: yellow">X X X X X X X X X X</p></p>
41  </div>
42  <div id="region3">
43  <p>X X</p>
44  <p style="color: red"> X X X X X X X X X</p>
45  </div>
46  </div>
47 
48  <p>Requires Ahem font. Two different -shape-inside property are applied to the first and second region. The third region is a simple region without -shape-inside.
49  The rectangles should flow through the regions and the shape-insides should be applied to the first two regions.</p>
50  <p> Bug <a href="http://webkit.org/b/107880">107880</a>: Regions should respect shape-inside</p>
51 </body>
52 </html>
145084

LayoutTests/fast/regions/shape-inside-on-regions.html

1 <!DOCTYPE HTML>
2 <html>
3 <head>
4  <script>
5  if (window.internals)
6  window.internals.settings.setCSSExclusionsEnabled(true);
7  </script>
8  <style>
9  #rectangle {
10  font: 16px Ahem, sans-serif;
11  -webkit-flow-into: rectangle;
12  }
13 
14  .region { -webkit-flow-from: rectangle; }
15 
16  #region1 {
17  width: 180px;
18  height: 100px;
19  -webkit-shape-inside: rectangle(0, 0, 130px, 90px);
20  margin-top: 10px;
21  }
22  #region2 {
23  width: 300px;
24  height: 145px;
25  -webkit-shape-inside: rectangle(0, 0, 220px, 150px);
26  margin-top: 60px;
27  }
28  #region3 {
29  width: 300px;
30  height: 50px;
31  margin-top: 60px;
32  }
33  </style>
34 </head>
35 <body>
36  <div id="rectangle">
37  X X X X X
38  <p>X X</p>
39  <p style="color: green">X X X X X X</p>
40  <p style="color: orange">X X X X</p>
41  <p>X X X X X X X X<p style="color: yellow">X X X X X X X X X X</p> X X</p>
42  <div style="color: red"> X X X X X X X X X</div>
43  </div>
44  <div id="page">
45  <div id="region1" class="region"></div>
46  <div id="region2" class="region"></div>
47  <div id="region3" class="region"></div>
48  </div>
49  <p>Requires Ahem font. Two different -shape-inside property are applied to the first and second region. The third region is a simple region without -shape-inside.
50  The rectangles should flow through the regions and the shape-insides should be applied to the first two regions.</p>
51  <p> Bug <a href="http://webkit.org/b/107880">107880</a>: Regions should respect shape-inside</p>
52 </body>
53 </html>
145084

LayoutTests/fast/regions/shape-inside/shape-inside-on-parent-element-expected.html

 1<!DOCTYPE html>
 2<html>
 3<head>
 4<script>
 5 if (window.internals)
 6 window.internals.settings.setCSSExclusionsEnabled(true);
 7</script>
 8<style>
 9 .bigger_circle {
 10 width: 300px;
 11 height: 300px;
 12 font: 18px Ahem, sans-serif;
 13 line-height: 20px;
 14 -webkit-shape-inside: circle(50%, 50%, 50%);
 15 }
 16
 17 .smaller_circle {
 18 width: 300px;
 19 height: 300px;
 20 -webkit-shape-inside: circle(50%, 20%, 20%);
 21 }
 22</style>
 23</head>
 24<body>
 25<div class='bigger_circle'>
 26 X X X X X X X X X X X X X X X X X X X X X
 27 X X X X X X X X X X X X X X X X X X X X X
 28 X X X X X X X X X X X X X X X X X X X X X
 29 X X X X X X X X X X X X X X X X X X X X X
 30</div>
 31
 32<div class='bigger_circle'>
 33 <div class='smaller_circle'>
 34 X X X X X X X X X X X X X X X X X X X X X
 35 X X X X X X X X X X X X X X X X X X X X X
 36 </div>
 37</div>
 38<p>Requires Ahem font. This test checks if the shape-inside on a parent element is applied to the region content.
 39In the first box .bigger_circle should be applied to the text. In the second box .smaller_circle should be applied to the content.
 40</p>
 41<p> Bug <a href="http://webkit.org/b/111379">111379</a>: [CSS Exclusions][CSS Regions] Shape-inside on a parent element does not affect region content</p>
 42</body>
 43</html>
0

LayoutTests/fast/regions/shape-inside/shape-inside-on-parent-element.html

 1<!DOCTYPE html>
 2<html>
 3<head>
 4<script>
 5 if (window.internals)
 6 window.internals.settings.setCSSExclusionsEnabled(true);
 7</script>
 8<style>
 9 .setup {
 10 font: 18px Ahem, sans-serif;
 11 line-height: 20px;
 12 }
 13
 14 .bigger_circle {
 15 width: 300px;
 16 height: 300px;
 17 -webkit-shape-inside: circle(50%, 50%, 50%);
 18 }
 19
 20 .nested1 { -webkit-flow-from: flow1; }
 21 .content1 { -webkit-flow-into: flow1; }
 22
 23 .smaller_circle {
 24 width: 300px;
 25 height: 300px;
 26 -webkit-shape-inside: circle(50%, 20%, 20%);
 27 }
 28
 29 .nested2 { -webkit-flow-from: flow2; }
 30 .content2 { -webkit-flow-into: flow2; }
 31</style>
 32</head>
 33<body>
 34<div class="setup">
 35 <div class='bigger_circle'>
 36 <div>
 37 <div>
 38 <div class='nested1'></div>
 39 </div>
 40 </div>
 41 </div>
 42 <div class='content1'>
 43 X X X X X X X X X X X X X X X X X X X X X
 44 X X X X X X X X X X X X X X X X X X X X X
 45 X X X X X X X X X X X X X X X X X X X X X
 46 X X X X X X X X X X X X X X X X X X X X X
 47 </div>
 48
 49 <div class='bigger_circle'>
 50 <div class='smaller_circle'>
 51 <div>
 52 <div class='nested2'></div>
 53 </div>
 54 </div>
 55 </div>
 56 <div class='content2'>
 57 X X X X X X X X X X X X X X X X X X X X X
 58 X X X X X X X X X X X X X X X X X X X X X
 59 </div>
 60</div>
 61<p>
 62Requires Ahem font. This test checks if the shape-inside on a parent element is applied to the region content.
 63In the first box .bigger_circle should be applied to the text. In the second box .smaller_circle should be applied to the content.
 64</p>
 65<p> Bug <a href="http://webkit.org/b/111379">111379</a>: [CSS Exclusions][CSS Regions] Shape-inside on a parent element does not affect region content</p>
 66</body>
 67</html>
0

LayoutTests/ChangeLog

 12013-03-07 Zoltan Horvath <zoltan@webkit.org>
 2
 3 [CSS Exclusions][CSS Regions] Shape-inside on a parent element does not affect region content
 4 https://bugs.webkit.org/show_bug.cgi?id=111379
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 If the region doesn't have a shape-inside, but one of its parent element has one, then we should
 9 apply the most immediate one to the content.
 10
 11 * fast/regions/shape-inside: Added.
 12 * fast/regions/shape-inside-on-regions-expected.html: Removed.
 13 * fast/regions/shape-inside-on-regions.html: Removed.
 14 * fast/regions/shape-inside/shape-inside-on-parent-element-expected.html: Added.
 15 * fast/regions/shape-inside/shape-inside-on-parent-element.html: Added.
 16 * fast/regions/shape-inside/shape-inside-on-regions-expected.html: Copied from LayoutTests/fast/regions/shape-inside-on-regions-expected.html.
 17 * fast/regions/shape-inside/shape-inside-on-regions.html: Copied from LayoutTests/fast/regions/shape-inside-on-regions.html.
 18 * platform/chromium/TestExpectations: Modify expectations due to moved test.
 19 * platform/qt/TestExpectations: Modify expectations due to moved test.
 20
1212013-03-07 Mike West <mkwst@chromium.org>
222
323 XSSAuditor should send only one console error when blocking a page.
145088

LayoutTests/platform/chromium/TestExpectations

43944394
43954395webkit.org/b/110568 [ MountainLion ] fast/multicol/newmulticol/positioned-split.html [ ImageOnlyFailure ]
43964396
4397 webkit.org/b/110739 [ Release MountainLion ] fast/regions/shape-inside-on-regions.html [ ImageOnlyFailure ]
 4397webkit.org/b/110739 [ Release MountainLion ] fast/regions/shape-inside/shape-inside-on-regions.html [ ImageOnlyFailure ]
43984398
43994399# The following tests are are failing since chromium r184584
44004400webkit.org/b/110851 compositing/geometry/fixed-position-composited-page-scale-smaller-than-viewport.html [ ImageOnlyFailure ]
145084

LayoutTests/platform/qt/TestExpectations

22772277webkit.org/b/110089 fast/exclusions/shape-inside/shape-inside-circle-padding.html [ Skip ]
22782278webkit.org/b/110089 fast/exclusions/shape-inside/shape-inside-ellipse.html [ Skip ]
22792279webkit.org/b/110089 fast/exclusions/shape-inside/shape-inside-ellipse-padding.html [ Skip ]
2280 webkit.org/b/110447 fast/regions/shape-inside-on-regions.html [ Skip ]
 2280webkit.org/b/110447 fast/regions/shape-inside/shape-inside-on-regions.html [ Skip ]
22812281
22822282# Failing fast/css/sticky/ tests with minor pixel differences
22832283# https://bugs.webkit.org/show_bug.cgi?id=92080
145084