aboutsummaryrefslogtreecommitdiff
path: root/engines/wage
diff options
context:
space:
mode:
authorEugene Sandulenko2016-08-03 23:39:10 +0200
committerEugene Sandulenko2016-08-03 23:39:10 +0200
commit0cccd0ddd1d53b7d16e47a5b2d8ca62c87d992f4 (patch)
treec9c0be62f06ba7b5f7bebc69722a250a69e2203f /engines/wage
parent7c12e80552af036d8029b6fc197403e25a879e66 (diff)
downloadscummvm-rg350-0cccd0ddd1d53b7d16e47a5b2d8ca62c87d992f4.tar.gz
scummvm-rg350-0cccd0ddd1d53b7d16e47a5b2d8ca62c87d992f4.tar.bz2
scummvm-rg350-0cccd0ddd1d53b7d16e47a5b2d8ca62c87d992f4.zip
GRAPHICS/WAGE: Made MacWindowManager font maping requiring font size
Diffstat (limited to 'engines/wage')
-rw-r--r--engines/wage/dialog.cpp2
-rw-r--r--engines/wage/entities.cpp2
-rw-r--r--engines/wage/gui-console.cpp5
3 files changed, 3 insertions, 6 deletions
diff --git a/engines/wage/dialog.cpp b/engines/wage/dialog.cpp
index a2013db852..0a326817be 100644
--- a/engines/wage/dialog.cpp
+++ b/engines/wage/dialog.cpp
@@ -92,7 +92,7 @@ Dialog::~Dialog() {
}
const Graphics::Font *Dialog::getDialogFont() {
- return _gui->_wm.getFont("Chicago-12", Graphics::FontManager::kBigGUIFont);
+ return _gui->_wm.getFont(_gui->_wm.getFontName(0, 12), Graphics::FontManager::kBigGUIFont); // Default is Chicago
}
void Dialog::paint() {
diff --git a/engines/wage/entities.cpp b/engines/wage/entities.cpp
index 77ab2659af..3dcf37033a 100644
--- a/engines/wage/entities.cpp
+++ b/engines/wage/entities.cpp
@@ -158,7 +158,7 @@ void Scene::paint(Graphics::ManagedSurface *surface, int x, int y) {
}
const char *Scene::getFontName() {
- const char *name = ((WageEngine *)g_engine)->_gui->_wm.getFontName(_fontType);
+ const char *name = ((WageEngine *)g_engine)->_gui->_wm.getFontName(_fontType, _fontSize);
if (!name)
return "Unknown";
diff --git a/engines/wage/gui-console.cpp b/engines/wage/gui-console.cpp
index 1cf98ab991..2b364d3657 100644
--- a/engines/wage/gui-console.cpp
+++ b/engines/wage/gui-console.cpp
@@ -63,12 +63,9 @@
namespace Wage {
const Graphics::Font *Gui::getConsoleFont() {
- char fontName[128];
Scene *scene = _engine->_world->_player->_currentScene;
- snprintf(fontName, 128, "%s-%d", scene->getFontName(), scene->_fontSize);
-
- return _wm.getFont(fontName, Graphics::FontManager::kConsoleFont);
+ return _wm.getFont(scene->getFontName(), Graphics::FontManager::kConsoleFont);
}
void Gui::clearOutput() {