Bug description
As mentioned in #2417,
---
title: "Untitled"
format: latex
keep-md: true
---
```{r}
#| label: main-plot
#| out-width: 50%
plot(mtcars)
```
generates the following in LaTeX (as of version 1.2.335, RStudio 2022.12.0 on Windows 11):
\includegraphics[width=0.5\textwidth,height=\textheight]{test_files/figure-latex/main-plot-1.pdf}
In a 2-column document, the figure is not formated as expected: it is wider than its column.
In R Markdown, the same options generated
\includegraphics[width=0.5\textwidth]{test_files/figure-latex/main-plot-1.pdf}
which worked perfectly.
A temporary workaround is to divide the desired width by 2.
So I think height=\textheight should not be added if #| out-height: is not specified in the Quarto file: LaTeX does not need it and it does not allow correct format in 2-column documents.
Thanks!
Bug description
As mentioned in #2417,
generates the following in LaTeX (as of version 1.2.335, RStudio 2022.12.0 on Windows 11):
In a 2-column document, the figure is not formated as expected: it is wider than its column.
In R Markdown, the same options generated
which worked perfectly.
A temporary workaround is to divide the desired width by 2.
So I think
height=\textheightshould not be added if#| out-height:is not specified in the Quarto file: LaTeX does not need it and it does not allow correct format in 2-column documents.Thanks!