From 3036c37dd817545b4571f01625954c9c74c635ae Mon Sep 17 00:00:00 2001 From: Nicola Mettifogo Date: Sun, 8 Jul 2007 13:39:23 +0000 Subject: Yet another fix for broken parsing/displaying of strings. Now quotes are properly considered when they are needed, and ignored when they aren't. svn-id: r27967 --- engines/parallaction/graphics.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'engines/parallaction/graphics.cpp') diff --git a/engines/parallaction/graphics.cpp b/engines/parallaction/graphics.cpp index aca02a68bf..699ec5cbc5 100644 --- a/engines/parallaction/graphics.cpp +++ b/engines/parallaction/graphics.cpp @@ -608,7 +608,7 @@ bool Gfx::displayWrappedString(char *text, uint16 x, uint16 y, byte color, uint1 while (strlen(text) > 0) { - text = parseNextToken(text, token, 40, " "); + text = parseNextToken(text, token, 40, " ", true); linewidth += getStringWidth(token); if (linewidth > wrapwidth) { @@ -653,7 +653,8 @@ void Gfx::getStringExtent(char *text, uint16 maxwidth, int16* width, int16* heig while (strlen(text) != 0) { - text = parseNextToken(text, token, 40, " "); + text = parseNextToken(text, token, 40, " ", true); + printf("%s\n", text); w += getStringWidth(token); if (w > maxwidth) { -- cgit v1.2.3