Fix #113766: Incorrect Cursor With Offset Position #113784

Merged
Harley Acheson merged 1 commits from Harley/blender:Fix113766 into blender-v4.0-release 2023-10-16 19:17:35 +02:00
1 changed files with 1 additions and 1 deletions

View File

@ -2070,7 +2070,7 @@ static void widget_draw_text(const uiFontStyle *fstyle,
/* Find left edge of next character if available. */
int next_left_edge = 0;
bool has_next = false;
if (pos < strlen(drawstr)) {
if (pos < strlen(drawstr + but->ofs)) {
if (BLF_str_offset_to_glyph_bounds(fstyle->uifont_id, drawstr + but->ofs, pos, &bounds))
{
next_left_edge = bounds.xmin;