Eclipse vs. IDEA快捷键对比大全

http://blog.csdn.net/dc_726/article/details/9531281

花了一天时间熟悉IDEA的各种操作,将各种快捷键都试了一下,感觉很是不错!于是就整理了一下我经常用的一些Eclipse快捷键与IDEA的对比,方便像我一样使用Eclipse多年但想尝试些改变的同学们。另外推荐个IDEA必装插件Key Promoter ,对于你没用快捷键的操作它都会立即提示对应的快捷键,十分强大。IDEA比较惊艳的一些快捷键我都高亮了,想了解其中的神奇,就装一个IDEA亲自尝试下吧!


分类

功能点

Eclipse快捷键

IDEA快捷键

搜索

搜索文本

Ctrl + F

Ctrl + F

Ctrl + R 查找替换

Alt + P/A 逐个/全部替换

Alt + F3 查找当前选中词

继续搜索

Ctrl + K 向前

Ctrl + Shift + K 向后

F3

Shift + F3

搜索方法

Ctrl + O

Ctrl + F12

搜索类

Ctrl + Shift + T

Ctrl + N

搜索文件

Ctrl + Shift + T

Ctrl + Shift + N

这两个都支持简单的正则表达式,还支持直接按大写字母的缩略,例如:

查找JsonTranscoder,只需要输入JT

搜索所有引用处

Ctrl + Alt + H

Alt + F7

搜索所有文本出现的位置

Ctrl + H

Ctrl + Shift + F

编辑

自动代码补全

Alt + /

Ctrl + J

自动代码生成

 

Alt + Insert

快速修复错误

Ctrl + 1

Alt + Enter

删除当前行

Ctrl + D

Ctrl + X

复制到下一行

 

Ctrl + D

注释/取消注释

Ctrl + /

Ctrl + /

选中当前字

 

Ctrl + W

 

补全当前行

 

Ctrl + Shift + Enter

神器,补全当前行,最常用的场景时补全当前行后的;号,并将光标定位到下一行

调出最近复制的N份内容

 

Ctrl + Shift + V

查看最近编辑的文件

 

Ctrl + E

对比最近修改

 

Alt + Shift + C

格式化代码

Ctrl + Shift + F

Ctrl + Alt + L

整理import

Ctrl + Shift + O

Ctrl + Alt + O

跳转

显示方法层次

 

Ctrl + Shift + H

显示类、方法说明

F2

Ctrl + Q

跳到方法定义处

 

Ctrl + B

跳到方法实现处

 

Ctrl + Alt + B

跳到上/下一方法

 

Alt + Up/Down

上/下一查看处

Alt + <-

Alt + ->

Ctrl + Alt + Up/Down

跳到指定行

Ctrl + L

Ctrl + G

重构

改名

Alt + Shift + R

Shift + F6

其他常用

 

Ctrl + F6 修改方法签名

Ctrl + Shift + F6 修改参数的类型

Ctrl + Shift + V引入局部变量

Ctrl + Shift + P 引入参数

Ctrl + Shift + F 引入类变量

Ctrl + Shift + M 引入方法

Ctrl + Shift + C 引入常量

运行

启动调试

 

Alt + Shift + F9

启动运行

 

Alt + Shift + F10

单步进入

F5

F7

单步跳过

F6

F8

跳过

F8

F9

执行选中语句

 

Alt + F8

窗口

调出界面

 

Ctrl + Alt + S调出Settings界面

Ctrl + Alt + Shift + S调出项目Setting界面

关闭界面

 

Ctrl + F4 或 ESC

打开窗口

 

Alt + 窗口编号(例如项目窗口编号是1)

最大化窗口

Ctrl + M

Ctrl + Shift + F12

隐藏窗口

 

Shift + ESC

关闭当前文件

 

Ctrl + F4

垂直分屏

 

Ctrl + | (自定义的)

调整窗口位置

 

Ctrl + M 将当前光标处显示到屏幕中央

切换窗口

 

Ctrl + Tab




https://www.catalysts.cc/wissenswertes/intellij-idea-and-eclipse-shortcuts/

After around seven years of exclusively using Eclipse for Java development I recently got the chance to work on a project where IntelliJ IDEA is the standard editor. All of a sudden my tried and tested Eclipse keyboard shortcuts didn’t work any more. I’m still in the process of learning the IntelliJ Shortcuts but here are my favourites up to now (with equivalent Eclipse shortcuts).  This may be of help to anyone else switching over from Eclipse to IntelliJ.  Of course, there is an IntelliJ Plugin available which makes IntelliJ IDEA behave like Eclipse (same shortcuts and compiler behaviour) but why do that?

In the table below, in some cases, the shortcuts do not map 1:1 but they achieve the same effect.

EclipseIntelliJ IDEADescription
F4ctrl+hshow the type hierarchy
ctrl+alt+gctrl+alt+F7find usages
ctrl+shift+uctrl+f7finds the usages in the same file
alt+shift+rshift+F6rename
ctrl+shift+rctrl+shift+Nfind file / open resource
ctrl+shift+x, jctrl+shift+F10run (java program)
ctrl+shift+octrl+alt+oorganize imports
ctrl+octrl+F12show current file structure / outline
ctrl+shift+mctrl+alt+Vcreate local variable refactoring
syso ctrl+spacesout ctrj+jSystem.out.println(„“)
alt + up/downctrl + shift + up/downmove lines
ctrl + dctrl + ydelete current line
???alt + hshow subversion history
ctrl + hctrl + shift + fsearch (find in path)
„semi“ set in window-> preferencesctrl + shift + enterif I want to add the semi-colon at the end of a statement
ctrl + 1 or ctrl + shift + lctrl + alt + vintroduce local variable
alt + shift + salt + insertgenerate getters / setters
ctrl + shift + fctrl + alt + lformat code
ctrl + yctrl + shift + zredo
ctrl + shift + cctrl + /comment out lines (my own IDEA shortcut definition for comment/uncomment on german keyboard layout on laptop: ctrl + shift + y)
ctrl + alt + hctrl + alt + h (same!)show call hierarchy
none ?ctrl + alt + f7to jump to one of the callers of a method
ctrl + shift + ialt + f8evaluate expression (in debugger)
F3ctrl + bgo to declaration (e.g. go to method)
ctrl + lctrl + ggo to line


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值