emacs-devel
[Top][All Lists]
Advanced

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

Re: feature/icomplete-vertical


From: Gregory Heytings
Subject: Re: feature/icomplete-vertical
Date: Mon, 05 Oct 2020 10:53:24 +0000
User-agent: Alpine 2.22 (NEB 394 2020-01-19)


Part 1 of the solution (which solves the "root" problem, and is not specific to icomplete-vertical):

Right. I appreciate this separation: solve a bug _then_ implement a feature.


Thank you :-)


Now, as far as I understand Eli and remaining maintainers are not OK with your bugfix.


No, Eli is "not against using this as a workaround [...] until the better solution arrives". It's not yet clear what that "better solution" will be, and when it will be implemented. And for code that needs to work on older Emacsen, this will remain a good solution.

(setq icomplete-separator "\n")
(add-hook  'icomplete-minibuffer-setup-hook (lambda () (setq 
start-display-at-beginning-of-minibuffer t)))
(defun icomplete-vertical-reformat-completions (completions)
  (save-match-data
    (if (string-match "^\\((.*)\\|\\[.+\\]\\)?{\\(\\(?:.\\|\n\\)+\\)}" 
completions)
        (format "%s \n%s" (or (match-string 1 completions) "") (match-string 2 
completions))
      completions)))
(advice-add 'icomplete-completions :filter-return 
#'icomplete-vertical-reformat-completions)

For example, in my verticality thing I would even remove one extra feature of your implementation that I don't find useful: the indentation of the candidates.


Indeed, I forgot to remove this from my code when I first sent my proposed solution two weeks ago. This extra feature is not anymore present in the above code.



reply via email to

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