Things possible in Eclipse that aren’t possible in IntelliJ?

JavaEclipseIdeIntellij Idea

Java Problem Overview


I have heard from people who swear by one or the other. Both are full-featured, excellent IDEs. But each has slightly different strengths. This is not meant to turn into a holy IDE war. Please downvote any flamebait answers. Thanks.

This is the analog of this question.

Java Solutions


Solution 1 - Java

My favourite small annoyance in IDEA (and favourite small feature in Eclipse) is the positioning of the character when typing an opening curly brace (e.g. "{") or a semicolon. You'll have to enable it in Eclipse (Window/Preferences/Java/Editor/Typing: "Automatically insert at correct position: Semicolon, Braces")

With this just type ahead ("|" is the caret position)

while(|

results (no magic yet) in

while(|)

now type true{, results in

while(true) {|

So simple, yet so powerful.

Also, in (e.g.)

System.out.println("Hello world")

with the caret anywhere in that line, typing a semicolon will automagically type it at the end of the line. Backspace corrects, just like the usual autocorrection in your favourite wordprocessor.

Priceless. I'm physically no longer able to type a semicolon at the correct position on first try :)

Solution 2 - Java

Eclipse's incremental compiler lets you run unit tests even while there are compiler errors in unrelated code. IntelliJ relies on javac which doesn't emit bytecode unless all the code is valid.

Solution 3 - Java

I tried to switch to IntelliJ because of the new Android Studio. But I'm very disappointed now. I'm using Eclipse with the Code Recommenders Plugin. Here is a simple example why Eclipse is so awesome:

I want to create a new SimpleTimeZone. SimpleTimeZone has no Constructor with zero arguments.

Ctrl + Space in Eclipse

enter image description here

Ctrl + Space in IntelliJ

enter image description here

In IntelliJ I get no informations what kind of constructors SimpleTimeZone has.

After Enter in Eclipse

enter image description here

I get the previously selected constructor filled with predefined variable names. And I can see the type of every argument. With Code Recommenders Eclipse guesses the right constructor by the previously defined variable types in the current scope and fills the constructor with these vars.

After Enter in IntelliJ nothing happens. I get an empty constructor. I have to press Ctrl + P to see the expected arguments.

enter image description here

or try something simple. Type

syso<Ctrl+Space>

Eclipse: System.out.println()

IntelliJ: syso

Solution 4 - Java

As far as I know there is no alternative to Eclipse's excellent Mylyn task plugin in IntelliJ.

Solution 5 - Java

Since Eclipse 3.3 (but it can be done before using a plugin), you can automatically execute actions while saving a Java file:

  • organize imports
  • format source code
  • some other actions (like adding annotations, removing unnecessary casts...)

This can be configured in Preferences > Java > Editor > Save actions.

Solution 6 - Java

The open nature of Eclipse platform makes thrive the plugin writers community. There are tons of plugins available for all kind of tasks.

Solution 7 - Java

My favorite Eclipse features:

  • AspectJ integration that includes navigation between aspects and the code, annotation markers showing where aspects are applied, cross reference view, common open typed dialog showing aspect types (recently added)
  • OSGi tooling (aka PDE), editing and optimizing OSGI manifest, refactorings specific to OSGi and declarative services editor (currently in the works)

Solution 8 - Java

I can't figure out how to automatically add javadoc in Intellij, whereas in Eclipse it's just: Shift-Alt-j

Things I don't like about IntelliJ (from an Eclipse developer)

  • Tab key doesn't indent to correct spot with just one tab press.

  • The multi project is the first one...but many people have covered that before so I'll leave it.

  • The splitting of windows. In Eclipse you simply drag the window wherever you want it and it goes there.

  • The font sucks. I changed to the next best one i could find: Liberation Mono, size 14. (Setting>Editor>Colors&Font>Font)

  • Highlighting for XML is nasty...removed the bolds.

  • Syncing the editor window with the file selected in the project navigator. I can't make this happen by default, I have to press the button each time??? Found it:

  • Double clicking in project navigator sometimes doesn't open the file. Sometimes even tripple clicking won't do it. Only a quadruple click opens it up! ** Here is an answer...it's just that the double click speed is too freakin fast: In regards to the double clicking in IDEA the reason why it’s hard to open files by double clicking is that Java programs e.g. IDEA reads the double click speed from X11 resources. If it is not explicitly set then it defaults to 200 ms which is lightning fast. In order to have a more sane threshold create ~/.Xresources and add: *.multiClickSpeed: 400

  • Can't figure out how to get the suggestion: "Assign statement to local variable" that Ctrl-1 gives in eclipse. I use that all the time.

** Yep! This is the Introduce Variable refactoring. By default, select some text, and then hit Ctrl + Alt + V. If the expression is incomplete or invalid, IntelliJ will still make a good guess about what you meant and try to fix it for you.

  • Tab doesn't take line to correct spot right away.

  • Couldn't get it to auto complete properly ** Ctrl-Shift-Space helps...

  • Hot code re-run. In eclipse I can modify a method while in the debugger, and it reloads the frame. ** Right-click: drop-frame

  • Double clicking a variable to highlight it, doesn't highlight other occurrences of the variable.

  • Deprecated methods are not crossed out.

  • Can search properly in Settings menu. All it filters out is top level names as opposed to all strings inside menus themselves. Can't find where to set my jdk!

  • Doesn't compile on the fly, only when I hit 'debug' does it compile.

  • No 'right-click on class and choose New > JUnit' function.

  • When debugging, window comes up at bottom and can't move to where I'd like it. ** Drag the small icon when it's collapsed to whichever side you want it to pop out from.

Things I do like:

  • Paste history is nice:

Ctrl-Shift-V

  • Simply clicking the debug/run icons actually runs the last configuration, eclipse isn't that smart with it ( or it's too smart??? ), and I don't like the way it does it.

  • Autocomplete is very good.

  • Only click once to add a break-point

  • Code collapsing/expanding seems nicer.

  • Ctrl-Shift-- (minus) collapse/fold all.

  • “Column mode” can be turned on it “Edit - Column mode” or with alt + shift + insert

Solution 9 - Java

Only eclipse allows you to step through an ant build in the debugger.

Solution 10 - Java

Idea has no drools plugin and external editors (like excel) are hard to integrate.

Solution 11 - Java

In eclipse you can maximize the editor and in IntelliJ you can click escape, which is similar functionality. But in eclipse you can restore. There's no equivalent "un-maximize" in IntelliJ which is even more frustrating.

Solution 12 - Java

The biggest annoyance I've found (using both) is that in Eclipse I can create Ant Launch tasks. These tasks allow me to run the same ant task in the same build file using different sets of properties/arguments without editing each time.

In IDEA, properties are set across the entire build file. So not only can you not run the same ant task with different properties without editing, but you can't run different ant tasks with different properties unless they are in different build files.

Solution 13 - Java

I've summed up my comparison of Eclipse 3.6 and IntelliJ 10.5 in a blog (focused more on what I like in II or miss there compared to Eclipse)

Solution 14 - Java

Overall I had good working experience in both IDEs so both have many good features. In IDEA 9_0_3 I am facing a strange problem working with SVN. I can see the history of changes in repository view but it shows nothing as incoming changes which is frustrating. The alternate is to update the directories which bring latest but without any choice.. it get all

Solution 15 - Java

A working subversion integration, have a look at the bugs of the idea subversion plugin.

Solution 16 - Java

In eclipse it is possible to get annoyed by making a 10x10 editing area ( cols/row ) and see all the other windows at the same time.

In IntelliJ this in not possible since the 'ESC' key will close them all.

Ok, ok, I'm sorry I have to do it, shoot me now

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionCraig P. MotlinView Question on Stackoverflow
Solution 1 - JavaOlaf KockView Answer on Stackoverflow
Solution 2 - JavaCraig P. MotlinView Answer on Stackoverflow
Solution 3 - JavapasssyView Answer on Stackoverflow
Solution 4 - JavaSamBeranView Answer on Stackoverflow
Solution 5 - JavaRomain LinsolasView Answer on Stackoverflow
Solution 6 - JavaPeter SeverinView Answer on Stackoverflow
Solution 7 - JavaEugene KuleshovView Answer on Stackoverflow
Solution 8 - JavaftraversView Answer on Stackoverflow
Solution 9 - JavaCraig P. MotlinView Answer on Stackoverflow
Solution 10 - JavaArne BurmeisterView Answer on Stackoverflow
Solution 11 - JavaCraig P. MotlinView Answer on Stackoverflow
Solution 12 - JavaInstantsoupView Answer on Stackoverflow
Solution 13 - JavaJakub HolýView Answer on Stackoverflow
Solution 14 - JavaAdnan View Answer on Stackoverflow
Solution 15 - JavaArne BurmeisterView Answer on Stackoverflow
Solution 16 - JavaOscarRyzView Answer on Stackoverflow