From a9ff96da65ee14da35520e194978040d6a2881be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20A=2E=20Gomes?= Date: Thu, 7 Oct 2021 21:25:58 +0300 Subject: [PATCH 20/76] Deprecate org-bibtex-treat-headline-as-title. --- lisp/ol-bibtex.el | 6 +++--- lisp/org-compat.el | 2 ++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/lisp/ol-bibtex.el b/lisp/ol-bibtex.el index 4406a68d4..dd3b15300 100644 --- a/lisp/ol-bibtex.el +++ b/lisp/ol-bibtex.el @@ -247,7 +247,7 @@ For example setting to `BIB_' would allow interoperability with fireforg." (const nil) (string))) -(defcustom org-bibtex-treat-headline-as-title t +(defcustom org-bibtex-treat-heading-as-title t "Treat heading text as title if title property is absent. If an entry is missing a title property, use the heading text as the property. If this value is t, `org-bibtex-check' will ignore @@ -458,7 +458,7 @@ With optional argument OPTIONAL, also prompt for optional fields." (keyword (lambda (name) (intern (concat ":" (downcase name))))) (name (lambda (keyword) (substring (symbol-name keyword) 1)))) (dolist (field (append - (if org-bibtex-treat-headline-as-title + (if org-bibtex-treat-heading-as-title (remove :title (funcall val :required (funcall val type org-bibtex-types))) (funcall val :required (funcall val type org-bibtex-types))) (when optional (funcall val :optional (funcall val type org-bibtex-types))))) @@ -633,7 +633,7 @@ If nonew is t, add data to the heading of the entry at point." nil nil (when nonew (org-bibtex-get org-bibtex-type-property-name)))) (type (if (keywordp type) type (intern (concat ":" type)))) - (org-bibtex-treat-headline-as-title (if nonew nil t))) + (org-bibtex-treat-heading-as-title (if nonew nil t))) (unless (assoc type org-bibtex-types) (error "Type:%s is not known" type)) (if nonew diff --git a/lisp/org-compat.el b/lisp/org-compat.el index 2ef5b6b0f..2e571cc17 100644 --- a/lisp/org-compat.el +++ b/lisp/org-compat.el @@ -348,6 +348,8 @@ Counting starts at 1." 'org-beamer-heading "9.5") (define-obsolete-variable-alias 'org-bibtex-headline-format-function 'org-bibtex-heading-format-function "9.5") +(define-obsolete-variable-alias 'org-bibtex-treat-headline-as-title + 'org-bibtex-treat-heading-as-title "9.5") (defun org-in-fixed-width-region-p () "Non-nil if point in a fixed-width region." -- 2.33.0