Closed hustf closed 1 year ago
Not sure what you mean here. Is there a fix for some problem that should be a PR to Luxor.jl?
Sorry to have been unclear. Yes, I still believe there is an issue with reading largish svg files which can be fixed by reading the files as string first.
I have opened a fork and am trying to reproduce this parsing error (which of course was persistent a couple days ago).
However, the file size of the svg file is not the problem in itself. I don't know so far what is (or was).
I have a halfway explanation now. We don't need to change anything in Luxor.
Here's the gist:
When we parse an svg file using readsvg(filename)
and readsvg(string_contents_of_filename)
, it seems we are using a less lenient parser.
While testing the current master, I triggered a bug in the fix. The file was not acceptable to the less lenient parser. The best way forward is fixing the bug. I'm putting the details in #150.
Resolved in master. Issue should be closed. If anything happens it's better to create new issues. The existing issues are getting cluttered a bit.
Originally posted by @hustf in https://github.com/JuliaGraphics/Luxor.jl/issues/150#issuecomment-1368536768_
4) From 'adaptive_scaling.jl': 115, linked above:
With the fix above, we can work with extremely large svg files. I believe a similar fix applies to 'Luxor/images/_readsvgfile(fname).