Files
ladybird/Tests/LibWeb/Layout/input/svg-text-dominant-baseline.html
Tim Ledbetter f05bc7c0cd LibWeb: Implement dominant-baseline for SVG text
This property determines the default baseline used to align content
within the given box.
2026-02-26 09:23:23 +01:00

18 lines
1.4 KiB
HTML

<!DOCTYPE html>
<svg viewBox="0 0 400 400" width="400" height="400" xmlns="http://www.w3.org/2000/svg">
<line x1="0" y1="50" x2="400" y2="50" stroke="gray" stroke-width="0.5"/>
<line x1="0" y1="100" x2="400" y2="100" stroke="gray" stroke-width="0.5"/>
<line x1="0" y1="150" x2="400" y2="150" stroke="gray" stroke-width="0.5"/>
<line x1="0" y1="200" x2="400" y2="200" stroke="gray" stroke-width="0.5"/>
<line x1="0" y1="250" x2="400" y2="250" stroke="gray" stroke-width="0.5"/>
<line x1="0" y1="300" x2="400" y2="300" stroke="gray" stroke-width="0.5"/>
<line x1="0" y1="350" x2="400" y2="350" stroke="gray" stroke-width="0.5"/>
<text x="10" y="50" font-size="20" font-family="SerenitySans" dominant-baseline="auto">auto</text>
<text x="10" y="100" font-size="20" font-family="SerenitySans" dominant-baseline="alphabetic">alphabetic</text>
<text x="10" y="150" font-size="20" font-family="SerenitySans" dominant-baseline="central">central</text>
<text x="10" y="200" font-size="20" font-family="SerenitySans" dominant-baseline="middle">middle</text>
<text x="10" y="250" font-size="20" font-family="SerenitySans" dominant-baseline="hanging">hanging</text>
<text x="10" y="300" font-size="20" font-family="SerenitySans" dominant-baseline="ideographic">ideographic</text>
<text x="10" y="350" font-size="20" font-family="SerenitySans" dominant-baseline="mathematical">mathematical</text>
</svg>