IntelliJ IDEA common shortcut keys Windows version

foreword

IDEA supports two types of shortcut keys by default, one is from familiar with Eclipse development tools to IDEA development, the other is the default of the operating system, for example, WIndwos is Default copy, Eclipse is Eclipse copy, and Mac is another set Now, here is a summary of the default IDEA shortcut keys of the WIndwos system, which are basically borrowed from the Internet, which is convenient for efficient development and debugging, and facilitates our fast Coding.
insert image description here

1. IntelliJIDEA_ReferenceCard officially provides shortcut key documentation

2. Ctrl

hot key introduce
Ctrl + F Search text in current file(必备)
Ctrl + R replace text in the current file(必备)
Ctrl + Z revoke(必备)
Ctrl + Y Delete the line where the cursor is located or delete the selected line(必备)
Ctrl + X Cut the cursor line or cut the selection
Ctrl + C Copy the cursor line or copy the selection
Ctrl + D Copy the line where the cursor is located or copy the selection, and insert the copied content below the cursor position(必备)
Ctrl + W Incremental selection of code blocks. You can select the word or paragraph where the cursor is located. Pressing continuously will expand the selection range based on the original selection.
Ctrl + E Display a list of recently opened file records(必备)
Ctrl + N Find the class file based on the entered class name
Ctrl + G Jump to the specified line in the current file
Ctrl + J Insert custom dynamic code template
Ctrl + P Method parameter prompt display
Ctrl + Q The variable/class name/method name where the cursor is located (you can also press it when prompted to add) to display the content of the document
Ctrl + U Go to the method/interface definition of the parent class of the method where the current cursor is located
Ctrl + B Enter the interface of the method/variable where the cursor is located or define it, which is equivalent toCtrl + 左键单击
Ctrl + K Version control submits a project, which needs to be added to version control before it can be used
Ctrl + T Version control update project, this project needs to be added to version control to be available
Ctrl + H Displays the current class hierarchy(必备)
Ctrl + O Choose an overridable method(必备)
Ctrl + I Select inheritable methods, methods that the interface needs to implement(必备)
Ctrl + + expand code(必备)
Ctrl + - folding code(必备)
Ctrl + / Comment on the line of code where the cursor is located, and different comment symbols will be used according to different current file types(必备)
Ctrl + [ Move the cursor to the beginning of the curly braces of the current code
Ctrl + ] Move the cursor to the end of curly braces in the current code
Ctrl + F1 Display the error message at the error code where the cursor is located
Ctrl + F3 Move to the next quoted position of the selected word
Ctrl + F4 Close the currently edited file
Ctrl + F8 In Debug mode, set the cursor's current behavior breakpoint, if it is already a breakpoint, remove the breakpoint
Ctrl + F9 Execute Make Project operation
Ctrl + F11 Select file/folder, use mnemonic to set/unbookmark
Ctrl + F12 Pop up the current file structure layer, you can directly input on the pop-up layer to filter
Ctrl + Tab Edit window switching, if you press delete during the switching process, it will close the corresponding selected window
Ctrl + Enter Smart line breaks
Ctrl + End jump to end of file
Ctrl + Home jump to file header
Ctrl + Space Basic code completion, which is occupied by the input method by default on Windows systems, and needs to be modified. It is recommended to modify it toCtrl + 逗号 (必备)
Ctrl + Delete Delete the word or Chinese sentence after the cursor
Ctrl + BackSpace Delete the word or Chinese sentence in front of the cursor
Ctrl + 1,2,3…9 Locate the bookmark position of the corresponding value
Ctrl + left click On the title of the opened file, the file path pops up
Ctrl + cursor positioning Press Ctrl and don't release it, it will display the summary of the class information where the cursor is located
Ctrl + Left Arrow The cursor jumps to the left start position of the current word/Chinese sentence
Ctrl + Right Arrow The cursor jumps to the right start position of the current word/Chinese sentence
Ctrl + Forward Arrow 等效于鼠标滚轮向前效果
Ctrl + 后方向键 等效于鼠标滚轮向后效果

三、Alt

快捷键 介绍
Alt + ` 显示版本控制常用操作菜单弹出层
Alt + Q 弹出一个提示,显示当前类的声明 / 上下文信息
Alt + F1 显示当前文件选择目标弹出层,弹出层中有很多目标可以进行选择
Alt + F2 对于前面页面,显示各类浏览器打开目标选择弹出层
Alt + F3 选中文本,逐个往下查找相同文本,并高亮显示
Alt + F7 查找光标所在的方法 / 变量 / 类被调用的地方
Alt + F8 在 Debug 的状态下,选中对象,弹出可输入计算表达式调试框,查看该输入内容的调试结果
Alt + Home 定位 / 显示到当前文件的 Navigation Bar
Alt + Enter IntelliJ IDEA 根据光标所在问题,提供快速修复选择,光标放在的位置不同提示的结果也不同 (必备)
Alt + Insert 代码自动生成,如生成对象的 set / get 方法,构造函数,toString() 等(必备)
Alt + 左方向键 按左方向切换当前已打开的文件视图(必备)
Alt + 右方向键 按右方向切换当前已打开的文件视图(必备)
Alt + 前方向键 当前光标跳转到当前文件的前一个方法名位置(必备)
Alt + 后方向键 当前光标跳转到当前文件的后一个方法名位置(必备)
Alt + 1,2,3…9 显示对应数值的选项卡,其中 1 是 Project 用得最多

四、Shift

快捷键 介绍
Shift + F1 如果有外部文档可以连接外部文档
Shift + F2 跳转到上一个高亮错误 或 警告位置
Shift + F3 在查找模式下,查找匹配上一个
Shift + F4 对当前打开的文件,使用新Windows窗口打开,旧窗口保留
Shift + F6 对文件 / 文件夹 重命名
Shift + F7 在 Debug 模式下,智能步入。断点所在行上有多个方法调用,会弹出进入哪个方法
Shift + F8 在 Debug 模式下,跳出,表现出来的效果跟 F9 一样
Shift + F9 等效于点击工具栏的 Debug 按钮
Shift + F10 等效于点击工具栏的 Run 按钮
Shift + F11 弹出书签显示层
Shift + Tab 取消缩进
Shift + ESC 隐藏当前 或 最后一个激活的工具窗口
Shift + End 选中光标到当前行尾位置
Shift + Home 选中光标到当前行头位置
Shift + Enter 开始新一行。光标所在行下空出一行,光标定位到新行位置
Shift + 左键单击 在打开的文件名上按此快捷键,可以关闭当前打开文件
Shift + 滚轮前后滚动 当前文件的横向滚动轴滚动

五、Ctrl + Alt

快捷键 介绍
Ctrl + Alt + L 格式化代码,可以对当前文件和整个包目录使用 (必备)
Ctrl + Alt + O 优化导入的类,可以对当前文件和整个包目录使用 (必备)
Ctrl + Alt + I 光标所在行 或 选中部分进行自动代码缩进,有点类似格式化
Ctrl + Alt + T 对选中的代码弹出环绕选项弹出层
Ctrl + Alt + J 弹出模板选择窗口,讲选定的代码加入动态模板中
Ctrl + Alt + H 调用层次
Ctrl + Alt + B 在某个调用的方法名上使用会跳到具体的实现处,可以跳过接口(必备)
Ctrl + Alt + V 快速引进变量
Ctrl + Alt + Y 同步、刷新
Ctrl + Alt + S 打开 IntelliJ IDEA 系统设置(必备)
Ctrl + Alt + F7 显示使用的地方。寻找被该类或是变量被调用的地方,用弹出框的方式找出来
Ctrl + Alt + F11 切换全屏模式
Ctrl + Alt + Enter 光标所在行上空出一行,光标定位到新行
Ctrl + Alt + Home 弹出跟当前文件有关联的文件弹出层
Ctrl + Alt + Space 类名自动完成
Ctrl + Alt + 左方向键 退回到上一个操作的地方 (必备)**(注意与其他软件快捷键冲突)**
Ctrl + Alt + 右方向键 前进到上一个操作的地方 (必备)**(注意与其他软件快捷键冲突)**
Ctrl + Alt + 前方向键 在查找模式下,跳到上个查找的文件
Ctrl + Alt + 后方向键 在查找模式下,跳到下个查找的文件

六、Ctrl + Shift

快捷键 介绍
Ctrl + Shift + F 根据输入内容查找整个项目 或 指定目录内文件 (必备)
Ctrl + Shift + R 根据输入内容替换对应内容,范围为整个项目 或 指定目录内文件 (必备)
Ctrl + Shift + J 自动将下一行合并到当前行末尾 (必备)
Ctrl + Shift + Z 取消撤销 (必备)
Ctrl + Shift + W 递进式取消选择代码块。可选中光标所在的单词或段落,连续按会在原有选中的基础上再扩展取消选中范围 (必备)
Ctrl + Shift + N 通过文件名定位 / 打开文件 / 目录,打开目录需要在输入的内容后面多加一个正斜杠 (必备)
Ctrl + Shift + U 对选中的代码进行大 / 小写轮流转换 (必备)
Ctrl + Shift + T 对当前类生成单元测试类,如果已经存在的单元测试类则可以进行选择 (必备)
Ctrl + Shift + C 复制当前文件磁盘路径到剪贴板 (必备)
Ctrl + Shift + V 弹出缓存的最近拷贝的内容管理器弹出层
Ctrl + Shift + E 显示最近修改的文件列表的弹出层
Ctrl + Shift + H 显示方法层次结构
Ctrl + Shift + B 跳转到类型声明处 (必备)
Ctrl + Shift + I 快速查看光标所在的方法 或 类的定义
Ctrl + Shift + A 查找动作 / 设置
Ctrl + Shift + / 代码块注释 (必备)
Ctrl + Shift + [ 选中从光标所在位置到它的顶部中括号位置 (必备)
Ctrl + Shift + ] 选中从光标所在位置到它的底部中括号位置 (必备)
Ctrl + Shift + + 展开所有代码 (必备)
Ctrl + Shift + - 折叠所有代码 (必备)
Ctrl + Shift + F7 高亮显示所有该选中文本,按Esc高亮消失 (必备)
Ctrl + Shift + F8 在 Debug 模式下,指定断点进入条件
Ctrl + Shift + F9 编译选中的文件 / 包 / Module
Ctrl + Shift + F12 编辑器最大化 (必备)
Ctrl + Shift + Space 智能代码提示
Ctrl + Shift + Enter 自动结束代码,行末自动添加分号 (必备)
Ctrl + Shift + Backspace 退回到上次修改的地方 (必备)
Ctrl + Shift + 1,2,3…9 快速添加指定数值的书签 (必备)
Ctrl + Shift + 左键单击 把光标放在某个类变量上,按此快捷键可以直接定位到该类中 (必备)
Ctrl + Shift + 左方向键 在代码文件上,光标跳转到当前单词 / 中文句的左侧开头位置,同时选中该单词 / 中文句 (必备)
Ctrl + Shift + 右方向键 在代码文件上,光标跳转到当前单词 / 中文句的右侧开头位置,同时选中该单词 / 中文句 (必备)
Ctrl + Shift + 前方向键 光标放在方法名上,将方法移动到上一个方法前面,调整方法排序 (必备)
Ctrl + Shift + 后方向键 光标放在方法名上,将方法移动到下一个方法前面,调整方法排序 (必备)

七、Alt + Shift

快捷键 介绍
Alt + Shift + N 选择 / 添加 task (必备)
Alt + Shift + F 显示添加到收藏夹弹出层 / 添加到收藏夹
Alt + Shift + C 查看最近操作项目的变化情况列表
Alt + Shift + I 查看项目当前文件
Alt + Shift + F7 在 Debug 模式下,下一步,进入当前方法体内,如果方法体还有方法,则会进入该内嵌的方法中,依此循环进入
Alt + Shift + F9 弹出 Debug 的可选择菜单
Alt + Shift + F10 弹出 Run 的可选择菜单
Alt + Shift + 左键双击 选择被双击的单词 / 中文句,按住不放,可以同时选择其他单词 / 中文句 (必备)
Alt + Shift + 前方向键 移动光标所在行向上移动 (必备)
Alt + Shift + 后方向键 移动光标所在行向下移动 (必备)

八、Ctrl + Shift + Alt

快捷键 介绍
Ctrl + Shift + Alt + V 无格式黏贴 (必备)
Ctrl + Shift + Alt + N Go to the specified variable/method
Ctrl + Shift + Alt + S Open current project settings(必备)
Ctrl + Shift + Alt + C Copy reference information

9. Others

hot key introduce
F2 Jump to the next highlighted error or warning location(必备)
F3 In find mode, locate the next match
F4 edit source(必备)
F7 In Debug mode, go to the next step. If the current line breakpoint is a method, enter the current method body. If the method body has a method, it will not enter the embedded method.
F8 In Debug mode, go to the next step, if the current line breakpoint is a method, do not enter the current method body
F9 In Debug mode, resume the program, but stop at the next breakpoint if there is a breakpoint in the code below the breakpoint
F11 add bookmark(必备)
F12 Go back to the previous tool window(必备)
Tab indentation(必备)
ESC Enter the code file window from the tool window(必备)
Double-click Shift popup Search Everywherepopup layer

10. IDEA debugging shortcut keys (must be mastered)

hot key introduce
F8 Single-step debugging. Go down line by line without entering the function
F7 Single-step debugging. Go down line by line and enter the inside of the function
Shift+F7 Select the function to enter
Shift+F8 out of function
Alt + F9 run to breakpoint
Alt + F8 Execute the expression to see the result
F9 Continue execution, enter the next breakpoint or finish executing the program
Ctr+F8 Set/cancel current line breakpoint
Ctr+Shift+F8 View breakpoints
soutc Quickly generate Lambda writing of System.out::pringLn

This article is shared on the blog "Thinkingcao" (CSDN).
If there is any infringement, please contact [email protected] to delete it.
This article participates in the " OSC Yuanchuang Project ", you are welcome to join and share with us.

{{o.name}}
{{m.name}}

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=324037039&siteId=291194637