From 4476ed5294e011e4e5eea08117791c3990519211 Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Sun, 13 Aug 2006 06:32:16 +0000 Subject: Made FF use the same max length for every line when word-wrapping subtitles, rather than using the length of the previous line. This fixes bug #1536401. svn-id: r23706 --- engines/simon/string.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'engines') diff --git a/engines/simon/string.cpp b/engines/simon/string.cpp index 447f258781..6975ea53d3 100644 --- a/engines/simon/string.cpp +++ b/engines/simon/string.cpp @@ -365,16 +365,15 @@ void SimonEngine::printScreenText(uint vgaSpriteId, uint color, const char *stri if (getGameType() == GType_FF) { uint16 b, pixels, spaces; - uint16 curWdth = width; while (1) { - string2 = getPixelLength(string, curWdth, pixels); + string2 = getPixelLength(string, width, pixels); if (*string2 == 0) { spaces = (width - pixels) / 12; if (spaces != 0) spaces--; while (spaces) { - *convertedString2++=' '; + *convertedString2++ = ' '; spaces--; } strcpy(convertedString2, string); @@ -400,7 +399,6 @@ void SimonEngine::printScreenText(uint vgaSpriteId, uint color, const char *stri y -= textHeight; if (y < 2) y = 2; - curWdth = pixels; string = string2; } } else { -- cgit v1.2.3