0 |
不同的IDE |
Eclipse快捷键 |
Idea快捷键 |
1 |
执行(run) |
alt+r |
Alt+Shift+F10 |
2 |
提示补全 (Class Name Completion) |
alt+/ |
ctrl+shift+space |
3 |
单行注释 |
ctrl + / |
ctrl + / |
4 |
多行注释 |
ctrl + shift + / |
ctrl + shift + / |
5 |
向下复制一行 (Duplicate Lines) |
ctrl+alt+down |
ctrl+d |
6 |
删除一行或选中行 (delete line) |
ctrl+d |
ctrl+x或者ctrl+y |
7 |
向下移动行(move statement down)方法内 |
alt+down |
ctrl+ shift +down |
8 |
向上移动行(move statement up) 方法内 |
alt+up |
ctrl+ shift + up |
9 |
向下开始新的一行(start new line) |
shift+enter |
shift+enter |
10 |
向上开始新的一行 (Start New Line before current) |
ctrl+shift+enter |
shift+enter |
11 |
如何查看源码 (class)/方法 |
ctrl + 选 中指 定的 结构 或ctrl + shift + t |
Ctrl+B |
12 |
万能解错/生成返回值变量 |
alt + enter |
alt + enter |
13 |
退回到前一个编辑的页面 (back) |
alt + left |
ctrl+alt + left |
14 |
进入到下一个编辑的页面(针对于上条) (forward) |
alt + right |
ctrl+ alt + right |
15 |
查看继承关系(type hierarchy) |
F4 |
ctrl+H |
16 |
格式化代码(reformat code) |
ctrl+shift+F |
Ctrl+Alt+L |
17 |
提示方法参数类型(Parameter Info) |
ctrl+alt+/ |
ctrl + p |
18 |
复制代码 |
ctrl + c |
ctrl + c |
19 |
撤销 |
ctrl + z |
ctrl + z |
20 |
反撤销 |
ctrl + y |
ctrl+shift+z/ctrl+y |
21 |
剪切 |
ctrl + x |
ctrl + x |
22 |
粘贴 |
ctrl + v |
ctrl + v |
23 |
保存 |
ctrl + s |
自动保存 |
24 |
全选 |
ctrl + a |
ctrl + a |
25 |
选中数行,整体往后移动 |
tab |
tab |
26 |
选中数行,整体往前移动 |
shift + tab |
shift + tab |
27 |
查看类的结构:类似于 eclipse 的 outline |
ctrl+o |
左侧structure |
28 |
重构:修改变量名与方法名(rename) |
alt+shift+r |
shift+F6 |
29 |
大写转小写/小写转大写(toggle case) |
ctrl+shift+y |
ctrl+shift+u |
30 |
生成构造器/get/set/toString |
alt +shift + s |
Alt + Insert |
31 |
查看文档说明(quick documentation) |
F2 |
ctrl+Q |
32 |
收起所有的方法(collapse all) |
alt + shift + c |
Ctrl+shift+”-”; |
33 |
打开所有方法(expand all) |
alt+shift+x |
Ctrl+shift+”+”; |
34 |
打开代码所在硬盘文件夹(show in explore) |
ctrl+shift+x |
右键show in explorer |
35 |
生成 try-catch 等(surround with) |
alt+shift+z |
ctrl+ alt +T |
36 |
局部变量抽取为成员变量(introduce field) |
alt+shift+f |
ctrl+alt+f |
37 |
查找/替换(当前) |
ctrl+f |
ctrl+f/r |
38 |
查找/替换(全局) |
ctrl+h |
ctrl+shift+f/r |
39 |
查找文件 |
double Shift |
double Shift |
40 |
查看类的继承结构图(Show UML Diagram) |
ctrl + shift + u |
ctrl+alt+u |
41 |
查看方法的多层重写结构(method hierarchy) |
ctrl+alt+h | |
42 |
添加到收藏(add to favorites) |
ctrl+alt+f |
右键add to favorites |
43 |
抽取方法(Extract Method) |
alt+shift+m |
Ctrl + Alt + M |
44 |
打开最近修改的文件(Recently Files) |
ctrl+E |
Ctrl+E |
45 |
关闭当前打开的代码栏(close) |
ctrl + w |
Ctrl+F4或右键close |
46 |
关闭打开的所有代码栏(close all) |
ctrl + shift + w |
右键close all |
47 |
快速搜索类中的错误(next highlighted error) |
ctrl + shift + q |
F2或shift+F2 |
48 |
选择要粘贴的内容(Show in Explorer) |
ctrl+shift+v |
ctrl+shift+v |
49 |
查找方法在哪里被调用(Call Hierarchy) |
ctrl+shift+h |
ctrl+shift+h |
50 |
补全变量名 |
Crtl + 1 |
ctrl+alt+v |
51 |
重写方法 |
Ctrl+O | |
52 |
查找类 |
Ctrl+Shift+Alt+N | |
53 |
选中一行内容 |
Crtl + W | |
54 |
移动一行或多行代码 |
Shift+Alt+down/up | |
55 |
Debug 进入方法 |
F5 |
F7 |
56 |
Debug单行调试 |
F6 |
F8 |
57 |
Debug运行到下一个断点 |
F7 |
Shift+F8 |
58 |
Debug恢复运行 |
F8 |
F9 |
59 |
查看和进入接口实现类的快捷键: |
Crtl+鼠标左键 |
Ctrl+Alt+B |
60 |
控制台全屏 |
双击 |
ctrl+shift+" |
61 |
自动补全当前语句的分号 | Ctrl + Shift + Enter | |
62 | 替换当前文件内容 |
Crtl + R |
Crtl + R |
63 | 复制的历史记录 | Ctrl+Shift+V | |
eclipse 和 idea快捷键对比
于 2020-02-22 16:14:10 首次发布