diff options
author | Gregory Montoir | 2003-11-10 15:45:53 +0000 |
---|---|---|
committer | Gregory Montoir | 2003-11-10 15:45:53 +0000 |
commit | 98d4b4cb311e5aa95f6b8db3771a1647bed1f545 (patch) | |
tree | 4d7120aea77f3b40e93df6bd2892545b71cae95a /queen/display.cpp | |
parent | 72d91990227ed6e64f6358011bda3bd5493fdb86 (diff) | |
download | scummvm-rg350-98d4b4cb311e5aa95f6b8db3771a1647bed1f545.tar.gz scummvm-rg350-98d4b4cb311e5aa95f6b8db3771a1647bed1f545.tar.bz2 scummvm-rg350-98d4b4cb311e5aa95f6b8db3771a1647bed1f545.zip |
hack for special french character
svn-id: r11250
Diffstat (limited to 'queen/display.cpp')
-rw-r--r-- | queen/display.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/queen/display.cpp b/queen/display.cpp index a78bb9e914..8d98516ac2 100644 --- a/queen/display.cpp +++ b/queen/display.cpp @@ -57,9 +57,9 @@ void TextRenderer::drawString(uint8 *dstBuf, uint16 dstPitch, uint16 x, uint16 y const uint8 *str = (const uint8*)text; while (*str && x < dstPitch) { - const uint8 *pchr = FONT + (*str) * 8; - // FIXME: handle 0x96 character in french version (replace with 0xFB) + uint8 c = (lang == FRENCH && *str == 0x96) ? 0xFB : *str; + const uint8 *pchr = FONT + c * 8; if (outlined) { drawChar(dstBuf, dstPitch, x - 1, y - 1, INK_OUTLINED_TEXT, pchr); @@ -73,7 +73,7 @@ void TextRenderer::drawString(uint8 *dstBuf, uint16 dstPitch, uint16 x, uint16 y } drawChar(dstBuf, dstPitch, x, y, color, pchr); - x += charWidth[ *str ]; + x += charWidth[ c ]; ++str; } } @@ -101,10 +101,11 @@ void TextRenderer::drawChar(uint8 *dstBuf, uint16 dstPitch, uint16 x, uint16 y, -Display::Display(OSystem *system, Input *input) +Display::Display(Language language, OSystem *system, Input *input) : _system(system), _input(input) { _dynalum.prevColMask = 0xFF; + _textRenderer.lang = language; _textRenderer.init(); _buffers[RB_BACKDROP] = new uint8[BACKDROP_W * BACKDROP_H]; |