The Sysadmin Notebook  

Sitemap

CSS for Text

Styling text with CSS

Property Description Example Values
color Sets the color of a text red
rgb(255,255,0)
#ff0000
direction Sets the text direction ltr
rtl
line-height Sets the distance between lines normal
1.5
15pt
150%
letter-spacing Increase or decrease the space between characters normal
12px
-0.4px
text-align Aligns the text in an element left
right
center
justify
text-decoration Adds decoration to text none
underline
overline
line-through
blink
text-indent Indents the first line of text in an element 20px
-12px
20%
text-shadow   none
color
length
text-transform Controls the letters in an element none
capitalize
uppercase
lowercase
unicode-bidi   normal
embed
bidi-override
white-space Sets how white space inside an element is handled normal
pre
nowrap
word-spacing Increase or decrease the space between words normal
length