Parsing SVGs to internal vector format #43
Replies: 15 comments 19 replies
-
This isn't really a formal bug report, so I'm moving it to Discussions. |
Beta Was this translation helpful? Give feedback.
-
Batik has enough bugs, both in the main code and its testing infrastructure, that one cannot reliably run their test suite. Their tests aren't reproducible, if you do not believe this please try to run their "regard test suite". IMO that's the main reason why they do not fix bugs unless they have a CVE attached.
After a lot of work, I managed to transform Batik's tests into something that can be run consistently from CI (at least on Windows). If I write a patch I can reliably check for regressions, so I believe that this project is at least a better place. I'll look at your issues and see what I can do. |
Beta Was this translation helpful? Give feedback.
-
Hello Dan, I've looked at those issues and there seems to be the assumption that Batik is causing certain problems, but I do not see any Batik-specific investigation that I could use. I'm not familiar with your software and do not know what happens under the hood. I'd suggest that you open one or more issues here, each with a sample SVG image that allows to clearly reproduce the problem (with authorisation to include the image as a new rendering test in this project), and also the expected/obtained rendering. You may want to look at The file If you aren't rendering but instead expect a specific value being obtained from some EchoSVG/Batik method, you should also give the relevant values and information to reproduce. I look forward your issues being opened. |
Beta Was this translation helpful? Give feedback.
-
Thanks for taking a look. Do I understand correctly that your fork should be a direct replacement for batik? after changing include paths and module-info, of course. API the same, implementation changed. Our project is maven-based. I see your getting started instructions are all for gradle and build-it-yourself. is there a maven central dependency I can use? |
Beta Was this translation helpful? Give feedback.
-
for maven i added <repositories>
<!-- for echoSVG -->
<repository>
<id>css4j</id>
<name>CSS4J repository</name>
<url>https://css4j.github.io/maven/</url>
</repository>
</repositories> and in module-info.java requires io.sf.carte.echosvg; then fixed all import commands. The only issue stopping my build now is SVGDocument newDocumentFromInputStream(InputStream in) throws Exception {
String parser = XMLResourceDescriptor.getXMLParserClassName();
SAXSVGDocumentFactory factory = new SAXSVGDocumentFactory(parser);
return (SVGDocument) factory.createDocument("",in);
} The system claims it doesn't recognize requires io.sf.carte.echosvg.util; and now i need a hint, please. |
Beta Was this translation helpful? Give feedback.
-
So based on the private static SVGDocument newDocumentFromInputStream(InputStream in) throws Exception {
SAXDocumentFactory factory = new SAXSVGDocumentFactory();
return (SVGDocument)factory.createDocument(null,in);
} and now I get a runtime boot layer failure becaues of |
Beta Was this translation helpful? Give feedback.
-
Exactly, the JPMS wants Xalan to have a Perhaps I should create a EchoSVG FAQ containing this, what do you think? |
Beta Was this translation helpful? Give feedback.
-
MarginallyClever/Makelangelo-software#645 |
Beta Was this translation helpful? Give feedback.
-
Well then my question is "how did you get it to run?" I'm still trying to get around the BSFManager problem to execute the debugger in IntelliJ. |
Beta Was this translation helpful? Give feedback.
-
great. can i please get the maven moditect settings?
…On Thu, Apr 7, 2022 at 11:35 AM carlosame ***@***.***> wrote:
And the new FAQ <https://github.com/css4j/echosvg/blob/master/FAQ.md>
talks about this...
—
Reply to this email directly, view it on GitHub
<#43 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AALFRBTHZ4THXNH53O4YFGLVD4TITANCNFSM5SOPPWDQ>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
--
Dan Royer
Owner, Marginally Clever Robots, Ltd.
------------------------------
1 (604) 259 9564 <16042599564> ***@***.***
https://marginallyclever.com <http://www.marginallyclever.com>
<https://www.facebook.com/MarginallyClever/>
<https://www.instagram.com/imakerobots/>
<https://www.youtube.com/channel/UCfbRxqjuOgE2EzRKxcePArw>
<https://twitter.com/MarginallyC> <https://github.com/MarginallyClever/>
|
Beta Was this translation helpful? Give feedback.
-
The Xalan issue is something that anyone trying to use Maven is going to find. Although my advice is always to migrate from Maven to Gradle (because Maven is not friendly to smaller, non-central repositories), the current situation is unacceptable and I decided to get rid of the Xalan dependency. |
Beta Was this translation helpful? Give feedback.
-
loads for me like the last part of the curve is wrong, namely
When I parse it I in my app what I receive from
My code for this test begins here: On the chance that I'm going blind with age, can you see what I'm doing wrong? Did I forget a + that should be a -? |
Beta Was this translation helpful? Give feedback.
-
Hello! I hope you're doing well. I had enough motivation to day to jump into this again and updated the original bug on makelangelo software with a more thorough analysis of what's going on. I'm using EchoSVG 0.2 and getting the same glitch I had with Batik so...the bug was ported over? |
Beta Was this translation helpful? Give feedback.
-
I don't know if this qualifies as a bug yet...
when trying to load <svg xmlns="http://www.w3.org/2000/svg" width="320" height="320">
<path d="M 10 315
L 110 215
A 36 60 0 0 1 150.71 170.29
L 172.55 152.45
A 30 50 -45 0 1 215.1 109.9
L 315 10" stroke="black"/>
<circle cx="150.71" cy="170.29" r="2" fill="red"/>
<circle cx="110" cy="215" r="2" fill="red"/>
<ellipse cx="144.931" cy="229.512" rx="36" ry="60" fill="transparent" stroke="blue"/>
<ellipse cx="115.779" cy="155.778" rx="36" ry="60" fill="transparent" stroke="blue"/>
</svg> ellipse elements seem to make it mad. |
Beta Was this translation helpful? Give feedback.
-
Given that this discussion is receiving some attention these days, I wanted to point out that the issue with |
Beta Was this translation helpful? Give feedback.
-
Hello! Glad to find a java svg parse that is active.
We're using Batik in makelangelo software and either it has issues or I'm really bad at reading the documentation. I'm looking for an alternative that avoids the issues we've run across.
Have I come to the right place?
Beta Was this translation helpful? Give feedback.
All reactions