1
0
Fork 0

Fix #12775: Text truncated incorrectly on Windows. (#12782)

Caused by a -1 in the wrong place, which moved glyphs left one pixel.
pull/12785/head
Peter Nelson 2024-06-14 16:32:31 +01:00 committed by GitHub
parent 7b7e00123e
commit f9f07e9001
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -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;
}