How do I attatch javadoc for "java.awt.Graphics?"

Hi,

I have installed the javadoc’s to my computers location. However I noticed that graphics2d methods have no attatched javadoc. Because I am a graphics2d noob, I would like the javadoc’s installed.

Thanks for any help!

p.s. I did google this first. For about 15 minutes. This is my last resort :confused:

I assume you’re talking about eclipse?

If so, right click your project, then go to properties. In the Properties menu, go to the Java Build Path section on the left. On that section, go to the Libraries tab.

On the Libraries tab, you should have a JRE or a JDK listed. Expand that by clicking the little triangle next to it, and under that you should see rt.jar. Expand rt.jar, and you should see a Source Attachment option. Click that and then click the edit button, which brings up a dialog where you can enter the location of the source zip.

The source zip comes with the JDK, so it’s in the directory your JDK is in. For example mine is located at C:/Program Files/Java/jdk1.7.0_51/src.zip

Select “External location” and then navigate to your src.zip location, then click OK in all of the screens. That should do it!

If that doesn’t make sense, googling “eclipse attach jdk source” seems to return a bunch of informative results. Like this one: http://www.mkyong.com/eclipse/eclipse-how-to-attach-jdk-source-code/

Edit: I believe you can also do this from the “this class doesn’t have any attached source” screen, just click the “attach source” link/button and then navigate to the src.zip in your JDK. The effect should be the same though.

Thank you!

This fixes everything. I am also sorry I didn’t post I was using Eclipse. However, like a boss, you swooped in and helped me out. Thanks man!

;D