-
Notifications
You must be signed in to change notification settings - Fork 25
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
Unescape when creating SVG files #2
Comments
Howdy. I'd be happy to add this. Could you give an example of what you're trying to do and the dot output you'd expect to see? |
Dave, Thanks for looking into this. I have included an example blw. (-> (digraph [ [:a :b] [:a :c] [:a {:label "A\nSubheading\nAn example link."}] ]) dot (save! "test.dot" Running this results in the attached test.dot file which looks ok, but when (-> (digraph [ [:a :b] [:a :c] [:a {:label "A\nSubheading\nAn example link."}] ]) dot (save! "svg.dot" it results in the attached test.svg which has the html chars escaped. I have handedited the attached svg-retrofit.svg to match my expected result. I realise that this looks like a Graphviz issue, but am hoping you might /mac On Sun, Mar 10, 2013 at 4:45 AM, Dave Ray notifications@github.com wrote:
|
Hi. Sorry about the delayed reponse. ClojureWest happened :) I've played around with this a bit and it doesn't seem that there's a way to defeat the escaping of the content in SVG text nodes, at least in part because of this change: http://www.graphviz.org/mantisbt/view.php?id=560 Interestingly, wrapping the label in html tags which should invoke Graphviz's html support causes the text to be completely omitted from the SVG output. I guess it's understandable in that they might not know how to layout the text of a node when it contains arbitrary markup. So, I'm not sure what can be done. You could devise some kind of post-processing step, but I'm not sure whether that would give you good results. :( |
Dave, Thanks for the response and thanks again for looking into this. I agree it As much as I hate it will try do some post-processing of the SVG /mac On Fri, Mar 22, 2013 at 6:01 AM, Dave Ray notifications@github.com wrote:
|
Thanks for making dorothy. It is really easy to use. I am currently using it to generate SVG diagrams. In doing so I have trying to embed links in the diagrams. Graphviz of course supports links on nodes and edges, but I need to generate links on for instance a part of a label. To that end I have tried to embed raw svg strings in the label text, but dorothy (graphviz?) escape these. Is there a way to circumvent this behaviour or an alternative way of accomplishing what I am trying to do?
The text was updated successfully, but these errors were encountered: