From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#3717: M-x man completion Date: Thu, 26 Nov 2009 11:28:27 +0200 Organization: JURTA Message-ID: <87aay94ouh.fsf@mail.jurta.org> References: <87bpo6p3de.fsf@turtle.gmx.de> <87ab3pfqj0.fsf@jidanni.org> <87ocmsqa7z.fsf@mail.jurta.org> <87d4364lmh.fsf@mail.jurta.org> <87bpiqtde7.fsf@blah.blah> Reply-To: Juri Linkov , 3717@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1259230115 11860 80.91.229.12 (26 Nov 2009 10:08:35 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 26 Nov 2009 10:08:35 +0000 (UTC) Cc: 3717@emacsbugs.donarmstrong.com, jidanni@jidanni.org To: Kevin Ryde Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Nov 26 11:08:28 2009 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1NDbH1-0008Ga-Sj for geb-bug-gnu-emacs@m.gmane.org; Thu, 26 Nov 2009 11:08:28 +0100 Original-Received: from localhost ([127.0.0.1]:59497 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NDbH1-0003Qn-FI for geb-bug-gnu-emacs@m.gmane.org; Thu, 26 Nov 2009 05:08:27 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NDbG9-0002eu-IZ for bug-gnu-emacs@gnu.org; Thu, 26 Nov 2009 05:07:33 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NDbG4-0002cD-DN for bug-gnu-emacs@gnu.org; Thu, 26 Nov 2009 05:07:32 -0500 Original-Received: from [199.232.76.173] (port=49265 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NDbG4-0002bs-9S for bug-gnu-emacs@gnu.org; Thu, 26 Nov 2009 05:07:28 -0500 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:34662) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NDbG3-0007yh-1P for bug-gnu-emacs@gnu.org; Thu, 26 Nov 2009 05:07:27 -0500 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nAQA7MlS003988; Thu, 26 Nov 2009 02:07:23 -0800 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.14.3/8.14.3/Submit) id nAQ9o6vh001927; Thu, 26 Nov 2009 01:50:06 -0800 Resent-Date: Thu, 26 Nov 2009 01:50:06 -0800 X-Loop: owner@emacsbugs.donarmstrong.com Resent-From: Juri Linkov Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs 2Resent-Date: Thu, 26 Nov 2009 09:50:06 +0000 Resent-Message-ID: Resent-Sender: owner@emacsbugs.donarmstrong.com X-Emacs-PR-Message: followup 3717 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 3717-submit@emacsbugs.donarmstrong.com id=B3717.12592286891448 (code B ref 3717); Thu, 26 Nov 2009 09:50:06 +0000 Original-Received: (at 3717) by emacsbugs.donarmstrong.com; 26 Nov 2009 09:44:49 +0000 X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. Original-Received: from mx2.starman.ee (smtp-out4.starman.ee [85.253.0.6]) by rzlab.ucr.edu (8.14.3/8.14.3/Debian-5) with ESMTP id nAQ9il7R001441 for <3717@emacsbugs.donarmstrong.com>; Thu, 26 Nov 2009 01:44:49 -0800 X-Virus-Scanned: by Amavisd-New at mx2.starman.ee Original-Received: from mail.starman.ee (82.131.35.156.cable.starman.ee [82.131.35.156]) by mx2.starman.ee (Postfix) with ESMTP id 0BA423F40C9; Thu, 26 Nov 2009 11:44:39 +0200 (EET) In-Reply-To: <87bpiqtde7.fsf@blah.blah> (Kevin Ryde's message of "Thu, 26 Nov 2009 10:04:16 +1100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (x86_64-pc-linux-gnu) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Resent-Date: Thu, 26 Nov 2009 05:07:32 -0500 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:32952 Archived-At: >> Possible completions are: >> lib (3erl) >> lib (3perl) > > If you complete from "li" it gives "lib (", which will make man error > out. What man error? I see no problem here. If the user sees an incomplete manual name with the opening parenthesis, then s?he continues to complete it to the specific section name. > I insert a bare "lib" for such cases so that completion stops > without the "(" for whatever is man's default page for "lib". You may > have seen the "chmod" example in my code. I think it's bad to hide the fact that a manual name is ambiguous and that the user have to select the necessary section instead of using an arbitrary default section. IOW, what I don't like is missing indication that may cause to select a wrong section. For manual names that belong only to one section, removing the section name would be ok. `M-x woman' deals with this problem by asking a manual file name when the selected manual name is ambiguous. > I also put in stuff like "3erl lib", since you can enter it like that to > man, and it can be easier to give the section first then complete among > pages in the section, as opposed to a section suffix. This duplicates completions for every manual name with e.g. "lib (3erl)" and "3erl lib". Perhaps this is not a problem, because when the first character of the completion is a digit, then completions are performed on the format "3erl lib". Otherwise, completions are performed on the format "lib (3erl)". For the format "lib (3erl)", you can narrow all completions to the specific section with `M-x man RET * (3erl) TAB'. But for the "3erl lib" format, it is easier to type `M-x man RET 3erl TAB'. So it seems this is a good change. > That latter probably doesn't cooperate with Stefan's prefix-based cache > thing as it stands. But I found it better to cache all page names once, > because a "-k" run is pretty much as slow asking for a few matches as > many. > > I did say there was lots of things I've already been through for > friendliness and features! :-) In your first message to bug#3717, you named them "feeping creatures" :-) (I hope most features in man-completion.el are not creeping.) -- Juri Linkov http://www.jurta.org/emacs/