From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eric Abrahamsen Newsgroups: gmane.emacs.help Subject: Re: Looking for universal completion with simple UI Date: Wed, 08 Oct 2014 00:51:48 +0800 Message-ID: <87a957zuu3.fsf@ericabrahamsen.net> References: <778b7522-e7b5-4ee7-89fa-10548516d79c@googlegroups.com> <30188c0f-ed06-4dda-ab75-6aec7722b63a@googlegroups.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1412700761 11591 80.91.229.3 (7 Oct 2014 16:52:41 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 7 Oct 2014 16:52:41 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Oct 07 18:52:35 2014 Return-path: Envelope-to: geh-help-gnu-emacs@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 1XbY01-00032a-4Q for geh-help-gnu-emacs@m.gmane.org; Tue, 07 Oct 2014 18:52:33 +0200 Original-Received: from localhost ([::1]:59916 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XbY00-0006pJ-RD for geh-help-gnu-emacs@m.gmane.org; Tue, 07 Oct 2014 12:52:32 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:48070) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XbXzh-0006p3-Rn for help-gnu-emacs@gnu.org; Tue, 07 Oct 2014 12:52:19 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XbXzc-0000ly-7g for help-gnu-emacs@gnu.org; Tue, 07 Oct 2014 12:52:13 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:40780) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XbXzb-0000lq-Tr for help-gnu-emacs@gnu.org; Tue, 07 Oct 2014 12:52:08 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1XbXzZ-0002gX-Dd for help-gnu-emacs@gnu.org; Tue, 07 Oct 2014 18:52:05 +0200 Original-Received: from 50.56.99.223 ([50.56.99.223]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 07 Oct 2014 18:52:05 +0200 Original-Received: from eric by 50.56.99.223 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 07 Oct 2014 18:52:05 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 301 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 50.56.99.223 User-Agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/25.0.50 (gnu/linux) Cancel-Lock: sha1:4SfDafZMnNQTZTC+0JMoDyIMO0c= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:100327 Archived-At: dont.spam.earl@gmail.com writes: > Great - thanks for the pointer! I see it appears to occupy the same > niche as Company. While both are being actively developed on github, > searching doesn't uncover any recent comparisons of the two. > > How would you compare them? And why Helm over Company? I've never used Company, so I can't say. I picked Helm because "ooh, shiny!" If you're concerned about simplicity and the ease of adoption, do look closely at Helm before you jump in. Its defaults surprise the heck out some people. Particularly when it comes to file selection, one of the most basic Emacs UI elements there is -- it takes a bit of getting used to. > On Sunday, October 5, 2014 10:02:44 PM UTC-7, Eric Abrahamsen wrote: >> dont.spam.earl writes: >> >> >> >> > Drew - thanks for the response. Yes, Icicles is the most comprehensive >> >> > package for completion I've found, particularly for the mini buffer. I >> >> > found it especially helpful to read you explaining the philosophy >> >> > here: >> >> > http://stackoverflow.com/questions/2100166/making-sense-out-of-emacs-completion-mode-choices >> >> > >> >> > It appears Icicles is focused on mini-buffer completion though. Any >> >> > tips for the various forms of in-buffer completion: searching, cycling >> >> > through killed text, etc.? >> >> >> >> I think "helm" is becoming the standard response to this question -- it >> >> does all the minibuffer stuff, and provides a unified completion >> >> mechanism over find/grep/kill-ring/mark-ring, etc etc. People have made >> >> backends for an astonishing amount of stuff. You can also use it for >> >> in-buffer text completion by using the auto-complete backend. >> >> >> >> > On Sunday, October 5, 2014 8:28:54 PM UTC-7, Drew Adams wrote: >> >> >> > I'm posting to ask about a completion model I have in mind. Before I >> >> >> >> >> >> > code it up myself I'm trying to find any packages that already >> >> >> >> >> >> > implement most or all of this functionality. >> >> >> >> >> >> > >> >> >> >> >> >> > The Emacs Wiki Category page for Completion lists packages for >> >> >> >> >> >> > minibuffer completion and text completion: >> >> >> >> >> >> > http://www.emacswiki.org/emacs/CategoryCompletion >> >> >> >> >> >> > >> >> >> >> >> >> > I want a package for completion both INSIDE and OUTSIDE of the >> >> >> >> >> >> > minibuffer with a universal UI: >> >> >> >> >> >> > - Minibuffer Input Completion: >> >> >> >> >> >> > - finding files >> >> >> >> >> >> > - switching buffers >> >> >> >> >> >> > - apropos for functions and variables >> >> >> >> >> >> > - and any other minibuffer history lists >> >> >> >> >> >> > - Text Completion in a Buffer: >> >> >> >> >> >> > - code completion >> >> >> >> >> >> > - executables/commands at a comint prompt >> >> >> >> >> >> > - i-searching in the current buffer >> >> >> >> >> >> > - cycling through killed text for yanking >> >> >> >> >> >> > >> >> >> >> >> >> > Further, I want to navigate via a couple "dimensions" of context, >> >> >> >> >> >> > both historical (previous inputs I've entered), and alphabetical >> >> >> >> >> >> > (previous and next alphabetically, as in files in a directory). >> >> >> >> >> >> > >> >> >> >> >> >> > The UI model and keybindings for this might be as simple as: >> >> >> >> >> >> > - show prefix candidates with TAB >> >> >> >> >> >> > - show substring candidates with S-TAB >> >> >> >> >> >> > - with candidates already shown, the second TAB/S-TAB would select >> >> >> >> >> >> > the first candidate >> >> >> >> >> >> > - navigate candidates alphabetically with C-r, C-s >> >> >> >> >> >> > - navigate candidates historically with C-p, C-n >> >> >> >> >> >> > >> >> >> >> >> >> > Do any packages implement this already? >> >> >> >> >> >> >> >> >> >> >> >> I think you will find that several packages support much or even >> >> >> >> >> >> all of what you request. Even vanilla Emacs supports much of it. >> >> >> >> >> >> >> >> >> >> >> >> I can't speak for other packages (others will), but Icicles >> >> >> >> >> >> supports pretty much all of what you mention. >> >> >> >> >> >> >> >> >> >> >> >> Icicle features apply mainly to the minibuffer. >> >> >> >> >> >> >> >> >> >> >> >> For in-buffer text (code) completion, whenever there are >> >> >> >> >> >> multiple candidates matching the buffer text to be completed, >> >> >> >> >> >> Icicles extends some vanilla commands to let you use its >> >> >> >> >> >> minibuffer completion features (regexp or substring matching, >> >> >> >> >> >> multiple-pattern matching, candidate sorting, cycling, etc.) >> >> >> >> >> >> >> >> >> >> >> >> So for text completion, instead of cycling among multiple >> >> >> >> >> >> candidates in place, Icicles uses the minibuffer and shows >> >> >> >> >> >> the candidates in `*Completions*'. When there is only one >> >> >> >> >> >> candidate, text completion in Icicles reverts to vanilla, >> >> >> >> >> >> in-place completion. >> >> >> >> >> >> >> >> >> >> >> >> Apart from Emacs Lisp, Icicles offers nothing particular for >> >> >> >> >> >> code completion that is language-specific. But its completion >> >> >> >> >> >> features are automatically available for any code-specific >> >> >> >> >> >> completion that uses `completing-read'. >> >> >> >> >> >> >> >> >> >> >> >> You can download Icicles from Emacs Wiki or MELPA, to try it. >> >> >> >> >> >> http://www.emacswiki.org/Icicles