Skip to main content

set_font

Function set_font 

Source
pub fn set_font(font: Font) -> bool
Expand description

Registers the font components use for emphasised text, such as card and toast titles. Pass the same font you give iced’s default_font, before the first view. Returns false if a font was already set.

Without it, emphasised text uses iced’s generic sans-serif family, which the system resolves and may differ from your default font.