mirror of https://github.com/OpenTTD/OpenTTD
Fix #12775: Text truncated incorrectly on Windows.
Caused by a -1 in the wrong place, which moved glyphs left one pixel.pull/12782/head
parent
219995c643
commit
402f648a63
|
@ -479,7 +479,7 @@ UniscribeParagraphLayout::UniscribeVisualRun::UniscribeVisualRun(const Uniscribe
|
|||
int advance = x;
|
||||
for (int i = 0; i < this->num_glyphs; i++) {
|
||||
int x_advance = range.advances[i];
|
||||
this->positions.emplace_back(range.offsets[i].du + advance - 1, range.offsets[i].du + advance + x_advance, range.offsets[i].dv);
|
||||
this->positions.emplace_back(range.offsets[i].du + advance, range.offsets[i].du + advance + x_advance - 1, range.offsets[i].dv);
|
||||
|
||||
advance += x_advance;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue