Ok. I have read all the posts out there and I still am coming up with undesirable results. Can someone explain the steps I need to do to get JFreeChart working on a UNIX box (Weblogic and JDK 1.3) using the PJAToolkit?
I have already downloaded pja.jar and pjatools.jar
I put those in the java classpath. When I try to run any of my charts, I get
java.lang.Error: Could not find class: com.eteks.awt.PJAToolkit
Thanks in advance.
Jeremy
How do I use PJAToolkit to solve x11 problem on UNIX box?
You have to add the libraries to the boot classpath, not the normal classpath, and then pass additional options to the JVM, like:
-Xbootclasspath/a:${PJALIB}/pja.jar -Dawt.toolkit=com.eteks.awt.PJAToolkit -Djava.awt.graphicsenv=com.eteks.java2d.PJAGraphicsEnvironment -Djava2d.font.usePlatormFont=false -Djava.awt.fonts=/usr/j2se/jre/lib/fonts.
When using Tomcat, these options can be added to the CATALINA_OPTS environment variable, before starting Tomcat.
This is working for me on Solaris 8.
Regards
Georg
-Xbootclasspath/a:${PJALIB}/pja.jar -Dawt.toolkit=com.eteks.awt.PJAToolkit -Djava.awt.graphicsenv=com.eteks.java2d.PJAGraphicsEnvironment -Djava2d.font.usePlatormFont=false -Djava.awt.fonts=/usr/j2se/jre/lib/fonts.
When using Tomcat, these options can be added to the CATALINA_OPTS environment variable, before starting Tomcat.
This is working for me on Solaris 8.
Regards
Georg
Thanks Georg, that FINALLY makes sense now!
I am going to go and try that right now. I am having the sys. admin. change the options as I type this.
I will let you know the results!
Thanks again for the help.
Jeremy
I will let you know the results!
Thanks again for the help.
Jeremy
Well, that didn't quite work. I am getting .. (in)
java.lang.ExceptionInInitializerError: java.lang.ClassCastException: com.eteks.awt.PJAToolkit
at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:58)
at java.awt.Font.initializeFont(Font.java:264)
at java.awt.Font.<init>(Font.java:298)
at org.jfree.chart.plot.PiePlot.<clinit>(Unknown Source)
at org.jfree.chart.ChartFactory.createPieChart(Unknown Source)
Any thoughts?
at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:58)
at java.awt.Font.initializeFont(Font.java:264)
at java.awt.Font.<init>(Font.java:298)
at org.jfree.chart.plot.PiePlot.<clinit>(Unknown Source)
at org.jfree.chart.ChartFactory.createPieChart(Unknown Source)
Any thoughts?
Re: How do I use PJAToolkit to solve x11 problem on UNIX box
Hi everybody,
I have the same problem. I'm working with Weblogic 5.1 and j2sdk1_3_1_01. On my local machine there isn't any problem. But no in epicentric (with UNIX). The version of jFreeChart I have is jFreeChart 0.9.8. I have the classpath wrritten below.
Could anybody try to hepl me to solve my problem???
Thanls a lot,
Regards.
I have the same problem. I'm working with Weblogic 5.1 and j2sdk1_3_1_01. On my local machine there isn't any problem. But no in epicentric (with UNIX). The version of jFreeChart I have is jFreeChart 0.9.8. I have the classpath wrritten below.
Could anybody try to hepl me to solve my problem???
Thanls a lot,
Regards.
jred33 wrote:Ok. I have read all the posts out there and I still am coming up with undesirable results. Can someone explain the steps I need to do to get JFreeChart working on a UNIX box (Weblogic and JDK 1.3) using the PJAToolkit?
I have already downloaded pja.jar and pjatools.jar
I put those in the java classpath. When I try to run any of my charts, I get
java.lang.Error: Could not find class: com.eteks.awt.PJAToolkit
Thanks in advance.
Jeremy
Try the bootClasspath as listed by.....
See Georg's post above.
"You have to add the libraries to the boot classpath, not the normal classpath, and then pass additional options to the JVM, like:
-Xbootclasspath/a:${PJALIB}/pja.jar -Dawt.toolkit=com.eteks.awt.PJAToolkit -Djava.awt.graphicsenv=com.eteks.java2d.PJAGraphicsEnvironment -Djava2d.font.usePlatormFont=false -Djava.awt.fonts=/usr/j2se/jre/lib/fonts. "
Changing from the normal classpath to the boot classpath moved me further along. My next problem looks to be adding the java.awt.fonts property. That also seems to be required.
-Jeremy
"You have to add the libraries to the boot classpath, not the normal classpath, and then pass additional options to the JVM, like:
-Xbootclasspath/a:${PJALIB}/pja.jar -Dawt.toolkit=com.eteks.awt.PJAToolkit -Djava.awt.graphicsenv=com.eteks.java2d.PJAGraphicsEnvironment -Djava2d.font.usePlatormFont=false -Djava.awt.fonts=/usr/j2se/jre/lib/fonts. "
Changing from the normal classpath to the boot classpath moved me further along. My next problem looks to be adding the java.awt.fonts property. That also seems to be required.
-Jeremy
Jeremy,
the options I posted work for me on a Tomcat/Solaris 2.8 box. They worked with Tomcat 3.2.1 and now they work with 1.4.0.
Sorry, I cannot give you more info on this (no Weblogic available).
Most probably, moving to 1.4.1 would be the best solution, but I guess, that road is blocked in your city...
Georg
the options I posted work for me on a Tomcat/Solaris 2.8 box. They worked with Tomcat 3.2.1 and now they work with 1.4.0.
Sorry, I cannot give you more info on this (no Weblogic available).
Most probably, moving to 1.4.1 would be the best solution, but I guess, that road is blocked in your city...
Georg