Function: ido-restrict-to-matches

ido-restrict-to-matches is an interactive and byte-compiled function defined in ido.el.gz.

Signature

(ido-restrict-to-matches &optional REMOVEP)

Documentation

Set current item list to the currently matched items.

When argument REMOVEP is non-nil, the currently matched items are instead removed from the current item list.

Probably introduced at or before Emacs version 25.1.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/ido.el.gz
(defun ido-restrict-to-matches (&optional removep)
  "Set current item list to the currently matched items.

When argument REMOVEP is non-nil, the currently matched items are
instead removed from the current item list."
  (interactive "P")
  (when ido-matches
    (setq ido-cur-list (if removep
                           ;; An important feature is to preserve the
                           ;; order of the elements.
                           (seq-difference ido-cur-list ido-matches)
                         ido-matches)
          ido-matches ido-cur-list
	  ido-text-init ""
	  ido-rescan nil
	  ido-exit 'keep)
    (exit-minibuffer)))