contrib/lisp: don't use `outline-regexp'.
Use `org-outline-regexp' or `org-outline-regexp-bol' instead. * org-toc.el (org-toc-before-first-heading-p, org-toc-show) (org-toc-get-headlines-status): Use `org-outline-regexp-bol'. * org-lparse.el (org-do-lparse): Use `org-outline-regexp-bol'. * org-export-generic.el (org-export-generic): Use `org-outline-regexp'.
This commit is contained in:
parent
c3748fcd80
commit
52fd747983
|
@ -846,7 +846,7 @@ underlined headlines. The default is 3."
|
||||||
(org-init-section-numbers)
|
(org-init-section-numbers)
|
||||||
(org-export-generic-check-section "top")
|
(org-export-generic-check-section "top")
|
||||||
(while (setq line (pop lines))
|
(while (setq line (pop lines))
|
||||||
(when (and link-buffer (string-match "^\\*+ " line))
|
(when (and link-buffer (string-match org-outline-regexp-bol line))
|
||||||
(org-export-generic-push-links (nreverse link-buffer))
|
(org-export-generic-push-links (nreverse link-buffer))
|
||||||
(setq link-buffer nil))
|
(setq link-buffer nil))
|
||||||
(setq wrap nil)
|
(setq wrap nil)
|
||||||
|
|
|
@ -791,7 +791,7 @@ version."
|
||||||
(while (setq line (pop lines) origline line)
|
(while (setq line (pop lines) origline line)
|
||||||
(catch 'nextline
|
(catch 'nextline
|
||||||
(when (and (org-lparse-current-environment-p 'quote)
|
(when (and (org-lparse-current-environment-p 'quote)
|
||||||
(string-match "^\\*+ " line))
|
(string-match org-outline-regexp-bol line))
|
||||||
(org-lparse-end-environment 'quote))
|
(org-lparse-end-environment 'quote))
|
||||||
|
|
||||||
(when (org-lparse-current-environment-p 'quote)
|
(when (org-lparse-current-environment-p 'quote)
|
||||||
|
|
|
@ -210,7 +210,7 @@ specified, then make `org-toc-recenter' use this value."
|
||||||
(defun org-toc-before-first-heading-p ()
|
(defun org-toc-before-first-heading-p ()
|
||||||
"Before first heading?"
|
"Before first heading?"
|
||||||
(save-excursion
|
(save-excursion
|
||||||
(null (re-search-backward "^\\*+ " nil t))))
|
(null (re-search-backward org-outline-regexp-bol nil t))))
|
||||||
|
|
||||||
;;;###autoload
|
;;;###autoload
|
||||||
(defun org-toc-show (&optional depth position)
|
(defun org-toc-show (&optional depth position)
|
||||||
|
@ -226,7 +226,7 @@ specified, then make `org-toc-recenter' use this value."
|
||||||
(let ((pos (or position
|
(let ((pos (or position
|
||||||
(save-excursion
|
(save-excursion
|
||||||
(if (org-toc-before-first-heading-p)
|
(if (org-toc-before-first-heading-p)
|
||||||
(progn (re-search-forward "^\\*+ " nil t)
|
(progn (re-search-forward org-outline-regexp-bol nil t)
|
||||||
(match-beginning 0))
|
(match-beginning 0))
|
||||||
(point))))))
|
(point))))))
|
||||||
(setq org-toc-cycle-global-status org-cycle-global-status)
|
(setq org-toc-cycle-global-status org-cycle-global-status)
|
||||||
|
@ -441,7 +441,7 @@ status."
|
||||||
(goto-char (point-min))
|
(goto-char (point-min))
|
||||||
(while (and (not (eobp))
|
(while (and (not (eobp))
|
||||||
(goto-char (next-overlay-change (point))))
|
(goto-char (next-overlay-change (point))))
|
||||||
(when (looking-at "^\\*+ ")
|
(when (looking-at org-outline-regexp-bol)
|
||||||
(add-to-list
|
(add-to-list
|
||||||
'output
|
'output
|
||||||
(cons (buffer-substring-no-properties
|
(cons (buffer-substring-no-properties
|
||||||
|
|
Loading…
Reference in New Issue