]> git.eshelyaron.com Git - emacs.git/commitdiff
(bibtex-entry-field-alist): Use defcustom.
authorRoland Winkler <Roland.Winkler@physik.uni-erlangen.de>
Mon, 16 Apr 2007 18:03:29 +0000 (18:03 +0000)
committerRoland Winkler <Roland.Winkler@physik.uni-erlangen.de>
Mon, 16 Apr 2007 18:03:29 +0000 (18:03 +0000)
lisp/ChangeLog
lisp/textmodes/bibtex.el

index 7412a5d27b491cc46408e3c93aed9e6ec3cd9138..825487a0881b51929d4ae81b44ce43a35168451f 100644 (file)
@@ -1,3 +1,7 @@
+2007-04-16  Roland Winkler  <Roland.Winkler@physik.uni-erlangen.de>
+
+       * textmodes/bibtex.el (bibtex-entry-field-alist): Use defcustom.
+
 2007-04-16  Dan Nicolaescu  <dann@ics.uci.edu>
 
        * progmodes/perl-mode.el (perl-indent-level): Mark as safe local var.
index 2c8406f86565ec7501ffd46143b47bf4ac69804c..0545ca8581282b0561d90765d3bbd7ca0bcb3b7f 100644 (file)
@@ -224,7 +224,7 @@ If parsing fails, try to set this variable to nil."
   :group 'bibtex
   :type 'boolean)
 
-(defvar bibtex-entry-field-alist
+(defcustom bibtex-entry-field-alist
   '(("Article"
      ((("author" "Author1 [and Author2 ...] [and others]")
        ("title" "Title of the article (BibTeX converts it to lowercase)")
@@ -452,7 +452,47 @@ appears in the echo area, INIT is either the initial content of the
 field or a function, which is called to determine the initial content
 of the field, and ALTERNATIVE-FLAG (either nil or t) marks if the
 field is an alternative.  ALTERNATIVE-FLAG may be t only in the
-REQUIRED or CROSSREF-REQUIRED lists.")
+REQUIRED or CROSSREF-REQUIRED lists."
+  :group 'bibtex
+  :type '(repeat (list (string :tag "Entry name")
+                       (list (repeat :tag "required"
+                                     (group (string :tag "Field")
+                                            (string :tag "Comment")
+                                            (option (choice :tag "Init" :value nil
+                                                            (const nil)
+                                                            (string :tag "string")
+                                                            (function :tag "function")))
+                                            (option (choice (const nil)
+                                                            (const :tag "Alternative" t)))))
+                             (repeat :tag "optional"
+                                     (group (string :tag "Field")
+                                            (string :tag "Comment")
+                                            (option (choice :tag "Init" :value nil
+                                                            (const nil)
+                                                            (string :tag "string")
+                                                            (function :tag "function")))
+                                            (option (choice (const nil)
+                                                            (const :tag "Alternative" t))))))
+                       (option
+                        (list :tag "Crossref"
+                              (repeat :tag "required"
+                                      (group (string :tag "Field")
+                                             (string :tag "Comment")
+                                             (option (choice :tag "Init" :value nil
+                                                             (const nil)
+                                                             (string :tag "string")
+                                                             (function :tag "function")))
+                                             (option (choice (const nil)
+                                                             (const :tag "Alternative" t)))))
+                              (repeat :tag "optional"
+                                      (group (string :tag "Field")
+                                             (string :tag "Comment")
+                                             (option (choice :tag "Init" :value nil
+                                                             (const nil)
+                                                             (string :tag "string")
+                                                             (function :tag "function")))
+                                             (option (choice (const nil)
+                                                             (const :tag "Alternative" t))))))))))
 (put 'bibtex-entry-field-alist 'risky-local-variable t)
 
 (defcustom bibtex-comment-start "@Comment"