Want to share your CSS expertise with others? Apply to the MDN Fellowship by April 1! http://mzl.la/MDNFellowship

mozilla

Revision 40890 of letter-spacing

  • Revision slug: CSS/letter-spacing
  • Revision title: letter-spacing
  • Revision id: 40890
  • Created:
  • Creator: Jeremie
  • Is current revision? No
  • Comment 63 words added, 17 words removed

Revision Content

{{ CSSRef() }}

Summary

The letter-spacing CSS property specifies spacing behavior between text characters.

  • {{ Xref_cssinitial() }}: {{ Cssxref("normal") }}
  • Applies to: all elements
  • {{ Xref_cssinherited() }}: yes
  • Percentages: n/a
  • Media: {{ Xref_cssvisual() }}
  • {{ Xref_csscomputed() }}: normal or absolute length

Syntax

letter-spacing:  normal | <length>

Values

normal
The spacing is the normal spacing for the current font. This value allows the user agent to alter the space between characters in order to justify text. That's the difference to the length value 0.
<length>
Indicates inter-character space in addition to the default space between characters. Values may be negative, but there may be implementation-specific limits. User agents may not further increase or decrease the inter-character space in order to justify text.
See {{ Xref_csslength() }} values for possible units.

Examples

p { letter-spacing: 0.4em }

Specifications

Browser compatibility

{{ CompatibilityTable() }}

Feature Firefox (Gecko) Chrome Internet Explorer Opera Safari (WebKit)
Basic support 1.0 ({{ CompatGeckoDesktop(geckoversion) }}) 1.0 4.0 3.5 1.0 (85)
Feature Firefox Mobile (Gecko) Android IE Mobile Opera Mobile Safari Mobile
Basic support {{ CompatUnknown() }} {{ CompatUnknown() }} {{ CompatUnknown() }} {{ CompatUnknown() }} {{ CompatUnknown() }}

See also

{{ CSS_Reference:Text() }}

{{ languages( { "pl": "pl/CSS/letter-spacing" } ) }}

Revision Source

<p>{{ CSSRef() }}</p>
<h3 name="Summary">Summary</h3>
<p>The<code> letter-spacing </code>CSS property specifies spacing behavior between text characters.</p>
<ul> <li>{{ Xref_cssinitial() }}: {{ Cssxref("normal") }}</li> <li>Applies to: all elements</li> <li>{{ Xref_cssinherited() }}: yes</li> <li>Percentages: n/a</li> <li>Media: {{ Xref_cssvisual() }}</li> <li>{{ Xref_csscomputed() }}: <code>normal </code>or absolute length</li>
</ul>
<h3 name="Syntax">Syntax</h3>
<pre class="eval">letter-spacing:  normal | &lt;length&gt;
</pre>
<h3 name="Values">Values</h3>
<dl><dt>normal</dt><dd> The spacing is the normal spacing for the current font. This value allows the user agent to alter the space between characters in order to justify text. That's the difference to the length value<code> 0</code>.<br>
</dd><dt>&lt;length&gt;</dt><dd> Indicates inter-character space <em>in addition to</em> the default space between characters. Values may be negative, but there may be implementation-specific limits. User agents may not further increase or decrease the inter-character space in order to justify text.<br>
See {{ Xref_csslength() }} values for possible units.<br>
</dd></dl>
<h3 name="Examples">Examples</h3>
<pre class="eval">p { letter-spacing: 0.4em }
</pre>
<h3 name="Specifications">Specifications</h3>
<ul> <li><a class="external" href="http://www.w3.org/TR/CSS21/text.html#propdef-letter-spacing" title="http://www.w3.org/TR/CSS21/text.html#propdef-letter-spacing">CSS 2.1 Text #letter-spacing</a></li>
</ul>
<h3 name="Browser_compatibility">Browser compatibility</h3>
<p>{{ CompatibilityTable() }}</p>
<div id="compat-desktop">
<table class="compat-table"> <tbody> <tr> <th>Feature</th> <th>Firefox (Gecko)</th> <th>Chrome</th> <th>Internet Explorer</th> <th>Opera</th> <th>Safari (WebKit)</th> </tr> <tr> <td>Basic support</td> <td>1.0 ({{ CompatGeckoDesktop(geckoversion) }})</td> <td>1.0</td> <td>4.0</td> <td>3.5</td> <td>1.0 (85)</td> </tr> </tbody>
</table>
</div>
<div id="compat-mobile">
<table class="compat-table"> <tbody> <tr> <th>Feature</th> <th>Firefox Mobile (Gecko)</th> <th>Android</th> <th>IE Mobile</th> <th>Opera Mobile</th> <th>Safari Mobile</th> </tr> <tr> <td>Basic support</td> <td>{{ CompatUnknown() }}</td> <td>{{ CompatUnknown() }}</td> <td>{{ CompatUnknown() }}</td> <td>{{ CompatUnknown() }}</td> <td>{{ CompatUnknown() }}</td> </tr> </tbody>
</table>
</div><h3 name="See_also">See also</h3>
<p>{{ CSS_Reference:Text() }}</p>
<p>{{ languages( { "pl": "pl/CSS/letter-spacing" } ) }}</p>
Revert to this revision