We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpIntegration › NetBeans & can't load font
Page Index Toggle Pages: 1
NetBeans & can't load font (Read 872 times)
NetBeans & can't load font
Jul 26th, 2006, 10:56pm
 
Hi,
I am developing a Processing Java applet within NetBeans and I can not figure out where to put the *.vlw file so that NetBeans can find it correctly when I attempt to launch the applet from within NetBeans.

I can launch the applet fine from an HTML page by placing the font in a data/ directory in that HTML page's directory, but from within NetBeans, I get the following NullPointerException.

Any ideas? (The reason I want to run it from within NetBeans is that I want to run the Profiler on the code to determine bottlenecks in my code.)


java.lang.NullPointerException
       at java.io.DataInputStream.readInt(DataInputStream.java:353)
       at processing.core.PFont.<init>(PFont.java:122)
       at processing.core.PApplet.loadFont(PApplet.java:3366)
       at com.sun.labs.constellation.vizsocnet.Constellation.<init>(Constellation.java:62)

       at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
       at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorI
mpl.java:39)
       at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorA
ccessorImpl.java:27)
       at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
       at java.lang.Class.newInstance0(Class.java:350)
       at java.lang.Class.newInstance(Class.java:303)
       at sun.applet.AppletPanel.createApplet(AppletPanel.java:721)
       at sun.applet.AppletPanel.runLoader(AppletPanel.java:650)
       at sun.applet.AppletPanel.run(AppletPanel.java:324)
       at java.lang.Thread.run(Thread.java:613)
Re: NetBeans & can't load font
Reply #1 - Jul 27th, 2006, 9:36pm
 
a subfolder called 'data' relative to the codebase, the location of the code, not the html file itself, should work ok.
Page Index Toggle Pages: 1