From e9cbf5fcbd1af19d1936593d1de736c0e0e91f89 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Sun, 16 Apr 2006 19:54:39 +0000 Subject: - Moves Graphics::loadFont to Graphics::NewFont::loadFont - adds code for caching of fonts (just for Graphics::NewFont) - implements cache using in the modern theme for custom fonts - adds cache file for current normal font in the theme zip file svn-id: r21952 --- graphics/font.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'graphics/font.h') diff --git a/graphics/font.h b/graphics/font.h index 66a8e84222..5e8db40610 100644 --- a/graphics/font.h +++ b/graphics/font.h @@ -123,10 +123,11 @@ public: virtual int getCharWidth(byte chr) const; virtual void drawChar(Surface *dst, byte chr, int x, int y, uint32 color) const; -}; -NewFont *loadFont(Common::SeekableReadStream &stream); -NewFont *loadFont(const byte *src, uint32 size); + static NewFont *loadFont(Common::SeekableReadStream &stream); + static bool cacheFontData(const NewFont &font, const Common::String &filename); + static NewFont *loadFromCache(Common::SeekableReadStream &stream); +}; #if (defined(PALMOS_ARM) || defined(PALMOS_DEBUG) || defined(__GP32__)) # define DEFINE_FONT(n) \ -- cgit v1.2.3