HTML and CSS Reference
In-Depth Information
186
Figure 9-9: Changing PNG and GIF fi le sizes.
Changing SVG fi le sizes
Unlike the bitmapped graphics, changing SVG graphic sizes is simple and doesn't hurt the
look of the image. h e following Web page code shows a 500 x 400
.svg
i le displayed in
dif erent sizes determined by the width and height attributes: h e following script (
SVG.
html
in this chapter's folder at
www.wiley.com/go/smashinghtml5
) uses a single
.svg
i le to display many dif erent sizes without distortion.
<!
DOCTYPE HTML
>
<
html
>
<
head
>
<
meta http
-
equiv
=
”Content-Type”
content
=
”text/html; charset=UTF-8”
>
<
title
>
SVG Test
</
title
>
</
head
>