LaTeKiSS 1.2

- Update template to support the `--citeproc` flag
This commit is contained in:
Raffaele Mignone 2021-05-28 13:30:02 +02:00
parent adbda2c2f0
commit 6ec27a84bb
Signed by: norangebit
GPG Key ID: F5255658CB220573
2 changed files with 26 additions and 7 deletions

View File

@ -54,7 +54,7 @@ I link e i riferimenti sono in nero di default, e possibile abilitare il colore
#### Bibliografia
È possibile gestire la bibliografia attraverso il filtro [pandoc-citeproc][].
È possibile gestire la bibliografia attraverso il flag `--citeproc`.
#### Compilazione degli esempi
Di seguito è riportato il comando utilizzato per compilare gli esempi forniti nella cartella samples.
@ -179,5 +179,3 @@ pandoc --template latekiss <input-file> -o <output-file> --top-level-division ch
[pandoc-crossref]: https://lierdakil.github.io/pandoc-crossref/
[pandoc-citeproc]: https://github.com/jgm/pandoc-citeproc

View File

@ -246,6 +246,7 @@ $if(dir)$
\newenvironment{LTR}{\beginL}{\endL}
\fi
$endif$
$if(natbib)$
\usepackage[$natbiboptions$]{natbib}
\bibliographystyle{$if(biblio-style)$$biblio-style$$else$plainnat$endif$}
@ -256,13 +257,33 @@ $for(bibliography)$
\addbibresource{$bibliography$}
$endfor$
$endif$
$if(nocite-ids)$
\nocite{$for(nocite-ids)$$it$$sep$, $endfor$}
$endif$
$if(csl-refs)$
\newlength{\cslhangindent}
\setlength{\cslhangindent}{1.5em}
\newenvironment{cslreferences}%
{$if(csl-hanging-indent)$\setlength{\parindent}{0pt}%
\everypar{\setlength{\hangindent}{\cslhangindent}}\ignorespaces$endif$}%
{\par}
\newlength{\csllabelwidth}
\setlength{\csllabelwidth}{3em}
\newenvironment{CSLReferences}[2] % #1 hanging-ident, #2 entry spacing
{% don't indent paragraphs
\setlength{\parindent}{0pt}
% turn on hanging indent if param 1 is 1
\ifodd #1 \everypar{\setlength{\hangindent}{\cslhangindent}}\ignorespaces\fi
% set entry spacing
\ifnum #2 > 0
\setlength{\parskip}{#2\baselineskip}
\fi
}%
{}
\usepackage{calc}
\newcommand{\CSLBlock}[1]{#1\hfill\break}
\newcommand{\CSLLeftMargin}[1]{\parbox[t]{\csllabelwidth}{#1}}
\newcommand{\CSLRightInline}[1]{\parbox[t]{\linewidth - \csllabelwidth}{#1}\break}
\newcommand{\CSLIndent}[1]{\hspace{\cslhangindent}#1}
$endif$
$if(csquotes)$
\usepackage{csquotes}
$endif$
\PassOptionsToPackage{