Variable: bibtex-entry-format

bibtex-entry-format is a customizable variable defined in bibtex.el.gz.

Value

(opts-or-alts required-fields numerical-fields)

Documentation

Type of formatting performed by bibtex-clean-entry.

It may be t, nil, or a list of symbols out of the following:
opts-or-alts Delete empty optional and alternative fields and
                      remove OPT and ALT prefixes from used fields.
required-fields Signal an error if a required field is missing.
numerical-fields Delete delimiters around numeral fields.
page-dashes Change double dashes in page field to single dash
                      (for scribe compatibility).
whitespace Delete whitespace at the beginning and end of fields.
inherit-booktitle If entry contains a crossref field and the booktitle
                      field is empty, set the booktitle field to the content
                      of the title field of the cross-referenced entry.
realign Realign entries, so that field texts and perhaps equal
                      signs (depending on the value of
                      bibtex-align-at-equal-sign) begin in the same column.
                      Also fill fields.
last-comma Add or delete comma on end of last field in entry,
                      according to value of bibtex-comma-after-last-field.
delimiters Change delimiters according to variables
                      bibtex-field-delimiters and bibtex-entry-delimiters.
unify-case Change case of entry and field names according to
                      bibtex-unify-case-function.
braces Enclose parts of field entries by braces according to
                      bibtex-field-braces-alist.
strings Replace parts of field entries by string constants
                      according to bibtex-field-strings-alist.
sort-fields Sort fields to match the field order in
                    bibtex-BibTeX-entry-alist.

The value t means do all of the above formatting actions. The value nil means do no formatting at all.

Probably introduced at or before Emacs version 20.1.

Source Code

;; Defined in /usr/src/emacs/lisp/textmodes/bibtex.el.gz
(defcustom bibtex-entry-format
  '(opts-or-alts required-fields numerical-fields)
  "Type of formatting performed by `bibtex-clean-entry'.
It may be t, nil, or a list of symbols out of the following:
opts-or-alts        Delete empty optional and alternative fields and
                      remove OPT and ALT prefixes from used fields.
required-fields     Signal an error if a required field is missing.
numerical-fields    Delete delimiters around numeral fields.
page-dashes         Change double dashes in page field to single dash
                      (for scribe compatibility).
whitespace          Delete whitespace at the beginning and end of fields.
inherit-booktitle   If entry contains a crossref field and the booktitle
                      field is empty, set the booktitle field to the content
                      of the title field of the cross-referenced entry.
realign             Realign entries, so that field texts and perhaps equal
                      signs (depending on the value of
                      `bibtex-align-at-equal-sign') begin in the same column.
                      Also fill fields.
last-comma          Add or delete comma on end of last field in entry,
                      according to value of `bibtex-comma-after-last-field'.
delimiters          Change delimiters according to variables
                      `bibtex-field-delimiters' and `bibtex-entry-delimiters'.
unify-case          Change case of entry and field names according to
                      `bibtex-unify-case-function'.
braces              Enclose parts of field entries by braces according to
                      `bibtex-field-braces-alist'.
strings             Replace parts of field entries by string constants
                      according to `bibtex-field-strings-alist'.
sort-fields         Sort fields to match the field order in
                    `bibtex-BibTeX-entry-alist'.

The value t means do all of the above formatting actions.
The value nil means do no formatting at all."
  :group 'bibtex
  :type '(choice (const :tag "None" nil)
                 (const :tag "All" t)
                 (set :menu-tag "Some"
                      (const opts-or-alts)
                      (const required-fields)
                      (const numerical-fields)
                      (const page-dashes)
                      (const whitespace)
                      (const inherit-booktitle)
                      (const realign)
                      (const last-comma)
                      (const delimiters)
                      (const unify-case)
                      (const braces)
                      (const strings)
                      (const sort-fields)))
  :safe (lambda (x)
          (or (eq x t)
              (let ((ok t))
                (while (consp x)
                  (unless (memq (pop x)
                                '( opts-or-alts required-fields numerical-fields
                                   page-dashes whitespace inherit-booktitle
                                   realign last-comma delimiters unify-case
                                   braces strings sort-fields ))
                    (setq ok nil)))
                (unless x ok)))))