0ad/source/ps/NPFontManager.h
MarkT 6d5afc10ff Added PASAP entity systems
This was SVN commit r246.
2004-05-21 23:46:16 +00:00

40 lines
774 B
C++
Executable File

#ifndef _FONTMANAGER_H
#define _FONTMANAGER_H
// necessary includes
#include <vector>
// necessary declaration
class NPFont;
class NPFontManager
{
public:
// accessor; return the font manager
static NPFontManager& instance();
// release this font manager
static void release();
// destructor
~NPFontManager();
// add a font; return the created font, or 0 if not found
NPFont* add(const char* name);
// remove a font
bool remove(const char* name);
// find a font (return 0 if not found)
NPFont* find(const char* name);
private:
// hidden constructor; access available only through instance()
NPFontManager();
// list of recorded fonts
std::vector<NPFont*> _fonts;
// the sole instance of the FontManager
static NPFontManager* _instance;
};
#endif