plk / biblatex-apa

APA style for BibLaTeX
91 stars 48 forks source link

Missing Delimiters if Organization Field Contains Multiple Entries for @misc #218

Open lukeflo opened 1 year ago

lukeflo commented 1 year ago

As mentioned on TeX.SE, the delimiters are missing if an @misc contains multiple entries in the organization field. This may be due to line 548 in apa.bbx where the list format for misc is redefined with the following line: \DeclareListFormat[misc]{organization}{\mkbibemph{#1}}.

Thus, the usual listcount test is overwritten respectively deleted. You shall insert something like:

\DeclareListFormat[misc]{organization}{%
\mkbibemph{#1%
\ifthenelse{\value{listcount}<\value{liststop}}
{\multilistdelimiter}
{}}}

Or even some more sophisticated code which decides, if a multilistdelimiter or a finallistdelimiter should be inserted.

plk commented 1 year ago

Should be fixed in the next release.

lukeflo commented 1 year ago

Should be fixed in the next release.

Just looked at your commit. In line 555, you use DeclareDelimFormat with the entryfield organization as context argument. AFAIK the optional context argument for this command can't be an entryfield, but has to be something like bib, biblist or a cite-command (Manual p. 129 ff.).

But since you're also one of the biblatex authors, I may be wrong. If thats the case, just forget my comment here... ;)

plk commented 1 year ago

The context is basically arbitrary and is determined by \printdelim but you were right to note that that context wasn't being established anyway ... should be fixed now.