Text handling in SVG is carried out with three elements— <text>, which is always used when laying out text, and, optionally, <tspan> and <tref> elements.
To lay out text, the SVG rendering engine needs to know, in addition to what characters to render, where to place the text, what font and font size to use, and so on. You saw in Listing 23.1, the rollover button example, how text is used with a rollover button.
It is important to notice the difference in how the x and y attributes of <rect> and <text> elements are used. Listing 23.21 illustrates the difference in usage.
<?xml version="1.0" standalone="no"?> ...