Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /svg/text/reftests/text-text-anchor-201.svg - WPT Dashboard Interop Dashboard
<?xml version="1.0" encoding="utf-8"?>
<svg id="svg-root"
width="100%" height="100%" viewBox="0 0 480 360"
<g id="testmeta">
<title>Text: Text Anchor — 201</title>
<html:link rel="author"
title="Tavmjong Bah"
href="mailto:tavmjong@free.fr"/>
<html:link rel="help"
<html:link rel="match" href="text-text-anchor-201-ref.svg" />
</g>
<style id="test-font" type="text/css">
/* Standard Font (if needed). */
@font-face {
font-family: FreeSans;
src: url("fonts/FreeSans.woff") format("woff"),
local("FreeSans");
}
text { font-family: FreeSans, sans-serif }
</style>
<style id="test-style" type="text/css">
/* Style that is being tested (if needed). */
text { font-family: FreeSans, sans-serif }
</style>
<!-- TEMP -->
<g id="test-body-reference" style="font-size:16px;fill:red">
<g transform="translate(0,0)">
<circle cx="200" cy="114.8" r="2" style="fill:red"/>
<text x="200" y="114.8">Lorem ipsum dolor</text>
</g>
<g transform="translate(0,60)">
<circle cx="200" cy="114.8" r="2" style="fill:red"/>
<text x="200" y="114.8" style="text-anchor:middle">sit amet, consectetur</text>
</g>
<g transform="translate(0,120)">
<circle cx="200" cy="114.8" r="2" style="fill:red"/>
<text x="200" y="114.8" style="text-anchor:end">adipisicing elit,</text>
</g>
</g>
<g id="test-body-content" style="font-size:16px">
<text>
<tspan x="200" y="114.8" style="text-anchor:start">Lorem ipsum dolor</tspan>
<tspan x="200" y="174.8" style="text-anchor:middle">sit amet, consectetur</tspan>
<tspan x="200" y="234.8" style="text-anchor:end">adipisicing elit,</tspan>
</text>
</g>
</svg>