Developing ImageJ in Eclipse
Install and configure Eclipse
Install the Java Development Kit
- Download and install the Java Development Kit (JDK) from the Java web site.
- Download "Eclipse IDE for Java Developers" from the Eclipse web site.
- Unpack the archive to a location of your choice.
Configure Eclipse for your platform
Avoid permissions issues. We recommend installing Eclipse outside of the
Configuring Eclipse. After installing Eclipse, you will need to configure it to know about your JDK.
Use Wordpad to edit the
Now update Eclipse's JRE to be JDK-aware:
Understand Java 6 vs. Java 8. Eclipse should work on OS X with no further configuration. However, we recommend reading the OS X section of the FAQ, as there are several Java-related issues on OS X.
Avoid permissions issues. We recommend installing to
Do not use a package manager. For several reasons, we do not recommend installing Eclipse from a package manager. You may not get a new enough version of Eclipse (we recommend 4.3+), you will not get the Java Developers version that includes the M2E plugins, and you will likely have trouble installing additional plugins due to the permissions issues with the system-wide installation.
Clone the source code
Import the source code
- Choose from the Eclipse menu ›
- Select "Existing Maven Projects" and click Next
- Browse to the folder where you cloned the project source code
- Click Finish
If you cloned the imagej project, you can launch the program as follows:
- In the Package Explorer, expand the
- Navigate into
- Navigate into
- Right-click on
- Choose "Run As" and then "Java Application"
Other projects will have different main classes.
For Mac, replace ^ Ctrl with ⌘ Cmd
|^ Ctrl+⇧ Shift+T||find objects|
|^ Ctrl+1||quick fix|
|F3||jump to class (to edit the code, see snapshot coupling)|
|^ Ctrl+O||show outline|
|^ Ctrl+T||shows all implementations of interface or class|
|⎇ Alt+↑, ⎇ Alt+↓||move current line up or down|
|^ Ctrl+D||delete the current line|
|^ Ctrl+/||comment out (or uncomment) the currently selected line(s)|
|^ Ctrl+⇧ Shift+O||organize imports|
|^ Ctrl+⇧ Shift+F||format code (BUT make sure you set the coding style)|
|⎇ Alt+⇧ Shift+S U||clean up (does format and much more)|
|⎇ Alt+⇧ Shift+R||refactor rename|