From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Sean Whitton Newsgroups: gmane.emacs.bugs Subject: bug#62468: 30.0.50; Improve Icomplete while-no-input s.t. C-g quits the minibuffer Date: Sun, 26 Mar 2023 13:44:43 -0700 Message-ID: <87o7ofckec.fsf_-_@athena.silentflame.com> References: <831qlh79at.fsf@gnu.org> <87zg83e032.fsf@melete.silentflame.com> <83sfdv44df.fsf@gnu.org> 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="17985"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) To: 62468@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Mar 26 22:45:21 2023 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1pgXEt-0004M9-4k for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 26 Mar 2023 22:45:20 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pgXEe-0000rI-Ac; Sun, 26 Mar 2023 16:45:04 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pgXEd-0000qw-3N for bug-gnu-emacs@gnu.org; Sun, 26 Mar 2023 16:45:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pgXEc-0006fg-R0 for bug-gnu-emacs@gnu.org; Sun, 26 Mar 2023 16:45:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pgXEc-0006NP-4d for bug-gnu-emacs@gnu.org; Sun, 26 Mar 2023 16:45:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Sean Whitton Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 26 Mar 2023 20:45:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 62468 X-GNU-PR-Package: emacs X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.167986349024469 (code B ref -1); Sun, 26 Mar 2023 20:45:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 26 Mar 2023 20:44:50 +0000 Original-Received: from localhost ([127.0.0.1]:45981 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pgXEP-0006MZ-Vz for submit@debbugs.gnu.org; Sun, 26 Mar 2023 16:44:50 -0400 Original-Received: from lists.gnu.org ([209.51.188.17]:47276) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pgXEO-0006MQ-BZ for submit@debbugs.gnu.org; Sun, 26 Mar 2023 16:44:48 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pgXEO-0000oI-1p for bug-gnu-emacs@gnu.org; Sun, 26 Mar 2023 16:44:48 -0400 Original-Received: from out2-smtp.messagingengine.com ([66.111.4.26]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pgXEM-0006d9-72 for bug-gnu-emacs@gnu.org; Sun, 26 Mar 2023 16:44:47 -0400 Original-Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 513D65C00C7 for ; Sun, 26 Mar 2023 16:44:45 -0400 (EDT) Original-Received: from mailfrontend2 ([10.202.2.163]) by compute5.internal (MEProxy); Sun, 26 Mar 2023 16:44:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=spwhitton.name; h=cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to; s=fm1; t= 1679863485; x=1679949885; bh=Y9ihKAvC9kPIVwuoHZHOYAPyfYzFRikVTrv xEIcuQk8=; b=mupTytvWTosFak6PU4HLgub6mGdetvLksunaxfHp36KeYz0qPtJ BondFMCul8FWGKy/ygP+IwcLKXq08ATAPWF5JxWIHxuJG7BinLhnENpGaRRwmSaZ TNk50ACu5nbS25gxPPQ6XOKLUvJDevz8V6k1901aD6VVr4GjDvNv/0G6zFBrvMG9 uHXe+cVU5tj9NaA8wOF6L4rXu94EkAgEe3iDjLzqdOkKqRjkGyLl1ukpQWKC2OJQ 1O8hUF4wSgakHPK5XJGJUkwxdJKAPMEEiCZasuzmsjqFX7W4+o40c0jKqOzMZ0FD kMriIG5SDkJiKEp8+o7KP6/8WhYd17B+b2A== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:sender:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t=1679863485; x= 1679949885; bh=Y9ihKAvC9kPIVwuoHZHOYAPyfYzFRikVTrvxEIcuQk8=; b=a WmTZqgP/TNjPmCAtqPbgqkypL+9p27r9+087XhbdC521spbt8ZozKBg6beH32H2V KQmO9b7KUNS6UagqbHKCuPGQ2+kSBaoCNJnw7Wvd+Ku3olu6fvWPRQG8F7Dje1UB +HlkBs3mQoZwreNsYYF/MpggK1iwrJoQnPz0yKdMtSsQDZfbIDWZGY/yKqk1dTmj WfKi2GNIhRRmHeEBMK6vmXRtzB9rMT0jcQv6D76+L2YuerGhA5OGapwX3ayHB6sY UthHn4xA7DQA7RsKQpa7qw1Rq2n+zR6ojLQIz/jP0zSifmmwYWZfnk/lEL0crn+d iy/nkvJjlF6ka22Q2XD2g== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvhedrvdehtddgudehfecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecunecujfgurhephffvufgjfhffkfgfgggtgfesth hqtddttderjeenucfhrhhomhepufgvrghnucghhhhithhtohhnuceoshhpfihhihhtthho nhesshhpfihhihhtthhonhdrnhgrmhgvqeenucggtffrrghtthgvrhhnpedugfehledtgf egkedvudetheffvddvfeegveduleehhefggeehhffhveekteejfeenucevlhhushhtvghr ufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehsphifhhhithhtohhnsehsph ifhhhithhtohhnrdhnrghmvg X-ME-Proxy: Feedback-ID: i23c04076:Fastmail Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA for ; Sun, 26 Mar 2023 16:44:44 -0400 (EDT) Original-Received: by athena.silentflame.com (Postfix, from userid 1000) id 777541B6035; Sun, 26 Mar 2023 20:44:43 +0000 (UTC) In-Reply-To: ("=?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?="'s message of "Fri, 24 Mar 2023 12:39:29 +0000") Received-SPF: pass client-ip=66.111.4.26; envelope-from=spwhitton@spwhitton.name; helo=out2-smtp.messagingengine.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_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:258699 Archived-At: Hello, X-debbugs-cc: joaotavora@gmail.com On Fri 24 Mar 2023 at 12:39PM GMT, Jo=C3=A3o T=C3=A1vora wrote: > As far as I know, the "unobtrusive" part of Icomplete &c is designed > primarily to let you modify the search pattern upon which Icomplete > is acting to show you potential candidates for the thing you ultimately > want to complete to as quickly as possible, so that if I type, say > > M-x fido-mode > M-x > f o o > > then the search for all commands whose name contains 'f' is interrupted, > and any results discarded, as soon as I type the 'o', the 'o' is shown > in the minibuffer, and a search starts anew. This is realized with > while-no-input. If the completion backend is particularly slow in searchi= ng > (which is usually not C-x b's case, but other backends are indeed slow), = this > helps a lot in seeing what you are typing. > > As far as I know, this behavior is _not_ designed to "tweak" the > C-g behaviour to be anything different from what you would get > if you were not using Icomplete or Fido mode. Thank you for this summary. So, this is pretty much a feature request to extend the unobtrusiveness a bit further, if we can. > That said, I don't understand exactly what you want to happen when you > type C-g before the search is complete, what happens instead, and why > do you think you're seeing a bug. Okay, how about this. As you describe, typing any self-insert chars while Icomplete is computing what to display cancels and restarts that computation. The primary purpose of this, as you say, is to allow the user to modify the search pattern as quickly as possible. A slightly broader way to understand the same thing is as allowing the user to /ignore Icomplete until they've finished inputting/ their pattern. So, if Icomplete starts computing essentially bogus completions, because I'm still typing my initial input, I don't have to do anything special to restart the search. We can make this broader: instead of allowing the user to ignore Icomplete just while inputting the initial pattern, I'd like to be able to /ignore Icomplete until and unless I want to use its bindings/. While I'm still inputting my initial pattern, I want to ignore Icomplete because I'm not ready to complete. Similarly, if I hit C-g to cancel minibuffer input, I would like to be able to ignore Icomplete because, again, I'm not interested in doing any completion. Many instances of completing-read are invoked by the user in order to enter arbitrary strings, and not to do any completion, even though it's available. I would like to be able to C-g out of these, as though Icomplete weren't there at all, because I have no interest in using it. However, as I described, if your C-g is unfortunately timed it gets caught by the Icomplete computation and so doesn't exit the minibuffer. Perhaps we can extend this so that it doesn't matter what moment the C-g comes in. --=20 Sean Whitton