Text Properties Used in Style Sheets

Style Name Function Attributes Examples
letter-spacing Controls the amount of space between each letter in a section of text. normal (default)
# of pixels (px)
letter-spacing: 2px;
line-height Controls the amount of vertical space between lines of text default is normal
# of pixels
or percentage
line-height: 5px;
line-height: 5%;
text-align Controls the alignment for a section of text default is left
left
right
center
text-align: left;
text-align: center;
text-align: right;
text-decoration Controls what the text looks like. Underline is especially useful for links, so they actually look like links. default is none
underline
overline
line-through
blink
text-decoration: underline;
text-decoration: overline;
text-decoration: line-through;
text-decoration: blink;
text-indent Controls the indentation of the first line in a section of text.
Em by the way, is an old typography measurement referring to the X height, or capital letter height of the particular size of type being used. Em space was the standard paragraph indent in the days of old, when ink was applied to paper and formed into books, for people to read in an easy chair. En space refers to the lowercase letter height. That's some information that now that you know, you'll never ever need to remember again.
default is none
number of pixels
ems
text-indent: 5px;
text-indent: 2em;
text-transform Changes the case of a section of text to all upper, lower, or every word capitalized. default is none
uppercase
lowercase
capitalize
text-transform: uppercase;
text-transform: lowercase;
text-transform: capitalize;
vertical-align Controls the vertical alignment of a section of text default is baseline
sub(script)
super(script)
top
text-top
middle
bottom
text-bottom
vertical-align: sub;
vertical-align: super;
vertical-align: top;
vertical-align: text-top;
vertical-align: middle;
vertical-align: bottom;
vertical-align: text-bottom;
word-spacing Determines the space between words default is none
number of pixels
word-spacing: none;
word-spacing: 4px;

< >


© Copyright Night Train Web Productions Night Train Web Productions — All Rights Reserved
No Part of This Work May be Reproduced by any Means Without Prior Written Authorization
8153 / 051006 / [an error occurred while processing this directive]