From 5664c3e3c99af8c27335c92365c87411189896dc Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Fri, 15 Mar 2024 20:41:10 -0700 Subject: [PATCH] core: enable link hovering --- src/Surface.zig | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/Surface.zig b/src/Surface.zig index 7ebbb364a..a5ecb3eba 100644 --- a/src/Surface.zig +++ b/src/Surface.zig @@ -2485,10 +2485,12 @@ fn linkAtPos( .semantic_prompt_boundary = false, }) orelse return null; - // TODO(paged-terminal) - if (true) return null; - - const strmap = try line.stringMap(self.alloc); + var strmap: terminal.StringMap = undefined; + self.alloc.free(try screen.selectionString(self.alloc, .{ + .sel = line, + .trim = false, + .map = &strmap, + })); defer strmap.deinit(self.alloc); // Go through each link and see if we clicked it