Add doom-unreal-buffer-p predicate function

This commit is contained in:
Henrik Lissner 2018-06-30 01:53:40 +02:00
parent 2ffad42466
commit 70230b0892
No known key found for this signature in database
GPG Key ID: 5F6C0EA160557395

View File

@ -116,6 +116,13 @@ If BUFFER-OR-NAME is omitted or nil, the current buffer is tested."
(run-hook-with-args-until-success 'doom-real-buffer-functions buf)
(not (run-hook-with-args-until-success 'doom-unreal-buffer-functions buf))))))
;;;###autoload
(defun doom-unreal-buffer-p (buffer-or-name)
"Return t if BUFFER-OR-NAME is an 'unreal' buffer.
See `doom-real-buffer-p' for details on what that means."
(not (doom-real-buffer-p buffer-or-name)))
;;;###autoload
(defun doom-buffers-in-mode (modes &optional buffer-list derived-p)
"Return a list of buffers whose `major-mode' is `eq' to MODE(S).