如何配置Asciidoctor的页码起始页



我使用asciidoctor和asciidoctor-pdf。我想在第三页之后开始编号。我如何在。yml文件中的asciidoctor中做到这一点?

我当前的页脚配置是

footer:
font_size: $base_font_size_small
# NOTE if background_color is set, background and border will span width of page
border_color: DDDDDD
border_width: 0.25
height: $base_line_height_length * 2.5
line_height: 1
padding: [$base_line_height_length / 2, 1, 0, 1]
vertical_align: top
recto:
#columns: "<50% =0% >50%"
right:
content: '{page-number}'
verso:
#columns: $footer_recto_columns
left:
content: $footer_recto_right_content

Asciidoctor PDF 2.0,你可以更新你的asciidoctor-pdf:

gem install asciidoctor-pdf

页面编号并不像人们想象的那么简单,因为您不仅有页码,还有虚拟页码。您可以查看新的asciidoctor-pdf文档,检查页码并配置页码。我假设第3页是在你的目录之后,看到你所有的参数,但你只需要在你的主题中添加这样的东西:

page:
numbering:
start-at: after-toc

最新更新