从
bookdown documentation
我们可以学到两件事:
-
没有
language.label.chapter_name
但是
language.ui.chapter_name
.
-
此设置用于HTML输出。对于pdf输出,应该配置latex。
配置乳胶非常简单。你只需要添加
lang: es
到你的头上。
但是,这将使用“captulo”而不是“mdulo”。可以通过重新定义latex命令来调整
\chaptername
. 顺便说一句,现在你不用
bookdown
但是标准
pdf_docuemnt
从
rmarkdown
. 如果你不想用
书呆子
功能,您应该使用
bookdown::pdf_book
或
bookdown::pdf_document2
.
把所有的东西放在一起:
---
title: "TITLE"
author: "Mario Modesto-Mata"
date: "`r Sys.Date()`"
output: bookdown::pdf_book
description: This is a minimal example of using the bookdown package to write a book.
The output format for this example is bookdown::gitbook.
documentclass: book
lang: es
link-citations: yes
bibliography: book.bib
site: bookdown::bookdown_site
header-includes:
- \AtBeginDocument{\renewcommand{\chaptername}{Módulo}}
---
结果: