1
0
mirror of https://github.com/OpenTTD/OpenTTD synced 2026-01-20 19:02:41 +01:00

Codechange: OS-specific data for font search is not used outside of searching.

This commit is contained in:
Michael Lutz
2021-01-04 15:20:34 +01:00
parent 84636fc2af
commit 2b0200d429
4 changed files with 2 additions and 9 deletions

View File

@@ -344,9 +344,7 @@ static int CALLBACK EnumFontCallback(const ENUMLOGFONTEX *logfont, const NEWTEXT
const char *english_name = font_name;
#endif /* WITH_FREETYPE */
PLOGFONT os_data = MallocT<LOGFONT>(1);
*os_data = logfont->elfLogFont;
info->callback->SetFontNames(info->settings, font_name, os_data);
info->callback->SetFontNames(info->settings, font_name, &logfont->elfLogFont);
if (info->callback->FindMissingGlyphs()) return 1;
DEBUG(freetype, 1, "Fallback font: %s (%s)", font_name, english_name);
return 0; // stop enumerating