Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / text / justification-padding-mid-word.html
blobe9d70e54a390e3ac69f1baa6f1b7d523b1c45f7f
1 <script src="../../resources/ahem.js"></script>
2 <div id="test" style="width: 200px; font-family: Ahem; font-size: 40px; text-rendering: optimizelegibility; text-align: justify;">a&shy;b c de</div>
3 <div id="reference" style="width: 200px; font-family: Ahem; font-size: 40px; text-align: justify;">a&shy;b c de</div>
4 <div id="result"></div>
5 <script>
6 if (window.testRunner)
7 testRunner.dumpAsText();
9 function widthOfFirstThreeCharacters(id)
11 var text = document.getElementById(id).firstChild;
12 var range = document.createRange();
13 range.setStart(text, 0);
14 range.setEnd(text, 3);
15 return range.getBoundingClientRect().width;
18 document.getElementById("result").innerText = widthOfFirstThreeCharacters("test") === widthOfFirstThreeCharacters("reference") ? "PASS" : "FAIL";
19 </script>