Eclipse's annotation browser

I switched from Eclipse to IntelliJ community edition two weeks ago.B-) Very good IDE although I am still not as productive as with eclipse due to shortcuts learning curve.

I would like to talk about a functionality I miss from eclipse so far.

Eclipse has an "annotation" browser that lets you choose over what type of annotation you want to cycle (errors, warning, occurrences, ...). You go to next annotation using ctrl+. and previous with ctrl+, (resp. control plus period and control plus comma).
I used to set cycling to "occurrences" ( = usages of identifier under caret), and I used this features very very frequently :)


In IDEA this is a bit more complicated. You have to hit Ctrl+shift+F7 each time you plan to browse usages in a file, then hit F3 to browse, then Esc to disable browsing mode. For me it is a real pain.

And there are multiple issues when I try to mimic eclipse behavior with macros:

  • Conflicts using esc in macro in cunjunction with Ctrl in macro mapping: ctrl+esc fires Windows start menu
  • using Ctrl+<whatever insertable character> either during the macro or for the macro mapping randomly inserts the given character.

Did not find yet working mappings. It's unfortunate, because F2 works just as expected, except it is not configurable to include other than errors/warnings.

Another detail from eclipse i'd like to mention, in eclipse's keymap preference page, you can do an inline search over keys. This is useful when you hit a keystroke without knowing what it does, and you are curious about it. Workaround: I do "Add Keyboard Shortcut..." to whatever action and try the keystroke there.

Comment actions Permalink

dunno about eclipse functionality (annotations) but:
-  you can switch to eclipse keymappings if you like (settings > keymap and select eclipse from the dropdown)
- Use: ctrl + shift + a to find the keymappings for specific action
- intellij has shortcuts for going to next (error, warning, change etc)

dunno if this is of any help..

Comment actions Permalink

Thanks for reply.

Actually I noticed about eclipse keymappings but I prefered to go ahead and try IDEA ones. :p

The real problem of eclipse's "next annotation" in IDEA is that you have to enter in a special mode: "Highlight usages in file".

It is only true for usages in file. As you said, there are straightforward shortcuts to navigate through errors, warnings, changes, etc.

Comment actions Permalink

Ctrl+F7 to start the search and F3 to cycle?

You could also enable "auto highlight symbol under caret" (something like that), this automatically highlight the current symbole, looks similair to highlight usages.


Comment actions Permalink

Thanks for the tip, Ctrl+F7 then F3 does not include declaration and first jumps to the first usage, but it is more usable than the way I was doing.

And yes, I find "Highlight usages of element at caret" to be invaluable; as an eclipse user it was the first setting I looked for :x


Please sign in to leave a comment.