Webmaster

References : Style sheets


Text properties

The following properties change the visual formatting of characters, spaces, words and paragraphs.

letter-spacing | line-height | text-align | text-decoration | text-indent | text-shadow | text-transform | vertical-align | white-space | word-spacing
letter-spacing
Defines the rules for character spacing.
 
CSS1 valuenormal | <length>
 
CSS2 valueinherit
 
Initial valuenormal
 
Applied to All elements.
 
Inherited Yes.
 
 Top
line-height
If applied to a block-level elements, specifies the minimum height of the inline elements' boxes contained, and if applied to an inline element, it sets the exact height of the generated box.
 
CSS1 valuenormal | number | <length> | <percentage>
 
CSS2 valueinherit
 
Initial valuenormal
 
Applied to All elements.
 
Inherited Yes.
 
 Top
text-align
Defines how the inline content of a block is aligned.
 
CSS1 valueleft | right | center | justify
 
CSS2 value<string> | inherit
 
Initial valueDepends on the browser and the writing direction.
 
Applied to Block-level elements.
 
Inherited Yes.
 
 Top
text-decoration
Describes the decorations added to the text of an element.
 
CSS1 valuenone | underline | overline | line-through | blink
 
CSS2 valueinherit
 
Initial valuenone
 
Applied to All elements.
 
Inherited No.
 
 Top
text-indent
Specifies the indentation of the first line of text in a block.
 
CSS1 value<length> | <percentage>
 
CSS2 valueinherit
 
Initial value0
 
Applied to Block-level elements.
 
Inherited Yes.
 
 Top
text-shadow
Accepts a list of shadow effects to be applied to the text of the element.
 
CSS2 valuenone | <color> | <length> | inherit
 
Initial valuenone
 
Applied to All elements.
 
Inherited No.
 
Notes You can also select text shadows with the : first-letter and : first-line pseudo-elements.
 
 Top
text-transform
Controls the capitalisation mode applied to an element's text.
 
CSS1 valuecapitalize | uppercase | lowercase | none
 
CSS2 valueinherit
 
Initial valuenone
 
Applied to All elements.
 
Inherited Yes.
 
 Top
vertical-align
Affects the vertical placement of inline element boxes in a line box.
 
CSS1 valuebaseline | sub | super | top | texttop | middle | bottom | text-bottom | sub | <percentage>
 
CSS2 valueinherit
 
Initial valuebaseline
 
Applied to Inline-level and table cell elements.
 
Inherited No.
 
 Top
white-space
Specifies how white spaces are handled in an element.
 
CSS1 valuenormal | pre | nowrap
 
CSS2 valueinherit
 
Initial valuenormal
 
Applied to Block-level elements.
 
Inherited Yes.
 
 Top
word-spacing
Specifies how word spacing occurs.
 
CSS1 valuenormal | <length>
 
CSS2 valueinherit
 
Initial valuenormal
 
Applied to All elements.
 
Inherited Yes.
 
 Top