Go to the documentation of this file.
39 m_defaultFont =
nullptr;
56 std::string name = fontNode->
valueAt(
"name");
59 for(
auto it = m_fonts.begin(); it != m_fonts.end(); ++it) {
60 if((*it)->getName() == name) {
68 m_fonts.push_back(font);
71 if(!m_defaultFont || fontNode->
valueAt<
bool>(
"default",
false))
84 if(font->getName() == fontName)
94 if(font->getName() == fontName)
void load(const OTMLNodePtr &fontNode)
Load font from otml node.
bool fontExists(const std::string &fontName)
static OTMLDocumentPtr parse(const std::string &fileName)
Parse OTML from a file.
bool importFont(std::string file)
void error(const std::string &what)
ResourceManager g_resources
T valueAt(const std::string &childTag)
virtual const char * what() const
stdext::shared_object_ptr< BitmapFont > BitmapFontPtr
BitmapFontPtr getFont(const std::string &fontName)
BitmapFontPtr getDefaultFont()
OTMLNodePtr at(const std::string &childTag)
std::string guessFilePath(const std::string &filename, const std::string &type)