bug#81467: [PATCH] Make bookmark-jump work with other-window/frame/tab-prefix
Stefan Monnier via "Bug reports for GNU Emacs, the Swiss army knife of text editors" <[email protected]> Fri, 31 Jul 2026 18:08:57 -0400
| Newsgroups | gmane.emacs.bugs |
|---|---|
| Message-ID | <[email protected]> |
> This is a touch messy ATM, but it gets the point across for the > bookmark-inhibit handler property. > > diff --git a/lisp/bookmark.el b/lisp/bookmark.el > index 77136308573..0024ecef1b6 100644 > --- a/lisp/bookmark.el > +++ b/lisp/bookmark.el > @@ -1265,12 +1265,23 @@ bookmark--jump-via > After calling DISPLAY-FUNCTION, set window point to the point specified > by BOOKMARK-NAME-OR-RECORD, if necessary, run `bookmark-after-jump-hook', > and then show any annotations for this bookmark." > - (let (buf point) > - (save-window-excursion > - (bookmark-handle-bookmark bookmark-name-or-record) > - (setq buf (current-buffer) > - point (point))) > - (funcall display-function buf) > + (let (buf > + point > + (inhibit-display-function > + (memq 'display-function > + (get (or (bookmark-get-handler bookmark-name-or-record) > + #'bookmark-default-handler) > + 'bookmark-inhibit)))) > + (if inhibit-display-function > + (progn > + (bookmark-handle-bookmark bookmark-name-or-record) > + (setq buf (current-buffer) > + point (point))) > + (save-window-excursion > + (bookmark-handle-bookmark bookmark-name-or-record) > + (setq buf (current-buffer) > + point (point))) > + (funcall display-function buf)) > (when-let* ((win (get-buffer-window buf 0))) > (set-window-point win point)) > (when bookmark-fringe-mark I don't really understand the intention behind it: why/when would a bookmark set `inhibit-display-function`? === Stefan