diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-05-31 21:46:58 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-05-31 21:46:58 +0300 |
commit | 243497fdab7c2f88bebb0e469ecbb2f1fbbe350d (patch) | |
tree | 4f41129e44bdba74a97857cc1107dac3aebb9758 /src/gui/gui.cpp | |
parent | 4157793fab13e00d8176d2d4f0ffd5f9cc957fbe (diff) | |
download | ManaVerse-243497fdab7c2f88bebb0e469ecbb2f1fbbe350d.tar.gz ManaVerse-243497fdab7c2f88bebb0e469ecbb2f1fbbe350d.tar.bz2 ManaVerse-243497fdab7c2f88bebb0e469ecbb2f1fbbe350d.tar.xz ManaVerse-243497fdab7c2f88bebb0e469ecbb2f1fbbe350d.zip |
Add secure font. Now unused.
Diffstat (limited to 'src/gui/gui.cpp')
-rw-r--r-- | src/gui/gui.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp index a23da8157..6651a01d5 100644 --- a/src/gui/gui.cpp +++ b/src/gui/gui.cpp @@ -169,6 +169,21 @@ Gui::Gui(Graphics *graphics): std::string("': ") + e.getMessage()); } + // Set secure font + fontFile = config.getValue("secureFont", ""); + if (fontFile.empty()) + fontFile = branding.getStringValue("secureFont"); + + try + { + mSecureFont = new SDLFont(fontFile, fontSize); + } + catch (const gcn::Exception &e) + { + logger->error(std::string("Unable to load '") + fontFile + + std::string("': ") + e.getMessage()); + } + gcn::Widget::setGlobalFont(mGuiFont); // Initialize mouse cursor and listen for changes to the option @@ -195,6 +210,8 @@ Gui::~Gui() boldFont = 0; delete mHelpFont; mHelpFont = 0; + delete mSecureFont; + mSecureFont = 0; delete mInfoParticleFont; mInfoParticleFont = 0; delete getTop(); |