Try to avoid the split point jumping around when it occurs exactly on the boundary requested

This commit is contained in:
Chris Young 2013-05-18 13:34:36 +01:00
parent 13e667ff78
commit 5fcdbb80f0
1 changed files with 2 additions and 3 deletions

View File

@ -341,8 +341,6 @@ bool nsfont_split(const plot_font_style_t *fstyle,
}
}
tx += tempx;
if ((x < tx) && (*char_offset != 0)) {
/* Reached available width, and a space was found;
* split there. */
@ -350,6 +348,7 @@ bool nsfont_split(const plot_font_style_t *fstyle,
return true;
}
tx += tempx;
utf16 = utf16next;
utf8_pos = utf8_next(string, length, utf8_pos);
}