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/opacity.svg - WPT Dashboard Interop Dashboard
<metadata>
<h:title>Opacity on tspan, textPath, and a elements</h:title>
<h:link rel="match" href="opacity-ref.svg"/>
<h:link rel="stylesheet" type="text/css" href="/fonts/ahem.css" />
</metadata>
<style>
text {
font-size: 50px;
}
</style>
<defs>
<path id="path" d="M100, 120 300, 120"/>
</defs>
<text x="100" y="60">
<tspan style="opacity: 0.5">tspan</tspan>
</text>
<text>
<textPath href="#path" style="opacity: 0.5">textPath</textPath>
</text>
<text x="100" y="180">
</text>
<text x="100" y="240">
</text>
<text x="100" y="300" opacity="0.5" font-family="Ahem">
<tspan style="opacity: 0.5">XXXX</tspan>
</text>
</svg>