diff options
author | sylvaintv | 2015-03-19 21:42:08 +0100 |
---|---|---|
committer | sylvaintv | 2015-03-19 21:42:08 +0100 |
commit | e73faeee681a904751db28456a1320b74232ce43 (patch) | |
tree | 8fda9be651555ba57f260fc78c6563671dbbd9f1 /engines/toon/font.cpp | |
parent | 55a94d8fd4bc79c088ecb191f7e639996c6e5127 (diff) | |
download | scummvm-rg350-e73faeee681a904751db28456a1320b74232ce43.tar.gz scummvm-rg350-e73faeee681a904751db28456a1320b74232ce43.tar.bz2 scummvm-rg350-e73faeee681a904751db28456a1320b74232ce43.zip |
TOON: Add options menu
- Add options menu when pressing F1
- Add in-game font change
Diffstat (limited to 'engines/toon/font.cpp')
-rw-r--r-- | engines/toon/font.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/toon/font.cpp b/engines/toon/font.cpp index ab941e5de9..9b08e432fc 100644 --- a/engines/toon/font.cpp +++ b/engines/toon/font.cpp @@ -99,7 +99,7 @@ void FontRenderer::renderText(int16 x, int16 y, const Common::String &origText, } else { curChar = textToFont(curChar); _currentFont->drawFontFrame(_vm->getMainSurface(), curChar, curX, curY, _currentFontColor); - curX = curX + _currentFont->getFrameWidth(curChar) - 1; + curX = curX + MAX<int32>(_currentFont->getFrameWidth(curChar) - 2, 0); height = MAX<int32>(height, _currentFont->getFrameHeight(curChar)); } text++; @@ -138,8 +138,8 @@ void FontRenderer::computeSize(const Common::String &origText, int16 *retX, int1 // really tell how far it will stick out. For now, // assume we only need to take the lower bound into // consideration. - Common::Rect charRect = _currentFont->getFrameRect(curChar); - lastLineHeight = MAX(lastLineHeight, charRect.bottom); + //Common::Rect charRect = _currentFont->getFrameRect(curChar); + lastLineHeight = MAX(lastLineHeight, _currentFont->getHeight()); } text++; } |