LazReport, Fix breaking lines properly when text contains utf8 chars, from Julio Jiménez Borreguero, issue #23291

git-svn-id: trunk@39266 -
This commit is contained in:
jesus 2012-11-08 17:57:36 +00:00
parent 67447dd7f1
commit d46192418c

View File

@ -2955,8 +2955,8 @@ var
// output the portion of word that fits maxwidth
OutLine(UTF8Range(s, beg, last - beg, Desc));
// if space was found, advance to next no space char
if s[last] = ' ' then
last := last + 1;
while (UTF8Char(s, last, Desc) = ' ') and (last < Length(s)) do
Inc(last);
end;
beg := last;