mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-08-12 09:09:09 +00:00
Codechange: Expose IsDefaultFont() in fontcache.cpp
This commit is contained in:
@@ -199,9 +199,10 @@ void SetFont(FontSize font_size, const std::string &font, uint size)
|
||||
|
||||
/**
|
||||
* Test if a font setting uses the default font.
|
||||
* @param setting The font setting to check.
|
||||
* @return true iff the font is not configured and no fallback font data is present.
|
||||
*/
|
||||
static bool IsDefaultFont(const FontCacheSubSetting &setting)
|
||||
bool IsDefaultFont(const FontCacheSubSetting &setting)
|
||||
{
|
||||
return setting.font.empty() && setting.os_handle == nullptr;
|
||||
}
|
||||
|
@@ -232,6 +232,7 @@ std::string GetFontCacheFontName(FontSize fs);
|
||||
void DebugPrintFontSettings(const std::string &desc);
|
||||
bool GetFontAAState();
|
||||
void InitFontCache();
|
||||
bool IsDefaultFont(const FontCacheSubSetting &setting);
|
||||
void ResizeFont(FontSize font_size, uint size);
|
||||
void SetFont(FontSize fontsize, const std::string &font, uint size);
|
||||
void UninitFontCache();
|
||||
|
Reference in New Issue
Block a user