From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= Newsgroups: gmane.emacs.bugs Subject: bug#48545: 28.0.50; `icomplete-vertical-mode` does not support the `group-function` Date: Sat, 21 Aug 2021 13:42:46 +0100 Message-ID: <874kbjq88p.fsf@gmail.com> References: <10d162d5-2cd6-dd87-3289-a0187dfbf51f@daniel-mendler.de> <871r6sw9iz.fsf@gmail.com> <87a6lfnld0.fsf@gmail.com> <87eearulft.fsf@gmail.com> <871r6pr8bk.fsf@gmail.com> <54e4e409-5525-b796-9e9c-582735995cc1@yandex.ru> <87r1epp6h9.fsf@gmail.com> <266d8a54-90de-e904-f548-8ec29e52923c@yandex.ru> <87pmu8qu8s.fsf@gmail.com> <878s0vqgny.fsf@gmail.com> <54ad79de-d527-0462-edaa-eee56c724565@yandex.ru> 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="4499"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) Cc: Daniel Mendler , 48545@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Aug 21 14:43:10 2021 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 1mHQL7-000145-VI for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 21 Aug 2021 14:43:10 +0200 Original-Received: from localhost ([::1]:53478 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mHQL5-00028H-VX for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 21 Aug 2021 08:43:07 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54872) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mHQL0-000289-78 for bug-gnu-emacs@gnu.org; Sat, 21 Aug 2021 08:43:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:52666) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mHQKz-0001fv-VP for bug-gnu-emacs@gnu.org; Sat, 21 Aug 2021 08:43:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mHQKz-0000Mn-Ok for bug-gnu-emacs@gnu.org; Sat, 21 Aug 2021 08:43:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: =?UTF-8?Q?Jo=C3=A3o_?= =?UTF-8?Q?T=C3=A1vora?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 21 Aug 2021 12:43:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48545 X-GNU-PR-Package: emacs Original-Received: via spool by 48545-submit@debbugs.gnu.org id=B48545.16295497791401 (code B ref 48545); Sat, 21 Aug 2021 12:43:01 +0000 Original-Received: (at 48545) by debbugs.gnu.org; 21 Aug 2021 12:42:59 +0000 Original-Received: from localhost ([127.0.0.1]:35979 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mHQKw-0000MW-G3 for submit@debbugs.gnu.org; Sat, 21 Aug 2021 08:42:58 -0400 Original-Received: from mail-wm1-f42.google.com ([209.85.128.42]:43889) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mHQKu-0000MJ-PA for 48545@debbugs.gnu.org; Sat, 21 Aug 2021 08:42:57 -0400 Original-Received: by mail-wm1-f42.google.com with SMTP id o39-20020a05600c512700b002e74638b567so51818wms.2 for <48545@debbugs.gnu.org>; Sat, 21 Aug 2021 05:42:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-transfer-encoding; bh=ikuXexwb32swGlu3eGMl+0RH3R6Td0MQomZuT+Qv9RU=; b=OT1OcY+WE2xBfOaBtHn2d3Z9+mrUBPO3ohKYIgeqWydSg7c4Wmp7WZHhV888hR5FDW CbaAW/TyBkREG2YFzPl/SIuWAuoVf18nIPTOoRLO+4yepN+J5Y76o4KBdKvgqHOgbqDi phjmahXgYN8MhLOZmQhHopcF/h7UTJRnSAREFjQ/+My1ty7l1+mMmNEfsapw2Lg7tY4Q 9s/hU00Ig52ebqM+iRF+6ilXpVM4xTAwTDQV0Ekj6U8lNuB6vQVYHq3rXbznG1hV9Fok xRCSfkRoPVxD+sXzD15jl0syRA28VgcYE2WIQAF76z0wakBflOLDKZ/HfX5FJKYiX317 MldQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=ikuXexwb32swGlu3eGMl+0RH3R6Td0MQomZuT+Qv9RU=; b=cJtdLih+xVs4bEFy8wElPq06MvNcLI5M5wH64PtH/YhTXCXrE5ZMEMFO1mgaf0rLs3 lJHWm2KdCMRAoVoJOqT7oKCNeAKM/XapuAEQF6a1LhHU+Ts8jSFNpu5fgbFTwyiCsTUO nWuMKP3yP17L2shfOnizP8l/8BLm7lgnPcjXybpv+eBCfn2A21xqLHIgdq82hkwY04O/ lVYYbqapIEv5luIlcgNEPZxAlXal0r1yklKNcVNBvxacEgA2DxO6R4La2oQa3IBGMuN9 IFFo4BHSQmPh4dcrDJDCY03yV+7m7FLZLKfpZ/OMXskmHJGk7DAonx30s5TuqazsGLo4 ZzcQ== X-Gm-Message-State: AOAM5311v6IzPGNZ9EzfJhwyjsZ3lylr7URZtFX0M09JMa6uloc9kKui 0pUf2/Rd1PKAntQ0KBF9CV1dJsbfZqo= X-Google-Smtp-Source: ABdhPJwDBSzPhhN3UiSJ0Ykeu8AqIsxmW5e4NTiQ3cECljhMBhL+ngZBrMV7jVZc32Q/zSbXSxacBA== X-Received: by 2002:a7b:cf16:: with SMTP id l22mr8429158wmg.185.1629549770487; Sat, 21 Aug 2021 05:42:50 -0700 (PDT) Original-Received: from krug (a94-133-228-229.cpe.netcabo.pt. [94.133.228.229]) by smtp.gmail.com with ESMTPSA id r20sm298512wrr.47.2021.08.21.05.42.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 21 Aug 2021 05:42:49 -0700 (PDT) In-Reply-To: <54ad79de-d527-0462-edaa-eee56c724565@yandex.ru> (Dmitry Gutov's message of "Sat, 21 Aug 2021 15:01:06 +0300") 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" Xref: news.gmane.io gmane.emacs.bugs:212336 Archived-At: Dmitry Gutov writes: > On 21.08.2021 12:40, Jo=C3=A3o T=C3=A1vora wrote: >> Yes, I think you see what you mean. But I also imagine it would be >> terrifyingly confusing for a user of a scrolling dropdown to see >> candidates jump back and forth into their groups as the user scrolls >> down to see a new candidate and hide another. If what I imagine isn't >> what you mean, maybe you could code something up and show what you mean. > > I suppose yes, if you only group candidates that are visible on the > screen, it could lead to jumping. Good point. Then I would suggest to > go back to "global" grouping. Then do. Go back to that experiment and its drawbacks and actually prototype it the way you envision it. Then share results here. > The order of completions coming from xref is essentially random. Yes, > they are grouped by files (usually), but the files are not coming in > any particular order. So I would prefer not to skip the sorting step. > Of course, there might be different scenarios and preferences in that > regard. If you sort the groups but not _inside_ the groups, you can skip the expensive sorting and still keep some order. Though in xref nothing is particularly expensive anyway. > Okay. Sorting seems to indeed be costly in this case (if I trust your > measurements). You can do them yourself. I posted what I measured from. If it's not clear, you should let me know. > Sorting is part of the default completion behavior (with grouping or > not). You want to remove it instead of fixing? It's very simple: As I've explained some times already, I contend, and K=C3=A9vin at least seems to agree, is that when there grouping the current slow 'a+l+r' sorting is not particularly useful. At least the "r =3D=3D=3D recently" part seems completely useful there. But the 'a+l' also seem to be kinda lame, at least for xref and C-x 8 RET. Now, if one agrees that sorting not particularly useful when there is grouping and that is significantly slows things down, then there is a good case for removing it when there is grouping. It's super simple. >>> Try disabling grouping. Is completion still slow? Then it's a problem >>> with sorting speed that needs to be solved separately anyway. >> icomplete.el doesn't do any grouping, it merely prints the grouping >> information as headers for the few matches that it will print. >> completion-all-sorted-completions also doesn't care about grouping. So >> there's nothing to disable in that regard. > > That addressed 3 words out of 20. How in heck could I adress the remaining ones which refer to the first three if those three were nonsense?=20=20 Look, you're asking me to do vaguely worded experiments that you can perfectly run yourself. If you understand what you mean, go run them yourself, document your findings and share them here for others to work from. It'll save us all time. >>>> This is flex doing its thing. >>> Yup. This is what I suggested to change. >> As I explained two or three times now: you can. In a new >> dmitry-flex >> style. That style is only a few lines of code away, I suppose. Or a >> defcustom, if you prefer those. The current behaviour for 'flex' is the >> correct one. It was conceived like this. flex scoring trumps grouping, >> table orders, etc... If you don't like this you can change this, like >> everything in Emacs. > > Nothing I suggested should call for a change in completion style. Then I misunderstood, again. You did suggest changes to the 'flex' completion style in another bug thread, I naturally though you meant that. Here, you wrote "this is what I suggested to change" after I described how the flex completion style worked. You provide no accurate description or code of what you want changed. If you weren't a programmer or especially versed in Elisp, I would comprehend. Given that you are, it is baffling, time-wasting and quite tiring. I'll just stop answering your hypothetical questions. Jo=C3=A3o