HTML and CSS Reference
In-Depth Information
(a) Legend without
embedded style sheet.
default legends
small, italic, blue
legends floated
on the left
(b) Legend with
embedded style sheet.
Figure 6-23
In this style sheet, you will change the color, font-style, and font-size of the legend
(lines 10 through 13), making it blue and smaller than the surrounding text. You will also
use the float property (line 10) to align the legend on the left. In Chapter 3, you used the
float property to align images relative to the Web page text. The float property indicates
in which direction (in this case left or right) to display (or float) an element (the legend)
being inserted on a Web page. It can be an effective Web development practice to use an
alignment element such as float so that you can easily change the alignment if you choose.
Search WWH ::




Custom Search