Community
Participate
Working Groups
I would like to see another EMACS feature (I think I posted it already here): Text autocompletion: Hitting <ALT+/> (alt+slash) will complete the current word with all possible completions from open editors. This feature should be context-less, i.e, ignore its position and it should be available in all editors (java, text, etc). I can use it when I edit some configuration file and I need to complete a class name from one of the open editors, or when I write some documentation and have to type long words which have nothing to do with java code
Moving to Platform UI.
For reference, this function is called "hippie-expand" in Emacs. Basically it looks for completions in a couple of different places: * look for file names on disk * look for words in the current buffer * look for words in the clipboard * look for words in deleted text* look for lisp function names I don't know the particular order of the search or the exact algorithm used, but roughly, this is what it does. If it matters to anybody, I have it bound to SHIFT-TAB in Emacs, and actually find it quite useful. Possibly, Eclipse could use this instead of code completion in any context where code completion is not available (like comments or non-java buffers).
I would venture to say that this option should be made available in the java editor as well. I find the emacs auto-completion (even with its lack of context sensitivity) to make me more efficient that the current eclipse one. The reason is because emacs automatically inserts the next available completion into the buffer, so that if the first suggestion is correct (as is usually the case), you just go on editing - without having to shift your eyes to the completion list that eclipse drops down for you. And because you are pressing the same key combo over and over again to cycle through available completion, instead of having to move your hand to the arrows to select the one you want, emacs is faster even if the correct choice is not the first one it proposes.
Lev: To me it sounds as if what you are opposed to is the UI of the context sensitive completion, not its context sensitivity. Is that correct? Would a more hippie-expand:ish UI for the current context sensitive completion make you happier?
I wouldn't say that I am "opposed" to it, but yes, i believe it is the UI that could use extension. I didn't want to file a second bug saying "make autocomp the same as EMACS" :) I think both behaviors are useful. A "visual" autocomp (the way eclipse does it now) is a good way for you to see your options when you're not sure what identifier to choose. An emacs ("hippie:is") style of completion is useful for when you know exactly what you want to type in, but want a shortcut to doing so. Having both versions of it would be great: Alt-Space for what it already does and Alt-Slash for emacs style completion.
JEdit has something akin to this feature. Working in any text file, hitting ctrl-b (I think, I reconfigured the mapping to ctrl-space) will provide a completion list based on all text in the active buffer. As was mentioned, this is very helpful when writing documentation, or in XML/HTML and that sort of thing.
Post 2.0
This seems like a dupe of bug 11668. I know this one was first, but the other one comes with patches. As I am not allowed to mark it as a duplicate, it'd be great if somebody with proper permissions could do it.
reopening to mark as dup.
closing as dup as requested in comment 8. *** This bug has been marked as a duplicate of 11668 ***