File: oc-basic.el.html

The basic citation processor provides "activate", "follow", "export" and
"insert" capabilities.

"activate" capability reuses default fontification, but provides additional
features on both correct and wrong keys according to the bibliography defined in the document.

When the mouse is over a known key, it displays the corresponding bibliography entry. Any wrong key, however, is highlighted with error face. Moreover, moving the mouse onto it displays a list of suggested correct keys, and pressing <mouse-1> on the faulty key will try to fix it according to those suggestions.

On a citation key, "follow" capability moves point to the corresponding entry in the current bibliography. Elsewhere on the citation, it asks the user to follow any of the keys cited there, with completion.

"export" capability supports the following citation styles:

  - author (a), including caps (c) variant,
  - noauthor (na) including bare (b) variant,
  - text (t), including bare (b), caps (c), and bare-caps (bc) variants,
  - note (ft, including bare (b), caps (c), and bare-caps (bc) variants,
  - nocite (n)
  - numeric (nb),
  - default, including bare (b), caps (c), and bare-caps (bc) variants.

It also supports the following styles for bibliography:
  - plain
  - numeric
  - author-year (default)

"insert" capability inserts or edits (with completion) citation style or
citation reference keys. In an appropriate place, it offers to insert a new citation. With a prefix argument, it removes the one at point.

It supports bibliography files in BibTeX (".bibtex"), biblatex (".bib") and JSON (".json") format.

Disclaimer: this citation processor is meant to be a proof of concept, and possibly a fall-back mechanism when nothing else is available. It is too limited for any serious use case.

Defined variables (9)

org-cite-basic--bibliography-cacheCache for parsed bibliography files.
org-cite-basic--completion-cacheCache for key completion table.
org-cite-basic--file-id-cacheHash table linking files to their hash.
org-cite-basic-author-column-endColumn where author field ends in completion table, as an integer.
org-cite-basic-author-year-separatorString used to separate cites in an author-year configuration.
org-cite-basic-column-separatorColumn separator in completion table, as a string.
org-cite-basic-max-key-distanceMaximum (Levenshtein) distance between a wrong key and its suggestions.
org-cite-basic-mouse-over-key-faceFace used when mouse is over a citation key.
org-cite-basic-sorting-fieldField used to sort bibliography items as a symbol, or nil.

Defined functions (26)

org-cite-basic--all-keys()
org-cite-basic--citation-numbers(CITATION INFO)
org-cite-basic--close-keys(KEY KEYS)
org-cite-basic--complete-key(&optional MULTIPLE)
org-cite-basic--complete-style(_)
org-cite-basic--field-less-p(FIELD INFO)
org-cite-basic--format-author-year(CITATION FORMAT-CITE FORMAT-REF INFO)
org-cite-basic--get-author(ENTRY-OR-KEY &optional INFO RAW)
org-cite-basic--get-entry(KEY &optional INFO)
org-cite-basic--get-field(FIELD ENTRY-OR-KEY &optional INFO RAW)
org-cite-basic--get-year(ENTRY-OR-KEY INFO &optional NO-SUFFIX)
org-cite-basic--key-completion-table()
org-cite-basic--key-number(KEY INFO)
org-cite-basic--number-to-suffix(N)
org-cite-basic--parse-bibliography(&optional INFO)
org-cite-basic--parse-bibtex(DIALECT)
org-cite-basic--parse-json()
org-cite-basic--print-bibtex-string(ELEMENT &optional INFO)
org-cite-basic--print-entry(ENTRY STYLE &optional INFO)
org-cite-basic--set-keymap(BEG END SUGGESTIONS)
org-cite-basic--shorten-names(NAMES)
org-cite-basic--sort-keys(KEYS INFO)
org-cite-basic-activate(CITATION)
org-cite-basic-export-bibliography(KEYS FILES STYLE PROPS BACKEND INFO)
org-cite-basic-export-citation(CITATION STYLE _ INFO)
org-cite-basic-goto(DATUM _)

Defined faces (0)