就像按键精灵的录制功能,emacs也轻松能做到,帅
将下面的代码拷贝到配置文件,一般c:/_emacs或者~/.emacs
(global-set-key [(f3)] 'start-kbd-macro)
(global-set-key [(f4)] 'end-kbd-macro)
(defun call-last-kbd-macro-N-times (n)
"Call call-last-kbd-macro N times."
(interactive "How many times?")
(call-last-kbd-macro n))
(global-set-key [(f5)] 'call-last-kbd-macro-N-times)
使用方法:
按f3开始录制,然后按键(鼠标无效), f4结束
f5,输入重复次数。
于是重复编辑动作瞬间完成
或者录制好后,按c-x e,然后每次执行后,按e,则重复执行,按住不放吧,boy^_^
2008年7月31日
emacs实现键盘录制功能
2008年7月11日
Eclipse编码保存出错
保存时出现一下错误。
Save could not be completed. Reason: some characters cannot be mapped using “ISO-8859-1“ character encoding. Either change the encoding or remove the characters which are not supported by the “ISO-8859-1“ character encoding.
解决方法:
eclipse --> window --> Preferences --> General --> Content Types --> Test --> 单击 Java Properties File,在底部出现 'Default edcodng:',改成utf-8或GBK,然后update
订阅:
博文 (Atom)