录制文本编辑宏
在代码编辑器中打开文件时,可以将键盘序列录制为宏。然后可以播放宏来重复序列。您可以保存最新的宏,并为运行宏指定键盘快捷键,或从定位器中运行宏。
录制宏
录制文本编辑宏:
- 转到Tools >Text Editing Macros >Record Macro 或选择Alt+[。
- 选择键盘按键。
- 要停止录制,请访问Tools >Text Editing Macros >Stop Recording Macro 或选择Alt+]。
注意: 宏记录器不支持代码自动补全。
播放宏
播放最后一个宏:
- 转到Tools >Text Editing Macros >Play Last Macro 。
- 选择Alt+R。
- 在定位器中输入
rm
。
保存宏
要保存最后一个宏,请转到Tools >Text Editing Macros >Save Last Macro 。
要查看和删除已保存的宏,请转至首选项>Text Editor >Macros 。
为宏指定键盘快捷键
要为文本编辑宏指定键盘快捷方式,请转至首选项>Environment >Keyboard 。
Copyright © The Qt Company Ltd. and other contributors. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.