Propriété d'espacement des mots CSS
Exemple
Spécifiez que l'espace entre les mots dans les éléments <p> doit être de 30 pixels :
p
{
word-spacing: 30px;
}
Définition et utilisation
La word-spacing
propriété augmente ou diminue l'espace blanc entre les mots.
Remarque : Les valeurs négatives sont autorisées.
Valeur par défaut: | Ordinaire |
---|---|
Hérité: | Oui |
Animable : | Oui. En savoir plus sur l'animation |
Version: | CSS1 |
Syntaxe JavaScript : | objet .style.wordSpacing="20px" |
Prise en charge du navigateur
Les nombres dans le tableau indiquent la première version du navigateur qui prend entièrement en charge la propriété.
Property | |||||
---|---|---|---|---|---|
word-spacing | 1.0 | 6.0 | 1.0 | 1.0 | 3.5 |
Syntaxe CSS
word-spacing: normal|length|initial|inherit;
Valeurs de propriété
Value | Description | Play it |
---|---|---|
normal | Defines normal space between words (0.25em) . This is default | |
length | Defines an additional space between words (in px, pt, cm, em, etc). Negative values are allowed. Read about length units | |
initial | Sets this property to its default value. Read about initial | |
inherit | Inherits this property from its parent element. Read about inherit |
Pages connexes
Tutoriel CSS : Texte CSS
Référence HTML DOM : propriété wordSpacing