[Scummvm-cvs-logs] SF.net SVN: scummvm:[49890] scummvm/trunk/engines/sci/graphics/frameout.cpp

m_kiewitz at users.sourceforge.net m_kiewitz at users.sourceforge.net
Tue Jun 15 22:23:25 CEST 2010


Revision: 49890
          http://scummvm.svn.sourceforge.net/scummvm/?rev=49890&view=rev
Author:   m_kiewitz
Date:     2010-06-15 20:23:25 +0000 (Tue, 15 Jun 2010)

Log Message:
-----------
SCI: make umlauts work in kFrameout for sci32

Modified Paths:
--------------
    scummvm/trunk/engines/sci/graphics/frameout.cpp

Modified: scummvm/trunk/engines/sci/graphics/frameout.cpp
===================================================================
--- scummvm/trunk/engines/sci/graphics/frameout.cpp	2010-06-15 20:01:31 UTC (rev 49889)
+++ scummvm/trunk/engines/sci/graphics/frameout.cpp	2010-06-15 20:23:25 UTC (rev 49890)
@@ -265,14 +265,15 @@
 						uint16 curX = itemEntry->x;
 						uint16 curY = itemEntry->y;
 						for (uint32 i = 0; i < text.size(); i++) {
+							unsigned char curChar = text[i];
 							// TODO: proper text splitting... this is a hack
-							if ((text[i] == ' ' && i > 0 && text[i - i] == ' ') || text[i] == '\n' || 
-								(curX + font->getCharWidth(text[i]) > _screen->getWidth())) {
+							if ((curChar == ' ' && i > 0 && text[i - i] == ' ') || curChar == '\n' || 
+								(curX + font->getCharWidth(curChar) > _screen->getWidth())) {
 								curY += font->getHeight();
 								curX = itemEntry->x;
 							}
-							font->draw(text[i], curY, curX, foreColor, dimmed);
-							curX += font->getCharWidth(text[i]);
+							font->draw(curChar, curY, curX, foreColor, dimmed);
+							curX += font->getCharWidth(curChar);
 						}
 						delete font;
 					}


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list