From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.devel Subject: RE: filename input wildcard `?' Date: Thu, 27 Oct 2005 08:39:37 -0700 Message-ID: References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-15" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1130430103 6088 80.91.229.2 (27 Oct 2005 16:21:43 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 27 Oct 2005 16:21:43 +0000 (UTC) Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Oct 27 18:21:40 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1EVARF-0003ov-Kz for ged-emacs-devel@m.gmane.org; Thu, 27 Oct 2005 18:17:14 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EVARE-000136-FE for ged-emacs-devel@m.gmane.org; Thu, 27 Oct 2005 12:17:12 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1EV9r3-0001jN-7R for emacs-devel@gnu.org; Thu, 27 Oct 2005 11:39:49 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1EV9r1-0001gf-Mk for emacs-devel@gnu.org; Thu, 27 Oct 2005 11:39:48 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1EV9r1-0001fD-06 for emacs-devel@gnu.org; Thu, 27 Oct 2005 11:39:47 -0400 Original-Received: from [148.87.122.30] (helo=rgminet01.oracle.com) by monty-python.gnu.org with esmtp (TLS-1.0:DHE_RSA_3DES_EDE_CBC_SHA:24) (Exim 4.34) id 1EV9r0-0003U6-Mn for emacs-devel@gnu.org; Thu, 27 Oct 2005 11:39:46 -0400 Original-Received: from rgmsgw301.us.oracle.com (rgmsgw301.us.oracle.com [138.1.186.50]) by rgminet01.oracle.com (Switch-3.1.6/Switch-3.1.6) with ESMTP id j9RFdhZa006114 for ; Thu, 27 Oct 2005 09:39:43 -0600 Original-Received: from rgmsgw301.us.oracle.com (localhost [127.0.0.1]) by rgmsgw301.us.oracle.com (Switch-3.1.7/Switch-3.1.7) with ESMTP id j9RFdg0M027734 for ; Thu, 27 Oct 2005 09:39:43 -0600 Original-Received: from dradamslap (dradams-lap.us.oracle.com [130.35.177.126]) by rgmsgw301.us.oracle.com (Switch-3.1.7/Switch-3.1.7) with SMTP id j9RFdg2m027727 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NO) for ; Thu, 27 Oct 2005 09:39:42 -0600 Original-To: X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) In-Reply-To: X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1506 Importance: Normal X-Brightmail-Tracker: AAAAAQAAAAI= X-Whitelist: TRUE X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:44973 Archived-At: If these are the only ways to input a `?' as a file-name wildcard, shouldn't this be mentioned in the Emacs manual? As it stands, it gives (me) the impression that you can just type `foo?.el', which you cannot (AFAICT). Thanks. Thank you. I don't really want to open a can of worms, so ignore this if you think it's a bad idea or controversial: I wonder if we might consider allowing `?' to be bound, in the minibuffer, to `self-insert-command' instead of `minibuffer-completion-help', and use `C-h' for `minibuffer-completion-help'? That is: (define-key minibuffer-local-completion-map "?" 'self-insert-command) (define-key minibuffer-local-completion-map [remap help-command] 'minibuffer-completion-help) Advantages: 1) `?' would be available, without `C-q' quoting, not only as a file-name wildcard, but also as a normal, self-insertable character, for inclusion in command names, buffer names, menu items, data-entry values, ... , _any_ input for `completing-read'. Function `completing-read' is general, and it can be used by programmers for many different applications - why should it treat `?' specially when typed as input? If a programmer using `completing-read' wants to let users type `?' as input (without quoting), he must currently jump through a few hoops to make that happen. 2) `C-h' is a control character, not a printable character. It rarely needs to be included in an input string. Anyone wanting to include it will likely know about using `C-q' (which is not true for people typing `?'). 3) `C-h' (or ) is more likely to be people's first guess at finding completion help. Except for those already in the habit, people are unlikely to expect `?' to do what it does now. 4) Less potential confusion. Currently, if people do `C-h' during minibuffer completion (perhaps by accident): a. They are prompted for another help-command character. ("Huh, whatzis?") b. The help command is processed. ("Whereami now?") c. They end up back in minibuffer completion. They need to look for, and notice, the minibuffer prompt, to recognize this (probably unexpected) state. It's easy to mistakenly think you're back at top level. ("Ah, finally back home, safe. ?!*??@!! whatzis?") This current behavior can be disorienting to the uninitiated - and some of the `help-for-help' options can disorient more than others, taking users far afield of minibuffer input and completion (imagine reading the News, then coming back to minibuffer completion!). Better to have `C-h' do only one, simple thing, and that one help action to be specific to input completion. People can always exit the minibuffer first (`C-g'), if they really want `help-for-help' or one of the other global help commands. Disadvantages: ?