Feature request: more arguments to screenshot_pdf
ps0ares opened this issue · comments
Consider adding the following arguments to screenshot_pdf: print_background
, pagesize
and margins
. That way It would be possible to print html slideshows to pdf, for example.
Please also consider scale
, which could be mapped to the zoom
argument already handled by webshot()
. My tables print with scrollbars because I cannot scale them to match the PDF page size.
I believe this is also impact automatic screenshot feature for PDF in knitr when HTML content is detected (like a leaflet map). The fig.height
and fig.width
options of the chunk options will only have impact to set the viewport, but then the PDF output will be based on a print of the page using default pagesize (which is letter I think). This lead to wrong size screenshot on wide size webpage. (Quarto is expecting 300 DPI content which led to higher pixel size than rmarkdown).
See issue linked above for context.