From 6b89bb6f91cf3a39db33e2459f8a8f2048db4471 Mon Sep 17 00:00:00 2001 From: reuk Date: Mon, 13 May 2024 13:12:05 +0100 Subject: [PATCH] Font: Fix result of getDescent(), which was incorrect when font height was set in points --- modules/juce_graphics/fonts/juce_Font.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/juce_graphics/fonts/juce_Font.cpp b/modules/juce_graphics/fonts/juce_Font.cpp index ed5ec07ebc..5a6712f839 100644 --- a/modules/juce_graphics/fonts/juce_Font.cpp +++ b/modules/juce_graphics/fonts/juce_Font.cpp @@ -744,7 +744,7 @@ float Font::getHeight() const noexcept return height > 0.0f ? height : font->getPointHeight() / getHeightToPointsFactor(); } -float Font::getDescent() const { return font->getHeight() - getAscent(); } +float Font::getDescent() const { return getHeight() - getAscent(); } float Font::getHeightInPoints() const {