10/14/15

STS shortcuts

Shortcuts
Description
“sysout” + Crtl + Space
Quick System.out.println()
Alt + Enter
Open project properties
Alt + Shift + R
Rename
Alt + Shift + S
Context menu with possible actions
Alt + Shift + S, C
Generate constructor from superclass
Alt + Shift + S, H
Generate hashCode() and equals()
Alt + Shift + S, O
Generate constructor using fields
Alt + Shift + S, R
Generate getters and setters
Alt + Shift + S, S
Generate toString()
ALT <- or ALT ->
Go to previous or next edit positions from editor history list
ALT SHIFT Z
Enclose block in try-catch
Crtl + Alt + Down arrow
Copy current line below
Crtl + D
Delete current line
Crtl + I
Indent lines
Crtl + L
Go To Line Number
Crtl + N
Open New file/project wizard
Crtl + Shift + C
Add / remove single line comments
Crtl + Shift + F
Format code
Crtl + Shift + L
Quick Text Search (STS only)
Crtl + Shift + O
Organize import statements
Crtl + Space
Autocomplete
Crtl + W
Close currently viewed file
CTRL /
Comment a line
CTRL E
Open a file (editor) from within the list of all open files
CTRL H
Java search in workspace
CTRL M
Maximize editor
CTRL O
List all methods of the class and again CTRL O lists including inherited methods
CTRL PAGE UP or PAGE DOWN
Navigate to previous or next file from within the list of all open files
CTRL SHIFT G
Search for current cursor positioned word reference in workspace
CTRL SHIFT P
Go to the matching parenthesis
CTRL SHIFT R
Open a resource
CTRL SHIFT U
Find reference in file
CTRL T
Show inheritance tree of current token.
F3
Go to the declaration of the variable.
F4
Show type hierarchy of on a class.
Shift + Enter
Insert blank line after current line
SHIFT F2
Show Javadoc for current element

No comments: