常用
- 1.补全代码的声明:option + /
- 2.快速修复: Command + 1
- 3.批量导包: Command + shift + O
- 4.使用单行注释:Command + /
- 5.使用多行注释:
- 6.取消多行注释:
- 7.复制指定行的代码:Command + option + down 或 Command + option + up
- 8.删除指定行的代码:Command + d
- 9.上下移动代码: option + up 或 option + down
- 10.切换到下一行代码空位:shift + enter
- 11.切换到上一行代码空位:Command + shift + enter
- 12.如何查看源码: Command + 指定结构 或 Command + shift + t
- 13.退回到前一个编辑的页面:Command + shift + left
- 14.进入到下一个编辑的页面(针对于上面那条来说的):Command + shift +right
- 15.光标选中指定的类,查看继承树结构:Command + t
- 16.复制代码: Command + c
- 17.撤销: Command + z
- 18.反撤销: Command + y
- 19.剪切: Command + x
- 20.粘贴: Command + v
- 21.保存: Command + s
- 22.全选: Command + a
- 23.格式化代码: Command + shift +f
- 24.选中数行,整体往后移动: tab
- 25.选中数行,整体往前移动: shift + tab
- 26.在当前类中,显示类结构,并支持搜索指定的方法、属性等:Command + o
- 27.批量修改指定的变量名、方法名、类名等: option + command + R 或
- 28.选中的结构的大小写的切换:变成大写: Command + shift + x
- 29.选中的结构的大小写的切换:变成小写: Command + shift +y
- 30.调出生成getter/setter/构造器等结构: option + Command + s
- 31.显示当前选择资源(工程 or 文件)的属性: option + enter
- 32.快速查找:参照选中的Word快速定位到下一个: command + k
不常用
- 33.关闭当前窗口:command + w
- 34.关闭所有的窗口:command + shift + w
- 35.查看指定的结构使用过的地方:command + option + g
- 36.查找与替换: Command + f
- 37.最大化当前的View:Control + m
- 38.直接定位到当前行的首位:
- 39.直接定位到当前行的末位: