* bug#70459: Flymake small improvements
@ 2024-04-18 17:23 Juri Linkov
2024-04-22 6:54 ` Juri Linkov
0 siblings, 1 reply; 2+ messages in thread
From: Juri Linkov @ 2024-04-18 17:23 UTC (permalink / raw)
To: 70459
[-- Attachment #1: Type: text/plain, Size: 311 bytes --]
Tags: patch
1. clicking on flymake fringe indicator will show buffer diagnostics;
2. display diagnostics buffers at the bottom;
3. to do the above there is a need to swap the order
of generating the buffer contents and displaying the buffer,
i.e. the same as was done recently in info.el for bug#70213.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: flymake.patch --]
[-- Type: text/x-diff, Size: 1739 bytes --]
diff --git a/lisp/progmodes/flymake.el b/lisp/progmodes/flymake.el
index 22a139d3045..f5bf68db574 100644
--- a/lisp/progmodes/flymake.el
+++ b/lisp/progmodes/flymake.el
@@ -1331,7 +1331,10 @@ flymake-start
nil))))))))
(defvar flymake-mode-map
- (let ((map (make-sparse-keymap))) map)
+ (let ((map (make-sparse-keymap)))
+ (define-key map `[,flymake-fringe-indicator-position mouse-1]
+ #'flymake-show-buffer-diagnostics)
+ map)
"Keymap for `flymake-mode'.")
;;;###autoload
@@ -1972,8 +1975,12 @@ flymake-show-buffer-diagnostics
(current-buffer)))))
(with-current-buffer target
(setq flymake--diagnostics-buffer-source source)
- (display-buffer (current-buffer))
- (revert-buffer))))
+ (revert-buffer)
+ (display-buffer (current-buffer)
+ `((display-buffer-reuse-window
+ display-buffer-below-selected)
+ (window-height . (lambda (window)
+ (fit-window-to-buffer window 10))))))))
\f
;;; Per-project diagnostic listing
@@ -2073,8 +2080,11 @@ flymake-show-project-diagnostics
(with-current-buffer buffer
(flymake-project-diagnostics-mode)
(setq-local flymake--project-diagnostic-list-project prj)
- (display-buffer (current-buffer))
- (revert-buffer))))
+ (revert-buffer)
+ (display-buffer (current-buffer)
+ `((display-buffer-reuse-window
+ display-buffer-at-bottom)
+ (window-height . fit-window-to-buffer))))))
(defun flymake--update-diagnostics-listings (buffer)
"Update diagnostics listings somehow relevant to BUFFER."
^ permalink raw reply related [flat|nested] 2+ messages in thread
* bug#70459: Flymake small improvements
2024-04-18 17:23 bug#70459: Flymake small improvements Juri Linkov
@ 2024-04-22 6:54 ` Juri Linkov
0 siblings, 0 replies; 2+ messages in thread
From: Juri Linkov @ 2024-04-22 6:54 UTC (permalink / raw)
To: 70459
close 70459 30.0.50
stop
> 1. clicking on flymake fringe indicator will show buffer diagnostics;
> 2. display diagnostics buffers at the bottom;
> 3. to do the above there is a need to swap the order
> of generating the buffer contents and displaying the buffer,
> i.e. the same as was done recently in info.el for bug#70213.
This is pushed to master and closed.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-04-22 6:54 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-18 17:23 bug#70459: Flymake small improvements Juri Linkov
2024-04-22 6:54 ` Juri Linkov
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).