diff options
author | thankyouverycool <66646555+thankyouverycool@users.noreply.github.com> | 2022-02-24 08:52:31 -0500 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2022-02-24 18:09:22 +0100 |
commit | d94db1900ea815926db35f160232070d318ecdc9 (patch) | |
tree | 2ac6f4c66b0f5e4ec14c155e87287c5a3628db89 /Userland/Libraries/LibGfx/Font.h | |
parent | 07910c12e316a20297ce56f9fc333a42755f3005 (diff) | |
download | serenity-d94db1900ea815926db35f160232070d318ecdc9.zip |
LibGUI+LibGfx: Defer to fonts when setting Editor line height
Fonts now provide their preferred line height based on maximum
height and requested line gap. TTFs provide a preferred line gap
from table metrics while BitmapFonts are hardcoded at the previous
default for now.
Diffstat (limited to 'Userland/Libraries/LibGfx/Font.h')
-rw-r--r-- | Userland/Libraries/LibGfx/Font.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Userland/Libraries/LibGfx/Font.h b/Userland/Libraries/LibGfx/Font.h index a7be32e9de..e9264de823 100644 --- a/Userland/Libraries/LibGfx/Font.h +++ b/Userland/Libraries/LibGfx/Font.h @@ -111,6 +111,7 @@ public: virtual int glyph_or_emoji_width(u32 code_point) const = 0; virtual u8 glyph_height() const = 0; virtual int x_height() const = 0; + virtual int preferred_line_height() const = 0; virtual u8 min_glyph_width() const = 0; virtual u8 max_glyph_width() const = 0; |