Commit 866a7257 authored by Carsten Dominik's avatar Carsten Dominik
Browse files

(bookmark-after-jump-hook): New hook.

(bookmark-jump): Run `bookmark-after-jump-hook'.
parent 6cd70a8c
......@@ -1037,6 +1037,10 @@ For example, if this is a Info buffer, return the Info file's name."
(lambda (x y) (string-lessp (car x) (car y))))))))
(defvar bookmark-after-jump-hook nil
"Hook run after `bookmark-jump' jumps to a bookmark.
Useful for example to unhide text in `outline-mode'.")
(defun bookmark-jump (bookmark)
"Jump to bookmark BOOKMARK (a point in some file).
......@@ -1059,6 +1063,7 @@ of the old one in the permanent bookmark record."
(and cell
(switch-to-buffer (car cell))
(goto-char (cdr cell))
(progn (run-hooks 'bookmark-jump-hook) t)
(if bookmark-automatically-show-annotations
;; if there is an annotation for this bookmark,
;; show it in a buffer.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment