When tabbing
through links, replaced elements that have an overflow setting of hidden will become
displaced on receiving the focus, revealing the underlying text as well as the image
overlaying it. Caution needs to be used here.
THE ESSENTIAL GUIDE TO CSS AND HTML WEB DESIGN
78
Some methods focus on hiding the text by setting display to none in CSS, but that can
cause problems for screen readers, so avoid doing this. Others use text-indent to shift
the text off of the page, although using absolute positioning with negative top and left
coordinates is better??”this prevents vertical space being taken up by the offset text, which
is quite often noticeable, especially if margins haven??™t been controlled.
Defining font size and line height
In theory, defining font sizes should be easy enough. You use the font-size property, and
then you can set the value to an absolute size, a relative size, a length, or a percentage. For
instance, you might set the following:
h1 {
font-size: 20px;
}
p {
font-size: 12px;
}
Scalable Inman Flash Replacement (sIFR) is an alternative to replacing text with GIF
images. Instead, is uses a combination of CSS, Flash, and JavaScript to switch out a
block of text. Note that although this provides a great deal of typographic flexibility, it
should still be used sparingly??”pages where too much text is switched out using sIFR
tend to be extremely sluggish. See sIFR Beauty (www.alvit.de/sifrbeauty/
sifr-resources.
Pages:
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151