Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /css/css-text/letter-spacing/letter-spacing-end-of-line-002.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<meta charset=utf-8>
<title>CSS Text test - letter-spacing applied to preserved newline</title>
<link rel="author" title="Jonathan Kew" href="mailto:jkew@mozilla.com">
<link rel="match" href="reference/letter-spacing-end-of-line-002-ref.html">
<meta name="assert" content="Letter-spacing on a preserved newline should not cause spurious line-wrapping.">
<style>
div {
margin: 1em;
font: 24px monospace;
white-space: pre-wrap;
display: inline-block;
outline: 1px solid gray;
}
.letterspc {
letter-spacing: 10px;
}
.nospc {
letter-spacing: 0px;
}
</style>
<p>None of these examples should wrap to a second line:</p>
<div class=letterspc><span>1. a</span><span> </span></div>
<br>
<div class=letterspc><span>2. b</span><span class=nospc> </span></div>
<br>
<div class=nospc><span>3. c</span><span class=letterspc> </span></div>