How to jump between errors and warnings
Below are the keys you can use to go to the next/previous annotation and to initiate quick fix.
Shortcut | Description |
Ctrl+. | Next Annotation. Moves to the next warning/error in the class. |
Ctrl+, | Previous Annotation. Moves to the previous warning/error in the class. |
Ctrl+1 | Quick Fix. A fast way to resolve certain warnings/errors automatically, but also useful for automating common editing tasks. |
Bonus Tip: Also see how to cleanup some of these warnings automatically every time you save.
Only jumping between errors
You might sometimes want to tell Eclipse to only move between errors (and not warnings) when you press the next/previous annotation command. Well, this is controlled by a Next/Previous Annotation dropdown menu in the toolbar (as shown in the image below). As you press the next/previous annotation key (either the keyboard shortcut or toolbar button), Eclipse will move to whatever annotations are checked in the dropdown.
Eclipse’s default only has Errors and Warnings selected (which is a reasonably good default, for once). You could disable Warnings if you only want to move between Errors, or vice versa.
Read full article from Navigate and fix errors and warnings in a class with Eclipse keyboard shortcuts | Eclipse On E
No comments:
Post a Comment