Helpful Eclipse Shortcuts

Every new IDE requires some time to learn and become accustomed to. After using Eclipse for many years, we have found the following shortcuts speed up software development significantly.

These shortcuts use Windows terms, so Mac OS X users should substitute Command and Option where appropriate:

  • Ctrl + Shift + G with the cursor on a function or field will perform a workspace search for all references to the function or field. For instance, if you want to see where a certain function is called, just click to move the cursor onto the function and press Ctrl + Shift + G.
  • F3 with the cursor on a calling into function will follow that call and bring you to the source code that declares and defines the function. Use this hotkey in combination with Ctrl + Shift + G for easy Java source code navigation. Doing the same on a class name or a field will open up its declaration.
  • Ctrl + spacebar autocompletes the function or field name you are currently typing. Start typing and press the shortcut after you have entered a few characters. When there are multiple possibilities, a box will appear.
  • Ctrl + Shift + O organizes the Java imports of the current source file.
  • Ctrl + Shift + F formats the current source file.
  • Ctrl + Shift + T jumps to any Java class.
  • Ctrl + Shift + R jumps to any resource file; that is, an image, a text file, and so on.
  • Alt + Shift + T brings up the refactor menu for the current selection.
  • Alt + Shift + R rename refactoring for the current selection.
  • Ctrl + Shift + L view listing for all Eclipse keyboard shortcuts.
  • Ctrl + Shift + P go to the matching bracket.
  • Ctrl + O lets you jump to any method or field in the currently open Java class.
  • Ctrl + L go to line.
  • Ctrl + Q going to last edited place.
  • Ctrl + T toggling between super type and subtype.
  • Ctrl + F11 runs the application.
  • F11 debugs the application.
  • Selecting class and pressing F4 to see its Type hierarchy

There are many more useful features in Eclipse, but mastering these basic keyboard shortcuts can significantly speed up your game development and make life in Eclipse just a little better. Eclipse is also very configurable. Any of these keyboard shortcuts can be reassigned to different keys in the Preferences.


Popular posts from this blog