@@ -412,13 +412,13 @@ static std::vector<SCRIPT_ITEM> Uniscrib
int cur_pos = 0;
for (std::vector<INT>::iterator l = vis_to_log.begin(); l != vis_to_log.end(); l++) {
std::vector<UniscribeRun>::iterator i_run = start_run + *l;
UniscribeRun run = *i_run;
/* Partial run after line break (either start or end)? Reshape run to get the first/last glyphs right. */
if (i_run == last_run - 1 && remaining_offset < (last_run - 1)->len) {
if (i_run == last_run - 1 && remaining_offset <= (last_run - 1)->len) {
run.len = remaining_offset - 1;
if (!UniscribeShapeRun(this->text_buffer, run)) return nullptr;
}
if (i_run == start_run && this->cur_range_offset > 0) {
assert(run.len - this->cur_range_offset > 0);
Status change: