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: Recentish C-s M-y change Date: Tue, 5 Jan 2021 08:30:27 -0800 (PST) Message-ID: References: <87r1na4tyu.fsf@gnus.org> <87tus6tj7s.fsf@mail.linkov.net> <87a6txigm1.fsf@gnus.org> <874kk5lzew.fsf@mail.linkov.net> <16f69740-8902-492e-bef9-a6ced7907602@default> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="17308"; mail-complaints-to="usenet@ciao.gmane.io" Cc: ghe@sdf.org, ams@gnu.org, emacs-devel@gnu.org To: rms@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Jan 05 17:34:32 2021 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 1kwpHz-0004Nv-PB for ged-emacs-devel@m.gmane-mx.org; Tue, 05 Jan 2021 17:34:31 +0100 Original-Received: from localhost ([::1]:42546 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kwpHy-0007e9-Qb for ged-emacs-devel@m.gmane-mx.org; Tue, 05 Jan 2021 11:34:30 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:60448) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kwpGC-0005ux-IT for emacs-devel@gnu.org; Tue, 05 Jan 2021 11:32:40 -0500 Original-Received: from aserp2130.oracle.com ([141.146.126.79]:56522) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kwpGA-000387-7J; Tue, 05 Jan 2021 11:32:39 -0500 Original-Received: from pps.filterd (aserp2130.oracle.com [127.0.0.1]) by aserp2130.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 105GIksm036097; Tue, 5 Jan 2021 16:32:33 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-2020-01-29; bh=g6pwNkULZNqyxeCok4N80YtYpfmfJ1nBnQLi9cCr4Vc=; b=OKE+Z3OZ/zJJOaDodtT5kNYUHN7H8XzF0qzWpXIyMT3tNghwfBTp81PVLfVICsP58bmb PDy9jTvFkWArOLPY4adNbtJMBxPBLHD3QvwchJkI6l2xNu+nxAQAsuC2zmc8GEUorFtV rtoph9B+oREn+MqwQBfHCsqV3ayGT8aHyJxhRx0wphj1SRRKnw4y2JEi0EKVVYUSo00B Z2n9a6xnvFOLTcgUw35SHEQ8m3J5wQTEYWb7/M21Hzt4jkETZHjCcIEOhqWBWioTua8Y wbxsMog5hkz6D4spOobX74XFSmGRTa0ycaa3uRdcUE4cqJY/huP7uO3P4TLvJQ70RyAk lA== Original-Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by aserp2130.oracle.com with ESMTP id 35tebaspkc-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Tue, 05 Jan 2021 16:32:32 +0000 Original-Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 105GKnWk087232; Tue, 5 Jan 2021 16:30:32 GMT Original-Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserp3020.oracle.com with ESMTP id 35v1f8tg08-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 05 Jan 2021 16:30:32 +0000 Original-Received: from abhmp0001.oracle.com (abhmp0001.oracle.com [141.146.116.7]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 105GUSVH001053; Tue, 5 Jan 2021 16:30:30 GMT In-Reply-To: X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.5095.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9855 signatures=668683 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxlogscore=809 phishscore=0 suspectscore=0 spamscore=0 bulkscore=0 adultscore=0 mlxscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2101050100 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9855 signatures=668683 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 phishscore=0 priorityscore=1501 spamscore=0 mlxscore=0 clxscore=1015 bulkscore=0 lowpriorityscore=0 impostorscore=0 mlxlogscore=802 adultscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2009150000 definitions=main-2101050100 Received-SPF: pass client-ip=141.146.126.79; envelope-from=drew.adams@oracle.com; helo=aserp2130.oracle.com X-Spam_score_int: -45 X-Spam_score: -4.6 X-Spam_bar: ---- X-Spam_report: (-4.6 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.252, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, GAPPY_SUBJECT=0.1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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:262531 Archived-At: > > > Except that with many control characters defined, it is hard to > > > remember which ones are defined -- hard to be confident that a give= n > > > control character is one that will exit the search for you. >=20 > > To this point (only), let me point out that we will > > have `describe-keymap' (in Emacs 28, I guess), to > > which you can enter `isearch-mode-map' at the prompt > > to see all of its key bindings human-readably. >=20 > Sure -- there are various ways to find the current state > of these bindings. But not while thinking about how to > exit the current search. Not to belabor this, but in case it helps as food for thought, to help deal with your concern: 1. We could provide a key in `isearch-mode-map', by default, that shows that info, and that continues searching normally when you hit some other key. 2. We could provide behavior similar to that of Icicles key completion or `which-key.el' but adapted to handle Isearch. That is, continually show the keys available currently (either on demand or by option). 3. Provide such on-the-fly key help in some other way. ___ FWIW, although I haven't tried to address that need directly, with my library isearch+.el you can already get it currently, albeit in a somewhat roundabout way: 1. `C-x o' in Isearch opens a recursive edit. 2. `C-h M-k isearch-mode-map' shows Isearch keys. 3. `C-M-c' ends recursive edit and continues Isearch where you left off. (`C-x o' is a general Isearch command. It lets you interrupt a search, do whatever, then continue the search where you left off.) ___ And here's a quick and dirty command (thrown together in a minute) that if bound to an Isearch key shows the Isearch bindings in another window without interrupting Isearch. It makes use of another Isearch+ feature. (defun isearchp-show-keys (arg) "..." (interactive "P") (save-window-excursion (let ((isearchp-on-demand-action-function 'isearch-describe-bindings)) (isearchp-act-on-demand arg)) (setq this-command 'isearchp-act-on-demand))) (define-key isearch-mode-map 'isearchp-show-keys) [`isearchp-act-on-demand' is itself bound in Isearch to `C-M-RET'. It invokes the value of option `isearchp-on-demand-action-function', passing it the current search hit string and its start/end positions. Repeating it continues the action on subsequent hits. The default value of the action function replaces the search hit. This means you can replace (or delete) chosen search hits on demand.] ___ I'm not proposing any of this. Just showing that we could provide some on-the-fly key help, to give users an idea what's possible at any time during Isearch. (Yes, doing that might involve binding some key in Isearch or setting some option.)