From c990340c5a69834b0dc6ebc06269cf5f56b2ec11 Mon Sep 17 00:00:00 2001 From: Sam Atkins Date: Thu, 12 Aug 2021 16:26:58 +0100 Subject: [PATCH] LibGfx: Mark Typeface::get_font() const, because it is const --- Userland/Libraries/LibGfx/Typeface.cpp | 2 +- Userland/Libraries/LibGfx/Typeface.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Userland/Libraries/LibGfx/Typeface.cpp b/Userland/Libraries/LibGfx/Typeface.cpp index 0a2fa337de..17fd08b266 100644 --- a/Userland/Libraries/LibGfx/Typeface.cpp +++ b/Userland/Libraries/LibGfx/Typeface.cpp @@ -38,7 +38,7 @@ void Typeface::set_ttf_font(RefPtr font) m_ttf_font = font; } -RefPtr Typeface::get_font(unsigned size) +RefPtr Typeface::get_font(unsigned size) const { for (auto font : m_bitmap_fonts) { if (font->presentation_size() == size) diff --git a/Userland/Libraries/LibGfx/Typeface.h b/Userland/Libraries/LibGfx/Typeface.h index ae3a235b81..818cb5a760 100644 --- a/Userland/Libraries/LibGfx/Typeface.h +++ b/Userland/Libraries/LibGfx/Typeface.h @@ -35,7 +35,7 @@ public: void add_bitmap_font(RefPtr); void set_ttf_font(RefPtr); - RefPtr get_font(unsigned size); + RefPtr get_font(unsigned size) const; private: String m_family;