Been a long day, so take this FWIW ... On Thu, Nov 17, 2011 at 4:17 PM, andrea rossato <[email protected]> wrote: > Hi, > > there is an issue with a style (chicago-author-date shipped with pandoc, > which comes from the test-suite repository) and the way is uses > <substitute>. > > This is the issue, from the citeproc-hs perspective: according to the > specification "[s]ubstituted variables are suppressed in the rest of the > output to prevent duplication." This style uses the variable "editor" as > a substitute and then checks if it is set, or if it is set the variable > "author" or the variable "translator". If none of them is set then > "Anon." is printed. Author and translator are not set and editor has > been suppressed. Which, in citeproc-hs sense means unset. > > I think it is a style bug (I do not think chicago-author-date belongs to > the best coded styles), but it may also be my wrong interpretation of > what "suppressed" means. What do you think? > > This is the relevant style code: > <macro name="contributors"> > <names variable="author"> > <name and="text" delimiter=", " delimiter-precedes-last="always" > name-as-sort-order="first" sort-separator=", " /> > <label form="verb-short" prefix=", " suffix="." text-case="lowercase" /> > <substitute> > <text macro="editor" /> > <text macro="translator" /> > </substitute> > </names> > <text macro="anon"/> > <text macro="recipient" /> > </macro> > > with "anon" being: > > <macro name="anon"> > <choose> > <if match="none" variable="author editor translator"> > <text form="short" term="anonymous" text-case="capitalize-first" /> > </if> > </choose> > </macro>
WRT to the style, I think it should work, but that it would be better if the <text macro="anon"/> fragment got folded in at the end of the substitute element. I don't think citeproc-hs should be printing "anon" unless there is no author, editor, or translator. Bruce ------------------------------------------------------------------------------ All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d _______________________________________________ xbiblio-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/xbiblio-devel
