Skip to contents

Configure fonts for ggplot2 plots using either showtext or extrafont method.

Usage

set_fonts(base_family = "Open Sans", font_method = c("showtext", "extrafont"))

Arguments

base_family

Character string specifying the font family. Default is "Open Sans". Bundled fonts "Open Sans" and "Lato" are available for offline use. Other Google Fonts work but require an internet connection.

font_method

Character string specifying the font rendering method. Must be one of "showtext" (default, recommended) or "extrafont" (legacy).

Value

Invisible NULL, called for side effects.