1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/layout/reftests/w3c-css/submitted/flexbox/flexbox-baseline-empty-1-ref.html Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,48 @@ 1.4 +<!DOCTYPE html> 1.5 +<!-- 1.6 + Any copyright is dedicated to the Public Domain. 1.7 + http://creativecommons.org/publicdomain/zero/1.0/ 1.8 +--> 1.9 +<!-- In this reference case, we have inline-blocks instead of inline 1.10 + flex containers. We stick an Ahem whitespace character in each 1.11 + inline-block, with a customized line-height to make the baseline 1.12 + end up at the bottom of the inline-block's content-box. --> 1.13 +<html> 1.14 +<head> 1.15 + <title>CSS Reftest Reference</title> 1.16 + <link rel="author" title="Daniel Holbert" href="mailto:dholbert@mozilla.com"> 1.17 + <meta charset="utf-8"> 1.18 + <link rel="stylesheet" type="text/css" href="support/ahem.css" /> 1.19 + <style> 1.20 + body { 1.21 + font: 20px Ahem; 1.22 + } 1.23 + .flexContainer { 1.24 + display: inline-block; 1.25 + height: 16px; 1.26 + width: 16px; 1.27 + /* Each inline-block's baseline will be the baseline of the single Ahem 1.28 + character that it contains. We want to set up that char such that its 1.29 + baseline is at the bottom of the container's content box (since that's 1.30 + the corresponding flex container's baseline). So, we use a line-height 1.31 + of 20px, which gives us a baseline of 20px * 0.8 = 16px, which is the 1.32 + bottom of the container's content-box -- awesome. */ 1.33 + line-height: 20px; 1.34 + background: purple; 1.35 + border: 0px dotted black; 1.36 + /* (Elements that want a border will set their border-width.) */ 1.37 + } 1.38 + </style> 1.39 +</head> 1.40 +<body> 1.41 + A 1.42 + <!-- We have to include a character in the inline-blocks in order for them 1.43 + to baseline-align; otherwise, they align the bottom of their 1.44 + border-boxes. --> 1.45 + <div class="flexContainer"> </div> 1.46 + <div class="flexContainer" style="padding-bottom: 20px"> </div> 1.47 + <div class="flexContainer" style="padding: 10px"> </div> 1.48 + <div class="flexContainer" style="border-width: 3px"> </div> 1.49 + <div class="flexContainer" style="border-bottom-width: 4px"> </div> 1.50 +</body> 1.51 +</html>