forked from mirrors/org-mode
org-lint: Allow jumping outside narrowing when jumping to source
* lisp/org-lint.el (org-lint--jump-to-source): When buffer is narrowed and the location to jump is outside the narrowing, widen.
This commit is contained in:
parent
2cf245810b
commit
b2e34474f5
|
@ -274,6 +274,7 @@ CHECKERS is the list of checkers used."
|
||||||
(interactive)
|
(interactive)
|
||||||
(let ((mk (org-lint--current-marker)))
|
(let ((mk (org-lint--current-marker)))
|
||||||
(switch-to-buffer-other-window org-lint--source-buffer)
|
(switch-to-buffer-other-window org-lint--source-buffer)
|
||||||
|
(unless (<= (point-min) mk (point-max)) (widen))
|
||||||
(goto-char mk)
|
(goto-char mk)
|
||||||
(org-fold-show-set-visibility 'local)
|
(org-fold-show-set-visibility 'local)
|
||||||
(recenter)))
|
(recenter)))
|
||||||
|
|
Loading…
Reference in New Issue