From 72a1aabafd39d2516b7b71297f7cfe63af7a0188 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 31 Mar 2025 10:47:25 +0530 Subject: [PATCH] Fix hover underline remaining on screen when screen is scrolled --- docs/changelog.rst | 5 ++++- kitty/screen.c | 7 +++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/docs/changelog.rst b/docs/changelog.rst index 59c99c3c4..0611ccc84 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -100,12 +100,15 @@ Detailed list of changes - Fix a regression in the previous release that caused rendering of emoji using the VS16 variation selector to fail with some fonts (:iss:`8495`) -- Fix a regression that caused tab bar margins to not be properly blanked when +- Fix a regression in 0.40.0 that caused tab bar margins to not be properly blanked when the tab bar is at the bottom (:iss:`8494`) - Wayland: panel kitten: Fix incorrect initial font size on compositors such as Hyprland that set scale late in the window creation process (:iss:`8496`) +- Fix a regression in 0.40.1 that caused hyperlink underline on hover to remain + on screen when the screen is scrolled + 0.41.0 [2025-03-29] ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/kitty/screen.c b/kitty/screen.c index bb35e6e54..9469e2d24 100644 --- a/kitty/screen.c +++ b/kitty/screen.c @@ -319,7 +319,9 @@ index_selection(const Screen *self, Selections *selections, bool up) { } \ INDEX_GRAPHICS(1) \ self->is_dirty = true; \ - index_selection(self, &self->selections, false); + index_selection(self, &self->selections, false); \ + clear_selection(&self->url_ranges); + static void nuke_in_line(CPUCell *cp, GPUCell *gp, index_type start, index_type x_limit, char_type ch) { @@ -1996,7 +1998,8 @@ screen_cursor_to_column(Screen *self, unsigned int column) { } \ linebuf_clear_line(self->linebuf, bottom, true); \ self->is_dirty = true; \ - index_selection(self, &self->selections, true); + index_selection(self, &self->selections, true); \ + clear_selection(&self->url_ranges); void screen_index(Screen *self) {