input: Fix Input cursor x position when scrolled. (#966)
https://github.com/user-attachments/assets/db76d3a3-ecd6-45c6-8377-0afa4746f2db
This commit is contained in:
parent
de491a790c
commit
869d48b446
1 changed files with 1 additions and 1 deletions
|
|
@ -178,7 +178,7 @@ impl TextElement {
|
|||
let cursor_height = line_height;
|
||||
cursor_bounds = Some(Bounds::new(
|
||||
point(
|
||||
bounds.left() + cursor_pos.x + line_number_width,
|
||||
bounds.left() + cursor_pos.x + line_number_width + scroll_offset.x,
|
||||
bounds.top() + cursor_pos.y + ((line_height - cursor_height) / 2.),
|
||||
),
|
||||
size(CURSOR_WIDTH, cursor_height),
|
||||
|
|
|
|||
Loading…
Reference in a new issue