New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for dx, dy attributes for text #44
Comments
flutter_svg had an incorrect but sometimes working implementation of this. I'm not really sure if we should bother carrying it over or not. There is at least one SVG I had as a test case that happened to work because it fell into the almost-correct part of what was implemented (text_02.svg). A correct implementation of this needs to know the "current text position", which would either require offline text measurement or require us to make several I'm inclined to pass on this for now. |
Updating to v2 also breaks text that uses v1.1.6 v2 svg
|
dx and dy shoul dbe working now, but this SVG is showing a different bug. |
(it doesn't use dx/dy at all) |
Sorry, I thought the transform and dx/dy were related, especially because it stopped working with v2. |
Actually, try just running |
@dnfield I am encountering this on flutter_svg 2.0.5 and vector_graphics 1.1.5 (1.1.5+1 available), should I update a different package? |
You need 1.1.5+1 to fix the issue you're seeing. Do |
It doesn't work with 1.1.5+1 if Example: <?xml version="1.0" encoding="UTF-8"?>
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="700" height="500" viewBox="0 0 700 500">
<g>
<text text-anchor="end" x="50" y="20" transform="translate(0,300)">1</text>
</g>
<g class="ytick">
<text text-anchor="end" x="50" y="20" transform="translate(0,200)">2</text>
</g>
<g class="ytick">
<text text-anchor="end" x="50" y="20" transform="translate(0,100)">3</text>
</g>
</svg> Expected result: Actual result: Should I submit a new bug? |
Yes |
No description provided.
The text was updated successfully, but these errors were encountered: