SVG icon indicating copy to clipboard operation
SVG copied to clipboard

dominant-baseline="middle" not working?

Open Mehuge opened this issue 3 years ago • 1 comments

Description

dominant-baseline attribute seems to be ignored. Using the svg below the text label middle is expected to be aligned with x axis but the bottom of the text is aligned with the x axis regardless of what dominant-baseline is set to.

image

In the browser this renders as expected:

image

Example data

<svg id="main" viewBox="-20 0 2809.766081871345 1007.1690598469762">
	<!-- X and Y axis  -->
	<line x1="100" y1="900" x2="100" y2="100" style="stroke:rgb(200,200,200);stroke-width:1"></line>
	<line x1="100" y1="900" x2="2389.766081871345" y2="900" style="stroke:rgb(200,200,200);stroke-width:1"></line>
	<text x="20" y="900" fill="rgb(200,200,200)" text-anchor="middle" dominant-baseline="middle"  font-size="51.549707602339176" style="font-family:Roboto">0</text>
</svg>

Used Versions

Svg 3.4.3

Mehuge avatar Oct 14 '22 10:10 Mehuge

See also #977.

mrbean-bremen avatar Oct 14 '22 11:10 mrbean-bremen