border-image-width-005

border image area - border-image-width

WeasyPrint

Reference (good) by WeasyPrint

Reference (good) by this browser

This browser

Flags
image
Assertion
This test checks that the border image area can still exists even if the border area (or border belt) of an element is inexistent. In this test, the border image fills the content area, the padding area and 25px of the extended-beyond-border-belt area, 25px into the margin area of the element.

Source

 1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
 2 <html>
 3 
 4  <head>
 5 
 6   <title>CSS Backgrounds and Borders Test: border image area - border-image-width</title>
 7 
 8   <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/">
 9   <link rel="help" href="http://www.w3.org/TR/css3-background/#the-border-image-width" title="6.3. Drawing Areas: the 'border-image-width' property">
10   <link rel="match" href="reference/ref-filled-green-100px-square.htm">
11 
12   <meta name="flags" content="image">
13   <meta content="This test checks that the border image area can still exists even if the border area (or border belt) of an element is inexistent. In this test, the border image fills the content area, the padding area and 25px of the extended-beyond-border-belt area, 25px into the margin area of the element." name="assert">
14 
15   <!--
16   created 2015-11-18
17   [css-backgrounds] Please remove the "unless there is a border image" wording
18   http://lists.w3.org/Archives/Public/www-style/2015Nov/0258.html
19   -->
20 
21   <style type="text/css">
22   p
23     {
24       margin-bottom: 41px; /* border-image-outset + 16px (1em) .
25       This 41px margin-bottom value is just to position the rendered layout to accurately match the reference file . */
26     }
27 
28   div
29     {
30       background-color: red;
31       border-color: red;
32       border-style: none; /* or border-style: dotted or any other 'border-style' value */
33       border-width: 0px; /* so the border belt (or border area) of the element is 0px tall and 0px wide */
34       border-image-source: url("support/outline-5px-10px-15px-20px-green.png");
35       border-image-slice: 5% 10% 15% 20%; /* <number> Percentages are relative to the size of the image: the width of the image for the horizontal offsets, the height for vertical offsets. */
36       border-image-width: 50px; /* The four values of ‘border-image-width’ specify offsets that are used to divide the border image area into nine parts. They represent inward distances from the the top, right, bottom, and left sides of the area, respectively. */
37       border-image-outset: 25px 25px 25px 25px; /* The border-image-outset values specify the amount by which the border image area *_ extends beyond the border box_*. */
38       height: 20px;
39       margin-left: 25px; /* == border-image-outset . This margin-left value is just to position the rendered layout to accurately match the reference file . */
40       padding: 15px 15px 15px 15px;
41       width: 20px;
42     }
43   </style>
44 
45  </head>
46 
47  <body>
48 
49   <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
50 
51   <div></div>
52 
53  </body>
54 </html>