The idea is to replicate the PDF output on rmarkdown
in quarto
, in this case, is creating a multiple-page orientation on a single document. In rmarkdown
I can do it easily by using this trick. However, I could not do that in quarto, it keeps sending the error message
compilation failed- error
Undefined control sequence.
l.201 \blandscape
Here is my code:
---
title: "Portrait and Landscape"
format:
pdf:
include-in-header:
- packages.tex
---
# Quarto
Quarto enables you to weave together content and executable code into a finished document. To learn more about Quarto see <https://quarto.org>.
\newpage
\blandscape
# Running Code
When you click the **Render** button a document will be generated that includes both content and the output of embedded code. You can embed code like this:
You can add options to executable code like this
The `echo: false` option disables the printing of code (only output is displayed).
\elandscape
Interestingly, I can create a multiple page orientation by modified the YAML and inserting raw latex to start and end the landscape page, but it will erase all the rmarkdown
formatting and turned it into normal text inside the landscape page:
---
title: "Portrait and Landscape"
format:
pdf:
include-in-header:
text: |
\usepackage{pdflscape}
---
\begin{landscape}
bla bla bla
\end{landscape}
Is there any workaround on this matter?
PS: my header.tex contains this stuff
\usepackage{pdflscape}
\newcommand{\blandscape}{\begin{landscape}}
\newcommand{\elandscape}{\end{landscape}}
packages.tex
? – Componypackaged.tex
contents in my question, thank you for pointing that out. – Vanpeltlscape
orpdflscape
which one do you need to use? – Componypdflscape
, but anything that work is OK. I've tried both inquarto
but had no luck. – Vanpelt