public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
* MMD to PDF with chicago/turabian styled bibliography
@ 2020-09-07  4:28 Matt Gass
       [not found] ` <571d8037-a829-4216-aac8-6fab02b386c9n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 5+ messages in thread
From: Matt Gass @ 2020-09-07  4:28 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 1255 bytes --]

I'm having difficulty using pandoc with the latex package 
turabian-formatting <https://www.ctan.org/pkg/turabian-formatting> thesis, 
but some conflict between the pandoc latex template, `pandoc-citeproc`, 
and/or the latex package is clobbering the bibliography:

   1. If I use citeproc, the bibliography is inserted at the end of the 
   main body where the paragraph formatting is not correct for a bibliography.
   2. If I use biblatex and `\printbibliography` command rather than 
   citeproc, the bibliography never appears.
   3. I've also tried to merge the default pandoc latex template with the 
   turabian-formatting template, but citeproc seems determined to place the 
   bibliography at the end of `\mainmatter`.

What is the recommended workflow for creating correctly formatted 
bibliographies in PDF documents using pandoc?

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/571d8037-a829-4216-aac8-6fab02b386c9n%40googlegroups.com.

[-- Attachment #1.2: Type: text/html, Size: 1571 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: MMD to PDF with chicago/turabian styled bibliography
       [not found] ` <571d8037-a829-4216-aac8-6fab02b386c9n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2020-09-07 12:48   ` Denis Maier
       [not found]     ` <e88ddd38-589f-a806-45cd-b0231e00d9bb-cl+VPiYnx/1AfugRpC6u6w@public.gmane.org>
  0 siblings, 1 reply; 5+ messages in thread
From: Denis Maier @ 2020-09-07 12:48 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

