Sunday, September 12, 2010

Eclipse - Shortcut Keys

Block Select Mode: Alt + Shift + A
Mouse Hover: Ctrl + 1, Ctrl + 3
Incremental Search: Ctrl + J
Java Search: Ctrl + H
Refactor Menu: Alt + Shift + T
Change Method Signature: Alt + Shift + C
Extract Method: Alt + Shift + M
Format Code: Ctrl + Shift + F
Move: Alt + Shift + V
Re-Run: Ctrl + F11   (For CTRL+F11 to work the way you want, you must set (from "Windows/Preferences") the "Run/debug > Launching : Launch Operation" setting to: Always launch the previously launched application)
Shift Code Down 1 Line: Alt + Down
Shift Code Up 1 Line: Alt + Up
Inline: Alt + Shift  + I
Show Javadoc: Shift + F2
Convert to Uppercase: Ctrl + Shift X
Convert to Lowercase: Ctrl + Shift Y
 
Focus Package Explorer: Alt + Shift + Q, P
Run JUnit Plugin Test:  Alt + Shift + X, P
Collapse all Branches: Ctrl + Shift + /
Quick Type Hierarchy: Ctrl + T
 
Copy current line to below : Ctrl+Alt+Down
Copy current line to above : Ctrl+Alt+Up
 
Surround With: Alt + Shift + Z
Display occurrences in file: Ctrl + Shift + U
Add import: Ctrl + Shift + M
 
Toggle Breakpoint: Ctrl + Shift + B
 
Next Perspective: Ctrl + F8
Next View: Ctrl + F7
Editor View: F12
 
Toggle Mark Occurrences: Alt + Shift + O
 
Static Imports...
Favourites section under Window->Preferences->Java->Editor->Content Assist
If you use org.junit.Assert a lot, you might find some value to adding it there