emacs-orgmode
[Top][All Lists]
Advanced

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

Re: Question about citation processors [wip-cite branch]


From: Nicolas Goaziou
Subject: Re: Question about citation processors [wip-cite branch]
Date: Tue, 04 May 2021 18:22:55 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)

Hello,

Joost Kremers <joostkremers@fastmail.fm> writes:

> - A user should be able to insert citations into an Org document. IIUC nothing
>   in org-cite provides any functionality for this, right? Is there a default
>   list of styles a user would expect to be supported, or does this depend 
> solely
>   on the bibliography style one uses?

Org Cite does not provide anything in that area because there nothing to
provide. You can write your own function inserting citations without
plugging it anywhere in Org. For others capabilities (activate, follow,
export), you need Org to cooperate.

If you think my assumption is incorrect, please let me know what kind of
hook would be required.

> - =:active= just means "font-lock", right?

Yes, with the emphasis that more than faces could be provided (e.g.,
help-echo, specific keymap, …). I think that Org Ref only needs this
property (barring its export part).

> - Since I don't plan on writing an exporter, I assume that it is possible to
>   mix and match processors? Say, have one for the =:follow= property, another
>   for =:activate= and a third one for =:export-*=?

Exactly! A processor may only provide an :activate property.

> - What kind of data structure do the =:follow= and =:activate= functions take?
>   Should I just look at =oc-basic.el= or is this written down
>   somewhere?

Processors must be registered using `org-cite-register-processor'
function from "oc.el". See its docstring for details. All arguments are
detailed.

As an example, "oc-basic.el" is a citation processor. It calls the
function above at the end of the file and registers all three
capabilities (activate, follow and export).

At some point, we will need to write some documentation in the manual,
too...

> - Is there a function or buffer-local variable that gives me a list of all the
>   bibliography files of a buffer? Related to that: if a user has set
>   =org-cite-global-bibliography= and also provides a =#+bibliography= keyword,
>   are both sources used, or only the keyword?

"oc.el" provides a number of hopefully useful tools. Among them,
`org-cite-list-bibliography-files' function returns what you're asking
for. Global variable and keywords are cumulative.

HTH!

Regards,
-- 
Nicolas Goaziou



reply via email to

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