tools/flycheck: prevent flycheck popup buffer taking focus

When tooltip/childframe is off, long errors can spawn a popup window
that, by default, will steal input focus. No more!

Reported by @rgrinberg
This commit is contained in:
Henrik Lissner 2019-10-25 01:26:56 -04:00
parent 7f317e32ca
commit 923a0a58b6
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395

View file

@ -22,6 +22,11 @@ errors.")
;; Display errors a little quicker (default is 0.9s)
(setq flycheck-display-errors-delay 0.25)
;; Don't commandeer input focus if the error message pops up (happens when
;; tooltips and childframes are disabled).
(after! flycheck
(set-popup-rule! flycheck-error-message-buffer :select nil))
(add-hook! 'doom-escape-hook :append
(defun +flycheck-buffer-h ()
"Flycheck buffer on ESC in normal mode."