emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Basic citations: should default citation style have a name and style cod


From: William Denton
Subject: Basic citations: should default citation style have a name and style code?
Date: Thu, 11 Jan 2024 05:25:28 +0000

This is a small point, but I think I've found a situation where the lack of a 
name for a default means there are situations where it can't be used.  

Let's say we have Basic.bib with this:

  @book{friends,
    title = {{{LaTeX}} and Friends},
    author = {van Dongen, M.R.C.},
    date = {2012},
    location = {Berlin},
    publisher = {Springer},
    doi = {10.1007/978-3-642-23816-1},
    isbn = {9783642238161}
  }

Also we have this Org file.  Note that it's using the basic citation processor 
and the author-year bibliography style.  There's no bibliography printed, but 
that doesn't matter for this example.  The author-year bibliography style is 
the default: if it was left out of the cite_export line it would still be used, 
but it can be specified by name.

Because no citation style is set for the document, the default (which has no 
name) will be used.  The first citation object will use the default and the 
second will be text with caps (/t/c means the style is set with t for text, 
variant with c for caps):

# ----------

#+bibliography: Basic.bib
#+cite_export: basic author-year

"Most scholarly works have citations and a bibliography or reference section," 
wrote a computer scientist [cite:@friends].

[cite/t/c:@friends] wrote, "Most scholarly works have citations and a 
bibliography or reference section."

# ----------

This exports (C-c C-e t A) to:

# ----------

"Most scholarly works have citations and a bibliography or reference
section," wrote a computer scientist (van Dongen, M.R.C., 2012).

Van Dongen, M.R.C. (2012) wrote, "Most scholarly works have citations
and a bibliography or reference section."

# ----------

But let's say we set the citation style for the document to "text".  Now there 
is no way to use the unnamed "default" citation style!  Note the change in the 
second citation object here, because now text is the default.

# ----------

#+bibliography: Basic.bib
#+cite_export: basic author-year text

"Most scholarly works have citations and a bibliography or reference section," 
wrote a computer scientist [cite:@friends].

[cite//c:@friends] wrote, "Most scholarly works have citations and a 
bibliography or reference section."

# ----------

This exports to:

# ----------

"Most scholarly works have citations and a bibliography or reference
section," wrote a computer scientist van Dongen, M.R.C. (2012).

Van Dongen, M.R.C. (2012) wrote, "Most scholarly works have citations
and a bibliography or reference section."

# ----------

As far as I can tell, there's nothing that can be done to the first citation 
object to make it use the "default" style.  The document-level setting makes a 
new default, and because the original "default" has no name or style code, 
there's no way to get at it.

The basic citation processor is a proof of concept and shouldn't be used for 
real work, so this is probably never going to result in a real problem.  
Nevertheless, it seems like a bug.  There is a combination that should be 
possible but isn't.  Sadly my Lisp isn't good enough for me to offer a working 
solution, but if the default citation style had, for example, the name 
"default" and one-letter code "d" then I think the problem would go away.

With thanks to everyone who did all the great citation work originally,

Bill

--
William Denton
https://www.miskatonic.org/
Librarian, artist and licensed private investigator.
Toronto, Canada



reply via email to

[Prev in Thread] Current Thread [Next in Thread]