Make sure outline path display uses full path, even in a narrowed buffer

When a buffer was narrowed, the path was truncated.
This commit is contained in:
Carsten Dominik 2009-11-15 09:59:33 +01:00
parent 1497c94c11
commit 2129ea6494
2 changed files with 7 additions and 4 deletions

View File

@ -1,6 +1,7 @@
2009-11-15 Carsten Dominik <carsten.dominik@gmail.com>
* org.el (org-set-effort): Improve prompt.
(org-get-outline-path): Widen to get full path.
* org-latex.el (org-export-as-latex): Add the :drawers property.

View File

@ -9006,10 +9006,12 @@ avoiding backtracing."
(aset org-olpa level heading)))
(let (rtn)
(save-excursion
(while (org-up-heading-safe)
(when (looking-at org-complex-heading-regexp)
(push (org-match-string-no-properties 4) rtn)))
rtn))))
(save-restriction
(widen)
(while (org-up-heading-safe)
(when (looking-at org-complex-heading-regexp)
(push (org-match-string-no-properties 4) rtn)))
rtn)))))
(defun org-format-outline-path (path &optional width prefix)
"Format the outlie path PATH for display.