[英]Emacs auto-complete
since I can't get CEDET
to work for automatic code-completion (aka intelli-sense in the MS-world), after trying several times (no, it's just not working!), I've decided to use auto-complete
, which works "quite fine" for me. 因为我无法让
CEDET
在自动代码完成(也就是MS世界中的智能)中工作,经过多次尝试(不,它只是不起作用!),我决定使用auto-complete
,这对我来说“非常好”。
Unfortunately, auto-complete
has an annoying behaviour when it comes to quit the imenu
with its suggestions. 不幸的是,当涉及退出
imenu
及其建议时, auto-complete
有一个恼人的行为。
auto-complete
starts imenu
, no matter how many suggestions it has. auto-complete
启动imenu
。 So, if there's only one suggestion, the menu appears. imenu
, I have to use the LEFT
or RIGHT
keys in order to make the menu disappear. imenu
,我必须使用LEFT
或RIGHT
键才能使菜单消失。 ESC-ESC-ESC
does not have any effect. ESC-ESC-ESC
没有任何效果。 Is there any way, to modify these two behaviors? 有什么方法可以修改这两种行为吗?
Here's an excerpt of my .emacs
file showing the auto-complete
relevant stuff: 这是我的
.emacs
文件的摘录,显示了auto-complete
相关内容:
(require 'auto-complete-config) (add-to-list 'ac-dictionary-directories "~/.emacs.d/ac-dict") (ac-config-default) (setq ac-delay 0.5) ;; eclipse uses 500ms
Kind regards, mefiX 亲切的问候,mefiX
'Stop autocompleting' can be set by adding the following to your .emacs: 可以通过在.emacs中添加以下内容来设置“停止自动填充”:
(define-key ac-completing-map "\ESC/" 'ac-stop)
...or alternatively you can use Cg as the default Emacs StopSomething command :) ...或者你可以使用Cg作为默认的Emacs StopSomething命令:)
As for showing the completion in a menu when there's only one candidate, I'm not really sure what other behaviour you'd want? 至于只有一个候选人在菜单中显示完成时,我不确定你想要的其他行为是什么?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.