【问题标题】:Bookdown different even and odd pages margins with pdf output使用 pdf 输出记录不同的偶数和奇数页边距
【发布时间】:2020-06-02 19:21:11
【问题描述】:

我正在使用带有 R 3.6.0 的 bookdown 包版本 0.13。

当我生成 pdf 输出时,偶数页和奇数页的边距不同。偶数页向右移动,奇数页向左移动(见下图)。这是某种类型的功能吗?比如打印?

如何禁用此行为?

在尝试the official demo 中提供的最小示例时,我得到了相同的边距差异。 _bookdown.yml 文件有这样的内容:

book_filename: "bookdown-demo"
language:
  ui:
    chapter_name: "Chapter "
delete_merged_file: true
new_session: yes

【问题讨论】:

  • 如果您包含一个简单的reproducible example,其中包含可用于测试和验证可能解决方案的示例输入和所需输出,则更容易为您提供帮助。您的文件的 YAML 标头中有什么?
  • 我已经编辑了我的问题以包含可重现的示例和 YAML 内容。

标签: r pdf r-markdown bookdown


【解决方案1】:

边距发生了变化,因为默认情况下格式是双面的。我通过将其更改为一侧来解决此问题。这是通过在 index.Rmd 中添加以下内容来完成的

classoption: oneside

在乳胶中,这是用:

\documentclass[oneside]{book}

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2011-03-28
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2014-08-06
    • 2010-09-12
    • 1970-01-01
    • 2015-08-05
    相关资源
    最近更新 更多