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
Rendering issue #742
Comments
Which platform? |
Tried on web, macos and iOS and it has same result. |
This is a bug in the path parsing library. Specifically, it's not handling concatenated arc commands well right now. This is a smaller reproduction <svg xmlns="http://www.w3.org/2000/svg" width="45" height="45">
<g fill="none" fill-rule="evenodd" stroke="#000" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" transform="scale(4)">
<path d="M5.5 5.5a.5 1.5 30 1 1-.866-.5.5 1.5 30 1 1 .866.5z" fill="black" stroke="black" />
</g>
</svg> |
Ahh it's not even just back to back arcs, the decomposition math is wrong for the arcs in here. |
path_parsing is failing to convert degrees to radians when doing a matrix rotation operation. Ugh. How did this ever work. |
I have a fix for this and I'm very curious how many golden image tests it breaks in google. |
Thank you for your quick resolution. I started learning flutter 2 days ago, not familiar with the term golden image tests in Google, does it mean that there might be an issue on web? |
Closed by mistake, just wanted to leave comment |
No, sorry - this package is used internally at Google by a large number of golden image tests. Fixing this could potentially change them if people accepted this mistake. Luckily, it looks like not many of the tests internal to Google use this feature :) I'll be publishing a fix for this soon. |
(In other words - this is a real bug, but it's been around since I created this package so some people might be depending on the incorrect behavior, which is sad) |
Just tested, works great! |
For future me:the reason this wasn't caught sooner is because most usages that were ever seriously tested were circular (or roughly circular) arc commands, where the rotation didn't make a difference. |
SVG:
Expected result:
Actual result:
The text was updated successfully, but these errors were encountered: