You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-users@xmlgraphics.apache.org by Jane Singer <js...@cc.huji.ac.il> on 2002/08/04 18:00:09 UTC

SVGApplication Apache example code

I'm trying to run the example SVGApplication that appears on the Apache site.
I am getting an error about the getActionMap() method of the  javax.
swing.JComponent.

This occurs on the second line of the Main():
JFrame f = new JFrame("Batik");
SVGApplication app = new SVGApplication(f);

Can anyone tell me why?

This is what I get:

AppAccelerator(tm) 1.2.010 for Java (JDK 1.2), x86 version.
Copyright (c) 1997-1999 Inprise Corporation. All Rights Reserved.
java.lang.reflect.InvocationTargetException: java.lang.NoSuchMethodError: javax.
swing.JComponent: method getActionMap()Ljavax/swing/ActionMap; not found
        at org.apache.batik.swing.JSVGCanvas.<init>(Unknown Source)
        at org.apache.batik.swing.JSVGCanvas.<init>(Unknown Source)
        at myDom.SVGApplication.<init>(SVGApplication.java:36)
        at myDom.SVGApplication.main(SVGApplication.java:21)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.borland.jbuilder.util.BootStrap.invokeMain(Unknown Source)
        at com.borland.jbuilder.util.BootStrap.main(Unknown Source)


Thanks!

Jane




Re: SVGApplication Apache example code

Posted by J Aaron Farr <ja...@yahoo.com>.
--- Jane Singer <js...@cc.huji.ac.il> wrote:
> I'm trying to run the example SVGApplication that appears on the Apache site.
> I am getting an error about the getActionMap() method of the  javax.
> swing.JComponent.
> 

The issue is that you are using JDK 1.2.  ActionMap is a 1.3 class.  Switch to
1.3+ and you shouldn't have any problems.

If anyone else knows any better, please speak up.

jaaron

__________________________________________________
Do You Yahoo!?
Yahoo! Health - Feel better, live better
http://health.yahoo.com

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