Function: corfu--exhibit
corfu--exhibit is a byte-compiled function defined in corfu.el.
Signature
(corfu--exhibit)
Documentation
Exhibit Corfu UI.
Implementations
:after (corfu--exhibit (NIL ((&context . corfu-popupinfo-mode) eql t))) in `corfu-popupinfo.el'.
Undocumented
:after (corfu--exhibit (NIL ((&context . corfu-echo-mode) eql t))) in `corfu-echo.el'.
Undocumented
(corfu--exhibit) in `corfu.el'.
Undocumented
Source Code
;; Defined in ~/.emacs.d/elpa/corfu-20260813.950/corfu.el
(cl-defgeneric corfu--exhibit ()
"Exhibit Corfu UI."
(pcase-let ((`(,beg ,end ,table ,pred . ,_) completion-in-region--data)
(`(,str . ,pt) (corfu--update 'interruptible)))
(cond
;; 1) Single exactly matching candidate and no further completion is possible.
((and corfu-on-exact-match
(not (eq corfu-on-exact-match 'show))
(equal corfu--candidates (list str))
(not (consp (corfu--try-completion str table pred pt))))
(if (eq corfu-on-exact-match 'quit)
(corfu-quit)
(corfu--done (car corfu--candidates) 'finished nil)))
;; 2) There exist candidates => Show candidates popup.
(corfu--candidates
(let ((pos (posn-at-point (min (point-max) (+ beg (length corfu--base))))))
(corfu--preview-current beg end)
(corfu--candidates-popup pos)))
;; 3) No candidates & `corfu-quit-no-match' & initialized => Confirmation popup.
((pcase-exhaustive corfu-quit-no-match
('t nil)
('nil corfu--input)
('separator (seq-contains-p (car corfu--input) corfu-separator)))
(corfu--popup-show (posn-at-point beg) 0 8 '(#("No match" 0 8 (face italic)))))
;; 4) No candidates & initialized => Quit.
(corfu--input (corfu-quit)))))