MyGUI  3.2.1
MyGUI_FontManager.h
Go to the documentation of this file.
00001 /*
00002  * This source file is part of MyGUI. For the latest info, see http://mygui.info/
00003  * Distributed under the MIT License
00004  * (See accompanying file COPYING.MIT or copy at http://opensource.org/licenses/MIT)
00005  */
00006 
00007 #ifndef __MYGUI_FONT_MANAGER_H__
00008 #define __MYGUI_FONT_MANAGER_H__
00009 
00010 #include "MyGUI_Prerequest.h"
00011 #include "MyGUI_Enumerator.h"
00012 #include "MyGUI_IFont.h"
00013 #include "MyGUI_Singleton.h"
00014 #include "MyGUI_XmlDocument.h"
00015 #include "MyGUI_ResourceManager.h"
00016 #include "MyGUI_BackwardCompatibility.h"
00017 
00018 namespace MyGUI
00019 {
00020 
00021     class MYGUI_EXPORT FontManager :
00022         public Singleton<FontManager>,
00023         public MemberObsolete<FontManager>
00024     {
00025     public:
00026         FontManager();
00027 
00028         void initialise();
00029         void shutdown();
00030 
00034         const std::string& getDefaultFont() const;
00038         void setDefaultFont(const std::string& _value);
00039 
00041         IFont* getByName(const std::string& _name) const;
00042 
00043     private:
00044         void _load(xml::ElementPtr _node, const std::string& _file, Version _version);
00045 
00046     private:
00047         std::string mDefaultName;
00048 
00049         bool mIsInitialise;
00050         std::string mXmlFontTagName;
00051         std::string mXmlPropertyTagName;
00052         std::string mXmlDefaultFontValue;
00053     };
00054 
00055 } // namespace MyGUI
00056 
00057 #endif // __MYGUI_FONT_MANAGER_H__