diff options
| author | Daniel Mendler <mail@daniel-mendler.de> | 2021-11-12 13:29:01 +0100 |
|---|---|---|
| committer | Daniel Mendler <mail@daniel-mendler.de> | 2021-11-12 14:14:00 +0100 |
| commit | 4b7b726279a83ba25d34cb2e895f1624c71a6f8a (patch) | |
| tree | 76b24b267c6d334476b0314576f9e6b52fbdd7c9 | |
| parent | f28192d6f55ae681e106e0f20323d6f21a020694 (diff) | |
Automatically select first candidatepreview-current
| -rw-r--r-- | corfu.el | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -729,6 +729,10 @@ A scroll bar is displayed from LO to LO+BAR." ((and corfu--candidates (not (equal corfu--candidates (list str))) continue) + ;; Automatically select first candidate! + (unless (or corfu-preview-current (>= corfu--index 0) + (test-completion str table pred)) + (setq corfu--index 0)) (corfu--show-candidates beg end str)) ;; 3) When after `completion-at-point/corfu-complete', no further ;; completion is possible and the current string is a valid match, exit |
