From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Emacs completion matches selection UI Date: Mon, 18 Nov 2013 19:43:04 -0500 Message-ID: References: <87fvqtg02v.fsf@flea.lifelogs.com> <877gc5fm30.fsf@flea.lifelogs.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1384821794 20008 80.91.229.3 (19 Nov 2013 00:43:14 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 19 Nov 2013 00:43:14 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Nov 19 01:43:20 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ViZPU-0005hb-8J for ged-emacs-devel@m.gmane.org; Tue, 19 Nov 2013 01:43:20 +0100 Original-Received: from localhost ([::1]:46521 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ViZPT-00060X-Oe for ged-emacs-devel@m.gmane.org; Mon, 18 Nov 2013 19:43:19 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56294) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ViZPL-0005zV-H8 for emacs-devel@gnu.org; Mon, 18 Nov 2013 19:43:17 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ViZPF-0005bG-BB for emacs-devel@gnu.org; Mon, 18 Nov 2013 19:43:11 -0500 Original-Received: from ironport2-out.teksavvy.com ([206.248.154.182]:57364) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ViZPF-0005bA-7A for emacs-devel@gnu.org; Mon, 18 Nov 2013 19:43:05 -0500 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av4EABK/CFHO+KWN/2dsb2JhbABEvw4Xc4IeAQEEAVYoCws0EhQYDUCIAgYMwSGNYYMpA4hhnBmBXoMV X-IPAS-Result: Av4EABK/CFHO+KWN/2dsb2JhbABEvw4Xc4IeAQEEAVYoCws0EhQYDUCIAgYMwSGNYYMpA4hhnBmBXoMV X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="38566746" Original-Received: from 206-248-165-141.dsl.teksavvy.com (HELO pastel.home) ([206.248.165.141]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 18 Nov 2013 19:43:04 -0500 Original-Received: by pastel.home (Postfix, from userid 20848) id 10A9C60120; Mon, 18 Nov 2013 19:43:04 -0500 (EST) In-Reply-To: <877gc5fm30.fsf@flea.lifelogs.com> (Ted Zlatanov's message of "Mon, 18 Nov 2013 16:15:31 -0500") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.154.182 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:165348 Archived-At: >>> In "(emacs.info) Completion Commands" there is help for using the >>> rudimentary buffer to select completion matches. I was struck by how >>> hard to use this was, compared to more recent packages like these: >>> http://www.emacswiki.org/emacs/AutoComplete >>> http://www.emacswiki.org/emacs/CompanyMode >>> Is there any chance the default Emacs appearance for selecting >>> completion matches can be improved (not necessarily by default) for >>> 24.4? I would help with this but don't know what's "state of the art" >>> and if there's already work in this direction. BB> Unlike auto-complete-mode, Emacs's default completion system is rock-solid. BB> :-) auto-complete uses some pretty messed up popup display library that BB> doesn't play well with many packages. company-mode is much better in this BB> regard. company-mode's popup is also far from rock-solid (I have no experience with auto-complete's popup, so can't compare). But FWIW, I'd like to move company-mode into the core completion code. I've implemented a bridge between company-mode and completion-at-point-functions ("company-capf"), and moved company-mode's completion tables for Elisp into lisp-mode.el. But there needs to be some further integration work to make sure company-mode works well with existing completion-at-point-functions. But it wouldn't be enabled by default, anyway. > The completion system is fine. The selection of matches is the problem: > 1) see a new buffer popup with minimal help text and no highlighting > 2) left, right, up, down don't work > 3) realize problem, switch to candidates buffer (mouse click or `C-x o') > 4) select candidate you want, get popped in original buffer > That's not simple! It's not intuitive either, forcing me to use the > mouse unless I've read the manual node referenced above. > An alternative UI doesn't have to be fancy or graphical, only allow me > to select from among the candidates immediately, without switching > buffers, using the intuitive keys. I hope that explains my request better. Oh, that should be reasonably easy. Just add the corresponding key-bindings in minibuffer-local-completion-map, mostly. The main issue is to try and avoid clashing with existing bindings (since there are 2 buffers at play: the minibuffer and the *Completions* buffer), and without C-x o, you're still in the minibuffer where left/right should still mean "cursor movement in the minibuffer". Stefan