emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Now branch isearch-vertical


From: Gregory Heytings
Subject: Re: Now branch isearch-vertical
Date: Sat, 10 Apr 2021 20:00:39 +0000


Hi Ergus,


1) Could you add some customs for the separators? This may simplify the "unless" calls you needed to add twice. But also will permit the user to configure them.

IMO the best alternative is a sort of format; but at least setting the {} [] and () somehow will be very handy... maybe with a const pair.


That's not necessary to implement icomplete/fido verticality, so it should better be done with another patch I think. I'll submit a patch for that later.

(There is a single "unless" AFAICS.)


2) I am wondering about the icomplete-code that determines the number of candidates. IIRC the candidates are determined by the windows width... so maybe that needs some check? Because with narrow windows or long candidates the list may be needlessly truncated in vertical?


The trick is that there is no calculation of the number of candidates. A (long enough) list of candidates is added in an overlay, and Emacs automatically displays the first ones. With a smaller window you'll see less candidates, with a larger one you'll see more of them.


3) When you corrected my branch that time ago I remember that your recommendation was to respect the user option icomplete-separator. To detect if it had a "\n". Now that most of the display issues are solved and the setup is simpler. Isn't it possible to do that with a simple (if) in icomplete-minibuffer-setup instead of adding a hook?; setting some variables and then avoid all the `unless` and `if` in the (if prospects) part? So we don't need the extra mode and the setup for the user will be simpler.


That would have been possible in principle, but the code would not have been much simpler, and I think changing the behavior for a specific value of a user variable isn't the best thing to do. It's clearer to have a minor mode that users can toggle, and the setup in an init file is as simple as possible: "(icomplete-vertical-mode 1)".



reply via email to

[Prev in Thread] Current Thread [Next in Thread]