1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-12-07 23:33:15 +02:00
This commit is contained in:
AlexVinS
2016-11-06 02:04:54 +03:00
parent 6a272d8f0c
commit 46196daa07
6 changed files with 35 additions and 130 deletions

View File

@@ -3,7 +3,6 @@
#include "../lib/filesystem/Filesystem.h"
#include "../lib/filesystem/CBinaryReader.h"
#include "CDefHandler.h"
#include "gui/SDL_Extensions.h"
#include "gui/CAnimation.h"
#include <SDL_ttf.h>
@@ -335,11 +334,11 @@ void Graphics::loadFonts()
std::string filename = bmpConf[i].String();
if (!hanConf[filename].isNull())
fonts[i] = new CBitmapHanFont(hanConf[filename]);
fonts[i] = std::make_shared<CBitmapHanFont>(hanConf[filename]);
else if (!ttfConf[filename].isNull()) // no ttf override
fonts[i] = new CTrueTypeFont(ttfConf[filename]);
fonts[i] = std::make_shared<CTrueTypeFont>(ttfConf[filename]);
else
fonts[i] = new CBitmapFont(filename);
fonts[i] = std::make_shared<CBitmapFont>(filename);
}
}