Skip to content
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

Adding a fix to readNoteType so it properly advances the string #55

Closed
wants to merge 1 commit into from

Conversation

ill
Copy link

@ill ill commented Jul 14, 2017

Adding a fix to readNoteType so it properly advances the string when it didn't read a new command char and reruns the same command.

Was having a problem where some of my svgs weren't loading.

I have confirmed this is the right behavior from here:

https://www.w3.org/TR/SVG2/paths.html

"The command letter can be eliminated on subsequent commands if the same command is used multiple times in a row (e.g., you can drop the second "L" in "M 100 200 L 200 100 L -100 -200" and use "M 100 200 L 200 100 -100 -200" instead)."

…it didn't read a new command char and reruns the same command.
@Chlumsky
Copy link
Owner

Omission of repeated commands has been supported by the SVG parser from the beginning, your file couldn't be loaded due to extra commas. I have now fixed this in 28ee740.

@Chlumsky Chlumsky closed this Jul 23, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants