Intellij Idea Guide
快捷键
# 查看类关系:
1. shift ctrl alt u: 在新页面显示uml
2. ctrl alt u: 在弹窗中显示uml
3. ctrl h: 查看类继承结构
# 查看源代码 F4(k6:alt+s)
# 生成代码: alt insert(k6: alt+home)
# 复制全类名: ctrl shift alt + C
# 创建新文件:点击目录 alt insert
# 显示设置页面快捷键:
1. shift ctrl alt s:显示项目配置
2. alt ctrl s: 系统设置
# search:
1. double shift: 进入搜索,类,class,file,symboles,actions
2. shift ctrl a: 直接搜索action
3. ctrl alt shift n: 直接搜索方法,变量
4. ctrl shift n: 搜索项目中的文件
5. ctrl n: 搜索class,各种api等等
# context actions: alter enter 根据上下文提供一些便利的操作,包括lint提示
# 补全功能:
1. ctrl alt space: 会出现推荐补全菜单
2. ctrl shift enter 补全语句,比如尾部分号等
3. ctrl shift enter:当在for,if等后面按下时,会自动补全对应语句,补全语句后再按,
进入语句内部,写代码后再按,会格式化代码格式
4. 简写:
1. sout, psvm...
2. `.`在语句后方加 . 回提示简写功能:
3. .sout
4. .nn: 生成 if (xxx != null) {}
5. .null: 生成 if (xx == null) {}
6. .switch, .return, .try,
7. .lambda
8. .var: 定义变量时,可以补全变量的类型
9. .cast, .castvar: 强制变型
# 编辑器快捷键:
1. ctrl w: 按一次w选中单词, 在按w选中整个句子,再按选中“
2. ctrl double w: 选中整行
3. ctrl shift / 多行注释
4. ctrl D 复制当前行,ctrl y 删除当前行
5. shift + 上下左右,模仿鼠标进行多选
6. alt shift 上下:上下行换位置
7. ctrl shift 上下:上下语句表达式换位置
8. ctrl -:把方法代码折叠 ctrl =: 把代码展开
9. ctrl shift -: 把代码折叠 ctrl shift =: 展开代码
10. ctrl alt t: 选中使用trycatch,if等语句包围选中的代码
11. shift f6: 为属性重命名,会自动把所有位置都重命名
本文作者:ivanohohoh
本文链接:https://www.cnblogs.com/ivanohohoh/p/17081421.html
版权声明:本作品采用知识共享署名-非商业性使用-禁止演绎 2.5 中国大陆许可协议进行许可。
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步