cardargus uses Jost as its default font, a modern sans-serif from Google Fonts. This article explains how to configure and manage fonts for best results.
This function:
For offline use or better performance, download fonts to your local cache:
cardargus embeds fonts via Google Fonts CSS in SVGs:
cardargus caches downloaded fonts in a user directory:
setup_fonts() before creating cardsfont_available("Jost")For correct font rendering in PNG exports with rsvg:
For perfect font rendering, use Chrome-based conversion:
# Ensure Chrome is available
ensure_chrome(download = TRUE)
# Create and export
card <- svg_card(...)
svg_to_png_chrome(card, "card.png", dpi = 300)Chrome handles Google Fonts automatically via @import,
so no local font installation is needed.
| Font | Type | Description |
|---|---|---|
| Jost | Sans-serif | Default, modern |
| Montserrat | Sans-serif | Elegant alternative |
| Roboto | Sans-serif | Readable, Google Material |
| Open Sans | Sans-serif | Neutral, versatile |
| Lato | Sans-serif | Friendly, rounded |