lang/org: remove unnecessary toc-org advice

It was initially written to avoid the cursor hopping about the buffer
when regenerating the table of contents. This isn't really an issue
anymore. Although, I would like to prevent emacs from adding adding an
undo step when it is regenerated...
This commit is contained in:
Henrik Lissner 2019-10-20 12:51:33 -04:00
parent 29f6db6ead
commit 7e3849be67
No known key found for this signature in database
GPG Key ID: 5F6C0EA160557395

View File

@ -878,12 +878,7 @@ compelling reason, so..."
;;; Packages
(after! toc-org
(setq toc-org-hrefify-default "gh")
(defadvice! +org--unfold-toc-a (&rest _)
:before #'toc-org-insert-toc
(save-excursion
(when (re-search-forward toc-org-toc-org-regexp (point-max) t)
(+org/open-fold)))))
(setq toc-org-hrefify-default "gh"))
(use-package! org-pdfview
:when (featurep! :tools pdf)