* lisp/emacs-lisp/checkdoc.el (checkdoc-show-diagnostics): Don't make bogus
assumptions about window ordering.
This commit is contained in:
parent
81d89d88ae
commit
ad6c1be923
3 changed files with 15 additions and 8 deletions
|
@ -2619,14 +2619,15 @@ function called to create the messages."
|
|||
(defun checkdoc-show-diagnostics ()
|
||||
"Display the checkdoc diagnostic buffer in a temporary window."
|
||||
(if checkdoc-pending-errors
|
||||
(let ((b (get-buffer checkdoc-diagnostic-buffer)))
|
||||
(if b (progn (pop-to-buffer b)
|
||||
(goto-char (point-max))
|
||||
(re-search-backward "\C-l" nil t)
|
||||
(beginning-of-line)
|
||||
(forward-line 1)
|
||||
(recenter 0)))
|
||||
(other-window -1)
|
||||
(let* ((b (get-buffer checkdoc-diagnostic-buffer))
|
||||
(win (if b (display-buffer b))))
|
||||
(when win
|
||||
(with-selected-window win
|
||||
(goto-char (point-max))
|
||||
(re-search-backward "\C-l" nil t)
|
||||
(beginning-of-line)
|
||||
(forward-line 1)
|
||||
(recenter 0)))
|
||||
(setq checkdoc-pending-errors nil)
|
||||
nil)))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue