mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-07-15 08:16:13 +03:00
termio: hook up OSC8
This commit is contained in:
@ -1335,12 +1335,17 @@ pub fn Stream(comptime Handler: type) type {
|
||||
},
|
||||
|
||||
.hyperlink_start => |v| {
|
||||
_ = v;
|
||||
@panic("TODO(osc8)");
|
||||
if (@hasDecl(T, "startHyperlink")) {
|
||||
try self.handler.startHyperlink(v.uri, v.id);
|
||||
return;
|
||||
} else log.warn("unimplemented OSC callback: {}", .{cmd});
|
||||
},
|
||||
|
||||
.hyperlink_end => {
|
||||
@panic("TODO(osc8)");
|
||||
if (@hasDecl(T, "endHyperlink")) {
|
||||
try self.handler.endHyperlink();
|
||||
return;
|
||||
} else log.warn("unimplemented OSC callback: {}", .{cmd});
|
||||
},
|
||||
}
|
||||
|
||||
|
@ -2358,6 +2358,14 @@ const StreamHandler = struct {
|
||||
}
|
||||
}
|
||||
|
||||
pub fn startHyperlink(self: *StreamHandler, uri: []const u8, id: ?[]const u8) !void {
|
||||
try self.terminal.screen.startHyperlink(uri, id);
|
||||
}
|
||||
|
||||
pub fn endHyperlink(self: *StreamHandler) !void {
|
||||
self.terminal.screen.endHyperlink();
|
||||
}
|
||||
|
||||
pub fn deviceAttributes(
|
||||
self: *StreamHandler,
|
||||
req: terminal.DeviceAttributeReq,
|
||||
|
Reference in New Issue
Block a user