From mboxrd@z Thu Jan  1 00:00:00 1970
Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail
From: Spencer Baugh <sbaugh@catern.com>
Newsgroups: gmane.emacs.devel
Subject: Re: Updating *Completions* as you type
Date: Wed, 18 Oct 2023 23:27:50 +0000 (UTC)
Message-ID: <87h6mnv7d6.fsf@catern.com>
References: <87bkd3z9bi.fsf@catern.com> <86cyxjyr1y.fsf@mail.linkov.net>
 <ier34ye4a3x.fsf@janestreet.com> <86r0lxm7um.fsf@mail.linkov.net>
 <87sf6dx954.fsf@catern.com> <8334ycqv0g.fsf@gnu.org>
 <87h6mryj5o.fsf@catern.com> <874jiqyd80.fsf@catern.com>
 <861qdtyvoe.fsf@mail.linkov.net>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214";
	logging-data="816"; mail-complaints-to="usenet@ciao.gmane.io"
Cc: emacs-devel@gnu.org
To: Juri Linkov <juri@linkov.net>
Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Thu Oct 19 01:29:02 2023
Return-path: <emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org>
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 <emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org>)
	id 1qtFyH-000AXS-AU
	for ged-emacs-devel@m.gmane-mx.org; Thu, 19 Oct 2023 01:29:02 +0200
Original-Received: from localhost ([::1] helo=lists1p.gnu.org)
	by lists.gnu.org with esmtp (Exim 4.90_1)
	(envelope-from <emacs-devel-bounces@gnu.org>)
	id 1qtFxH-0001fK-Pt; Wed, 18 Oct 2023 19:27:59 -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 <bounces+21787432-489d-emacs-devel=gnu.org@em8926.catern.com>)
 id 1qtFxF-0001ey-O0
 for emacs-devel@gnu.org; Wed, 18 Oct 2023 19:27:57 -0400
Original-Received: from s.wfbtzhsv.outbound-mail.sendgrid.net ([159.183.224.104])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1)
 (envelope-from <bounces+21787432-489d-emacs-devel=gnu.org@em8926.catern.com>)
 id 1qtFxD-0007V7-37
 for emacs-devel@gnu.org; Wed, 18 Oct 2023 19:27:57 -0400
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=catern.com;
 h=from:subject:in-reply-to:references:mime-version:to:cc:content-type:
 content-transfer-encoding:cc:content-type:from:subject:to;
 s=s1; bh=08cQlbO3RQ2W8gd6V6jQcuV/Xb9B/i7f1vBStwf0BKE=;
 b=pmo+L3WsNITG+bg2drss+Asubg/410Sjppcl/1x14Sdw2wSpkvmRY1Qc1CO8qlm48xvj
 8Ve1u3klO6AgKGGQ1/H4SAQZ/QvOQchAyquBbhmU7J6v0hbR6ajSxbyF2Gpw/L4Ye34K4p
 kp6KxtAF1B9f3fZ3dSUkR1HmFGGQyGGMnXKoDO/Ecv/BIUKUWx9MkNyzYMOWLsHU8hjr8l
 GpT0qwCyfvvIFFB42dcqwlX5e8MfiktdAR1zx8j4cNZ7xOQBVHsOgk39f90sqPoQzX4rO9
 66tV5rft8EEya23UqyQBrawo6Z9ReRaUSPg9ln5ybecwQ9MsP0/6wEQByfFzmmAw==
Original-Received: by filterdrecv-655bd866f5-5xz2l with SMTP id
 filterdrecv-655bd866f5-5xz2l-1-653069F6-4
 2023-10-18 23:27:50.337595338 +0000 UTC m=+103619.833264501
Original-Received: from earth.catern.com (unknown) by geopod-ismtpd-15 (SG) with ESMTP
 id Eyc6aGzcSNWKMiCmAurPKQ Wed, 18 Oct 2023 23:27:50.208 +0000 (UTC)
X-Comment: SPF check N/A for local connections - client-ip=::1; helo=localhost;
 envelope-from=sbaugh@catern.com; receiver=linkov.net 
Original-Received: from localhost (localhost [IPv6:::1])
 by earth.catern.com (Postfix) with ESMTPSA id B287166D3D;
 Wed, 18 Oct 2023 19:27:49 -0400 (EDT)
In-Reply-To: <861qdtyvoe.fsf@mail.linkov.net>
X-SG-EID: =?us-ascii?Q?GW3oCMoYnalRiojMOuLzE6x2H5kORXvlCdz1UwQVRMVT4fbh9ODEfCogOe74cO?=
 =?us-ascii?Q?rI4e0V+MFZgakz9Re5a6=2FCgjUmbBrC9SkC3SzXT?=
 =?us-ascii?Q?8MmCSQi3UI5v7=2FpqOyq0ZCyM1dNw+G9nzJ=2FLxYr?=
 =?us-ascii?Q?G1QY2lqATK+IvJuwqgKPt2R9Wl5MMPEl3ysAcSe?=
 =?us-ascii?Q?m5il7b+II0zmrnzWc7spe0dfx35cpo5m7WGNbIh?=
 =?us-ascii?Q?50TlMGFwyERgfpwc7J7ceYpNKNuWCjiXB1y9rb?=
X-Entity-ID: d/0VcHixlS0t7iB1YKCv4Q==
Received-SPF: pass client-ip=159.183.224.104;
 envelope-from=bounces+21787432-489d-emacs-devel=gnu.org@em8926.catern.com;
 helo=s.wfbtzhsv.outbound-mail.sendgrid.net
X-Spam_score_int: -20
X-Spam_score: -2.1
X-Spam_bar: --
X-Spam_report: (-2.1 / 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_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001,
 UNPARSEABLE_RELAY=0.001 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." <emacs-devel.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/emacs-devel>,
 <mailto:emacs-devel-request@gnu.org?subject=unsubscribe>
List-Archive: <https://lists.gnu.org/archive/html/emacs-devel>
List-Post: <mailto:emacs-devel@gnu.org>
List-Help: <mailto:emacs-devel-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/emacs-devel>,
 <mailto:emacs-devel-request@gnu.org?subject=subscribe>
Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org
Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org
Xref: news.gmane.io gmane.emacs.devel:311562
Archived-At: <http://permalink.gmane.org/gmane.emacs.devel/311562>

Juri Linkov <juri@linkov.net> writes:
>> Currently if the user re-runs minibuffer-completion-help, point is
>> reset to the beginning of the buffer.  This throws away information
>> unnecessarily; let's keep point on the same completion the user
>> previously selected.
>
> Are you sure everyone would want to always preselect the previous
> candidate in the middle of completions in every new completion?

Definitely not.  I allowed that behavior just to demonstrate the patch.
The real version will only retrieve the previous completion when
Completions is currently displayed - in other words, it will forget
whenever Completions disappears.