Index: src/fontcache.cpp =================================================================== --- src/fontcache.cpp (wersja 25754) +++ src/fontcache.cpp (kopia robocza) @@ -75,7 +75,7 @@ virtual SpriteID GetUnicodeGlyph(WChar key); virtual void SetUnicodeGlyph(WChar key, SpriteID sprite); virtual void InitializeUnicodeGlyphMap(); - virtual void ClearFontCache() {} + virtual void ClearFontCache(); virtual const Sprite *GetGlyph(GlyphID key); virtual uint GetGlyphWidth(GlyphID key); virtual bool GetDrawGlyphShadow(); @@ -162,6 +162,11 @@ this->glyph_to_spriteid_map = NULL; } +void SpriteFontCache::ClearFontCache() +{ + Layouter::ResetFontCache(this->fs); +} + const Sprite *SpriteFontCache::GetGlyph(GlyphID key) { SpriteID sprite = this->GetUnicodeGlyph(key); @@ -392,6 +397,8 @@ free(this->glyph_to_sprite); this->glyph_to_sprite = NULL; + + Layouter::ResetFontCache(this->fs); } FreeTypeFontCache::GlyphEntry *FreeTypeFontCache::GetGlyphPtr(GlyphID key)