Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #1462
| From | Albert Retey <awnl@gmx-topmail.de> |
|---|---|
| Newsgroups | comp.soft-sys.math.mathematica |
| Subject | Re: WebMathematica and SVG graphics |
| Date | 2011-04-04 10:32 +0000 |
| Organization | Steven M. Christensen and Associates, Inc and MathTensor, Inc. |
| Message-ID | <inc6n2$10o$1@smc.vnet.net> (permalink) |
| References | <in3uun$hq1$1@smc.vnet.net> |
Am 01.04.2011 09:30, schrieb Eduardo:
> Hi,
>
> I have some Mathematica plots with interactive features like Tooltip
> and Mouseover which I'm trying to reproduce in a web environment using
> WebMathematica. From the documentation it is not clear how far one can
> go. Exporting a ListPlot with Mouseover effects drops the interactive
> component when it is rendered as a GIF or SVG.
>
> One approach I am trying is to write the plot as SVG and then use
> Mathematicas XML capabilities to insert the Mouseover in the SVG.
> Apparently in version 5.0 there was a function
> XML`SVG`GraphicsToSymbolicSVG which returned the SVG code, but in 8.0
> I can only find Export[] in SVG format. So my questions are:
>
> 1) Is there a better way to do this, getting interactive plot features
> like Mouseover into a web graphics format?
> 2) If SVG is the way to go, is there a package in 8.0 that can help
> (like XML`SVG` in 5.0)
> 3) If not, is there a way to Export the SVG to an in memory variable
> for further processing, rather than to a file?
>
> Any pointers a greatly appreciated.
Why do you think that XML`SVG`GraphicsToSymbolicSVG does not work
anymore? I just tried it (using the full name with all contexts and
without loading any package) with 8.0.1 on Windows and it worked alright:
XML`SVG`GraphicsToSymbolicSVG[Plot[x^4, {x, 0, 1}]]
Alternatively, you could also use something like this, which would not
rely on undocumented features:
ImportString[ExportString[Plot[x^4, {x, 0, 1}], "SVG"], "XML"]
I have no suggestions for other formats or techniques to create web
grahpics formats, but it might be worthwhile to explore since I found
the above to be relatively slow even for simple plots...
hth,
albert
Back to comp.soft-sys.math.mathematica | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
WebMathematica and SVG graphics Eduardo <eduzea@gmail.com> - 2011-04-01 07:30 +0000
Re: WebMathematica and SVG graphics Albert Retey <awnl@gmx-topmail.de> - 2011-04-04 10:32 +0000
Re: WebMathematica and SVG graphics Alexey <lehin.p@gmail.com> - 2011-04-05 10:41 +0000
csiph-web