diff options
author | Andreas Kling <kling@serenityos.org> | 2023-03-03 19:37:35 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2023-03-04 00:29:38 +0100 |
commit | 2e2c717e89ba50676b91c2e42e147bed1b85c3cf (patch) | |
tree | 1004d332195d9c3ab31240097c2aebe542cfb80d | |
parent | b71c7a6e44981c35ae93c91944e6cff70006285d (diff) | |
download | serenity-2e2c717e89ba50676b91c2e42e147bed1b85c3cf.zip |
LibGfx: Remove Font::glyph_height() virtual
The override on BitmapFont remains, as that is actually used within
the FontEditor program.
-rw-r--r-- | Userland/Libraries/LibGfx/Font/BitmapFont.h | 2 | ||||
-rw-r--r-- | Userland/Libraries/LibGfx/Font/Font.h | 1 | ||||
-rw-r--r-- | Userland/Libraries/LibGfx/Font/ScaledFont.h | 1 |
3 files changed, 1 insertions, 3 deletions
diff --git a/Userland/Libraries/LibGfx/Font/BitmapFont.h b/Userland/Libraries/LibGfx/Font/BitmapFont.h index 2bd673edc2..a917729ea9 100644 --- a/Userland/Libraries/LibGfx/Font/BitmapFont.h +++ b/Userland/Libraries/LibGfx/Font/BitmapFont.h @@ -66,7 +66,7 @@ public: virtual float glyph_or_emoji_width(Utf32CodePointIterator&) const override; float glyphs_horizontal_kerning(u32, u32) const override { return 0.f; } - u8 glyph_height() const override { return m_glyph_height; } + u8 glyph_height() const { return m_glyph_height; } int x_height() const override { return m_x_height; } virtual float preferred_line_height() const override { return glyph_height() + m_line_gap; } diff --git a/Userland/Libraries/LibGfx/Font/Font.h b/Userland/Libraries/LibGfx/Font/Font.h index 9b88759a04..e60e61b261 100644 --- a/Userland/Libraries/LibGfx/Font/Font.h +++ b/Userland/Libraries/LibGfx/Font/Font.h @@ -175,7 +175,6 @@ public: virtual float glyph_or_emoji_width(Utf8CodePointIterator&) const = 0; virtual float glyph_or_emoji_width(Utf32CodePointIterator&) const = 0; virtual float glyphs_horizontal_kerning(u32 left_code_point, u32 right_code_point) const = 0; - virtual u8 glyph_height() const = 0; virtual int x_height() const = 0; virtual float preferred_line_height() const = 0; diff --git a/Userland/Libraries/LibGfx/Font/ScaledFont.h b/Userland/Libraries/LibGfx/Font/ScaledFont.h index 7a2413cba1..4b4f0740a6 100644 --- a/Userland/Libraries/LibGfx/Font/ScaledFont.h +++ b/Userland/Libraries/LibGfx/Font/ScaledFont.h @@ -51,7 +51,6 @@ public: virtual float glyph_or_emoji_width(Utf32CodePointIterator&) const override; virtual float glyphs_horizontal_kerning(u32 left_code_point, u32 right_code_point) const override; virtual float preferred_line_height() const override { return metrics().height() + metrics().line_gap; } - virtual u8 glyph_height() const override { return pixel_size(); } virtual int x_height() const override { return m_point_height; } // FIXME: Read from font virtual u8 min_glyph_width() const override { return 1; } // FIXME: Read from font virtual u8 max_glyph_width() const override { return m_point_width; } // FIXME: Read from font |