Go to the documentation of this file.
18 template <> FontManager* Singleton<FontManager>::msInstance =
nullptr;
19 template <>
const char* Singleton<FontManager>::mClassTypeName =
"FontManager";
23 mXmlFontTagName(
"Font"),
24 mXmlPropertyTagName(
"Property"),
25 mXmlDefaultFontValue(
"Default")
40 mDefaultName =
"Default";
58 mIsInitialise =
false;
63 #ifndef MYGUI_DONT_USE_OBSOLETE
65 #endif // MYGUI_DONT_USE_OBSOLETE
70 if (node->
getName() == mXmlPropertyTagName)
74 #ifdef MYGUI_USE_FREETYPE
77 if (key ==
"DefaultGenerated")
86 mDefaultName = _value;
93 if (!_name.empty() && _name != mXmlDefaultFontValue)
96 if (result ==
nullptr)
99 if (!_name.empty() && _name != mXmlDefaultFontValue)
101 MYGUI_LOG(Error,
"Font '" << _name <<
"' not found. Replaced with default font.");
static ResourceManager & getInstance()
const std::string & getCategoryName() const
void unregisterFactory(const std::string &_category, const std::string &_type)
LoadXmlDelegate & registerLoadXmlDelegate(const std::string &_key)
void unregisterLoadXmlDelegate(const std::string &_key)
const std::string & getName() const
const std::string & getDefaultFont() const
static const char * getClassTypeName()
void registerFactory(const std::string &_category, const std::string &_type, Delegate::IDelegate *_delegate)
bool findAttribute(const std::string &_name, std::string &_value)
delegates::DelegateFunction< Args... > * newDelegate(void(*_func)(Args... args))
#define MYGUI_ASSERT(exp, dest)
Type * castType(bool _throw=true)
IFont * getByName(const std::string &_name) const
IResource * getByName(const std::string &_name, bool _throw=true) const
#define MYGUI_LOG(level, text)
void loadOldFontFormat(xml::ElementPtr _node, const std::string &_file, Version _version, const std::string &_tag)
ElementEnumerator getElementEnumerator()
void setDefaultFont(const std::string &_value)