aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra
diff options
context:
space:
mode:
authorJohannes Schickel2008-05-19 20:48:31 +0000
committerJohannes Schickel2008-05-19 20:48:31 +0000
commit75fcf38933eed3152d143298cbc46152fa37609d (patch)
tree50eb1de342ae5c9497848effa3bbc72506c8bf80 /engines/kyra
parentcefff90ac61e95641950ae694e3334c1c344c32d (diff)
downloadscummvm-rg350-75fcf38933eed3152d143298cbc46152fa37609d.tar.gz
scummvm-rg350-75fcf38933eed3152d143298cbc46152fa37609d.tar.bz2
scummvm-rg350-75fcf38933eed3152d143298cbc46152fa37609d.zip
Fix for bug #1967311 "KYRA3: Word-wrapping is slightly buggy".
svn-id: r32183
Diffstat (limited to 'engines/kyra')
-rw-r--r--engines/kyra/text_mr.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/engines/kyra/text_mr.cpp b/engines/kyra/text_mr.cpp
index 13b37fa77a..4e997d19bc 100644
--- a/engines/kyra/text_mr.cpp
+++ b/engines/kyra/text_mr.cpp
@@ -55,25 +55,25 @@ char *TextDisplayer_MR::preprocessString(const char *str) {
int count = 0, offs = 0;
if (textWidth > (3*maxTextWidth)) {
count = getCharLength(p, textWidth/4);
- offs = dropCRIntoString(p, getCharLength(p, maxTextWidth), count);
+ offs = dropCRIntoString(p, count, getCharLength(p, maxTextWidth));
p += count + offs;
- }
-
+ }
+
if (textWidth > (2*maxTextWidth)) {
count = getCharLength(p, textWidth/3);
- offs = dropCRIntoString(p, getCharLength(p, maxTextWidth), count);
+ offs = dropCRIntoString(p, count, getCharLength(p, maxTextWidth));
p += count + offs;
textWidth = _screen->getTextWidth(p);
}
count = getCharLength(p, textWidth/2);
- offs = dropCRIntoString(p, getCharLength(p, maxTextWidth), count);
+ offs = dropCRIntoString(p, count, getCharLength(p, maxTextWidth));
p += count + offs;
textWidth = _screen->getTextWidth(p);
if (textWidth > maxTextWidth) {
count = getCharLength(p, textWidth/2);
- offs = dropCRIntoString(p, getCharLength(p, maxTextWidth), count);
+ offs = dropCRIntoString(p, count, getCharLength(p, maxTextWidth));
}
}