emacs-eclim
emacs-eclim copied to clipboard
Autocompletion already starts after first character
Since I upgraded to the latest emacs-eclim, my Emacs 23 starts completion whenever I type a character. My auto-complete settings are set to complete words that are more than two characters long. In C++ (using clang auto-complete) this works. What can I do to make emacs-eclim honor this as well?
Turns out there was a bit of configuration in the ac-emacs-eclim backend that overrode the value for ac-auto-start. Should be fixed now.
Yes, this seems to work. However, now I don't get completions after typing '.' -- even when running M-x auto-complete manually. Running M-x eclim-complete at least shows me the completions in an extra buffer. Any ideas how to get this to work again?
I think that's a limitation of running auto-complete with a required prefix length; the point we want to start completion on is right after the period, and with your setup auto-complete wants at least three characters before starting.
One problem that I can also see is, that autocomplete uses a function that eclim does not provide anymore:
(defun ac-eclim-candidates ()
(with-no-warnings
(loop for c in (eclim/java-complete)
collect (nth 1 c))))
What's the correct way nowadays to get the eclim completion candidatese from elisp?
Hm... that is the eclim source bundled with auto-complete? Emacs-eclim provides its own source called ac-source-emacs-eclim, which is better integrated.
The correct way to get completions programatically is to call eclim--completion-candidates or eclim--complete.
Seems auto-complete-clang(https://github.com/brianjcj/auto-complete-clang/blob/master/auto-complete-clang.el#L289) provide a way to complete when users type ., ->, or :: in c++-mode.
Could we port this mechanism to eclim?
Any update on this? I would like eclim-complete to start after typing the . or ->. Thanks
No, sorry. I regret to say I haven't had much time or energy to devote to emacs-eclim recently. Patches are welcome, as always.