mirror of https://github.com/OpenTTD/OpenTTD
Codechange: Expose IsDefaultFont() in fontcache.cpp
parent
46ebb42fa8
commit
c172a24dc9
|
@ -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();
|
||||
|
|
Loading…
Reference in New Issue