From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ergus Newsgroups: gmane.emacs.devel Subject: Re: Question about completion behavior Date: Wed, 9 Mar 2022 11:11:59 +0100 Message-ID: <20220309101159.4k3uma2ztvldlqiz@Ergus> References: <20220309001013.gxyh2uasbuxiz6ww.ref@Ergus> <20220309001013.gxyh2uasbuxiz6ww@Ergus> <20220309014619.bptamkv47xdiyhzp@Ergus> <831qzbg5j2.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="7958"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Stefan Monnier , emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Mar 09 11:14:23 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 1nRtKo-0001qU-Ri for ged-emacs-devel@m.gmane-mx.org; Wed, 09 Mar 2022 11:14:22 +0100 Original-Received: from localhost ([::1]:39338 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nRtKn-0004lR-QD for ged-emacs-devel@m.gmane-mx.org; Wed, 09 Mar 2022 05:14:21 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:56802) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nRtJR-0002lp-ER for emacs-devel@gnu.org; Wed, 09 Mar 2022 05:12:58 -0500 Original-Received: from sonic305-1.consmr.mail.bf2.yahoo.com ([74.6.133.40]:39356) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nRtJL-0004ln-Sx for emacs-devel@gnu.org; Wed, 09 Mar 2022 05:12:56 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aol.com; s=a2048; t=1646820762; bh=B7gRCN8Q4v+2Xy7r0fSPGiOfu+Ap1ltwtjXxfBSgbgs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From:Subject:Reply-To; b=cAyO0EaQYMeklBXC0t5RscmYw4gh5QJq+ZR9a7TRJCT7db/s3XM/ykty3ZgA3AzT0b/qB06bSZBWHXIVPqIrTqZQMgfj2EqgtgSYBMIUrriQB0xL1jLXAB5NLdhRfcP+5Av3Q5RsC6MplWZ+i2ZXgAMKsUf6Q/0iOUAgeXQY5RhT1/z/eZ6jO5aTi2JTt2cfE7iwEpQjr7y/myq7/+3b91hgdH/ShHtZQSxjiQNwOAM1snaq1yG9gQYIbFZ6xgkQ1LG2mWHSCOWYYybWphu0JoVOZfzyKYhjvdv3nnYu4wONugQ9DNiJ9wl/AutYc7ZqAUcHP+jrhe/RUaZeK0fBSA== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1646820762; bh=PQvF476F3UHSH2scODlOPsBlcjw5nBMgqNaE1upfCST=; h=X-Sonic-MF:Date:From:To:Subject:From:Subject; b=mlagLfDrnwOXIkyelI8Ds6TFHwLXHnV8qv7fYC1Dc5Ca+hPw1iRWm4bHjSjj9mmpM6azQ3GSjUKMl1CesanOuTQrE+IC1idAysSmHQn35jzk7IBARUqgFfeVouI6qbdbec10nWf39G8bPcT/HzqXA4lQnKw4fzsnE7Y+Kmchr+NngN9xdcg2cCAuL09oI7a/CGVYyo2B458F4U8deBU0DqWq7s2bzSK+pFtT1zbfT6jU/gLDE1ulIVTbSEHBtO8Uzv1SEDUPsKsB8iKmn396b5xYLpKoIOyJ9dRf9wvdue/yWe0tkvz+/YdBbqgnwpPI7hldZLPGk/FECbCWXQWquA== X-YMail-OSG: Cf3l3GAVM1k.YlHJgKtAZW51DakyWHT2grjqoMYcElu8ES0Agt649tr6oH0Ezkg d2eFOc_8f2r5UywC5oasGWJ3S0eMfGThNcD_SiAyCpE.kifGJNJI2TuzvoGgqp_wpiLl59_1IAXJ arENxCeT6sbIDDwzURSyumG_ZpKdVItLRyUvj..srC45cxZ0Cl4uu5hgswovQpmUgCKWMqZhq2FX azpgDeQoMXqBIbrN9wXX8xu9LWpHj8gmLHw1koVeJUWzXZqZ5Y4OVQWe8H8g5TAZ2exWW_il_rR. q3EKOe4NrnF9wp96HxWHWbUU424dSzHFVn6VMinVsxstvgg5ikW80_cY8TbdgZniiFS281.w0t7g rR5VyigU7H8JBOAdpWZ4ChVy1Rr6jUFFwMRGdgPqYns.zh4hN077JPAr4e94RfRrkqWg17FR8Fyc hXHYEPvSDZoGBZkMWUT41Nq.5VAtut8i50FMHtPlh5QtuOVFLf2AcM5Wzf13umRddymaVFFHY0PL R2BlOPytg1VQRK4wLSPxW2Y0ANPXHhr9g8gLyT0glpZk91n1Xhl18Nt028ZfcBsYJ70h.E4ynudi NDO3oPlEz3HX98GenHcFJi9XikxSWQS4Oi1MrMi8Ga52pv.x2pLWKTUy7O9sUM8zUSCbCHOfjtlu ZTBJTgp6rt9NmXfG.4z_FwshozRXm_O3Ds_8RnGzCwHTOo1etSqvc9488wJZ5.Tnvd7RRshH.EPs 0c6xT9gt1FttV7bc29j8GB6MMVNA6PYLgwLB68c7jClbm459.K6gM0ZBqYsFmoxxOjH4bl7OqWpK Dp1OTu6Geitufa2iKt8q6.5PxsDTCqroBy4qHE4WVe X-Sonic-MF: Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic305.consmr.mail.bf2.yahoo.com with HTTP; Wed, 9 Mar 2022 10:12:42 +0000 Original-Received: by kubenode514.mail-prod1.omega.ir2.yahoo.com (VZM Hermes SMTP Server) with ESMTPA ID 0e20eecdab0edb632a280c9b1345c504; Wed, 09 Mar 2022 10:12:39 +0000 (UTC) Content-Disposition: inline In-Reply-To: <831qzbg5j2.fsf@gnu.org> X-Mailer: WebService/1.1.19878 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.aol Received-SPF: pass client-ip=74.6.133.40; envelope-from=spacibba@aol.com; helo=sonic305-1.consmr.mail.bf2.yahoo.com 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-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:286945 Archived-At: On Wed, Mar 09, 2022 at 05:37:37AM +0200, Eli Zaretskii wrote: >> From: Stefan Monnier >> Cc: emacs-devel@gnu.org >> Date: Tue, 08 Mar 2022 22:05:52 -0500 >> >> >>> Was all this behavior intended or how do you propose to solve this? >> >>I think this can be changed. >> >>Patches welcome. >> > I am struggling how to preserve the old behavior indeed, because what I >> > find a bit confusing is actually the default behavior. >> >> I think we should first consider *not* preserving the behavior. >> I.e. as suggested by the comment, rather than hide the completions, we >> should update them (if they're displayed). > >But please don't keep updating the completions buffer if TAB arrives >at a complete (but not necessarily unique) candidate. That would be >an annoyance. > Hi Eli: Thanks for replying. What do you mean by "at a complete"? there are several conditions to handle: These are the current more or less the conditions we have now: 1. no unique (shows or update completions) 2. unique common (complete-common and hides completion) 3. unique candidate (complete and hides completion) 4. unique common but completion is a valid entry (complete-common and hides completion) Is the 4 to what you refer? For example when we have: magit magit-commit magit-push .... and we do: magi the completion goes up to magit (adds the t) but it is a valid candidate. What I propose is: 1. no unique (shows or update completions) 2. unique common (complete-common and UPDATE completions) 3. unique candidate (complete and hides completion) 4. unique common but completion is a valid entry (complete-common and hides completion) Is this behavior fine?? Best, Ergus