Open marcuswu opened 2 weeks ago
Looking at the code it seems that it does not support this right now. I'll think about how this could be implemented. I might submit a PR.
I did find a hacky way of working around it for now similar to an SQL injection. I inject attributes via the path id field:
draw.Textpath("Some text here", "#topArc\" text-anchor=\"middle\" startOffset=\"50%", `font-size="25"`, `font-family='Salma Pro'`, `fill="black"`)
@ajstarks I know you have been focused on other libraries / projects (and I considered using one of them instead, but it doesn't cover all of my needs right now. Mainly text along a path), but I would love to have your opinion on the changes I proposed in the above PR.
Code like this:
Results in this xml:
I want the
text-anchor
andstartOffset
fields to be on the<textPath>
tag instead of the<text>
tag. How would I make that happen? Is there a way to define the two tags separately?