Forum How do I...?

text-anchor attributes for svg text elements

ianmaclarty
Hello,

Prince doesn't appear to support the text-anchor attribute for SVG text elements (text in the resulting PDF is always anchored at the start, even if the text-anchor attribute is set to "end").

Is there any plan to support this attribute in the future? Alternatively is there a way I can achieve the same effect by setting a CSS property? If so, which property?

I have some business graphics that I am generating in SVG which I display in firefox (which supports text-anchor) and I want the graphics to appear the same in the PDF generated by prince as they do in firefox.

Cheers,

Ian.
mikeday
Hi Ian,

We should be able to add support for the text-anchor SVG property to the next maintenance release of Prince 5.1.

While we're on the subject, are there any other omitted properties that you might like to see included? :)

(The existing SVG support documentation is a handy reference).

Best regards,

Michael
ianmaclarty
Thanks Michael, that would be great.

There does seem to be a problem with decimal lengths and the stroke-dasharray attribute. I've posted a report to the bugs forum.

Ian.