xmlgraphics-batik-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeremias Maerki <...@jeremias-maerki.ch>
Subject Re: IE8 doesn't do SVG, now is good timing for Batik to fix that in a more general way
Date Mon, 17 Mar 2008 07:29:23 GMT
On 16.03.2008 04:05:27 Cameron McCormack wrote:
> Hi Bruce.
> 
> Bruce Rindahl:
> > I am willing to give this a try if you can help point me in the right
> > direction.  I can compile Batik from source and have available VS2005.  I
> > will look into creating an ActiveX plugin but if you have any specific
> > references for me to check let me know.  We desperately need a new plug-in
> > and Batik would be a perfect solution.
> 
> I’d be happy to give you pointers on getting this to work!
> Unfortunately, I know next to nothing about writing ActiveX components,
> so that part you may have to work out yourself.

I've left the Windows development platform a few years back so I'm not
up to date, either. I'd start looking for how to write a plug-in for
Internet Explorer here: http://msdn2.microsoft.com/en-us/library/aa155133.aspx

> I think you could get away with having a JSVGCanvas running in the JVM
> (but not being displayed), and for it to be painted on a
> java.awt.Graphics object implemented with native methods that actually
> draw on the ActiveX component’s canvas.  Mouse and keyboard events could
> be captured on the ActiveX component and then synthesised and dispatched
> to the JSVGCanvas on the Java side.
> 
> But it could end up being more complex than this…

It's definitely going to be complex if animation is important. Otherwise,
you could get away with some minimal effort: just displaying a bitmap
that is rendered inside the JVM from the C part. That way you could keep
the JNI interaction to a minimum. Of course, there's the question about
not only integrating with Internet Explorer but also Firefox and other
browsers. The minimal variant could just be step 1 in order to gain
experience. Small steps....

Just some more brainstorming:
- Better yet: It is important to talk to the Apache Harmony people.
Maybe they have some good ideas. They needed to do the integration of
the class library with the native host system already (which surely
doesn't run via JNI). It might be possible to make use of this to avoid
writing a special adapter layer just for this plug-in. After all,
Harmony is ALv2 so we'd have no legal issues distributing this code.
Harmony could also profit from being used as JVM for such a plug-in.
Plus they don't have their own IE plug-in, yet, which could be a
side-product coming from this. Maybe they would even help with this. At
least, they have people who know how to work with the Windows platform.
The (smaller) downside here: Last I tested, Harmony still had some
problems running Batik. But with something that could push the Harmony
VM, help will certainly be available.
- Maybe it is possible to write a plug-in that embeds Sun's Java Applet
plug-in. That way Batik would simply be used as an applet and Sun's Java
Applet plug-in would do the whole bridging between Java and the host
system.


Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-dev-help@xmlgraphics.apache.org


Mime
View raw message