From b3104dab9c9ef6cdbc0535a066011eb43a58cd09 Mon Sep 17 00:00:00 2001 From: Mike Kaganski Date: Sun, 4 Aug 2024 00:00:36 +0500 Subject: tdf#123527: use the new font in SvxSearchCharSet::RecalculateFont Taking the font from the render context makes no sense, when the intention is to set the new font set in SvxShowCharSet::SetFont. Basically, it now does a similar thing as in overridden parent's SvxShowCharSet::RecalculateFont. Change-Id: I1077a44b41d881415e1424146bda8aeb47d8ab17 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/171446 Tested-by: Jenkins Reviewed-by: Mike Kaganski (cherry picked from commit 055c906d7b3f2e3709292d1410358d4e66a500ed) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/172003 Reviewed-by: Xisco Fauli --- svx/source/dialog/searchcharmap.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'svx') diff --git a/svx/source/dialog/searchcharmap.cxx b/svx/source/dialog/searchcharmap.cxx index c1c289d6366d..16acbc61e985 100644 --- a/svx/source/dialog/searchcharmap.cxx +++ b/svx/source/dialog/searchcharmap.cxx @@ -170,7 +170,7 @@ void SvxSearchCharSet::RecalculateFont(vcl::RenderContext& rRenderContext) Size aSize(GetOutputSizePixel()); - vcl::Font aFont = rRenderContext.GetFont(); + vcl::Font aFont = maFont; aFont.SetWeight(WEIGHT_LIGHT); aFont.SetAlignment(ALIGN_TOP); int nFontHeight = (aSize.Height() - 5) * 2 / (3 * ROW_COUNT); -- cgit