Installing Eclipse on Windows XP and Vista

This page tells you how to download Eclipse for Windows XP and Vista, install it, and configure it so that it looks like how I use it. If you need help, Blitz cs5help@cs.dartmouth.edu.

How to download and install Java

Your computer might or might not already have Java installed. Before you install Ecipse check to make sure you have Java. The official Java download website has a link to downloading Java, as well as one for determining whether you have Java already.

If you aren't sure whether you have Java or not, you can download and install Java anyway. All the installer will do if you already have it is upgrade it or tell you that you already have it.

Once you've installed (or checked that you already have) Java, it's time to download and install Eclipse.

How to download and install Eclipse

  1. Go to http://www.eclipse.org/downloads/ to download a copy of eclipse. The page will look like this:

    The first item listed is "Eclipse IDE for Java Developers (99 MB)." You (probably) want the 32-bit version, unless you have some reason to believe otherwise. (The 32-bit version will work just fine even on a 64-bit windows computer.)

  2. You will see the following window:

    Click on the green, downward pointing arrow. A download of eclipse-java-helios-win32.zip will start. Save the file to a convenient location, like your Desktop.

  3. Find eclipse-java-helios-win32.zip from wherever you saved it. Then double-click it. It will open with the default windows extraction wizard or with an extraction tool like Winzip or Winrar. You will see a folder named "eclipse."

  4. Drag the "eclipse" folder into your "Program Files." The easiest way to do so is to go to "Computer" (or "My Computer")--> "Local Disk (C:)" --> "Program Files" and drag the "eclipse" folder into the "Program Files" folder. Make sure that you do not drag it into a folder that's already within "Program Files." In other words, when you're done, the "Program Files" folder should have directly within it a folder named "eclipse." If Windows displays any dialog boxes asking for permission, click "allow" or "permit."

  5. (This step is not required, but it's strongly recommended.) Double click the "eclipse" folder. You'll see an application named "Eclipse"; it has a purple icon with white horizontal stripes. Right-click it and press "Send To" -> "Desktop (Create Shortcut)." Now you will be able to launch Eclipse from your desktop.

  6. You may now drag eclipse-java-galileo-win32.zip to the "Recycle Bin." Empty the "Recycle Bin" whenever you wish.

  7. Go ahead and open up Eclipse. You'll see something like the following window:

    Of course, the workspace name will have your user name in place of "Zach." You can choose whatever place you want for your workspace, but it's easiest to just use the default you're given. I recommend that you just click the checkbox next to "Use this as the default and do not ask again" and then click "OK."

  8. You'll then see the following screen:

    Click on the folded-over arrow on the right. You'll see the tooltip on the above screen when you move the mouse over the arrow. You won't see this screen again, even if you quit Eclipse and relaunch it.

  9. Now you'll see the following screen:

    Lots of buttons and panes, but nothing of consequence.

  10. You have now installed Eclipse!

How to configure Eclipse

You don't have to configure Eclipse so that it looks like how I use it, but you'll probably avoid some confusion if you do so. Here's how.
  1. In the Eclipse menu bar, click on the "Window" menu and then on "Preferences." You'll see a window with two panes. On the left pane is a list of types of things you can configure.

  2. Click on the plus sign to the left of "General." Then click on the plus sign to the left of "Appearance." Then click on "Colors and Fonts." You should see a window like this:

  3. In the window in the middle, click on the plus sign next to "Java." Then double-click on "Java Editor Text Font."

    As you can see, there's some text following "Java Editor Text Font." Don't worry about it.

  4. The following window will pop up:

    On the right, where you can select the size, click "12." Then close this window by clicking on the ok button.

  5. Close up the "General" preferences by clicking on the minus sign to the left of "General." Click the plus sign next to "Java" and then click the plus sign next to "Code Style." Then click "Formatter." Here's what you should see:

  6. Click the button that says "New...". You'll see a window such as this one:

    You can type in any profile name you like. I used "CS 5":

    Then click "OK."

  7. You should see a window that looks like this:

    Change the tab size to 2:

    You'll see that the Indentation size automatically changes as well.

  8. Click on "Blank Lines," and after "Between import groups" and "Before declarations of the same kind," change the values 1 to 0:

  9. Click on "Control Statements," and check the boxes as I've done here:

    Click "OK."

  10. Now click on minus sign to close up "Java." Click on the plus sign next to "Run/Debug," and then click on "Console."

  11. Click on the green color sample next to "Standard In text color." You'll get a color picker:

  12. Click on the box with the Darker Green (You're at Dartmouth. What other color could you possibly want?)

    Close the color picker window by clicking "OK", and click "OK" again to close the Preferences window.

  13. Finally, I don't use the Task List and Outline panes, which are on the right-hand side of the window. Click on the "X" next to "Task List" and next to "Outline" in the tabs of these panes:

    You'll get something like this:

    And you're done!


Thomas H. Cormen <thc@cs.dartmouth.edu>
Last modified: Fri Mar 25 16:37:28 2011