font

.font main:{String? = null}
heading:{String? = null}
code:{String? = null}
size:{Size? = null}
-> Void

Updates the global font configuration of the document.

Font families can be loaded from any of the following sources:

  • From file (e.g. path/to/font.ttf)

  • From URL (e.g. https://example.com/font.ttf)

  • From system fonts (e.g. Arial, Times New Roman)

  • From Google Fonts (e.g. GoogleFonts:Roboto).

Local and remote font resources are processed by the media storage. This means, for instance, HTML output will carry local fonts into the output directory for increased portability.

Parameters

main
  • Optional

main font family of content on each page

heading

font family of headings on each page

code

font family of code blocks and code spans on each page

size

font size of the text on each page

Wiki page

Font configuration