aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/facade/Font.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/crepe/facade/Font.cpp')
-rw-r--r--src/crepe/facade/Font.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/crepe/facade/Font.cpp b/src/crepe/facade/Font.cpp
index 47d0e39..51e9690 100644
--- a/src/crepe/facade/Font.cpp
+++ b/src/crepe/facade/Font.cpp
@@ -1,3 +1,5 @@
+#include <SDL2/SDL_ttf.h>
+
#include "../api/Asset.h"
#include "../api/Config.h"
#include "util/Log.h"
@@ -10,8 +12,7 @@ using namespace std;
using namespace crepe;
Font::Font(const Asset & src, Mediator & mediator)
- : Resource(src, mediator) {
- dbg_trace();
+ : Resource(src, mediator){
Config & config = Config::get_instance();
const std::string FONT_PATH = src.get_path();
@@ -23,8 +24,7 @@ Font::Font(const Asset & src, Mediator & mediator)
if (loaded_font == NULL) {
throw runtime_error(format("Font: {} (path: {})", TTF_GetError(), FONT_PATH));
}
- this->font = {loaded_font, [](TTF_Font * font) { TTF_CloseFont(font); }};
- */
+ this->font = {loaded_font, [](TTF_Font * close_font) { TTF_CloseFont(close_font); }};
}
TTF_Font * Font::get_font() const { return this->font.get(); }