diff options
author | Paweł Kołodziejski | 2003-03-30 19:32:12 +0000 |
---|---|---|
committer | Paweł Kołodziejski | 2003-03-30 19:32:12 +0000 |
commit | 7ee96df673902a6352c9c819b1ac89cbe776d3eb (patch) | |
tree | 450755154c53d8d97cd91a4379add798ab790862 /scumm/string.cpp | |
parent | 776cdf2d086f51b75f84041313276c87acf8ce61 (diff) | |
download | scummvm-rg350-7ee96df673902a6352c9c819b1ac89cbe776d3eb.tar.gz scummvm-rg350-7ee96df673902a6352c9c819b1ac89cbe776d3eb.tar.bz2 scummvm-rg350-7ee96df673902a6352c9c819b1ac89cbe776d3eb.zip |
fixed description centering in the FT and added hack for redraw descriptions in height while scrolling room
svn-id: r6890
Diffstat (limited to 'scumm/string.cpp')
-rw-r--r-- | scumm/string.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/scumm/string.cpp b/scumm/string.cpp index 201b3a63c9..a5bc387f3d 100644 --- a/scumm/string.cpp +++ b/scumm/string.cpp @@ -359,9 +359,10 @@ void Scumm::drawDescString(byte *msg) { _charset->_nextTop = _string[0].ypos; // Center text - _charset->_nextLeft -= _charset->getStringWidth(0, buffer) >> 1; - if (_charset->_nextLeft < 0) - _charset->_nextLeft = 0; + _string[0].xpos -= _charset->getStringWidth(0, buffer) >> 1; + if (_string[0].xpos < 0) { + _string[0].xpos = 0; + } _talkDelay = 1; @@ -383,12 +384,12 @@ void Scumm::drawDescString(byte *msg) { } while (c); _haveMsg = 1; - // hack: more 8 pixels at width redraw before and after text + // hack: more 8 pixels at width and height while redraw // for proper description redraw while scrolling room gdi._mask_left = _charset->_strLeft - 8; gdi._mask_right = _charset->_strRight + 8; - gdi._mask_top = _charset->_strTop; - gdi._mask_bottom = _charset->_strBottom; + gdi._mask_top = _charset->_strTop - 8; + gdi._mask_bottom = _charset->_strBottom + 8; } void Scumm::drawString(int a) { |