Tags: patch Following the recent discussion on emacs-devel[0], I'm attaching a patch that adds a new Completion Preview minor mode. I've been testing this patch with different completion backends, and so far I'm pretty happy with the results. I've made some tweaks compared to the version I posted on emacs-devel to make the implementation more robust, and in particular to accommodate for some peculiarities of LSP-based completion, which I've tested mostly with `eglot` but also with `lsp-mode`. In terms of documentation, this patch extends "(emacs)Symbol Completion" with a description of Completion Preview mode. That seemed like a good place to discuss this mode, but let me know if somewhere else would be preferable. Another question is whether to have RET/TAB/both accept and insert the completion suggestion. In VS Code, both RET and TAB do that AFAICT. If we want to, we can easily do that too by binding RET/TAB in `completion-preview-active-mode-map`. Alternatively, we can just suggest doing so in the documentation. The current patch binds neither RET nor TAB, so to accept the suggestion you complete with C-M-i. Personally, I find that convenient enough, but I can imagine that many users might expect TAB or RET to work too. [0] https://lists.gnu.org/archive/html/emacs-devel/2023-10/msg00693.html