input: Fix selection rendering for empty lines. (#868)
<img width="491" alt="image" src="https://github.com/user-attachments/assets/b24e4fbc-40e8-4570-b254-2974aa7735a7" />
This commit is contained in:
parent
b97abd6394
commit
67dd658635
1 changed files with 3 additions and 0 deletions
|
|
@ -226,6 +226,9 @@ impl TextElement {
|
|||
end_x = line_wrap_width;
|
||||
}
|
||||
|
||||
// Ensure at least 6px width for the selection for empty lines.
|
||||
end_x = end_x.max(start.x + px(6.));
|
||||
|
||||
line_corners.push(Corners {
|
||||
top_left: line_origin + point(start.x, start.y),
|
||||
top_right: line_origin + point(end_x, start.y),
|
||||
|
|
|
|||
Loading…
Reference in a new issue