Files
tubestation/layout/reftests/w3c-css/submitted/shapes1/shape-outside-padding-box-002-ref.html
Ting-Yu Lin 3885f92712 Bug 1309467 Part 4 - Implement <shape-box> values for shape-outside. r=dbaron
Per spec, float positioning and stacking is not affected by defining a float
area with a shape.
https://drafts.csswg.org/css-shapes/#relation-to-box-model-and-float-behavior

So all the call sites of GetFloatAvailableSpace() related to adding a
float are replaced by GetFloatAvailableSpaceForPlacingFloat().

<shape-box> with border-radius will be implemented in next part.

MozReview-Commit-ID: 1RXEeXDhdWo
2016-10-12 16:06:25 +08:00

64 lines
1.7 KiB
HTML

<!DOCTYPE html>
<!-- Any copyright is dedicated to the Public Domain.
- http://creativecommons.org/publicdomain/zero/1.0/ -->
<html>
<meta charset="utf-8">
<title>CSS Shape Test: float right, padding-box reference</title>
<link rel="author" title="Ting-Yu Lin" href="mailto:tlin@mozilla.com">
<link rel="author" title="Mozilla" href="http://www.mozilla.org/">
<style>
.container {
direction: rtl;
width: 175px;
line-height: 0;
}
.shape {
float: right;
/* Omit shape-outside: padding-box; */
box-sizing: content-box;
height: 25px;
width: 25px;
padding: 25px;
border-right: 25px solid lightgreen;
margin-right: 25px;
background-color: orange;
}
.box {
display: inline-block;
width: 25px;
height: 25px;
background-color: blue;
}
.longbox {
display: inline-block;
width: 175px;
height: 25px;
background-color: blue;
}
</style>
<body class="container">
<div class="longbox"></div> <!-- Saturate the margin space -->
<div class="longbox"></div> <!-- Saturate the border space -->
<div class="shape"></div>
<div class="box"></div>
<div class="box"></div>
<div class="box"></div>
<div class="longbox"></div> <!-- Saturate the border space -->
<div class="longbox"></div> <!-- Saturate the margin space -->
<div class="longbox"></div> <!-- Saturate the margin space -->
<div class="longbox"></div> <!-- Saturate the border space -->
<div class="shape"></div>
<div class="box"></div>
<div class="box"></div>
<div class="box"></div>
<div class="longbox"></div> <!-- Saturate the border space -->
<div class="longbox"></div> <!-- Saturate the margin space -->
</body>
</html>