From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.bugs Subject: bug#36525: M-x default when cursor on top of a M-x command in INFO Date: Sun, 7 Jul 2019 17:27:44 -0700 (PDT) Message-ID: <18bc1649-6d5b-42c4-bb12-3630b0728b9c@default> References: <87ftnj5s5s.2.fsf@jidanni.org> <59855a35-cdc2-4c58-bcb2-791c62188374@default> <87r2711n5i.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-2022-jp Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="211788"; mail-complaints-to="usenet@blaine.gmane.org" Cc: 36525@debbugs.gnu.org, =?UTF-8?Q?=E7=A9=8D=E4=B8=B9=E5=B0=BC?= Dan Jacobson To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Jul 08 02:28:09 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hkHVp-000syf-QV for geb-bug-gnu-emacs@m.gmane.org; Mon, 08 Jul 2019 02:28:09 +0200 Original-Received: from localhost ([::1]:37802 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hkHVo-0000Xw-RV for geb-bug-gnu-emacs@m.gmane.org; Sun, 07 Jul 2019 20:28:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50837) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hkHVj-0000V8-4a for bug-gnu-emacs@gnu.org; Sun, 07 Jul 2019 20:28:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hkHVi-0000Up-3k for bug-gnu-emacs@gnu.org; Sun, 07 Jul 2019 20:28:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:48772) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hkHVh-0000Uc-TF for bug-gnu-emacs@gnu.org; Sun, 07 Jul 2019 20:28:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hkHVh-0006a3-Ne for bug-gnu-emacs@gnu.org; Sun, 07 Jul 2019 20:28:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Drew Adams Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 08 Jul 2019 00:28:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 36525 X-GNU-PR-Package: emacs Original-Received: via spool by 36525-submit@debbugs.gnu.org id=B36525.156254567725282 (code B ref 36525); Mon, 08 Jul 2019 00:28:01 +0000 Original-Received: (at 36525) by debbugs.gnu.org; 8 Jul 2019 00:27:57 +0000 Original-Received: from localhost ([127.0.0.1]:57593 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hkHVc-0006Zi-Ip for submit@debbugs.gnu.org; Sun, 07 Jul 2019 20:27:56 -0400 Original-Received: from aserp2120.oracle.com ([141.146.126.78]:32958) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hkHVb-0006ZU-0S for 36525@debbugs.gnu.org; Sun, 07 Jul 2019 20:27:55 -0400 Original-Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x680NmoJ060280; Mon, 8 Jul 2019 00:27:48 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : cc : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=vfjnYr83etxZB7l1bU7hoacsIiWDu4z63QDhXovPITA=; b=kjT+VZRHRgqC5YM6rHFgny4Owh+kGF2lBgZEDQQKkOE2qhPhTaaTt/mITvw8zO4MzYtS loks/M4YSEts00hawgQUOuPyz3JLaCAVmw7EqamKJ7WIoZlJC6puUmwpPbchqAIIDf3A YNDB9e+EVF5Uq3OJChcn3RQrJ/YhLp1MDR1GMf0cSdLgQ2bh0vb25wW3TEdvsiwjPdab 18kcRFumwxnIyMKwGAjM2BxLGcbTXDRPJmihr5NRJ7SC/52HRC8+ZRLNSEhML4GHVUm7 SoVF1MMds6RgsVT4xF/tzf4kCTuwQGDvbrwngUMH3u7Q+2+602ariN0bLpvMEYR0GnJV nw== Original-Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by aserp2120.oracle.com with ESMTP id 2tjkkpbgbn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 08 Jul 2019 00:27:48 +0000 Original-Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x680MxgQ052237; Mon, 8 Jul 2019 00:27:47 GMT Original-Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by aserp3020.oracle.com with ESMTP id 2tjkf1xq84-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 08 Jul 2019 00:27:47 +0000 Original-Received: from abhmp0020.oracle.com (abhmp0020.oracle.com [141.146.116.26]) by userv0121.oracle.com (8.14.4/8.13.8) with ESMTP id x680RjFO024570; Mon, 8 Jul 2019 00:27:46 GMT In-Reply-To: <87r2711n5i.fsf@mail.linkov.net> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4861.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9311 signatures=668688 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=958 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1907080003 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9311 signatures=668688 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1907080003 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:162313 Archived-At: > > A better way to handle this is to have a key > > (Icicles uses `M-.') that pulls text from the > > buffer into the minibuffer, appending it to > > whatever input text might already be there. > > > > Summary: > > > > Repeated `M-.' can have two different behaviors. > > You can choose (by an option) which one to use. > > [...] > > > > Whether vanilla Emacs would allow flexibility > > to this degree is not so important as at > > least having Emacs have a key that grabs > > _something_ from the buffer text and appends > > it to minibuffer input. Choice #2 above is > > pretty simple to realize - give users an > > option to specify which kind of text thing > > they want to insert. >=20 > Do you think `M-.' is a suitable key for vanilla Emacs? > Its global keybinding is `xref-find-definitions', > but is this command useful in the minibuffer? > Or could be taken for grabbing text from the buffer > to the minibuffer? Default key choice preferences are somewhat of a mine field for discussion... Dunno whether `xref-find-definitions' is usable from the active minibuffer. I'm not familiar with it. Perhaps so, with non-nil `enable-recursive-minibuffers'. I will point out that `M-.' is a repeatable key. And a repeatable key is good for a command that is repeatable, such as doing something to/with consecutive bits of text (e.g. "things") from a buffer. Is `xref-find-definitions' a repeatable command (i.e. by holding the key pressed)? On the other hand, in the old days `M-.' was bound to `find-tag', which was not repeatable (unless perhaps with non-nil `enable-recursive-minibuffers'). In Icicle (minor) mode, where `M-.' is bound to a command that inserts buffer text into the minibuffer, I've never noticed any conflict between that and the global binding of `M-.'. That may be some evidence that it would be OK to use it for something similar in the vanilla Emacs minibuffer. --- All of that said, I'd suggest that, _other things being equal_, keys like `M-.' should not be bound globally to commands that can't benefit from holding them down to repeat the action. `M-.' was bound to `find-tag' eons ago, before there were so many default key bindings, so many modes, so many libraries, and so many commands that are repeatable. It's not as if repeatable key bindings are as scarce as berkelium, but there's also no great reason to "waste" them on non-repeatable commands. Habit does matter to some extent, though, which I suppose is why `M-.' is still bound to a find command.