[-- Attachment #1: Type: text/plain, Size: 2686 bytes --]

Hi,

Am 07.09.2020 um 06:28 schrieb Matt Gass:
> I'm having difficulty using pandoc with the latex package 
> turabian-formatting 
> <https://www.ctan.org/pkg/turabian-formatting> thesis, but some 
> conflict between the pandoc latex template, `pandoc-citeproc`, and/or 
> the latex package is clobbering the bibliography:

Giving advice is difficult without knowing more details... E.g. how are 
you loading the turabian-formatting package?

> If I use citeproc, the bibliography is inserted at the end of the main 
> body where the paragraph formatting is not correct for a bibliography.
Yeah, that's the way the bibliography is inserted at the moment. You can 
adjust the formatting if you redefine the cslreferences environment. The 
default is:

```\newlength{\cslhangindent}
\setlength{\cslhangindent}{1.5em}
\newenvironment{cslreferences}%
   {$if(csl-hanging-indent)$\setlength{\parindent}{0pt}%
\everypar{\setlength{\hangindent}{\cslhangindent}}\ignorespaces$endif$}%
   {\par}
```

So, maybe that may be an easy solution if paragraph formatting is the 
only problem.

I don't know this particular package. But maybe you could just add a 
`\backmatter` commmand somewhere at the end of you paper?


> If I use biblatex and `\printbibliography` command rather than 
> citeproc, the bibliography never appears.

You are using the the `--biblatex` option? If so, the documentation says 
this:

 > Use biblatex for citations in LaTeX output. This option is not for 
use with the pandoc-citeproc filter or with PDF output. It is intended 
for use in producing a LaTeX file that can be processed with bibtex or 
biber.

So, you can't go directly to PDF, but you'll need to produce a tex-file 
first. Then you can do pdflatex, biber, pdflatex as usual.


> I've also tried to merge the default pandoc latex template with the 
> turabian-formatting template, but citeproc seems determined to place 
> the bibliography at the end of `\mainmatter`.

Yes, that's how it is currently. You can use this syntax to move your 
bibliography to some other place:

```
::: {#refs}
:::
```
But I think it will always end up in the body.

@JohnMacFarlane: Will your new-pandoc-citeproc library change that?

Best,
Denis

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/e88ddd38-589f-a806-45cd-b0231e00d9bb%40mailbox.org.

[-- Attachment #2: Type: text/html, Size: 4268 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: MMD to PDF with chicago/turabian styled bibliography
       [not found]     ` <e88ddd38-589f-a806-45cd-b0231e00d9bb-cl+VPiYnx/1AfugRpC6u6w@public.gmane.org>
@ 2020-09-08  2:00       ` Matt Gass
       [not found]         ` <b37916e0-f90f-4c8e-abd9-2fc51d62b992n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 5+ messages in thread
From: Matt Gass @ 2020-09-08  2:00 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 3720 bytes --]

Thanks, Denis for your reply.

<how are you loading the turabian-formatting package?

I tried setting the documentclass with the `--variable` option like so:

```pandoc --variable documentclass="turabian-researchpaper" 
--pdf-engine=xelatex --bibliography "Bibliography.bib" --csl 
"chicago-note-bibliography-with-ibid.csl" --filter pandoc-citeproc 
Big_Idea.md -f markdown_mmd+citations -o out.pdf
```
In order to customize the bibliography formating, I started customizing the 
default latex template.

I modified the cslreferences environment as you suggested:

```\newlength{\cslhangindent}
\setlength{\cslhangindent}{1.5em}
\newenvironment{cslreferences}%
  \singlespacing
  {\setlength{\parindent}{0pt}%
  \setlength{\parskip}{1em}%
  \everypar{\setlength{\hangindent}{\cslhangindent}}\ignorespaces}%
  {\par}
```
But this makes the space between entries single not double. Is \parskip not 
the command to use for this?


On Monday, September 7, 2020 at 8:48:14 AM UTC-4 Denis Maier wrote:

> Hi,
>
>
> Am 07.09.2020 um 06:28 schrieb Matt Gass:
>
> I'm having difficulty using pandoc with the latex package 
> turabian-formatting <https://www.ctan.org/pkg/turabian-formatting> thesis, 
> but some conflict between the pandoc latex template, `pandoc-citeproc`, 
> and/or the latex package is clobbering the bibliography:
>
>
> Giving advice is difficult without knowing more details... E.g. how are 
> you loading the turabian-formatting package?
>
>
> If I use citeproc, the bibliography is inserted at the end of the main 
> body where the paragraph formatting is not correct for a bibliography.
>
> Yeah, that's the way the bibliography is inserted at the moment. You can 
> adjust the formatting if you redefine the cslreferences environment. The 
> default is:
>
> ```\newlength{\cslhangindent}
> \setlength{\cslhangindent}{1.5em}
> \newenvironment{cslreferences}%
>   {$if(csl-hanging-indent)$\setlength{\parindent}{0pt}%
>   \everypar{\setlength{\hangindent}{\cslhangindent}}\ignorespaces$endif$}%
>   {\par}
> ```
>
> So, maybe that may be an easy solution if paragraph formatting is the only 
> problem.
>
> I don't know this particular package. But maybe you could just add a 
> `\backmatter` commmand somewhere at the end of you paper?
>
>
>
> If I use biblatex and `\printbibliography` command rather than citeproc, 
> the bibliography never appears.
>
>
> You are using the the `--biblatex` option? If so, the documentation says 
> this:
>
> > Use biblatex for citations in LaTeX output. This option is not for use 
> with the pandoc-citeproc filter or with PDF output. It is intended for use 
> in producing a LaTeX file that can be processed with bibtex or biber.
>
> So, you can't go directly to PDF, but you'll need to produce a tex-file 
> first. Then you can do pdflatex, biber, pdflatex as usual.
>
>
>
> I've also tried to merge the default pandoc latex template with the 
> turabian-formatting template, but citeproc seems determined to place the 
> bibliography at the end of `\mainmatter`.
>
>
> Yes, that's how it is currently. You can use this syntax to move your 
> bibliography to some other place:
>
> ```
> ::: {#refs}
> :::
> ```
> But I think it will always end up in the body. 
>
> @JohnMacFarlane: Will your new-pandoc-citeproc library change that? 
>
> Best,
> Denis
>

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/b37916e0-f90f-4c8e-abd9-2fc51d62b992n%40googlegroups.com.

[-- Attachment #1.2: Type: text/html, Size: 5497 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: MMD to PDF with chicago/turabian styled bibliography
       [not found]         ` <b37916e0-f90f-4c8e-abd9-2fc51d62b992n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2020-09-08  9:26           ` Denis Maier
       [not found]             ` <0fbbe2cd-3637-0d17-e2dc-9f0215be900a-cl+VPiYnx/1AfugRpC6u6w@public.gmane.org>
  0 siblings, 1 reply; 5+ messages in thread
From: Denis Maier @ 2020-09-08  9:26 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

Hi Matt,
Am 08.09.2020 um 04:00 schrieb Matt Gass:

> I modified the cslreferences environment as you suggested:
>
> ```\newlength{\cslhangindent}
> \setlength{\cslhangindent}{1.5em}
> \newenvironment{cslreferences}%
>   \singlespacing
>   {\setlength{\parindent}{0pt}%
>   \setlength{\parskip}{1em}%
> \everypar{\setlength{\hangindent}{\cslhangindent}}\ignorespaces}%
>   {\par}
> ```
> But this makes the space between entries single not double. Is 
> \parskip not the command to use for this?
`\parskip` modifies the spacing between paragraph.
Maybe you should use `\doublespacing` instead of `\singlespacing`.

Best,
Denis

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/0fbbe2cd-3637-0d17-e2dc-9f0215be900a%40mailbox.org.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: MMD to PDF with chicago/turabian styled bibliography
       [not found]             ` <0fbbe2cd-3637-0d17-e2dc-9f0215be900a-cl+VPiYnx/1AfugRpC6u6w@public.gmane.org>
@ 2020-09-08 13:45               ` Matt Gass
  0 siblings, 0 replies; 5+ messages in thread
From: Matt Gass @ 2020-09-08 13:45 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

[-- Attachment #1: Type: text/plain, Size: 2270 bytes --]

The Chicago style spec calls for single spacing within each bib entry and double spacing between entries (i.e., a blank line between each item). \doublespacing  produces blank lines within the bib entry. \singlespacing removes the blank line between entries. Neither is correct.

I do appreciate the help. And I think pandoc is brilliant. Unfortunately, in this case it isn’t doing what I hoped it would—rescue me from diving into Latex syntax. I think I’ll revert to bypassing Latex with MS Word.

Thanks again.

Matt
On Sep 8, 2020, 5:26 AM -0400, Denis Maier <denis.maier.lists-cl+VPiYnx/1AfugRpC6u6w@public.gmane.org>, wrote:
> Hi Matt,
> Am 08.09.2020 um 04:00 schrieb Matt Gass:
>
> > I modified the cslreferences environment as you suggested:
> >
> > ```\newlength{\cslhangindent}
> > \setlength{\cslhangindent}{1.5em}
> > \newenvironment{cslreferences}%
> >   \singlespacing
> >   {\setlength{\parindent}{0pt}%
> >   \setlength{\parskip}{1em}%
> > \everypar{\setlength{\hangindent}{\cslhangindent}}\ignorespaces}%
> >   {\par}
> > ```
> > But this makes the space between entries single not double. Is
> > \parskip not the command to use for this?
> `\parskip` modifies the spacing between paragraph.
> Maybe you should use `\doublespacing` instead of `\singlespacing`.
>
> Best,
> Denis
>
> --
> You received this message because you are subscribed to a topic in the Google Groups "pandoc-discuss" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/topic/pandoc-discuss/fRT1PbynfrQ/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/0fbbe2cd-3637-0d17-e2dc-9f0215be900a%40mailbox.org.

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/50c30e29-1d47-4949-9915-f0b14624c66d%40Spark.

[-- Attachment #2: Type: text/html, Size: 3157 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-09-08 13:45 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-07  4:28 MMD to PDF with chicago/turabian styled bibliography Matt Gass
     [not found] ` <571d8037-a829-4216-aac8-6fab02b386c9n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2020-09-07 12:48   ` Denis Maier
     [not found]     ` <e88ddd38-589f-a806-45cd-b0231e00d9bb-cl+VPiYnx/1AfugRpC6u6w@public.gmane.org>
2020-09-08  2:00       ` Matt Gass
     [not found]         ` <b37916e0-f90f-4c8e-abd9-2fc51d62b992n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2020-09-08  9:26           ` Denis Maier
     [not found]             ` <0fbbe2cd-3637-0d17-e2dc-9f0215be900a-cl+VPiYnx/1AfugRpC6u6w@public.gmane.org>
2020-09-08 13:45               ` Matt Gass

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).