GNU bug report logs - #74561
[PATCH] Allow limiting the size of *Completions*

Previous Next

Package: emacs;

Reported by: Spencer Baugh <sbaugh <at> janestreet.com>

Date: Wed, 27 Nov 2024 20:26:02 UTC

Severity: wishlist

Tags: patch

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Juri Linkov <juri <at> linkov.net>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: Spencer Baugh <sbaugh <at> janestreet.com>, sbaugh <at> catern.com, dmitry <at> gutov.dev, joaotavora <at> gmail.com, Eli Zaretskii <eliz <at> gnu.org>, 74561 <at> debbugs.gnu.org, Stefan Kangas <stefankangas <at> gmail.com>
Subject: bug#74561: [PATCH] Allow limiting the size of *Completions*
Date: Sat, 15 Feb 2025 19:45:06 +0200
>> In the process, I realized that this optimization doesn't help
>> completions-format=vertical without a lot of effort, since that fills
>> the entire first column before continuing to the second column.
>
> FWIW, maybe we should change this behavior so instead of filling
> column-by-column we fill line-by-line.

I think this is exactly how we should improve completion--insert-vertical.
Instead of filling the first column before continuing to the second column
the algorithm could be changed to:

1. partition the list of completions (e.g. by `seq-partition`)
   into N groups corresponding to columns;
2. then take the first elements from each sublist
   while laying them out line-by-line.




This bug report was last modified 58 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.