aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lisp/ChangeLog6
-rw-r--r--lisp/textmodes/bibtex.el5
2 files changed, 9 insertions, 2 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 4b6d1517d6..7639ed724b 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,9 @@
+2009-04-06 Roland Winkler <[email protected]>
+
+ * textmodes/bibtex.el (bibtex-format-entry)
+ (bibtex-search-crossref): Allow OPT prefix for name of crossref
+ field.
+
2009-04-06 Sam Steingold <[email protected]>
* simple.el (completion-list-mode-map): Bind "q" to quit-window,
diff --git a/lisp/textmodes/bibtex.el b/lisp/textmodes/bibtex.el
index edc4b6562b..a45a187354 100644
--- a/lisp/textmodes/bibtex.el
+++ b/lisp/textmodes/bibtex.el
@@ -1932,7 +1932,8 @@ Formats current entry according to variable `bibtex-entry-format'."
;; Do we have a crossref key?
(goto-char (point-min))
- (if (setq bounds (bibtex-search-forward-field "crossref"))
+ (if (setq bounds (bibtex-search-forward-field
+ "\\(OPT\\)?crossref"))
(let ((text (bibtex-text-in-field-bounds bounds t)))
(unless (equal "" text)
(setq crossref-key text))))
@@ -3521,7 +3522,7 @@ for a crossref key, t otherwise."
(end (cdr (bibtex-valid-entry t)))
(_ (unless end (error "Not inside valid entry")))
(beg (match-end 0)) ; set by `bibtex-valid-entry'
- (bounds (bibtex-search-forward-field "crossref" end))
+ (bounds (bibtex-search-forward-field "\\(OPT\\)?crossref" end))
case-fold-search best temp crossref-key)
(if bounds
(setq crossref-key (bibtex-text-in-field-bounds bounds t)