mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-13 04:10:13 +00:00
textview: fix off-by-one in y_range invalidation
Previously, with selection bounds, we could have a state where a line display with selections set would eroniously stay in the cache. This aggresively releases those at the boundary cases fixing deselection drawing state.
This commit is contained in:
parent
329f7c1c40
commit
e4a00f864d
@ -681,7 +681,7 @@ gtk_text_line_display_cache_invalidate_y_range (GtkTextLineDisplayCache *cache,
|
||||
cache_y = _gtk_text_btree_find_line_top (btree, display->line, layout);
|
||||
cache_height = display->height;
|
||||
|
||||
if (cache_y + cache_height > y && cache_y < y + old_height)
|
||||
if (cache_y + cache_height >= y && cache_y <= y + old_height)
|
||||
{
|
||||
gtk_text_line_display_cache_invalidate_display (cache, display, cursors_only);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user