From eac24ac982784745d127d1899df30999b0035338 Mon Sep 17 00:00:00 2001 From: kernelkind Date: Fri, 3 Jan 2025 17:31:17 -0500 Subject: [PATCH] get bolded font helper Signed-off-by: kernelkind --- crates/notedeck/src/style.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/crates/notedeck/src/style.rs b/crates/notedeck/src/style.rs index 2a890457..d54ff572 100644 --- a/crates/notedeck/src/style.rs +++ b/crates/notedeck/src/style.rs @@ -49,4 +49,11 @@ impl NotedeckTextStyle { pub fn get_font_id(&self, ctx: &Context) -> FontId { FontId::new(get_font_size(ctx, self), self.font_family()) } + + pub fn get_bolded_font(&self, ctx: &Context) -> FontId { + FontId::new( + get_font_size(ctx, self), + egui::FontFamily::Name(crate::NamedFontFamily::Bold.as_str().into()), + ) + } }