pdf - 如何调整四开本(PDF 输出)中的图形大小?

标签 pdf markdown quarto

我不知道在 Quarto 中调整图形大小的语法,请你给我一个提示。以下无效。

---
title: "resize image"
format: pdf
---

![World](images/World.pdf){fig-width=5}

![World](images/World.pdf){fig-width=10}

![World](images/World.pdf){fig-width=50%}

![World](images/World.pdf){fig-height=50%}

https://quarto.org/docs/reference/formats/pdf.html#figures

https://quarto.org/docs/authoring/figures.html

最佳答案

您可以使用 widthheight,如记录 here .

---
title: "resize image"
format: pdf
---

![Elephant with small width](elephant.png){width=10%}

![Elephant with larger height](elephant.png){height=50%}

也可以使用pxin作为单位,或者在引号之间指定:

![Elephant with height=100px](elephant.png){height=100px}

![Elephant](elephant.png){height=2in}

![Elephant](elephant.png){height="100"}

为什么 fig-heightfig-width 不起作用?

document 中所述你引用,fig-heightfig-width 是 R 或 Matplotlib 图形生成的默认图形大小的设置

由于您的图像不是由 R 或 Matplotlib 生成的,因此您应该使用 pandoc 的属性,如记录 here .

关于pdf - 如何调整四开本(PDF 输出)中的图形大小?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/73844454/

相关文章:

pdf - 缩放以适应和调整页面大小

javascript - jspdf 将 html (div) 导出到 pdf 不起作用

android - APV pdf阅读器。安装,解压缩和 native 库问题

ruby-on-rails - 我可以在 Rails 中使用 prawn 生成 pdf 中的 highcharts 吗?

github - 如何在我的 github 博客上使用 Markdown 制作流程图

Github Markdown anchor 仅链接到页面顶部

html - Golang Martini 模板在渲染 Markdown 时只显示 HTML

r-markdown - 如何 PDF 呈现具有动态内容的四开本书籍?

javascript - 在 R 中向 Quarto HTML 文档添加串扰以加载 map

删除四开标题幻灯片上的幻灯片编号和页脚