The default.beamer
pandoc default template for LaTex beamer has this line:
$if(theme)$
\usetheme{$theme$}
$endif$
Does the test for a specific theme work as well? Something like:
$if(theme)$
\usetheme{$theme$}
$if(Berlin)$
\setbeamertemplate{headline}
{}
$endif$
$endif$
In the Pandoc - Pandoc User Guide, I've found this:
$if(variable)$
X
$else$
Y
$endif$
This will include X in the template if variable has a non-null value; otherwise it will include Y. X and Y are placeholders for any valid template text, and may include interpolated variables or other conditionals. The $else$ section may be omitted.
And more info on looping over variables with multiple values, however I can't seem to find information on how to test for a specific variable value - not true
or false
, but Darmstadt
or Berlin
in the specific example of a LaTex Beamer Theme.
Can this work somehow?
You could simply use a LaTeX conditional like
\usepackage{ifthen}
$if(theme)$
\usetheme{$theme$}
\expandafter\ifstrequal\expandafter{$theme$}{Berlin}{%
\setbeamertemplate{headline}}{%
% if false
}}%
$endif$
Pandoc itself does not allow this out of the box.
There are two ways to solve this:
For me, second approach is preferred, because:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With