class EE::Graphics::FontManager¶
Overview¶
The Font Manager is a singleton class that manages all the instance of fonts instanciated. And releases the font instances automatically. So the user doesn’t need to release any font instance. More…
#include <fontmanager.hpp> class FontManager: public EE::System::ResourceManager { public: // construction virtual ~FontManager(); // methods Graphics::Font* add(Graphics::Font* Font); Font* getColorEmojiFont() const; void setColorEmojiFont(Graphics::Font* font); Font* getEmojiFont() const; void setEmojiFont(Font* newEmojiFont); Font* getFallbackFont() const; void setFallbackFont(Font* fallbackFont); };
Inherited Members¶
public: // methods virtual T* add(T* resource); bool remove(T* resource, bool remove = true); bool removeById(const String::HashType& id, bool remove = true); bool removeByName(const std::string& name, bool remove = true); T* getByName(const std::string& name); T* getById(const String::HashType& id); Uint32 getCount(); Uint32 getCount(const std::string& name); Uint32 getCount(const String::HashType& id); bool exists(const std::string& name); bool existsId(const String::HashType& id); void destroy(); void printNames(); std::unordered_map<String::HashType, T*>& getResources(); const bool& isDestroying() const;
Detailed Documentation¶
The Font Manager is a singleton class that manages all the instance of fonts instanciated. And releases the font instances automatically. So the user doesn’t need to release any font instance.
Methods¶
Graphics::Font* add(Graphics::Font* Font)
Adds a new font to the manager.