Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » Trying to get the ACM Libraries to work in Eclipse
Trying to get the ACM Libraries to work in Eclipse [message #903742] Sat, 25 August 2012 11:03 Go to next message
Dan Donovan is currently offline Dan DonovanFriend
Messages: 2
Registered: August 2012
Junior Member
I am trying to get the ACM Libraries to work in eclipse so I can work through the problems in the "Art and Science of Java" if you are unfamiliar with the libraries they can be found here:
jtf.acm.org/

I worked through the tutorials that came with eclipse and worked out how to get the SWT Hello World program up and running but I seem to be unable to apply the principal I learned in that tutorial to getting a similar type program up and running using the ACM Libraries.

I am trying to run a very simple program(page 25, 'Art and Science of Java' if you want to reference it):

import acm.graphics.GLabel;
import acm.program.GraphicsProgram;

public class HelloWorldACM extends GraphicsProgram {
public void run() {
add(new GLabel("Hello, World", 100, 75));
}
}

And I get a ton of these errors:
Exception in thread "main" java.lang.NullPointerException
at sun.awt.FontConfiguration.getVersion(Unknown Source)
at sun.awt.FontConfiguration.readFontConfigFile(Unknown Source)
at sun.awt.FontConfiguration.<init>(Unknown Source)
at sun.awt.windows.WFontConfiguration.<init>(Unknown Source)
at sun.awt.Win32GraphicsEnvironment.createFontConfiguration(Unknown Source)
at sun.java2d.SunGraphicsEnvironment$2.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.java2d.SunGraphicsEnvironment.<init>(Unknown Source)
at sun.awt.Win32GraphicsEnvironment.<init>(Unknown Source)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at java.lang.Class.newInstance0(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(Unknown Source)
at java.awt.Window.init(Unknown Source)
at java.awt.Window.<init>(Unknown Source)
at java.awt.Frame.<init>(Unknown Source)
at java.awt.Frame.<init>(Unknown Source)
at sun.applet.AppletViewer.<init>(Unknown Source)
at sun.applet.StdAppletViewerFactory.createAppletViewer(Unknown Source)
at sun.applet.AppletViewer.parse(Unknown Source)
at sun.applet.AppletViewer.parse(Unknown Source)
at sun.applet.Main.run(Unknown Source)
at sun.applet.Main.main(Unknown Source)
at sun.applet.AppletViewer.main(Unknown Source)


I have added the external jar to the buildpath; or at least I believe I am adding it to the buildpath however I could be wrong. Any help getting through this error would be most appreciated and I am sure it's probably the most newb of newb issues but it's creating a wall between what I want to get accomplished and what I am currently able to get done and I want to smash that wall down. Wink

Thank you for your help. Also feel free to ask for more info and I will try my best to get you what you need.
Re: Trying to get the ACM Libraries to work in Eclipse [message #903747 is a reply to message #903742] Sat, 25 August 2012 12:04 Go to previous messageGo to next message
Dan Donovan is currently offline Dan DonovanFriend
Messages: 2
Registered: August 2012
Junior Member
I also used the directions from
facwiki.cs.byu.edu/cs142fa10/index.php/Using_the_ACM_library/Eclipse
to no avail.
Re: Trying to get the ACM Libraries to work in Eclipse [message #1067634 is a reply to message #903742] Tue, 09 July 2013 17:33 Go to previous message
Allen Chertoff is currently offline Allen ChertoffFriend
Messages: 1
Registered: July 2013
Junior Member
Dan, i don't see an answer to your request, did you ever get it working. if you did please post a "how to". I'm also reading "Art and Science of Java", and you would save me a lot of time and effort if you figured this out.
Previous Topic:No repository found at
Next Topic:BIRT software download borken
Goto Forum:
  


Current Time: Sat Nov 29 04:06:08 GMT 2014

Powered by FUDForum. Page generated in 0.02219 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software