MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / SpriteFontCache

Method SpriteFontCache

src/fontcache/spritefontcache.cpp:117–121  ·  view source on GitHub ↗

* Create a new sprite font cache. * @param fs The font size to create the cache for. */

Source from the content-addressed store, hash-verified

115 * @param fs The font size to create the cache for.
116 */
117SpriteFontCache::SpriteFontCache(FontSize fs) : FontCache(fs)
118{
119 this->height = ScaleGUITrad(FontCache::GetDefaultFontHeight(this->fs));
120 this->ascender = (this->height - ScaleFontTrad(FontCache::GetDefaultFontHeight(this->fs))) / 2;
121}
122
123void SpriteFontCache::ClearFontCache()
124{

Callers

nothing calls this directly

Calls 2

ScaleFontTradFunction · 0.85
ScaleGUITradFunction · 0.50

Tested by

no test coverage detected