From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.devel Subject: RE: [External] : Re: Completions and history Date: Wed, 13 Apr 2022 16:40:48 +0000 Message-ID: References: <20220411112901.kv3lsyvx6yxwjbph.ref@Ergus> <20220411112901.kv3lsyvx6yxwjbph@Ergus> <86sfqjzhgl.fsf@mail.linkov.net> <20220411174031.2yuh2je5fl3lej7i@Ergus> <87ilre5i5a.fsf@gmail.com> <86k0burxd4.fsf@mail.linkov.net> <865yndxvzt.fsf@mail.linkov.net> <87ee215h1j.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="2262"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Daniel Mendler , Ergus , "emacs-devel@gnu.org" To: Augusto Stoffel , Juri Linkov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Apr 13 18:58:10 2022 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1negJl-0000M2-KM for ged-emacs-devel@m.gmane-mx.org; Wed, 13 Apr 2022 18:58:09 +0200 Original-Received: from localhost ([::1]:43498 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1negJk-0007Pa-FQ for ged-emacs-devel@m.gmane-mx.org; Wed, 13 Apr 2022 12:58:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35218) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1neg3I-0000Fo-Mx for emacs-devel@gnu.org; Wed, 13 Apr 2022 12:41:08 -0400 Original-Received: from mx0b-00069f02.pphosted.com ([205.220.177.32]:52048) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1neg3B-0004QX-7D for emacs-devel@gnu.org; Wed, 13 Apr 2022 12:41:07 -0400 Original-Received: from pps.filterd (m0246632.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 23DG1wPa029074; Wed, 13 Apr 2022 16:40:53 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : references : in-reply-to : content-type : content-transfer-encoding : mime-version; s=corp-2021-07-09; bh=tM4d7nS7KIzioSSrtfYx3GteTydJ3gSsA7GjQkF2qNI=; b=uTMcZxB4xd/nC2EEZzA/+H2GsjFxpOyVLdrCwZ58XWHq6FGjrHkM79EPTe5n1EVDkobo C4j7T1d/WlIxq8iUQnLakf8qHEuzsprnrYXXOl999NQGR7t0YXoNIvmp+j0RURMui/Br hlRf+PNWDxZHNad9SoxUOxaKK7UnvfTWQxF2gHfGy/a3RcY37E7jjqWG4GdUfWHrbi18 IuF8TMqtO9wa/JJ/VusP34Tw6EQwxxPnPbJuqxV/CxIMcv1qpnbyhEswtBhkaxfMqtsm YAFtBM4ikc6S3Qcs3aVjj2vuNSLIO3tC3S5VpdIZcTICzqzSpelmBB1xq4JdBz3n7YUR uQ== Original-Received: from iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (iadpaimrmta01.appoci.oracle.com [130.35.100.223]) by mx0b-00069f02.pphosted.com with ESMTP id 3fb1rsakq8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 13 Apr 2022 16:40:52 +0000 Original-Received: from pps.filterd (iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com [127.0.0.1]) by iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com (8.16.1.2/8.16.1.2) with SMTP id 23DGRRtW008477; Wed, 13 Apr 2022 16:40:52 GMT Original-Received: from nam12-dm6-obe.outbound.protection.outlook.com (mail-dm6nam12lp2169.outbound.protection.outlook.com [104.47.59.169]) by iadpaimrmta01.imrmtpd1.prodappiadaev1.oraclevcn.com with ESMTP id 3fb0k45pe8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 13 Apr 2022 16:40:52 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Qi29sDJ3PYGBN29VBniUeofBv0ifG/DYgrgIxbeAnYdelPZYcFKkFfo5lVMnfUBS15E+tsBadELi6fl5nNl2s+fXc2yzmBxmYwdAhw5nEJzN9e1mAb/StgEKEyfqx524Mt77JL9Q4wgp356dWeW3HgoXy00LgftJvF9cKyK2zWJh68dwxAKqiyazg8OxUkSuA1SUIz038XPkpm0aqk28bQBCieS9/QpBIkjrzQk5fq9A7HW2mRQvHT8A5ePXSOJ6kE3pFsyVL2S4CtkZwIKXaZZ/0Hjc/jf50/w5/fISszsuyug9SGb1veQbOJsjYQL7va7gh184844h4M5MIeJwZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=tM4d7nS7KIzioSSrtfYx3GteTydJ3gSsA7GjQkF2qNI=; b=oQq1w2N5W6hwr3EL3rwcYd5LIGsjAgSTJctg4ZbFNhwf8dMz6NhmIAnubMve8DEeSf2MIMkQy7ZaW8aaj6apv0VEdGFmetPYs9MflYdN8MIP6jAbl7fakmbYytyMBkN7OJPo4+xx99/2DHVZgp77QwgEccAJyzwAVwCNe+W2k8I7nXFQG8f9izDcNYcDsDGGDDfm0viRCD/POjfTH/TF+tdAcGrrZqFXQbb0CDbCNp6P4sx/3WPRlGt/7w2deegtQ3q28yH7L6QDIbs4HNv5lAnVr8DNOeBfsWFWZufVt98Luhg6WD4blqymeBL5Nw5jt6IYFVIb6efBTPS/L1uA5w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=tM4d7nS7KIzioSSrtfYx3GteTydJ3gSsA7GjQkF2qNI=; b=gmDgH2dnp8GQuVHBBCDXWip2xVY84cgOYM6HRdNI08HSQBK0AiMnI01UKFRmUj4CleaRYmTi0CuesP85HZaQ5v+Tdh7Iqmf8E8Jmgs7o0Q4Uc+zxO+GqB9UrL27nVKxaDURhBj/jjFJPtAB9OJyK1mLlWZXc5ZYLsP/YXbfTXUA= Original-Received: from SJ0PR10MB5488.namprd10.prod.outlook.com (2603:10b6:a03:37e::19) by SN6PR10MB2462.namprd10.prod.outlook.com (2603:10b6:805:47::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5144.29; Wed, 13 Apr 2022 16:40:49 +0000 Original-Received: from SJ0PR10MB5488.namprd10.prod.outlook.com ([fe80::a0e7:5f38:ab50:5123]) by SJ0PR10MB5488.namprd10.prod.outlook.com ([fe80::a0e7:5f38:ab50:5123%7]) with mapi id 15.20.5144.030; Wed, 13 Apr 2022 16:40:49 +0000 Thread-Topic: [External] : Re: Completions and history Thread-Index: AQHYTy5DqFNQI/5m7UWDZC5E6gFLUKzt/fDg In-Reply-To: <87ee215h1j.fsf@gmail.com> Accept-Language: en-US Content-Language: en-US x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 1adb2ed4-8eb3-4ff8-0a05-08da1d6c5da4 x-ms-traffictypediagnostic: SN6PR10MB2462:EE_ x-microsoft-antispam-prvs: x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: JMCWLVzhFLh7i3Hbh07J/bJEJICgDEryNSmj9zANkwcIJF8mq0p6dKeb5DBg3/D/iEjiDhKMeRgJmJJw6sKryuqP9iWWsAP4T76KaIGDVUO6g5lDrLWpdXRSidI5ZsbCM2Ja2SsCTB8AyolnzNAwC2g5SQFhIViOlCk0dKuHBAJYfbDSYHpvTHVx2RNtpeZ5WkraMOLZWXqEQscg/Ro7ByFw4HMLHZwnDPodPHB2cVg96XrI8ImCMwu/piHM/nF0IbQBVjejBoggN6fVtDDU2edm7fXV3FYvn4JRK7zXn2DxRcPXRakcMtrkT1Qt+fuYvdTxhJIvB8QEgAE42iOBRm/McbI9jYETfBEMJCBZtpp4qljHheOY6XaxgEFgXoQAo7sf/s6ighNgF/YDrUczEJGKNkthfvBSwtEsZB6fXd5VBqquOBm/ZmoWj+24cVQ6XWfYejPaXPNeqb4gkOIjM6Ee4At0lfQxlR+r+A+bYGA3r/Q/6Mtdfs3O229VfFV3vMCVnQKwe47Bh+2k8mON9qNMfnbF12Hp6YjzEiuBYEyX9KtGVHqM6U3mvMuI1p7wMjhACJEAkyfVoLhOfxRZhIyGFy0eD3ZBDAq69F8qhjM6deDB49oN0R9li0usHwGtIMtHznDUUVFoz1zqLwy0rlF2ANN9AZjnAR5MssDmFSP/NxGrzq+Tin9ClnedRLtT0E0aNwwYo/rygnolQK4DHw== x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SJ0PR10MB5488.namprd10.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(366004)(2906002)(7696005)(4326008)(8676002)(66446008)(508600001)(66946007)(76116006)(66476007)(83380400001)(66556008)(64756008)(6506007)(86362001)(44832011)(52536014)(71200400001)(8936002)(26005)(186003)(5660300002)(9686003)(110136005)(122000001)(54906003)(55016003)(38070700005)(38100700002)(316002)(33656002); DIR:OUT; SFP:1101; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?RLtpxMsH1rIMrRdCBl487y+WPQq/mDT0yFy/GRYEjn0IudFmHHK0yfQS81CL?= =?us-ascii?Q?SWtzY7jcMHKlrwQAaQkSlP1vTo9z0YNowZiD5s/XSYG2M9QlRdV8xk61Gizq?= =?us-ascii?Q?3ahd8LK1IlFQc9T7k1BPD3utqWoCv+9L7mD4r8VFYAXOnjkCaHgOOXAFWctl?= =?us-ascii?Q?v5IhAReYjTeKyV5X8Nke88Vqj8GyHuOGIe5YLVG6ALUs+JLY+4g4+0VqdTyG?= =?us-ascii?Q?8tLPY530vhbqlL1Q/2ShQu716JHaQ501pZAPb25GJnN8ihVSk3hjGsNg82AA?= =?us-ascii?Q?Xv0SwA0z7n8KpaYlZY349DValBgd/nPhjP7rg/XQj9M/uCrB5NnSeKcgb9uC?= =?us-ascii?Q?doOP3e6unkuc5vwJS9ZgxBpHtqodo2p/V0j6ZQVgaVW1y/G8/rFNXiQz5fpG?= =?us-ascii?Q?uCguWKpkF55/IT2+7HRXZmgFQG5mp5zKPAVSC99yKfD26aMm5d1NQbPXJRZv?= =?us-ascii?Q?e224Nz09jyrTN4cvJz2pC213GbQePuEJATVfrgdzhga8SCAdfhZm+qcVw+pm?= =?us-ascii?Q?UGv/XNBwMN0UOMotuILPecDsF8vmRQlzvVMSINGp0gbSmVsK6hrDZrtj6DUS?= =?us-ascii?Q?wuRXOVlLi6GM6ZE5TUkH+JHoU6PWatiOuYp0goqYGIGPqURo0zNvzvfarZGQ?= =?us-ascii?Q?Iw X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: SJ0PR10MB5488.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 1adb2ed4-8eb3-4ff8-0a05-08da1d6c5da4 X-MS-Exchange-CrossTenant-originalarrivaltime: 13 Apr 2022 16:40:48.9645 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: NTfOE1eKRtrHyH+A5GOvoQ7ZLNWYbmMmjnRR3UV6RsKyA5qpa7zFkOkVoc1u5cPtb/lsTlMVLlpfx7a3DuFUkA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN6PR10MB2462 X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.486, 18.0.858 definitions=2022-04-13_03:2022-04-13, 2022-04-13 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 adultscore=0 malwarescore=0 bulkscore=0 suspectscore=0 mlxlogscore=614 mlxscore=0 spamscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2202240000 definitions=main-2204130085 X-Proofpoint-ORIG-GUID: 4Oc8dbbugCWuv3sQlENViPcpLei3jm9S X-Proofpoint-GUID: 4Oc8dbbugCWuv3sQlENViPcpLei3jm9S Received-SPF: pass client-ip=205.220.177.32; envelope-from=drew.adams@oracle.com; helo=mx0b-00069f02.pphosted.com X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:288368 Archived-At: > > Maybe the same key `C-c C-l' could be bound by default > > in the minibuffer to enable history completion? >=20 > Discussing default keybindings tends to be rather > unfruitful, but still: unless I'm missing something, > `M-r' (previous-matching-history-element) > is strictly less powerful than `C-M-r' > (isearch-backward-regexp). Dunno why you would choose to compare those two. Anyway, Isearch key `C-M-r' is "more powerful" than Isearch key `C-r' too. So what? There are good reasons why Emacs has two different keys for those different commands. > History completion is quite handy and would be a > better use for `M-r' in my opinion. Of course it's quite handy. So is simple history search with `M-r` (previous-matching-history-element). Let's please not try to cram the proposed feature onto an existing key binding. Users should _also_ be able to complete against history items. As the guy who long ago tried to get Emacs more interested in using completion for minibuffer reading, I'm convinced of its utility. That doesn't mean completion is always the best way to let users choose something. It's just one way. It doesn't mean that completion should replace other longstanding ways to choose things, especially when it doesn't offer the same possibilities. ___ I'll give you an analogous how-to-choose from Icicles, FWIW: You can use key `C-,' in the minibuffer during completion to change to a different sort order. How to choose the sort order? One way is completion: You can pick one from those available in the current context (you can see them in *Completions*). Another way is just cycling among them, without bothering to see them all or bothering to type input to match one. Icicles offers both possibilities, both (1) as a user preference (Customize option) and (2) on the fly, for any given use of `C-,'. In fact, the option allows three possibilities: 1. Always use completion. 2. Always use cycling. 3. Use completion if there are more than N sort orders to choose from; else use cycling. `C-u' flips the behavior: if the option would normally call for completion then cycle instead, and vice versa. Why go to the trouble of providing those different ways to change the sort order? Because completion, though "quite handy", as you say, isn't always the best or quickest way to choose something. Cycling isn't always the best way either. A simple rule is fine, but a given user, with a given command that involves choosing something, can want this or that behavior. Let users choose what they want easily.